Skip to content

DeprecationWarning on Python 3.10 #390

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

Closed
nikitagashkov opened this issue Feb 10, 2022 · 1 comment · Fixed by #395
Closed

DeprecationWarning on Python 3.10 #390

nikitagashkov opened this issue Feb 10, 2022 · 1 comment · Fixed by #395

Comments

@nikitagashkov
Copy link

nikitagashkov commented Feb 10, 2022

Hi! I've encountered a deprecation warning running on Python 3.10 complaining about using distutils:

../../../.pyenv/versions/3.10.1/envs/project/lib/python3.10/site-packages/openapi_core/unmarshalling/schemas/util.py:5
  /Users/gashkov/.pyenv/versions/3.10.1/envs/project/lib/python3.10/site-packages/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

Also, looks like there's a couple related to a new jsonschema:

  /Users/gashkov/.pyenv/versions/3.10.1/envs/project/lib/python3.10/site-packages/openapi_core/unmarshalling/schemas/unmarshallers.py:61: DeprecationWarning: Passing a schema to Validator.iter_errors is deprecated and will be removed in a future release. Call validator.evolve(schema=new_schema).iter_errors(...) instead.
    errors = tuple(errors_iter)

  /Users/gashkov/.pyenv/versions/3.10.1/envs/project/lib/python3.10/site-packages/jsonschema/validators.py:245: DeprecationWarning: Passing a schema to Validator.iter_errors is deprecated and will be removed in a future release. Call validator.evolve(schema=new_schema).iter_errors(...) instead.
    for error in self.evolve(schema=schema).iter_errors(instance):

  /Users/gashkov/.pyenv/versions/3.10.1/envs/project/lib/python3.10/site-packages/jsonschema/validators.py:276: DeprecationWarning: Passing a schema to Validator.iter_errors is deprecated and will be removed in a future release. Call validator.evolve(schema=new_schema).iter_errors(...) instead.
    error = next(self.iter_errors(instance), None)
@p1c2u
Copy link
Collaborator

p1c2u commented Jun 4, 2022

Fixed hence closing

@p1c2u p1c2u closed this as completed Jun 4, 2022
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 a pull request may close this issue.

2 participants