Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.
Bug 1871992
Summary: | Possible regression between Python 3.9.0b5 and rc1: SystemError: <built-in function compile> returned NULL without setting an error | ||||||
---|---|---|---|---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Miro Hrončok <mhroncok> | ||||
Component: | python3.9 | Assignee: | Victor Stinner <vstinner> | ||||
Status: | CLOSED ERRATA | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||
Severity: | unspecified | Docs Contact: | |||||
Priority: | unspecified | ||||||
Version: | rawhide | CC: | cstratak, mhroncok, pstodulk, pviktori, python-sig, thrnciar, torsava, vstinner | ||||
Target Milestone: | --- | ||||||
Target Release: | --- | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Whiteboard: | |||||||
Fixed In Version: | python3.9-3.9.0~rc2-1.fc33 | Doc Type: | If docs needed, set a value | ||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2020-09-26 00:14:44 UTC | Type: | Bug | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Attachments: |
|
Description
Miro Hrončok
2020-08-24 19:38:58 UTC
I can reproduce on Fedora 32 outside of mock: $ fedpkg clone mercurial $ cd mercurial $ fedpkg prep $ cd mercurial-5.4 $ cp -a hg hg3 $ PYTHON=/usr/bin/python3.9 make all /usr/bin/python3.9 setup.py build running build running build_mo running build_py running build_ext running build_scripts make -C doc make[1]: Entering directory '/home/churchyard/rpmbuild/fedora-scm/mercurial/mercurial-5.4/doc' /usr/bin/python3.9 gendoc.py "hgrc.5" > hgrc.5.txt.tmp Traceback (most recent call last): File "/home/churchyard/rpmbuild/fedora-scm/mercurial/mercurial-5.4/doc/gendoc.py", line 39, in <module> from mercurial.i18n import ( File "/usr/lib64/python3.9/importlib/util.py", line 245, in __getattribute__ self.__spec__.loader.exec_module(self) SystemError: <built-in function compile> returned NULL without setting an error This will make ti much easier to bisect, but I won't get to it today. > but I won't get to it today. Couldn't resist. Git bisect says it is: https://github.com/python/cpython/commit/d2bea2636d5f0c2b196966315790af8e79c7bf82 Victor, please make a look. Just leeting know that the same issue happens on F33 as well. I reported the issue upstream: https://bugs.python.org/issue41631 It's a Python 3.9 regression. I understand that only projects which monkey-patch the __import__() function, like Mercurial, are impacted. Note that __import__'s docs do mention that it can be replaced: https://docs.python.org/3/library/functions.html#__import__ Since Python 3.3, doing so is strongly discouraged, but nevertheless it should be possible. Created attachment 1713421 [details]
Workaround for FTBFS on Python 3.9
I was able to build with this one-line patch.
I'm not sure whether to call this a workaround or a fix -- that depends on how the CPython issue is solved.
Thanks Petr! We will try it. Sorry; I meant to post that comment on the Mercurial bug. Here's a PR for mercurial dist-git: https://src.fedoraproject.org/rpms/mercurial/pull-request/12 FEDORA-2020-bc1902e34e has been submitted as an update to Fedora 33. https://bodhi.fedoraproject.org/updates/FEDORA-2020-bc1902e34e FEDORA-2020-bc1902e34e has been pushed to the Fedora 33 testing repository. In short time you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2020-bc1902e34e` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2020-bc1902e34e See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates. Hello Petr, Could you offer this patch to Mercurial upstream? Possibly with a link to https://bugs.python.org/issue41631 instead of Bugzilla. I'm growing more and more convinced that the patch is the right way to go for Mercurial, and I'd like to hear their opinion. But I'm not very familiar with their bug-reporting process. Hi Petr, thanks for reminder. Reported: https://bz.mercurial-scm.org/show_bug.cgi?id=6407 This is fixed in Python 3.9.0rc2 (to be released this week). FEDORA-2020-78bb031321 has been submitted as an update to Fedora 33. https://bodhi.fedoraproject.org/updates/FEDORA-2020-78bb031321 FEDORA-2020-bc1902e34e has been pushed to the Fedora 33 stable repository. If problem still persists, please make note of it in this bug report. FEDORA-2020-78bb031321 has been pushed to the Fedora 33 stable repository. If problem still persists, please make note of it in this bug report. |