Bug#1119759: petsc4py: FTBFS: error: Cython failure: 'petsc4py/PETSc.pyx' -> 'petsc4py/PETSc.c'

Santiago Vila sanvila at debian.org
Fri Oct 31 11:29:09 GMT 2025


Package: src:petsc4py
Version: 3.22.4-2
Severity: serious
Tags: ftbfs forky sid

Dear maintainer:

During a rebuild of all packages in unstable, this package failed to build.

Below you will find the last part of the build log (probably the most
relevant part, but not necessarily). If required, the full build log
is available here:

https://people.debian.org/~sanvila/build-logs/202510/

About the archive rebuild: The build was made on virtual machines from AWS,
using sbuild and a reduced chroot with only build-essential packages.

If you cannot reproduce the bug please contact me privately, as I
am willing to provide ssh access to a virtual machine where the bug is
fully reproducible.

If this is really a bug in one of the build-depends, please use
reassign and add an affects on src:petsc4py, so that this is still
visible in the BTS web page for this package.

Thanks.

--------------------------------------------------------------------------------
[...]
 debian/rules clean
dh clean --with python3,sphinxdoc --buildsystem=pybuild
   dh_auto_clean -O--buildsystem=pybuild
   dh_autoreconf_clean -O--buildsystem=pybuild
   dh_clean -O--buildsystem=pybuild
   debian/rules execute_after_dh_clean
make[1]: Entering directory '/<<PKGBUILDDIR>>'
rm -rf .eggs
rm -f src/petsc4py/PETSc.c src/petsc4py/PETSc.h src/petsc4py/PETSc_api.h
rm -rf docs/source/reference docs/source/demo
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
 debian/rules binary
dh binary --with python3,sphinxdoc --buildsystem=pybuild
   dh_update_autotools_config -O--buildsystem=pybuild
   dh_autoreconf -O--buildsystem=pybuild
   debian/rules override_dh_auto_configure-arch
make[1]: Entering directory '/<<PKGBUILDDIR>>'
PYBUILD_NAME=petsc4py_real3.22 PETSC_DIR=/usr/lib/petscdir/petsc3.22/x86_64-linux-gnu-real  dh_auto_configure -ppython3-petsc4py-real3.22
PYBUILD_NAME=petsc4py_complex3.22 PETSC_DIR=/usr/lib/petscdir/petsc3.22/x86_64-linux-gnu-complex  dh_auto_configure -ppython3-petsc4py-complex3.22
PYBUILD_NAME=petsc4py_64_real3.22 PETSC_DIR=/usr/lib/petscdir/petsc64-3.22/x86_64-linux-gnu-real  dh_auto_configure -ppython3-petsc4py-64-real3.22
PYBUILD_NAME=petsc4py_64_complex3.22 PETSC_DIR=/usr/lib/petscdir/petsc64-3.22/x86_64-linux-gnu-complex  dh_auto_configure -ppython3-petsc4py-64-complex3.22
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
   debian/rules override_dh_auto_configure-indep
make[1]: Entering directory '/<<PKGBUILDDIR>>'
if ! [ -d /<<PKGBUILDDIR>>/.pybuild/cpython3_3.13_petsc4py_real3.22/build ]; then \
  PYBUILD_NAME=petsc4py_real3.22 PETSC_DIR=/usr/lib/petscdir/petsc3.22/x86_64-linux-gnu-real  pybuild -p3.13 --configure; \
fi
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
   debian/rules override_dh_auto_build-arch
make[1]: Entering directory '/<<PKGBUILDDIR>>'
PYBUILD_NAME=petsc4py_real3.22 PETSC_DIR=/usr/lib/petscdir/petsc3.22/x86_64-linux-gnu-real  dh_auto_build -ppython3-petsc4py-real3.22
I: pybuild plugin_pyproject:129: Building wheel for python3.13 with "build" module
I: pybuild base:311: python3.13 -m build --skip-dependency-check --no-isolation --wheel --outdir /<<PKGBUILDDIR>>/.pybuild/cpython3_3.13_petsc4py_real3.22  
* Building wheel...
/usr/lib/python3/dist-packages/setuptools/dist.py:759: SetuptoolsDeprecationWarning: License classifiers are deprecated.
!!

        ********************************************************************************
        Please consider removing the following classifiers in favor of a SPDX license expression:

        License :: OSI Approved :: BSD License

        See https://packaging.python.org/en/latest/guides/writing-pyproject-toml/#license for details.
        ********************************************************************************

!!
  self._finalize_license_expression()
running bdist_wheel
running build
running build_src
using Cython 3.1.6
cythonizing 'petsc4py/PETSc.pyx' -> 'petsc4py/PETSc.c'
warning: petsc4py/PETSc/petscis.pxi:196:4: '__getsegcount__' relates to the old Python 2 buffer protocol and is no longer used.
warning: petsc4py/PETSc/petscis.pxi:201:4: '__getreadbuffer__' relates to the old Python 2 buffer protocol and is no longer used.
warning: petsc4py/PETSc/petscvec.pxi:588:4: '__getsegcount__' relates to the old Python 2 buffer protocol and is no longer used.
warning: petsc4py/PETSc/petscvec.pxi:593:4: '__getreadbuffer__' relates to the old Python 2 buffer protocol and is no longer used.
warning: petsc4py/PETSc/petscvec.pxi:598:4: '__getwritebuffer__' relates to the old Python 2 buffer protocol and is no longer used.

Error compiling Cython file:
------------------------------------------------------------
...

    @classmethod
    def Print(
        cls,
        *args: Any,
        sep: str = ' ',
                   ^
------------------------------------------------------------

petsc4py/PETSc/Sys.pyx:159:19: Compiler crash in ExpressionWriter


Compiler crash traceback from this point on:
  File "Cython/Compiler/Visitor.py", line 174, in Cython.Compiler.Visitor.TreeVisitor._visit
  File "/<<PKGBUILDDIR>>/conf/cyautodoc.py", line 28, in visit_UnicodeNode
    self.emit_string(node, '')
    ^^^^^^^^^^^^^^^^
AttributeError: 'ExpressionWriter' object has no attribute 'emit_string'
error: Cython failure: 'petsc4py/PETSc.pyx' -> 'petsc4py/PETSc.c'

ERROR Backend subprocess exited when trying to invoke build_wheel
E: pybuild pybuild:389: build: plugin pyproject failed with: exit code=1: python3.13 -m build --skip-dependency-check --no-isolation --wheel --outdir /<<PKGBUILDDIR>>/.pybuild/cpython3_3.13_petsc4py_real3.22  
dh_auto_build: error: pybuild --build -i python{version} -p 3.13 returned exit code 13
make[1]: *** [debian/rules:61: override_dh_auto_build-arch] Error 25
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
make: *** [debian/rules:40: binary] Error 2
dpkg-buildpackage: error: debian/rules binary subprocess returned exit status 2
--------------------------------------------------------------------------------



More information about the debian-science-maintainers mailing list