Bug#1001483: scoop: (autopkgtest) needs update for python3.10: 'Iterable' from 'collections' is removed

2021-12-11 Thread Steve Langasek
Package: scoop
Version: 0.7.1.1-7
Followup-For: Bug #1001483
User: ubuntu-de...@lists.ubuntu.com
Usertags: origin-ubuntu jammy ubuntu-patch
Control: tags -1 patch

Please find attached a trivial patch for this bug.

-- 
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/
slanga...@ubuntu.com vor...@debian.org
diff -Nru scoop-0.7.1.1/debian/patches/python-3.10.patch 
scoop-0.7.1.1/debian/patches/python-3.10.patch
--- scoop-0.7.1.1/debian/patches/python-3.10.patch  1969-12-31 
16:00:00.0 -0800
+++ scoop-0.7.1.1/debian/patches/python-3.10.patch  2021-12-11 
10:14:53.0 -0800
@@ -0,0 +1,20 @@
+Description: Compatibility with python 3.10
+Author: Steve Langasek 
+Bug-Debian: https://bugs.debian.org/1001483
+Last-Update: 2021-12-11
+Forwarded: no
+
+Index: scoop-0.7.1.1/scoop/futures.py
+===
+--- scoop-0.7.1.1.orig/scoop/futures.py
 scoop-0.7.1.1/scoop/futures.py
+@@ -16,7 +16,8 @@
+ #
+ import os
+ from inspect import ismethod
+-from collections import namedtuple, Iterable
++from collections import namedtuple
++from collections.abc import Iterable
+ from functools import partial, reduce
+ import itertools
+ import copy
diff -Nru scoop-0.7.1.1/debian/patches/series 
scoop-0.7.1.1/debian/patches/series
--- scoop-0.7.1.1/debian/patches/series 2020-04-21 10:05:49.0 -0700
+++ scoop-0.7.1.1/debian/patches/series 2021-12-11 10:13:39.0 -0800
@@ -4,3 +4,4 @@
 sphinx.ext.pngmath.patch
 Call-wait-on-killed-child-processes.patch
 Adapt-conf.py-for-sphinx-2.0.patch
+python-3.10.patch


Bug#1001483: scoop: (autopkgtest) needs update for python3.10: 'Iterable' from 'collections' is removed

2021-12-10 Thread Paul Gevers

Source: scoop
Version: 0.7.1.1-7
Severity: serious
X-Debbugs-CC: debian...@lists.debian.org
Tags: sid bookworm
User: debian...@lists.debian.org
Usertags: needs-update
User: debian-pyt...@lists.debian.org
Usertags: python3.10
Control: affects -1 src:python3-defaults

Dear maintainer(s),

We are in the transition of adding python3.10 to the supported Python 
versions [0]. With a recent upload of python3-defaults the autopkgtest 
of scoop fails in testing when that autopkgtest is run with the binary 
packages of python3-defaults from unstable. It passes when run with only 
packages from testing. In tabular form:


   passfail
python3-defaults   from testing3.9.8-1
scoop  from testing0.7.1.1-7
all others from testingfrom testing

I copied some of the output at the bottom of this report.

Currently this regression is blocking the migration of python3-defaults 
to testing [1]. https://docs.python.org/3/whatsnew/3.10.html lists 
what's new in Python3.10, it may help to identify what needs to be 
updated. https://docs.python.org/3.9/library/collections.html says:

"""
Deprecated since version 3.3, will be removed in version 3.10: Moved 
Collections Abstract Base Classes to the collections.abc module. For 
backwards compatibility, they continue to be visible in this module 
through Python 3.9.

"""
Time to move on.

More information about this bug and the reason for filing it can be found on
https://wiki.debian.org/ContinuousIntegration/RegressionEmailInformation

Paul

[0] https://bugs.debian.org/996584
[1] https://qa.debian.org/excuses.php?package=python3-defaults

