File tree Expand file tree Collapse file tree 1 file changed +0
-33
lines changed
aws_lambda_powertools/event_handler/openapi Expand file tree Collapse file tree 1 file changed +0
-33
lines changed Original file line number Diff line number Diff line change @@ -364,39 +364,6 @@ def expand_pydantic_model_for_openapi(param_field: ModelField) -> list[ModelFiel
364364 return expanded_fields
365365
366366
367- def get_flat_params_with_pydantic_expansion (dependant : Dependant ) -> list [ModelField ]:
368- """
369- Get a list of all parameters from a Dependant object, expanding Pydantic models into individual fields.
370- This is used specifically for OpenAPI schema generation.
371-
372- Parameters
373- ----------
374- dependant : Dependant
375- The Dependant object containing the parameters.
376-
377- Returns
378- -------
379- list[ModelField]
380- A list of ModelField objects with Pydantic models expanded into individual fields.
381- """
382- flat_dependant = get_flat_dependant (dependant )
383- all_params = (
384- flat_dependant .path_params
385- + flat_dependant .query_params
386- + flat_dependant .header_params
387- + flat_dependant .cookie_params
388- )
389-
390- expanded_params = []
391-
392- for param in all_params :
393- # Expand Pydantic models into individual fields
394- expanded_fields = expand_pydantic_model_for_openapi (param )
395- expanded_params .extend (expanded_fields )
396-
397- return expanded_params
398-
399-
400367def get_body_field (* , dependant : Dependant , name : str ) -> ModelField | None :
401368 """
402369 Get the Body field for a given Dependant object.
You can’t perform that action at this time.
0 commit comments