[Debian-astro-maintainers] Bug#1135593: python-fitsio: testsuite fails with cfitsio 4.6.4

Aurelien Jarno aurel32 at debian.org
Sun May 3 10:49:58 BST 2026


Source: python-fitsio
Version: 1.3.0+ds-1
Severity: serious
Tags: ftbfs fixed-upstream patch
Justification: fails to build from source (but built successfully in the past)

Hi,

Following the upload of cfitsio 4.6.4 in the archive, the python-fitsio
testsuite fails, causing the package to FTBFS and to fail its
autopkgtest [1]:

 36s =================================== FAILURES ===================================
 36s _______________________ test_compression_diskfile_kwargs _______________________
 36s
 36s     def test_compression_diskfile_kwargs():
 36s         with tempfile.TemporaryDirectory() as tmpdir:
 36s             fn = os.path.join(tmpdir, 'test.fits')
 36s
 36s             img = np.ones((20, 20))
 36s             with fitsio.FITS(fn, 'rw', clobber=True) as fits:
 36s                 fits.write(
 36s                     img,
 36s                     compress='RICE',
 36s                     tile_dims=(10, 5),
 36s                     qlevel=7.0,
 36s                     qmethod='SUBTRACTIVE_DITHER_2',
 36s                     dither_seed=42,
 36s                 )
 36s             with fitsio.FITS(fn) as fits:
 36s                 assert len(fits) == 2
 36s             hdr = fitsio.read_header(fn, ext=1)
 36s             for key, val in [
 36s                 ('ZTILE1', 5),
 36s                 ('ZTILE2', 10),
 36s                 ('ZQUANTIZ', 'SUBTRACTIVE_DITHER_2'),
 36s                 ('ZDITHER0', 42),
 36s                 ('ZCMPTYPE', 'RICE_ONE'),
 36s             ]:
 36s >               assert hdr[key] == val
 36s E               AssertionError: assert 'RICE_1' == 'RICE_ONE'
 36s E
 36s E                 - RICE_ONE
 36s E                 + RICE_1
 36s
 36s /usr/lib/python3/dist-packages/fitsio/tests/test_image_compression_defaults.py:42: AssertionError
 36s =========================== short test summary info ============================
 36s FAILED tests/test_image_compression_defaults.py::test_compression_diskfile_kwargs
 36s =========== 1 failed, 1859 passed, 904 skipped, 113 xfailed in 5.64s ===========
 37s autopkgtest [06:51:39]: test command1: -----------------------]
 37s autopkgtest [06:51:39]: test command1:  - - - - - - - - - - results - - - - - - - - - -
 37s command1             FAIL non-zero exit status 1
 37s autopkgtest [06:51:39]: @@@@@@@@@@@@@@@@@@@@ summary
 37s command1             FAIL non-zero exit status 1

In cfitsio 4.6.4, the ZCMPTYPE header returns RICE_1 instead of
RICE_ONE [2]. A patch has been merged upstream to fix the issue [3].

Regards
Aurelien

[1] https://ci.debian.net/data/autopkgtest/testing/amd64/p/python-fitsio/70776186/log.gz
[2] https://github.com/HEASARC/cfitsio/commit/7d854ef29a4c0043ad4455f52657a593bd31476d
[3] https://github.com/esheldon/fitsio/commit/22eaef48e4b9f2a490f5e21514cc359b5948ce9a



More information about the Debian-astro-maintainers mailing list