joestump / python-oauth2

A fully tested, abstract interface to creating OAuth clients and servers.
MIT License
2.99k stars 912 forks source link

DeprecationWarning: distutils versions classes are deprecated. #245

Open cchacholiades opened 2 years ago

cchacholiades commented 2 years ago

This warning is thrown when using oauth2==1.9.0.post1 & Django 3.2

/venv3/lib/python3.9/site-packages/oauth2/_version.py:17: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
  __version__ = distutils_Version(verstr)

Should be easy to fix:

from packaging import version
 __version__ = version(verstr)