Bug#1027335: pairtools -- FTBFS in unstable
Control: severity -1 normal Control: retitle -1 pairtools -- current repo in salsa FTBFS Control: clone -1 -2 Control: reassign -2 python3-pysam 0.20.0+ds-2 Control: retitle -2 pysam -- no definition for bam_dup1 On Fri, Dec 30, 2022 at 08:24:42PM +0530, Nilesh Patra wrote: > On Fri, 30 Dec 2022 20:05:32 +0530 Nilesh Patra wrote: > > Source: pairtools > > Version: 0.3.0-3.2 > > Severity: serious > > > > Pairtools FTBFS with pysam related error. Looks like > > something is off. > > > > dh_auto_clean > > I: pybuild base:240: python3.11 setup.py clean > > Traceback (most recent call last): > > > > > > File "/<>/setup.py", line 130, in > > ext_modules=get_ext_modules(), > > ^ > > File "/<>/setup.py", line 81, in get_ext_modules > > extra_link_args=pysam.get_libraries(), > > ^ > > File "/usr/lib/python3/dist-packages/pysam/__init__.py", line 100, in > > get_libraries > > return [os.path.join(dirname, x + so) for x in pysam_libs] > >^^^ > > File "/usr/lib/python3/dist-packages/pysam/__init__.py", line 100, in > > > > return [os.path.join(dirname, x + so) for x in pysam_libs] > > ~~^~~~ > > TypeError: can only concatenate str (not "NoneType") to str > > This patch in pysam gets the build in pairtools going beyond this point, but > now the build chokes with: > > | pairtools.cli (unittest.loader._FailedTest.pairtools.cli) ... ERROR > > > | pairtools.lib (unittest.loader._FailedTest.pairtools.lib) ... ERROR > | > | == > | ERROR: pairtools.cli (unittest.loader._FailedTest.pairtools.cli) > | -- > | ImportError: Failed to import test module: pairtools.cli > | Traceback (most recent call last): > | File "/usr/lib/python3.11/unittest/loader.py", line 440, in _find_test_path > |package = self._get_module_from_name(name) > | > | File "/usr/lib/python3.11/unittest/loader.py", line 350, in > _get_module_from_name > |__import__(name) > | File > "/<>/.pybuild/cpython3_3.11/build/pairtools/cli/__init__.py", > line 188, in > |from . import ( > | File > "/<>/.pybuild/cpython3_3.11/build/pairtools/cli/dedup.py", line > 12, in > |from ..lib import fileio, pairsam_format, headerops > | File > "/<>/.pybuild/cpython3_3.11/build/pairtools/lib/__init__.py", > line 7, in > |from . import parse > | File > "/<>/.pybuild/cpython3_3.11/build/pairtools/lib/parse.py", line > 38, in > |from .parse_pysam import get_mismatches_c > | ImportError: > /<>/.pybuild/cpython3_3.11/build/pairtools/lib/parse_pysam.cpython-311-x86_64-linux-gnu.so: > undefined symbol: bam_dup1 Turns out this is because there is just a function "declaration" in pysam/libchtslib.pxd for bam_dup1. But the headers imported do not even have the function. I patched the current package in salsa to get the ball rolling. But this needs bioframe. Also, the below patch still needs to be applied to pysam. pushed to salsa. > Description: Add patch to return proper sysconf so for current python > Author: Nilesh Patra > Last-Update: 2022-12-30 > --- a/pysam/__init__.py > +++ b/pysam/__init__.py > @@ -96,5 +96,7 @@ > if pysam.config.HTSLIB == "builtin": > pysam_libs.append('libchtslib') > > -so = sysconfig.get_config_var('SO') > +so = sysconfig.get_config_var('EXT_SUFFIX') > +if not so: > +so = sysconfig.get_config_var('SO') > return [os.path.join(dirname, x + so) for x in pysam_libs] > -- Best, Nilesh signature.asc Description: PGP signature
Processed: Re: [Debian-med-packaging] Bug#1027335: pairtools -- FTBFS in unstable
Processing control commands: > tags -1 + confirmed Bug #1027335 [src:pairtools] pairtools -- FTBFS in unstable Added tag(s) confirmed. > reassign -1 src:python-pysam 0.20.0+ds-2 Bug #1027335 [src:pairtools] pairtools -- FTBFS in unstable Bug reassigned from package 'src:pairtools' to 'src:python-pysam'. No longer marked as found in versions pairtools/0.3.0-3.2. Ignoring request to alter fixed versions of bug #1027335 to the same values previously set Bug #1027335 [src:python-pysam] pairtools -- FTBFS in unstable Marked as found in versions python-pysam/0.20.0+ds-2. > affects -1 src:pairtools Bug #1027335 [src:python-pysam] pairtools -- FTBFS in unstable Added indication that 1027335 affects src:pairtools -- 1027335: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1027335 Debian Bug Tracking System Contact ow...@bugs.debian.org with problems
Bug#1027335: [Debian-med-packaging] Bug#1027335: pairtools -- FTBFS in unstable
Control: tags -1 + confirmed Control: reassign -1 src:python-pysam 0.20.0+ds-2 Control: affects -1 src:pairtools Hi Nilesh, Nilesh Patra, on 2022-12-30: > File "/<>/setup.py", line 130, in > ext_modules=get_ext_modules(), > ^ > File "/<>/setup.py", line 81, in get_ext_modules > extra_link_args=pysam.get_libraries(), > ^ > File "/usr/lib/python3/dist-packages/pysam/__init__.py", line 100, in > get_libraries > return [os.path.join(dirname, x + so) for x in pysam_libs] >^^^ > File "/usr/lib/python3/dist-packages/pysam/__init__.py", line 100, in > > return [os.path.join(dirname, x + so) for x in pysam_libs] > ~~^~~~ > TypeError: can only concatenate str (not "NoneType") to str Thanks for catching this, I confirm I can reproduce the error without pairtools in the loop. Given the reproducer.py below: import pysam for lib in pysam.get_libraries(): print(lib) I do get the error with python3.11: $ python3.11 reproducer.py Traceback (most recent call last): File "/home/emollier/tmp/reproducer.py", line 2, in for lib in pysam.get_libraries(): ^ File "/usr/lib/python3/dist-packages/pysam/__init__.py", line 100, in get_libraries return [os.path.join(dirname, x + so) for x in pysam_libs] ^^^ File "/usr/lib/python3/dist-packages/pysam/__init__.py", line 100, in return [os.path.join(dirname, x + so) for x in pysam_libs] ~~^~~~ TypeError: can only concatenate str (not "NoneType") to str Besides, the error looks genuine since in python3.10, the output seems to return the expected result: $ python3.10 reproducer.py /usr/lib/python3/dist-packages/pysam/libctabixproxies.cpython-310-x86_64-linux-gnu.so /usr/lib/python3/dist-packages/pysam/libcfaidx.cpython-310-x86_64-linux-gnu.so /usr/lib/python3/dist-packages/pysam/libcsamfile.cpython-310-x86_64-linux-gnu.so /usr/lib/python3/dist-packages/pysam/libcvcf.cpython-310-x86_64-linux-gnu.so /usr/lib/python3/dist-packages/pysam/libcbcf.cpython-310-x86_64-linux-gnu.so /usr/lib/python3/dist-packages/pysam/libctabix.cpython-310-x86_64-linux-gnu.so So I'm reassigning the issue accordingly. Have a nice day, :) -- Étienne Mollier Fingerprint: 8f91 b227 c7d6 f2b1 948c 8236 793c f67e 8f0d 11da Sent from /dev/pts/1, please excuse my verbosity. signature.asc Description: PGP signature
Bug#1027335: pairtools -- FTBFS in unstable
On Fri, 30 Dec 2022 20:05:32 +0530 Nilesh Patra wrote: > Source: pairtools > Version: 0.3.0-3.2 > Severity: serious > > Pairtools FTBFS with pysam related error. Looks like > something is off. > > dh_auto_clean > I: pybuild base:240: python3.11 setup.py clean > Traceback (most recent call last): > > > File "/<>/setup.py", line 130, in > ext_modules=get_ext_modules(), > ^ > File "/<>/setup.py", line 81, in get_ext_modules > extra_link_args=pysam.get_libraries(), > ^ > File "/usr/lib/python3/dist-packages/pysam/__init__.py", line 100, in > get_libraries > return [os.path.join(dirname, x + so) for x in pysam_libs] >^^^ > File "/usr/lib/python3/dist-packages/pysam/__init__.py", line 100, in > > return [os.path.join(dirname, x + so) for x in pysam_libs] > ~~^~~~ > TypeError: can only concatenate str (not "NoneType") to str This patch in pysam gets the build in pairtools going beyond this point, but now the build chokes with: | pairtools.cli (unittest.loader._FailedTest.pairtools.cli) ... ERROR | pairtools.lib (unittest.loader._FailedTest.pairtools.lib) ... ERROR | | == | ERROR: pairtools.cli (unittest.loader._FailedTest.pairtools.cli) | -- | ImportError: Failed to import test module: pairtools.cli | Traceback (most recent call last): | File "/usr/lib/python3.11/unittest/loader.py", line 440, in _find_test_path |package = self._get_module_from_name(name) | | File "/usr/lib/python3.11/unittest/loader.py", line 350, in _get_module_from_name |__import__(name) | File "/<>/.pybuild/cpython3_3.11/build/pairtools/cli/__init__.py", line 188, in |from . import ( | File "/<>/.pybuild/cpython3_3.11/build/pairtools/cli/dedup.py", line 12, in |from ..lib import fileio, pairsam_format, headerops | File "/<>/.pybuild/cpython3_3.11/build/pairtools/lib/__init__.py", line 7, in |from . import parse | File "/<>/.pybuild/cpython3_3.11/build/pairtools/lib/parse.py", line 38, in |from .parse_pysam import get_mismatches_c | ImportError: /<>/.pybuild/cpython3_3.11/build/pairtools/lib/parse_pysam.cpython-311-x86_64-linux-gnu.so: undefined symbol: bam_dup1 Description: Add patch to return proper sysconf so for current python Author: Nilesh Patra Last-Update: 2022-12-30 --- a/pysam/__init__.py +++ b/pysam/__init__.py @@ -96,5 +96,7 @@ if pysam.config.HTSLIB == "builtin": pysam_libs.append('libchtslib') -so = sysconfig.get_config_var('SO') +so = sysconfig.get_config_var('EXT_SUFFIX') +if not so: +so = sysconfig.get_config_var('SO') return [os.path.join(dirname, x + so) for x in pysam_libs] signature.asc Description: PGP signature
Bug#1027335: pairtools -- FTBFS in unstable
Source: pairtools Version: 0.3.0-3.2 Severity: serious Pairtools FTBFS with pysam related error. Looks like something is off. dh_auto_clean I: pybuild base:240: python3.11 setup.py clean Traceback (most recent call last): File "/<>/setup.py", line 130, in ext_modules=get_ext_modules(), ^ File "/<>/setup.py", line 81, in get_ext_modules extra_link_args=pysam.get_libraries(), ^ File "/usr/lib/python3/dist-packages/pysam/__init__.py", line 100, in get_libraries return [os.path.join(dirname, x + so) for x in pysam_libs] ^^^ File "/usr/lib/python3/dist-packages/pysam/__init__.py", line 100, in return [os.path.join(dirname, x + so) for x in pysam_libs] ~~^~~~ TypeError: can only concatenate str (not "NoneType") to str Thanks, Nilesh -- System Information: Debian Release: bookworm/sid APT prefers testing APT policy: (990, 'testing') Architecture: amd64 (x86_64) Kernel: Linux 6.0.0-6-amd64 (SMP w/8 CPU threads; PREEMPT) Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE not set Shell: /bin/sh linked to /usr/bin/dash Init: systemd (via /run/systemd/system) LSM: AppArmor: enabled