libgreat
libgreat copied to clipboard
build failing on newer python versions
libgreat is not compatible with newer python versions.
greatfet/libgreat/host $ python setup.py build
WARNING: The wheel package is not available.
Traceback (most recent call last):
File "/home/user/greatfet/libgreat/host/setup.py", line 24, in <module>
setup(
File "/usr/lib/python3.10/site-packages/setuptools/__init__.py", line 153, in setup
return distutils.core.setup(**attrs)
File "/usr/lib64/python3.10/distutils/core.py", line 108, in setup
_setup_distribution = dist = klass(attrs)
File "/usr/lib/python3.10/site-packages/setuptools/dist.py", line 455, in __init__
_Distribution.__init__(self, {
File "/usr/lib64/python3.10/distutils/dist.py", line 292, in __init__
self.finalize_options()
File "/usr/lib/python3.10/site-packages/setuptools/dist.py", line 807, in finalize_options
ep(self)
File "/usr/lib/python3.10/site-packages/setuptools/dist.py", line 814, in _finalize_setup_keywords
ep.load()(self, ep.name, value)
File "/home/user/greatfet/libgreat/host/.eggs/even_better_setuptools_git_version-1.0.7-py3.10.egg/even_better_setuptools_git_version.py", line 83, in validate_version_config
if not isinstance(config, collections.Mapping):
AttributeError: module 'collections' has no attribute 'Mapping'
$ python -V
Python 3.10.0
$ cat /etc/fedora-release
Fedora release 35 (Thirty Five)
it seems to be the change mentioned here:
Deprecated since version 3.3, will be removed in version 3.10: Moved Collections Abstract Base Classes to the collections.abc module.
googling for "python collections.Mapping removed" finds various other projects dealing with the issue, so probably a backwards-compatible way to change this can be found in one of them.
This appears to be a bug in ktemkin/even-better-setuptools-git-version which is used to setup/build libgreat.
FWIW, patching collections.Mapping
to collections.abc.Mapping
in the unpacked egg during the build at least unblocks me, but even-better-setup-tools-git-version seems like a bit of a hot potato perhaps. Or maybe I should view the chain of forks as testament to open source perseverance :smiley:
Fixed in https://github.com/greatscottgadgets/libgreat/pull/32