Fix add_suggested_values_to_schema when the schema has sections (#149718)

Co-authored-by: Erik Montnemery <erik@montnemery.com>
This commit is contained in:
karwosts
2025-07-31 11:50:26 -07:00
committed by GitHub
parent bbc1466cfc
commit aa6b37bc7c
2 changed files with 27 additions and 12 deletions

View File

@@ -676,9 +676,10 @@ class FlowHandler(Generic[_FlowContextT, _FlowResultT, _HandlerT]):
and key in suggested_values
):
new_section_key = copy.copy(key)
schema[new_section_key] = val
val.schema = self.add_suggested_values_to_schema(
val.schema, suggested_values[key]
new_val = copy.copy(val)
schema[new_section_key] = new_val
new_val.schema = self.add_suggested_values_to_schema(
new_val.schema, suggested_values[key]
)
continue