Bug 2050093
Summary: | python-simplewrap fails to build with Python 3.11: TypeError: 'float' object cannot be interpreted as an integer | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Tomáš Hrnčiar <thrnciar> |
Component: | python-simplewrap | Assignee: | Igor Raits <igor.raits> |
Status: | CLOSED RAWHIDE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
Severity: | unspecified | Docs Contact: | |
Priority: | unspecified | ||
Version: | 36 | CC: | code, igor.raits, mhroncok, neuro-sig, thrnciar |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2022-04-12 14:24:17 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: | |||
Bug Depends On: | |||
Bug Blocks: | 2016048 |
Description
Tomáš Hrnčiar
2022-02-03 08:56:48 UTC
$ python3.10 >>> import random >>> random.randint(1, 1e6) $ python3.11 >>> import random >>> random.randint(1, 1e6) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/lib64/python3.11/random.py", line 330, in randint return self.randrange(a, b+1) ^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.11/random.py", line 306, in randrange istop = _index(stop) ^^^^^^^^^^^^ TypeError: 'float' object cannot be interpreted as an integer https://bugs.python.org/issue42222 https://github.com/python/cpython/commit/5afa0a411243210a30526c7459a0ccff5cb88494 randrange: Remove deprecated support for non-integer values The randint/randrange change in Python violates Python's own policy for incompatible changes. I've asked the maintainer to revert it: https://bugs.python.org/issue46624 This bug appears to have been reported against 'rawhide' during the Fedora 36 development cycle. Changing version to 36. Looking at the COPR[1], it seems like there was finally a successful build[2], but now there is a new problem: > <frozen importlib._bootstrap>:241: RuntimeWarning: builtins.type size changed, may indicate binary incompatibility. Expected 896 from C header, got 904 from PyObject > /var/tmp/rpm-tmp.QKo0J6: line 43: 499 Segmentation fault (core dumped) /usr/bin/python3 setup.py test [1] https://copr.fedorainfracloud.org/coprs/g/python/python3.11/package/python-simplewrap/ [2] https://copr.fedorainfracloud.org/coprs/g/python/python3.11/build/3846738/ That is a transient issue. A new pre-release version of Python 3.11 has landed in our copr out and until every extension module in the dependency tree has been rebuilt with the new one, this can happen. In this case, this is probably caused by numpy. (In reply to Miro Hrončok from comment #6) > That is a transient issue. A new pre-release version of Python 3.11 has > landed in our copr out and until every extension module in the dependency > tree has been rebuilt with the new one, this can happen. In this case, this > is probably caused by numpy. Thanks. I thought I had seen it before in another package, but had never figured out exactly what was happening. I’m going to close this even though the build doesn’t currently succeed, since the one successful COPR build does seem to confirm the original Python change was properly reverted. |