[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#963816: numpy breaks astropy autopkgtest: TestFitscheck.test_overwrite_invalid fails

Source: numpy, astropy
Control: found -1 numpy/1:1.19.0-1
Control: found -1 astropy/4.0.1+post1-2
Severity: serious
Tags: sid bullseye
X-Debbugs-CC: debian-ci@lists.debian.org
User: debian-ci@lists.debian.org
Usertags: breaks needs-update

Dear maintainer(s),

With a recent upload of numpy the autopkgtest of astropy fails in
testing when that autopkgtest is run with the binary packages of numpy
from unstable. It passes when run with only packages from testing. In
tabular form:

                       pass            fail
numpy                  from testing    1:1.19.0-1
astropy                from testing    4.0.1+post1-2
all others             from testing    from testing

I copied some of the output at the bottom of this report.

Currently this regression is blocking the migration of numpy to testing
[1]. Due to the nature of this issue, I filed this bug report against
both packages. Can you please investigate the situation and reassign the
bug to the right package?

More information about this bug and the reason for filing it can be found on


[1] https://qa.debian.org/excuses.php?package=numpy


=================================== FAILURES
_____________________ TestFitscheck.test_overwrite_invalid

self = <astropy.io.fits.tests.test_fitscheck.TestFitscheck object at
capsys = <_pytest.capture.CaptureFixture object at 0x7fb217e24160>

    def test_overwrite_invalid(self, capsys):
        Tests that invalid checksum or datasum are overwriten when the
file is
        reffile = self.temp('ref.fits')
        with fits.open(self.data('tb.fits')) as hdul:
            hdul.writeto(reffile, checksum=True)

        # replace checksums with wrong ones
        testfile = self.temp('test.fits')
        with fits.open(self.data('tb.fits')) as hdul:
            hdul[0].header['DATASUM'] = '1       '
            hdul[0].header['CHECKSUM'] = '8UgqATfo7TfoATfo'
            hdul[1].header['DATASUM'] = '2349680925'
            hdul[1].header['CHECKSUM'] = '11daD8bX98baA8bU'

        assert fitscheck.main([testfile]) == 1
        stdout, stderr = capsys.readouterr()
        assert 'BAD' in stderr
        assert 'Checksum verification failed' in stderr

        assert fitscheck.main([testfile, '--write', '--force']) == 1
        stdout, stderr = capsys.readouterr()
        assert 'BAD' in stderr

        # check that the file was fixed
>       assert fitscheck.main([testfile]) == 0
E       AssertionError: assert 1 == 0
E        +  where 1 = <function main at
E        +    where <function main at 0x7fb21d1a6dc0> = fitscheck.main

Attachment: signature.asc
Description: OpenPGP digital signature

Reply to: