You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think it makes sense not to actually change things back, but failing to merge the PR means we also failed to add unit tests.
Can we please add a general-purpose, fragile reproducibility test for the gzip module, so that this problem does not recur?
Ex. test that the output of gzip.compress("Hello world") remains stable
deftest_gzip_reproducibility():
"""If this test fails, gzip.compress does not give reproducible output. Either fix that, or document the change in What's New and change the constant 'expected' below."""expected=b'\x1f\x8b\x08\x00\xa2\xd2\xe1g\x02\xff\xf3H\xcd\xc9\xc9W(\xcf/\xcaI\x01\x00R\x9e\xd6\x8b\x0b\x00\x00\x00'assertgzip.compress(b"Hello world") ==expectedexpected=b'\x1f\x8b\x08\x00\x00\x00\x00\x00\x02\xff\xf3H\xcd\xc9\xc9W(\xcf/\xcaI\x01\x00R\x9e\xd6\x8b\x0b\x00\x00\x00'assertgzip.compress(b"Hello world", mtime=0) ==expected
The text was updated successfully, but these errors were encountered:
Uh oh!
There was an error while loading. Please reload this page.
The issue #112346 was reported, which was a failure to keep reproducibility in
gzip
module output from Python 3.10 to 3.11.There was a fix discussed and rejected in #112346
I think it makes sense not to actually change things back, but failing to merge the PR means we also failed to add unit tests.
Can we please add a general-purpose, fragile reproducibility test for the gzip module, so that this problem does not recur?
Ex. test that the output of
gzip.compress("Hello world")
remains stableThe text was updated successfully, but these errors were encountered: