Fedora Account System
Red Hat Associate
Red Hat Customer
python-peevee fails to build with Python 3.12.0a7. playhouse/_sqlite_udf.c: In function ‘__Pyx_PyInt_AddObjC’: playhouse/_sqlite_udf.c:5604:51: error: ‘PyLongObject’ {aka ‘struct _longobject’} has no member named ‘ob_digit’ 5604 | const digit* digits = ((PyLongObject*)op1)->ob_digit; | ^~ playhouse/_sqlite_udf.c: In function ‘__Pyx_PyUnicode_Equals’: playhouse/_sqlite_udf.c:569:51: warning: implicit declaration of function ‘_PyUnicode_Ready’; did you mean ‘PyUnicode_READY’? [-Wimplicit-function-declaration] 569 | 0 : _PyUnicode_Ready((PyObject *)(op))) | ^~~~~~~~~~~~~~~~ playhouse/_sqlite_udf.c:944:43: note: in definition of macro ‘unlikely’ 944 | #define unlikely(x) __builtin_expect(!!(x), 0) | ^ playhouse/_sqlite_udf.c:6097:22: note: in expansion of macro ‘__Pyx_PyUnicode_READY’ 6097 | if (unlikely(__Pyx_PyUnicode_READY(s1) < 0) || unlikely(__Pyx_PyUnicode_READY(s2) < 0)) | ^~~~~~~~~~~~~~~~~~~~~ playhouse/_sqlite_udf.c: In function ‘__Pyx_Raise’: playhouse/_sqlite_udf.c:6584:34: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘curexc_traceback’ 6584 | PyObject* tmp_tb = tstate->curexc_traceback; | ^~ playhouse/_sqlite_udf.c:6587:19: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘curexc_traceback’ 6587 | tstate->curexc_traceback = tb; | ^~ playhouse/_sqlite_udf.c: In function ‘__Pyx_PyInt_EqObjC’: playhouse/_sqlite_udf.c:6827:51: error: ‘PyLongObject’ {aka ‘struct _longobject’} has no member named ‘ob_digit’ 6827 | const digit* digits = ((PyLongObject*)op1)->ob_digit; | ^~ playhouse/_sqlite_udf.c: In function ‘__Pyx_CLineForTraceback’: playhouse/_sqlite_udf.c:6892:9: warning: ‘ma_version_tag’ is deprecated [-Wdeprecated-declarations] 6892 | __PYX_PY_DICT_LOOKUP_IF_MODIFIED( | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/include/python3.12/cpython/dictobject.h:22:34: note: declared here 22 | Py_DEPRECATED(3.12) uint64_t ma_version_tag; | ^~~~~~~~~~~~~~ playhouse/_sqlite_udf.c:6892:9: warning: ‘ma_version_tag’ is deprecated [-Wdeprecated-declarations] 6892 | __PYX_PY_DICT_LOOKUP_IF_MODIFIED( | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/include/python3.12/cpython/dictobject.h:22:34: note: declared here 22 | Py_DEPRECATED(3.12) uint64_t ma_version_tag; | ^~~~~~~~~~~~~~ playhouse/_sqlite_udf.c: In function ‘__Pyx_PyInt_As_int’: playhouse/_sqlite_udf.c:7193:53: error: ‘PyLongObject’ {aka ‘struct _longobject’} has no member named ‘ob_digit’ 7193 | const digit* digits = ((PyLongObject*)x)->ob_digit; | ^~ playhouse/_sqlite_udf.c:7248:53: error: ‘PyLongObject’ {aka ‘struct _longobject’} has no member named ‘ob_digit’ 7248 | const digit* digits = ((PyLongObject*)x)->ob_digit; | ^~ playhouse/_sqlite_udf.c: In function ‘__Pyx_PyInt_As_long’: playhouse/_sqlite_udf.c:7427:53: error: ‘PyLongObject’ {aka ‘struct _longobject’} has no member named ‘ob_digit’ 7427 | const digit* digits = ((PyLongObject*)x)->ob_digit; | ^~ playhouse/_sqlite_udf.c:7482:53: error: ‘PyLongObject’ {aka ‘struct _longobject’} has no member named ‘ob_digit’ 7482 | const digit* digits = ((PyLongObject*)x)->ob_digit; | ^~ playhouse/_sqlite_udf.c: In function ‘__Pyx_PyIndex_AsSsize_t’: playhouse/_sqlite_udf.c:7933:45: error: ‘PyLongObject’ {aka ‘struct _longobject’} has no member named ‘ob_digit’ 7933 | const digit* digits = ((PyLongObject*)b)->ob_digit; | ^~ GH-101291: Refactor the PyLongObject struct #101292 https://github.com/python/cpython/pull/101292 https://docs.python.org/3.12/whatsnew/3.12.html For the build logs, see: https://copr-be.cloud.fedoraproject.org/results/@python/python3.12/fedora-rawhide-x86_64/5840249-python-peevee/ For all our attempts to build python-peevee with Python 3.12, see: https://copr.fedorainfracloud.org/coprs/g/python/python3.12/package/python-peevee/ Testing and mass rebuild of packages is happening in copr. You can follow these instructions to test locally in mock if your package builds with Python 3.12: https://copr.fedorainfracloud.org/coprs/g/python/python3.12/ Let us know here if you have any questions. Python 3.12 is planned to be included in Fedora 39. To make that update smoother, we're building Fedora packages with all pre-releases of Python 3.12. A build failure prevents us from testing all dependent packages (transitive [Build]Requires), so if this package is required a lot, it's important for us to get it fixed soon. We'd appreciate help from the people who know this package best, but if you don't want to work on this now, let us know so we can try to work around it on our side.
Reported upstream: https://github.com/coleifer/peewee/issues/2720
__Pyx_PyInt_As_int makes me think this is Cython-generated code. All Cython-generated code must be removed in %prep and regenerated during build: https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#_using_cython [python-peewee (rawhide)]$ fedpkg --release rawhide prep ... [python-peewee (rawhide %)]$ rg 'Generated by Cython' peewee-3.16.0 peewee-3.16.0/playhouse/_sqlite_udf.c 1:/* Generated by Cython 0.29.32 */ peewee-3.16.0/playhouse/_sqlite_ext.c 1:/* Generated by Cython 0.29.32 */
Yup, removing Cython-generated code helped and the build passed.
PR: https://src.fedoraproject.org/rpms/python-peewee/pull-request/5
Merged. Should I close the upstream issue?
Thank you, upstream has already closed it.
This bug appears to have been reported against 'rawhide' during the Fedora Linux 39 development cycle. Changing version to 39.
This message is a reminder that Fedora Linux 39 is nearing its end of life. Fedora will stop maintaining and issuing updates for Fedora Linux 39 on 2024-11-26. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a 'version' of '39'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, change the 'version' to a later Fedora Linux version. Note that the version field may be hidden. Click the "Show advanced fields" button if you do not see it. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora Linux 39 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora Linux, you are encouraged to change the 'version' to a later version prior to this bug being closed.
This fix has been included since python-peewee-3.16.2-1. https://bodhi.fedoraproject.org/updates/FEDORA-2023-c890e6d994