Skip to content

Remove use of distutils #395

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

Merged
merged 1 commit into from
Jun 1, 2022
Merged

Conversation

stephenfin
Copy link
Contributor

@stephenfin stephenfin commented May 9, 2022

Distutils is going away in Python 3.12. Running tests on a project that uses openapi-core with Python 3.10 yields the following warning:

.../openapi_core/unmarshalling/schemas/util.py:5: DeprecationWarning:
The distutils package is deprecated and slated for removal in Python
3.12. Use setuptools or check PEP 632 for potential alternatives
  from distutils.util import strtobool

The offending API is really simple. Just vendor the code.

Fixes #390

@codecov
Copy link

codecov bot commented Jun 1, 2022

Codecov Report

Merging #395 (63a8247) into master (1627889) will increase coverage by 0.15%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master     #395      +/-   ##
==========================================
+ Coverage   95.25%   95.40%   +0.15%     
==========================================
  Files          83       83              
  Lines        1874     1873       -1     
  Branches      280      281       +1     
==========================================
+ Hits         1785     1787       +2     
+ Misses         68       67       -1     
+ Partials       21       19       -2     
Impacted Files Coverage Δ
openapi_core/unmarshalling/schemas/util.py 84.61% <ø> (+3.97%) ⬆️
openapi_core/casting/schemas/factories.py 100.00% <100.00%> (ø)
...penapi_core/unmarshalling/schemas/unmarshallers.py 92.06% <100.00%> (ø)
openapi_core/util.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1627889...63a8247. Read the comment docs.

@p1c2u p1c2u force-pushed the remove-distutils branch 2 times, most recently from 33f0058 to 0ff412d Compare June 1, 2022 04:18
Distutils is going away in Python 3.12. Running tests on a project that
uses openapi-core with Python 3.10 yields the following warning:

  .../openapi_core/unmarshalling/schemas/util.py:5: DeprecationWarning:
  The distutils package is deprecated and slated for removal in Python
  3.12. Use setuptools or check PEP 632 for potential alternatives
    from distutils.util import strtobool

The offending API is really simple. Just vendor the code.

Signed-off-by: Stephen Finucane <[email protected]>
@p1c2u p1c2u force-pushed the remove-distutils branch from 0ff412d to 63a8247 Compare June 1, 2022 04:22
@p1c2u p1c2u merged commit 178bfc7 into python-openapi:master Jun 1, 2022
@p1c2u
Copy link
Collaborator

p1c2u commented Jun 1, 2022

@stephenfin thank you for the contribution

@stephenfin stephenfin deleted the remove-distutils branch June 1, 2022 23:54
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.

DeprecationWarning on Python 3.10
2 participants