We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When generating python docs where the parameters are nested objects, their classes are not imported.
Example in the pet store docs: https://github.com/OpenAPITools/openapi-generator/blob/master/samples/client/petstore/python/docs/PetApi.md#find_pets_by_tags
In this file, Tag should be imported.
Tag
latest master branch
In the Petstore example https://github.com/OpenAPITools/openapi-generator/blob/master/samples/yaml/pet.yml, Pet has a $ref to Tag.
The text was updated successfully, but these errors were encountered:
Nested imports were fixed in #13137
For the listed case, the Tag schema is defined inline in the endpoint, and it is generated as a Schema class in the endpoint module here: https://github.com/OpenAPITools/openapi-generator/blob/master/samples/openapi3/client/petstore/python/petstore_api/paths/pet_find_by_tags/get.py#L59
And the Pet model imports the Tag model here:
openapi-generator/samples/openapi3/client/petstore/python/petstore_api/model/pet.py
Line 215 in 085e1e5
Sorry, something went wrong.
I am still seeing this with python-nextgen 6.5.0 and 6.6.0-SNAPSHOT. Is this only fixed in python?
python-nextgen
python
Yes. Python-nextgen did not exist when this ticket was created and closed. Please make a separate ticket for python-nextgen
No branches or pull requests
Bug Report Checklist
Description
When generating python docs where the parameters are nested objects, their classes are not imported.
Example in the pet store docs:
https://github.com/OpenAPITools/openapi-generator/blob/master/samples/client/petstore/python/docs/PetApi.md#find_pets_by_tags
In this file,
Tag
should be imported.openapi-generator version
latest master branch
OpenAPI declaration file content or url
In the Petstore example https://github.com/OpenAPITools/openapi-generator/blob/master/samples/yaml/pet.yml,
Pet has a $ref to Tag.
Generation Details
Steps to reproduce
Related issues/PRs
Suggest a fix
The text was updated successfully, but these errors were encountered: