[Bug 1218143] New: python2-pycairo is blocking update python-rpm-macros
https://bugzilla.suse.com/show_bug.cgi?id=1218143 Bug ID: 1218143 Summary: python2-pycairo is blocking update python-rpm-macros Classification: openSUSE Product: openSUSE Tumbleweed Version: Current Hardware: Other OS: Other Status: NEW Severity: Normal Priority: P5 - None Component: Python Assignee: python-maintainers@suse.com Reporter: ana.guerrero@suse.com QA Contact: qa-bugs@suse.de Target Milestone: --- Found By: --- Blocker: --- Created attachment 871412 --> https://bugzilla.suse.com/attachment.cgi?id=871412&action=edit python2-pycairo_log.txt python-rpm-macros 20231204.dd64e74 (SR#1130671) is blocked by python2-pycairo failing to build. Most relevant part of the build log (attached): [ 12s] + xargs -0 /usr/bin/python2 -c ' [ 12s] import sys, py_compile [ 12s] for f in sys.argv[1:]: [ 12s] fp=f[len("/home/abuild/rpmbuild/BUILDROOT/python2-pycairo-1.18.1-6.20.x86_64"):] [ 12s] print(f"Generating cached byte-code for {fp}") [ 12s] for o in [0, 1]: [ 12s] py_compile.compile(f, dfile=fp, optimize=o) [ 12s] ' [ 12s] File "<string>", line 5 [ 12s] print(f"Generating cached byte-code for {fp}") [ 12s] ^ [ 12s] SyntaxError: invalid syntax [ 12s] error: Bad exit status from /var/tmp/rpm-tmp.LYEGW2 (%install) This seems to be using f-strings in python2.7 where they are not yet supported. The last update of python2-pycairo is from March 2020, so I'm wondering if this package is still maintained by upsteam. However, gimp, python-gobject2, python-gtk have a direct dependency on this package. -- You are receiving this mail because: You are on the CC list for the bug.
https://bugzilla.suse.com/show_bug.cgi?id=1218143 https://bugzilla.suse.com/show_bug.cgi?id=1218143#c2 --- Comment #2 from Ana Guerrero <ana.guerrero@suse.com> --- Looks like it needs further fixing: [ 13s] + find /home/abuild/rpmbuild/BUILDROOT/python2-pycairo-1.18.1-6.57.x86_64/usr/lib64/python2.7/site-packages -iname '*.pyc' -delete [ 13s] + find /home/abuild/rpmbuild/BUILDROOT/python2-pycairo-1.18.1-6.57.x86_64/usr/lib64/python2.7/site-packages -iname '*.py' -print0 [ 13s] + xargs -0 /usr/bin/python2 -c ' [ 13s] import sys, py_compile [ 13s] for f in sys.argv[1:]: [ 13s] fp=f[len("/home/abuild/rpmbuild/BUILDROOT/python2-pycairo-1.18.1-6.57.x86_64"):] [ 13s] print("Generating cached byte-code for " + str(fp)) [ 13s] for o in [0, 1]: [ 13s] py_compile.compile(f, dfile=fp, optimize=o) [ 13s] ' [ 13s] Generating cached byte-code for /usr/lib64/python2.7/site-packages/cairo/__init__.py [ 13s] Traceback (most recent call last): [ 13s] File "<string>", line 7, in <module> [ 13s] TypeError: compile() got an unexpected keyword argument 'optimize' [ 13s] error: Bad exit status from /var/tmp/rpm-tmp.JyEZik (%install) [ 13s] -- You are receiving this mail because: You are on the CC list for the bug.
https://bugzilla.suse.com/show_bug.cgi?id=1218143 https://bugzilla.suse.com/show_bug.cgi?id=1218143#c12 Dominique Leuenberger <dimstar@opensuse.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |dimstar@opensuse.org Status|IN_PROGRESS |RESOLVED Resolution|--- |FIXED Flags|needinfo? | --- Comment #12 from Dominique Leuenberger <dimstar@opensuse.org> --- (In reply to Markéta Machová from comment #1)
This code actually comes from python-rpm-macros, where it was already fixed upstream: https://github.com/openSUSE/python-rpm-macros/pull/167.
pytho2-pycairo is by name the python2 compatible version of python-pycairo, which is alive. At the time it was probably a good decision to fork it. Wow, I didn't know we have so many python2-only packages still in our distro, even gimp. Maybe we could take a look whether they still need python2 and modernize them at some point.
py2 drop tracked at https://bugzilla.opensuse.org/show_bug.cgi?id=1219306 As for this bug, as far as I can see: nothing left. the python-rpm-macros have been fixed to not break py2 packages, -- You are receiving this mail because: You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@suse.com