Andreas Tille pushed to branch master at Debian Med / ariba
Commits: fc083795 by Andreas Tille at 2026-09-21T17:26:29+02:00 add patch to make code work with pysam >= 0.24 pysam 0.24.x stopped returning captured output from pysam.faidx(); write_fa_subset now uses pysam.FastaFile to fetch sequences, fixing the FTBFS of ariba/tests/faidx_test.py::test_write_fa_subset. - - - - - d1142e33 by Andreas Tille at 2026-09-21T17:30:38+02:00 Upload to unstable - - - - - 3 changed files: - debian/changelog - + debian/patches/faidx-pysam-0.24.patch - debian/patches/series Changes: ===================================== debian/changelog ===================================== @@ -1,11 +1,12 @@ -ariba (2.14.7+ds-14) UNRELEASED; urgency=medium +ariba (2.14.7+ds-14) unstable; urgency=medium * Team upload. * d/watch: version=5 * Standards-Version: 4.7.4 (routine-update) * Reflow Uploaders field (cme) + * Add patch to fix build failure with python3-pysam >= 0.24 - -- Andreas Tille <[email protected]> Mon, 21 Sep 2026 14:05:00 +0200 + -- Andreas Tille <[email protected]> Mon, 21 Sep 2026 17:26:40 +0200 ariba (2.14.7+ds-13) unstable; urgency=medium ===================================== debian/patches/faidx-pysam-0.24.patch ===================================== @@ -0,0 +1,26 @@ +Description: Fix write_fa_subset with pysam >= 0.24 + pysam 0.24.x rewrote the samtools stdout redirection. As a result + pysam.faidx(infile, region) no longer returns the fetched sequence as + a string (it returns an empty string while the sequence is written to + the process' real stdout), which made write_fa_subset write empty + output files and broke ariba/tests/faidx_test.py::test_write_fa_subset. + Fetch sequences via pysam.FastaFile instead, which works with all + supported pysam versions. +Forwarded: no +Last-Update: 2026-09-21 + +--- a/ariba/faidx.py ++++ b/ariba/faidx.py +@@ -8,7 +8,10 @@ + pysam.faidx(infile) + + f = pyfastaq.utils.open_file_write(outfile) +- for name in seq_names: +- print(pysam.faidx(infile, name), end='', file=f) ++ with pysam.FastaFile(infile) as fasta: ++ for name in seq_names: ++ seq = fasta.fetch(name) ++ print('>' + name, file=f) ++ print(seq, file=f) + pyfastaq.utils.close(f) + ===================================== debian/patches/series ===================================== @@ -9,3 +9,4 @@ python3.12_syntax_warning.patch py3.13.patch remove_pkg_resources.patch multiprocessing-py3.14.patch +faidx-pysam-0.24.patch View it on GitLab: https://salsa.debian.org/med-team/ariba/-/compare/acab067d3aef47394d26cf48034a7c389792b048...d1142e3304a5677924adbd7bf189c2030554280a -- View it on GitLab: https://salsa.debian.org/med-team/ariba/-/compare/acab067d3aef47394d26cf48034a7c389792b048...d1142e3304a5677924adbd7bf189c2030554280a You're receiving this email because of your account on salsa.debian.org. Manage all notifications: https://salsa.debian.org/-/profile/notifications | Help: https://salsa.debian.org/help
_______________________________________________ debian-med-commit mailing list [email protected] https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/debian-med-commit
