Importing ABC directly from collections module was removed in Python 3.9
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
python-lesscpy (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
I believe the package is currently broken in Ubuntu 22.04 due to the python3 version (3.10). To make the package compatible with Python >=3.9 one needs a patch like this:
https:/
The upstream bug report: https:/
How to reproduce:
Download simple css file, e.g.
$ wget https:/
Then run the module on the file:
$ python3 -m lesscpy -x gistfile1.css
expected output (works for example with Ubuntu 20.04):
body{margin:
h1{font-
.someclass{
#someid{
Actual output/error:
$ python3 -m lesscpy -x gistfile1.css
Traceback (most recent call last):
File "/usr/lib/
return _run_code(code, main_globals, None,
File "/usr/lib/
exec(code, run_globals)
File "/usr/lib/
run()
File "/usr/lib/
p.parse(
File "/usr/lib/
self.result = self.parser.parse(
File "/usr/lib/
return self.parseopt_
File "/usr/lib/
p.callable(
File "/usr/lib/
p[1]
File "/usr/lib/
for n in utility.
File "/usr/lib/
if isinstance(elm, collections.
AttributeError: module 'collections' has no attribute 'Iterable'