chore: upgrade openapi-generator to v7.10.0#40
Conversation
| if 'Accept' not in _header_params: | ||
| _header_params['Accept'] = self.api_client.select_header_accept( | ||
| [ | ||
| 'application/json' | ||
| ] | ||
| ) |
There was a problem hiding this comment.
Changes like these in the API classes are a result of OpenAPITools/openapi-generator#19025, which enables overriding the Accept header
| access_point_dict = access_point_instance.to_dict() | ||
| # create an instance of AccessPoint from a dict | ||
| access_point_form_dict = access_point.from_dict(access_point_dict) | ||
| access_point_from_dict = AccessPoint.from_dict(access_point_dict) |
There was a problem hiding this comment.
These changes in the docs are a result of OpenAPITools/openapi-generator#18359, which fixes invalid code samples in docs.
| * `COLO` (value: `'COLO'`) | ||
|
|
||
| * `VD` (value: `'VD'`) | ||
|
|
||
| * `NETWORK` (value: `'NETWORK'`) |
There was a problem hiding this comment.
These kinds of changes are a result of OpenAPITools/openapi-generator#18804, which includes supported enum values in the docs for enum models
| for _item_data in self.data: | ||
| if _item_data: | ||
| _items.append(_item_data.to_dict()) |
There was a problem hiding this comment.
These sorts of changes are a result of OpenAPITools/openapi-generator#19223, which fixes a potential bug when models contain multiple list attributes with different element types.
| _files: Dict[ | ||
| str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] | ||
| ] = {} |
There was a problem hiding this comment.
These changes add support for multiple file parameters; I suspect this isn't relevant to us but it should be backwards-compatible anyway since the str type is still a member of the updated union type. OpenAPITools/openapi-generator#19329
| 'bool': bool, | ||
| 'date': datetime.date, | ||
| 'datetime': datetime.datetime, | ||
| 'decimal': decimal.Decimal, |
There was a problem hiding this comment.
Decimal support added in OpenAPITools/openapi-generator#19203
| encoding = match.group(1) if match else "utf-8" | ||
| response_text = response_data.data.decode(encoding) | ||
| return_data = self.deserialize(response_text, response_type) | ||
| return_data = self.deserialize(response_text, response_type, content_type) |
There was a problem hiding this comment.
Fix for issues with deserialization not matching the specified content type: OpenAPITools/openapi-generator#18800
| """Builds a JSON POST object. | ||
|
|
||
| If obj is None, return None. | ||
| If obj is SecretStr, return obj.get_secret_value() |
There was a problem hiding this comment.
Fix for handling credentials & other sensitive strings, which would previously crash: OpenAPITools/openapi-generator#18023
| _default: ClassVar[Optional[Self]] = None | ||
|
|
||
| def __init__( | ||
| self, | ||
| host: Optional[str]=None, | ||
| api_key: Optional[Dict[str, str]]=None, | ||
| api_key_prefix: Optional[Dict[str, str]]=None, | ||
| username: Optional[str]=None, | ||
| password: Optional[str]=None, | ||
| access_token: Optional[str]=None, | ||
| server_index: Optional[int]=None, | ||
| server_variables: Optional[ServerVariablesT]=None, | ||
| server_operation_index: Optional[Dict[int, int]]=None, | ||
| server_operation_variables: Optional[Dict[int, ServerVariablesT]]=None, | ||
| ignore_operation_servers: bool=False, | ||
| ssl_ca_cert: Optional[str]=None, | ||
| retries: Optional[int] = None, | ||
| *, | ||
| debug: Optional[bool] = None, | ||
| ) -> None: |
There was a problem hiding this comment.
Stronger typing for Python configuration class: OpenAPITools/openapi-generator#20014
| @@ -40,7 +40,7 @@ class CloudRouterActionsSearchFilter(BaseModel): | |||
| actual_instance: Optional[Union[CloudRouterActionsSearchExpression, CloudRouterActionsSearchOrFilter]] = None | |||
| else: | |||
| actual_instance: Any = None | |||
| any_of_schemas: List[str] = Field(default=Literal["CloudRouterActionsSearchExpression", "CloudRouterActionsSearchOrFilter"]) | |||
| any_of_schemas: Set[str] = { "CloudRouterActionsSearchExpression", "CloudRouterActionsSearchOrFilter" } | |||
There was a problem hiding this comment.
Addressing Pydantic warnings when serializing complex models: OpenAPITools/openapi-generator#17941
|
Ansible collection E2E tests passing with this generator upgrade: https://github.com/equinix/ansible-collection-equinix/actions/runs/12912927895/job/36008933210 |
|
This PR is included in version 0.8.0 🎉 |
No description provided.