[Python-modules-team] Bug#1001289: colorclass: needs update for python3.10: 'Mapping' from 'collections' is removed

Steve Langasek steve.langasek at canonical.com
Fri Dec 10 20:11:09 GMT 2021


Package: colorclass
Followup-For: Bug #1001289
User: ubuntu-devel at lists.ubuntu.com
Usertags: origin-ubuntu jammy ubuntu-patch
Control: tags -1 patch

Please find attached a trivial patch for this issue.

-- 
Steve Langasek                   Give me a lever long enough and a Free OS
Debian Developer                   to set it on, and I can move the world.
Ubuntu Developer                                   https://www.debian.org/
slangasek at ubuntu.com                                     vorlon at debian.org
-------------- next part --------------
diff -Nru colorclass-2.2.0/debian/patches/python-3.10.patch colorclass-2.2.0/debian/patches/python-3.10.patch
--- colorclass-2.2.0/debian/patches/python-3.10.patch	1969-12-31 16:00:00.000000000 -0800
+++ colorclass-2.2.0/debian/patches/python-3.10.patch	2021-12-10 12:09:15.000000000 -0800
@@ -0,0 +1,19 @@
+Description: compatibility with python 3.10
+Author: Steve Langasek <steve.langasek at ubuntu.com>
+Bug-Debian: https://bugs.debian.org/1001289
+Last-Update: 2021-12-10
+Forwarded: no
+
+Index: colorclass-2.2.0/colorclass/codes.py
+===================================================================
+--- colorclass-2.2.0.orig/colorclass/codes.py
++++ colorclass-2.2.0/colorclass/codes.py
+@@ -1,7 +1,7 @@
+ """Handles mapping between color names and ANSI codes and determining auto color codes."""
+ 
+ import sys
+-from collections import Mapping
++from collections.abc import Mapping
+ 
+ BASE_CODES = {
+     '/all': 0, 'b': 1, 'f': 2, 'i': 3, 'u': 4, 'flash': 5, 'outline': 6, 'negative': 7, 'invis': 8, 'strike': 9,
diff -Nru colorclass-2.2.0/debian/patches/series colorclass-2.2.0/debian/patches/series
--- colorclass-2.2.0/debian/patches/series	1969-12-31 16:00:00.000000000 -0800
+++ colorclass-2.2.0/debian/patches/series	2021-12-10 12:08:28.000000000 -0800
@@ -0,0 +1 @@
+python-3.10.patch


More information about the Python-modules-team mailing list