jbweston / miniver

Like Versioneer, but smaller
Creative Commons Zero v1.0 Universal
53 stars 10 forks source link

Do not import from distutils #24

Closed slavoutich closed 4 years ago

slavoutich commented 4 years ago

According to the comment [1], we are adviced to use functions wrapped by setuptools instead of distutils' raw ones.

Related problem is that setuptools-49.2.0 started to raise a warning, if it sees that distutils is imported already. This maybe mitigates this warning (if nothing imports distutils before

from ._version import __version__

is called.

[1] https://github.com/pypa/setuptools/issues/2261#issuecomment-658315975