You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This defines the model in openapi.json as components/schemas/TestModel.__pydantic_model__.
Finally, this leads to openapi-generator-cli outputing a model name as "TestModelPydanticModel".
Expected behavior
The model name in openapi.json should be components/schemas/TestModel not components/schemas/TestModel.__pydantic_model__.
Environment
ODMantic version: 0.9.2
MongoDB version: N/A
Pydantic infos (output of python -c "import pydantic.utils; print(pydantic.utils.version_info())):
Bug
Odmantic model names in openapi.json from FastAPI have
.__pydantic_model__
suffix.Current Behavior
.__pydantic_model__
as a suffixFor example:
This defines the model in openapi.json as
components/schemas/TestModel.__pydantic_model__
.Finally, this leads to openapi-generator-cli outputing a model name as "TestModelPydanticModel".
Expected behavior
The model name in openapi.json should be
components/schemas/TestModel
notcomponents/schemas/TestModel.__pydantic_model__
.Environment
python -c "import pydantic.utils; print(pydantic.utils.version_info())
):Using https://hub.docker.com/layers/openapitools/openapi-generator-cli/v6.6.0/images/sha256-54381220aecf2e77bb4b6694c4e1a03e733b49453292cd1af6f48b510f1f008a?context=explore
Using openapi-generator-cli from docker to generate typescript bindings as follows:
The text was updated successfully, but these errors were encountered: