Patch to make it work with Python 3.10
Closed this issue · 1 comments
Musikolo commented
Hi,
I just want to share a simple patch I had to create for CherryMusic to work with Python 3.10:
diff -ruN cherrymusic-0.41.2/cherrymusicserver/configuration.py cherrymusic-0.41.2-new/cherrymusicserver/configuration.py
--- cherrymusic-0.41.2/cherrymusicserver/configuration.py 2018-02-07 15:47:12.000000000 -0600
+++ cherrymusic-0.41.2-new/cherrymusicserver/configuration.py 2022-01-22 10:57:30.000000000 -0600
@@ -38,7 +38,8 @@
import re
import weakref
-from collections import Mapping, namedtuple
+from collections.abc import Mapping
+from collections import namedtuple
from backport.collections import OrderedDict
from backport import callable
diff -ruN cherrymusic-0.41.2/tinytag/tinytag.py cherrymusic-0.41.2-new/tinytag/tinytag.py
--- cherrymusic-0.41.2/tinytag/tinytag.py 2018-02-07 15:47:12.000000000 -0600
+++ cherrymusic-0.41.2-new/tinytag/tinytag.py 2022-01-22 10:57:19.000000000 -0600
@@ -23,7 +23,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>
#
-from collections import MutableMapping
+from collections.abc import MutableMapping
import codecs
from functools import reduce
import struct
It would be great to merge it upstream code.
I hope it helps!
Thanks.
devsnd commented
Hey @Musikolo, I've merged the patch by @tilboerner and therefore this issue is resolved. The lastest version on pypi also contains this fix. Thanks for keeping CM alive <3