Skip to content

FAILED tests/test_igzip_threaded.py::test_flush on openEuler 22.03 #241

Open

Description

@liuqinfei

I ran python-isal tests on the openEuler OS and Kunpeng AArch64 platform, where two test cases in tests/test_igzip_threaded.py failed.

OS:
[root@node1 python-isal]# cat /etc/os-release
NAME="openEuler"
VERSION="22.03 (LTS-SP3)"
ID="openEuler"
VERSION_ID="22.03"
PRETTY_NAME="openEuler 22.03 (LTS-SP3)"
ANSI_COLOR="0;31"

platform: Kunpeng-920

`
==================== short test summary info ==============

FAILED tests/test_igzip_threaded.py::test_flush[1] - AssertionError: assert b'\x01\x00\x00\x00' == b'\x00\x00\xff\xff'
FAILED tests/test_igzip_threaded.py::test_flush[2] - AssertionError: assert b'\x01\x00\x00\x00' == b'\x00\x00\xff\xff'

============== 2 failed, 9439 passed, 6 skipped, 2 warnings in 35.67s ====================
`

tmp_path = PosixPath('/tmp/pytest-of-root/pytest-11/test_flush_1_0'), threads = 1

@pytest.mark.parametrize("threads", [1, 2])
def test_flush(tmp_path, threads):
    empty_block_end = b"\x00\x00\xff\xff"
    compressobj = zlib.compressobj(wbits=-15)
    deflate_last_block = compressobj.compress(b"") + compressobj.flush()
    test_file = tmp_path / "output.gz"
    with igzip_threaded.open(test_file, "wb", threads=threads) as f:
        f.write(b"1")
        f.flush()
        data = test_file.read_bytes()

> assert data[-4:] == empty_block_end

E AssertionError: assert b'\x01\x00\x00\x00' == b'\x00\x00\xff\xff'
E At index 0 diff: b'\x01' != b'\x00'
E Use -v to get more diff

tests/test_igzip_threaded.py:255: AssertionError

I subsequently reproduced the same issue on an Intel(R) Xeon(R) Gold 6266C platform.

Activity

  1. rhpvorderman commented on Sep 9, 2025

    @rhpvorderman
    Collaborator

    Thank you for submitting the bug. It does work correctly on Linux (Ubuntu, Debian), MacOS and Windows. It also works on ubuntu aarch64 (emulated). Are you sure this is not an OpenEuler bug?

    I ran it on an intel skylake processor: also no issue. Since I am not able to reproduce the error, I can not fix it. If you manage to find the cause, then fixes are welcome.

  2. changed the title [-]FAILED tests/test_igzip_threaded.py::test_flush[/-] [+]FAILED tests/test_igzip_threaded.py::test_flush on openEuler 22.03[/+] on Sep 9, 2025
  3. liuqinfei commented on Sep 9, 2025

    @liuqinfei
    Author
  4. rhpvorderman commented on Sep 10, 2025

    @rhpvorderman
    Collaborator

    Hey, I did a check and there are some test cases in the current test suite that fail on older versions of python-isal. If you did not test the latest and greatest code on the develop branch this test is expected to fail. I am in the process of releasing 1.8.0 which should fix the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions