tpircher-zz / pycrc

Free, easy to use Cyclic Redundancy Check (CRC) calculator and source code generator
https://pycrc.org
MIT License
169 stars 36 forks source link

broken on python 3.10 ? #46

Open fenugrec opened 2 years ago

fenugrec commented 2 years ago
Traceback (most recent call last):
  File "/usr/bin/pycrc", line 26, in <module>
    from pycrc.main import main
  File "/usr/lib/python3.10/site-packages/pycrc/main.py", line 46, in <module>
    import pycrc.codegen as cg
  File "/usr/lib/python3.10/site-packages/pycrc/codegen.py", line 37, in <module>
    import pycrc.symtable
  File "/usr/lib/python3.10/site-packages/pycrc/symtable.py", line 49, in <module>
    class SymbolTable(collections.MutableMapping):
AttributeError: module 'collections' has no attribute 'MutableMapping'

Looks like collections.MutableMapping was deprecated at some point ?

fenugrec commented 2 years ago

Possible fix (I don't actually know what I'm doing) : two lines to change,

from collections.abc import MutableMapping
.....
class SymbolTable(MutableMapping):
tpircher commented 2 years ago

Sorry for the late answer; I have been locked out from github, and had to create a new account. The fix should be in https://github.com/tpircher/pycrc