Skip to content

Commit 90c2ab2

Browse files
authored
[Gemini] Fix bad-unpacking pyrefly error (#37828)
* Fix bad-unpacking pyrefly error * formatting * gemini suggestion
1 parent 41b513e commit 90c2ab2

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

sdks/python/apache_beam/yaml/yaml_ml.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -487,9 +487,10 @@ def fn(x: PredictionResult):
487487
model_handler_provider._postprocess_fn_internal()),
488488
inference_args=inference_args)
489489
| beam.Map(
490-
lambda row: beam.Row(**{
491-
inference_tag: row[1], **row[0]._asdict()
492-
})).with_output_types(schema))
490+
lambda row: beam.Row(
491+
**{
492+
**row[0]._asdict(), str(inference_tag): row[1]
493+
})).with_output_types(schema))
493494

494495

495496
def _config_to_obj(spec):

sdks/python/pyrefly.toml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,5 +58,4 @@ bad-context-manager = "ignore"
5858
invalid-yield = "ignore"
5959
bad-argument-count = "ignore"
6060
bad-typed-dict-key = "ignore"
61-
no-access = "ignore"
62-
bad-unpacking = "ignore"
61+
no-access = "ignore"

0 commit comments

Comments
 (0)