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

Add support for python #41

Merged
merged 11 commits into from
May 1, 2020
Merged

Conversation

fullcircle23
Copy link
Contributor

@fullcircle23 fullcircle23 commented Apr 30, 2020

This PR includes the following:

  • Generate the openapi3 library including test files* for python.
  • Update travis (Required quite a bit of trial and error to automate the build on TravisCI's Trusty Ubuntu 14.04 build):
    • install python 3.5 as the base
    • install python 3.6.3 environment on pyenv for the build.
    • upgrade pip version.
  • Build the python library.
  • Automate the publish/release of the python artifact to PyPI/TestPyPI.

The pytest command to test the openapi3 generated python test files is commented out as the test files are very buggy. I've spent almost as much time to try to debug and patch but it was getting too uphill a battle and did not make sense to hold of this PR when the issues seem mainly in the openapi-generator.

A sample of the kinds of errors (not exhaustive) found by pytest in the openapi-generated python test files:

  1. Syntax errors
  2. Value error
    • e.g. Invalid value for signature, must not be None
  3. Attribute errors
    • e.g. module 'symbol_openapi_client.models' has no attribute 'target_id'

With the exception of the first issue for which the fix is quite straightforward, the other 2 types (at least) of issues seem to be related to the following:

  • known issues with anyOf / allOf
  • $ref parameters seem not resolved when they are deep

This PR supersedes PR #27
If merged, this PR closes #26 and #28

fullcircle23 and others added 11 commits February 27, 2020 18:05
Add support for Python symbol#26

Add support for Python symbol#26
Add python dependencies in .travis.yml

Add python dependencies in .travis.yml

Add python dependencies in .travis.yml

Add python dependencies in .travis.yml

Add python dependencies in .travis.yml

Add python dependencies in .travis.yml

Add python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies in .travis.yml

Fix python dependencies

Fix python dependencies

Fix python dependencies

Fix python dependencies

Fix python dependencies

Fix python dependencies

Fix python dependencies

Fix python dependencies

Fix python dependencies

Fix python dependencies

Fix python dependencies

Fix python dependencies

Fix python dependencies

Test openapi3 fix

Test openapi3 fix

List openapi3 string value errors

pyenv global 3.6.3

Cleanup

test workaround for invalid syntax errors

workaround for invalid syntax errors

workaround for invalid syntax errors

patch invalid string values in openapi3.yml

update patch script

update patch script to fix invalid string examples

temp set pytest maxfail to 100

enable git_push

enable git_push

Fix travis git_push

Script to enclose strings having single quotes with double quotes

Fix bug in script to enclose value with double-quotes

Change after_install to before_script in travis yml

add debug info in travis yml

pyenv install 3.7.7

pyenv install --list

pyenv install 3.7-dev

pyenv install 3.7.0a1

revert to pyenv global 3.6.3

Remove redundant pip install pytest pyyaml; add grep to debug

fix bug

Put back pip install pytest pyyaml

Add pyenv --version

Disabled pytest

Typo

Minor improvement

Add support for python symbol#26
@fullcircle23 fullcircle23 requested review from fboucquez and rg911 April 30, 2020 10:18
@rg911 rg911 merged commit 0e15545 into symbol:master May 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Py] Add support for Python
2 participants