https://ci.debian.net/data/autopkgtest/testing/amd64/s/scoop/17446737/log.gz

Traceback (most recent call last):
  File 
"/tmp/autopkgtest-lxc.iso4fc4h/downtmp/autopkgtest_tmp/test/tests.py", 
line 34, in 

from scoop import futures, _control, utils, shared
  File "/usr/lib/python3/dist-packages/scoop/futures.py", line 19, in 


from collections import namedtuple, Iterable
ImportError: cannot import name 'Iterable' from 'collections' 
(/usr/lib/python3.10/collections/__init__.py)
/usr/lib/python3/dist-packages/scoop/futures.py:19: DeprecationWarning: 
Using or importing the ABCs from 'collections' instead of from 
'collections.abc' is deprecated since Python 3.3, and in 3.10 it will 
stop working

  from collections import namedtuple, Iterable
/usr/lib/python3/dist-packages/scoop/futures.py:19: DeprecationWarning: 
Using or importing the ABCs from 'collections' instead of from 
'collections.abc' is deprecated since Python 3.3, and in 3.10 it will 
stop working

  from collections import namedtuple, Iterable
./tmp/autopkgtest-lxc.iso4fc4h/downtmp/autopkgtest_tmp/test/tests.py:332: ResourceWarning: 
unclosed socket 

  scoop._control.execQueue = FutureQueue()
ResourceWarning: Enable tracemalloc to get the object allocation traceback
./tmp/autopkgtest-lxc.iso4fc4h/downtmp/autopkgtest_tmp/test/tests.py:332: ResourceWarning: 
unclosed socket 

  scoop._control.execQueue = FutureQueue()
ResourceWarning: Enable tracemalloc to get the object allocation traceback
./tmp/autopkgtest-lxc.iso4fc4h/downtmp/autopkgtest_tmp/test/tests.py:332: ResourceWarning: 
unclosed socket 

  scoop._control.execQueue = FutureQueue()
ResourceWarning: Enable tracemalloc to get the object allocation traceback
./tmp/autopkgtest-lxc.iso4fc4h/downtmp/autopkgtest_tmp/test/tests.py:332: ResourceWarning: 
unclosed socket 

  scoop._control.execQueue = FutureQueue()
ResourceWarning: Enable tracemalloc to get the object allocation traceback
./usr/lib/python3/dist-packages/scoop/futures.py:19: DeprecationWarning: 
Using or importing the ABCs from 'collections' instead of from 
'collections.abc' is deprecated since Python 3.3, and in 3.10 it will 
stop working

  from collections import namedtuple, Iterable
./tmp/autopkgtest-lxc.iso4fc4h/downtmp/autopkgtest_tmp/test/tests.py:332: ResourceWarning: 
unclosed socket 

  scoop._control.execQueue = FutureQueue()
ResourceWarning: Enable tracemalloc to get the object allocation traceback
./tmp/autopkgtest-lxc.iso4fc4h/downtmp/autopkgtest_tmp/test/tests.py:332: ResourceWarning: 
unclosed socket 

  scoop._control.execQueue = FutureQueue()
ResourceWarning: Enable tracemalloc to get the object allocation traceback
/usr/lib/python3/dist-packages/scoop/futures.py:19: DeprecationWarning: 
Using or importing the ABCs from 'collections' instead of from 
'collections.abc' is deprecated since Python 3.3, and in 3.10 it will 
stop working

  from collections import namedtuple, Iterable
../tmp/autopkgtest-lxc.iso4fc4h/downtmp/autopkgtest_tmp/test/tests.py:332: 
ResourceWarning: unclosed socket 

  scoop._control.execQueue = FutureQueue()
ResourceWarning: Enable tracemalloc to get the object allocation traceback
/usr/lib/python3/dist-packages/scoop/futures.py:19: DeprecationWarning: 
Using or importing the ABCs from 'collections' instead of from 
'collections.abc' is deprecated