Skip to content
New issue

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

Fix inconsistency between model name and file name in python client #7684

Merged
merged 1 commit into from
Feb 22, 2018
Merged

Fix inconsistency between model name and file name in python client #7684

merged 1 commit into from
Feb 22, 2018

Conversation

banh-gao
Copy link
Contributor

Fixes issue #7357 using the same fix as #4958

PR checklist

  • Read the contribution guidelines.
  • Ran the shell script under ./bin/ to update Petstore sample so that CIs can verify the change. (For instance, only need to run ./bin/{LANG}-petstore.sh and ./bin/security/{LANG}-petstore.sh if updating the {LANG} (e.g. php, ruby, python, etc) code generator or {LANG} client's mustache templates). Windows batch files can be found in .\bin\windows\.
  • Filed the PR against the correct branch: 3.0.0 branch for changes related to OpenAPI spec 3.0. Default: master.

Description of the PR

Fixes modules filename generation for the python client. Issue reported in #7357 and #4684.
The fix applied to python client generator is the same as the one applied to the Flask server in #4958.

@wing328
Copy link
Contributor

wing328 commented Feb 22, 2018

@banh-gao tests (with updated samples) passed via https://travis-ci.org/swagger-api/swagger-codegen/builds/344730950

Next time, please update the Python Petstore samples by running the shell scripts or batch files under ./bin/ or .\bin\windows\

@wing328 wing328 added this to the v2.4.0 milestone Feb 22, 2018
@wing328 wing328 merged commit b39c35c into swagger-api:master Feb 22, 2018
@wing328
Copy link
Contributor

wing328 commented Feb 22, 2018

Python petstore samples updated via b4827be

@bedge
Copy link

bedge commented May 9, 2018

This bug is present in STABLE, 2.3.1:

❯ swagger-codegen version
2.3.1

~/git/apis/bindings/bindings/models/init.py in ()
21 from bindings.models.http_endpoint import HTTPEndpoint
22 from bindings.models.map_context_root import MapContextRoot
---> 23 from bindings.models.model_property import ModelProperty
24 from bindings.models.module import Module
25 from bindings.models.node import Node

~/git/apis/bindings/bindings/models/model_property.py in ()
16 import six
17
---> 18 from bindings.models.object import Object # noqa: F401,E501

3.0.0 claims no python code generators:

https://github.com/swagger-api/swagger-codegen/releases:

java and inflector are the only supported languages.

Is there a functional tag one can use for python in the interim?

@samohant
Copy link

samohant commented May 7, 2019

Module not found for 'swagger_client.model.errorunknown' in swagger_client python

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants