pyroma icon indicating copy to clipboard operation
pyroma copied to clipboard

Incompatible with Python 3.12

Open mweinelt opened this issue 1 year ago • 0 comments

We are moving towards Python 3.12 over in nixpkgs, and noticed this package relies somewhat heavily on distutils, which has been deprecated since 3.10, see https://peps.python.org/pep-0632/.

Now I see that master recently started testing against 3.12, but I don't understand how that succeeds. For me, it fails like this on 4.2:

 ======================================================================
 ERROR: pyroma (unittest.loader._FailedTest.pyroma)
 ----------------------------------------------------------------------
 ImportError: Failed to import test module: pyroma
 Traceback (most recent call last):
   File "/nix/store/ly93xq4pckid6ykivk07ln04bgjf41hv-python3-3.12.0/lib/python3.12/unittest/loader.py", line 129, in loadTestsFromName
     module = __import__(module_name)
              ^^^^^^^^^^^^^^^^^^^^^^^
   File "/build/source/pyroma/__init__.py", line 4, in <module>
     from pyroma import projectdata, distributiondata, pypidata, ratings
   File "/build/source/pyroma/projectdata.py", line 8, in <module>
     from distutils import core
 ModuleNotFoundError: No module named 'distutils'

mweinelt avatar Dec 04 '23 16:12 mweinelt