Open caojieliyu opened 4 months ago
can you try python
client generator as well to see if the same issue occurs?
can you also share a spec to reproduce the issue?
paths:
/aaa:
get:
responses:
"2XX":
description: OK
Defining the schema in this way will work, but I am not sure if this is the syntax defined by OpenAPI. Non-explicit parsing should not be done because type safety will not be ensured.
Bug Report Checklist
Description
The response_types_map does not include responses starting with string types '1XX' and '2XX', so this syntax cannot achieve the desired effect: response_type = response_types_map.get(str(response_data.status)[0] + "XX", None).
api_client.py Lines of code
231 response_type = response_types_map.get(str(response_data.status)[0] + "XX", None)
eg:
response_data.status= 200
response_types_map ={'201':'AAAResponse}
response_type =None --> return_data =None
openapi-generator version
7.3.0
OpenAPI declaration file content or url
Generation Details
Steps to reproduce
Related issues/PRs
Suggest a fix