Skip to content

Python-exp clean up model classnames#7054

Merged
spacether merged 2 commits intoOpenAPITools:masterfrom
spacether:python_exp_clean_up_model_classnames
Jul 28, 2020
Merged

Python-exp clean up model classnames#7054
spacether merged 2 commits intoOpenAPITools:masterfrom
spacether:python_exp_clean_up_model_classnames

Conversation

@spacether
Copy link
Copy Markdown
Contributor

@spacether spacether commented Jul 27, 2020

Removes ~200 lines of code handling model naming from the python experimental java codegen file
Adds a lazy_import function in the python models to only load in imports lazily when they are needed
Tests updated

If merged, this will resolve #6988

  • Read the contribution guidelines.
  • If contributing template-only or documentation-only changes which will change sample output, build the project beforehand.
  • Run the shell script ./bin/generate-samples.shto update all Petstore samples related to your fix. This is important, as CI jobs will verify all generator outputs of your HEAD commit as it would merge with master. These must match the expectations made by your contribution. You may regenerate an individual generator by passing the relevant config(s) as an argument to the script, for example ./bin/generate-samples.sh bin/configs/java*. For Windows users, please run the script in Git BASH.
  • File the PR against the correct branch: master
  • Copy the technical committee to review the pull request if your PR is targeting a particular programming language.

Python Technical Committee:
@taxpon (2017/07) @frol (2017/07) @mbohlool (2017/07) @cbornet (2017/09) @kenjones-cisco (2017/11) @tomplus (2018/10) @Jyhess (2019/01) @arun-nalla (2019/11) @spacether (2019/11)
@sebastien-rosset

@spacether spacether added this to the 5.0.0 milestone Jul 27, 2020
@spacether spacether force-pushed the python_exp_clean_up_model_classnames branch from 112da85 to 6eca1a3 Compare July 27, 2020 03:27
…l removal of getPythonClassName call sites

Fixes PythonClientExperimentalTest.java

Python-exp smaples regeneration

Revers makefile

Reverst pom.xml

Fixes model imports in models.__init__

Updates docstring, omits lazy import in additional properties if we dont need it

Improves additional_properties_type assignment if None

Removes getPythonClassName

Fixes python-exp tests
@spacether spacether force-pushed the python_exp_clean_up_model_classnames branch from 6eca1a3 to 538fb0e Compare July 27, 2020 03:28
@spacether spacether merged commit ee0686e into OpenAPITools:master Jul 28, 2020
@spacether spacether deleted the python_exp_clean_up_model_classnames branch July 28, 2020 01:35
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.

[python-experimental] remove model module names from model names

1 participant