GNU bug report logs - #75786
python-fastbencode does not build the C extensions

Previous Next

Package: guix;

Reported by: Dariqq <dariqq <at> posteo.net>

Date: Thu, 23 Jan 2025 15:02:01 UTC

Severity: normal

Done: Sharlatan Hellseher <sharlatanus <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Dariqq <dariqq <at> posteo.net>
To: 75786 <at> debbugs.gnu.org
Subject: bug#75786: python-fastbencode does not build the C extensions
Date: Thu, 23 Jan 2025 15:00:46 +0000
Hello,
while troubleshooting some python things i got the following warning 
UserWarning: failed to load compiled extension: No module named 
'fastbencode._bencode_pyx'

Reason seems to be that something goes wrong during building:
Snippet of build log at 4241a5a4688e8a118b2f66423abd3ef8baae98fc


running build_ext
cythoning fastbencode/_bencode_pyx.pyx to fastbencode/_bencode_pyx.c

Error compiling Cython file:
------------------------------------------------------------
...
from cpython.mem cimport (
    PyMem_Free,
    PyMem_Malloc,
    PyMem_Realloc,
    )
from cpython.unicode cimport (
^
------------------------------------------------------------

fastbencode/_bencode_pyx.pyx:49:0: 
'cpython/unicode/PyUnicode_FromStringAndSize.pxd' not found

Error compiling Cython file:
------------------------------------------------------------
...
            raise ValueError('string size below zero: %d' % n)

        if self._bytestring_encoding == NULL:
            result = PyBytes_FromStringAndSize(self.tail, n)
        elif self._bytestring_encoding == b'utf-8':
            result = PyUnicode_FromStringAndSize(self.tail, n)
                    ^
------------------------------------------------------------

fastbencode/_bencode_pyx.pyx:201:21: 'PyUnicode_FromStringAndSize' is 
not a constant, variable or function identifier
building 'fastbencode._bencode_pyx' extension
creating build/temp.linux-x86_64-cpython-310
creating build/temp.linux-x86_64-cpython-310/fastbencode
gcc -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall 
-fno-semantic-interposition -fPIC -Ifastbencode 
-I/gnu/store/kayi1a27qjbizw1870vgpwd6mzcdggql-python-3.10.7/include/python3.10 
-c fastbencode/_bencode_pyx.c -o 
build/temp.linux-x86_64-cpython-310/fastbencode/_bencode_pyx.o
fastbencode/_bencode_pyx.c:1:2: error: #error Do not use this file, it 
is the result of a failed Cython compilation.
    1 | #error Do not use this file, it is the result of a failed 
Cython compilation.
      |  ^~~~~
warning: old_build_ext: building extension "fastbencode._bencode_pyx" 
failed: command 
'/gnu/store/86fc8bi3mciljxz7c79jx8zr4wsx7xw8-gcc-11.4.0/bin/gcc' failed 
with exit code 1




This bug report was last modified 169 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.