Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make gzip reproducible #560

Merged
merged 2 commits into from
Feb 18, 2021
Merged

Make gzip reproducible #560

merged 2 commits into from
Feb 18, 2021

Conversation

skearnes
Copy link
Collaborator

open-reaction-database/ord-data#64 is stuck in an infinite loop because gzip encodes the modification time (see mtime). This PR sets a constant mtime in message_helpers.write_message to make repeated writes to the same file reproducible. Note that the filename is also encoded, so repeated writes to different files will not have identical bytes.

@codecov
Copy link

codecov bot commented Feb 18, 2021

Codecov Report

Merging #560 (3f96fce) into main (0e61a20) will decrease coverage by 0.02%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #560      +/-   ##
==========================================
- Coverage   76.29%   76.27%   -0.03%     
==========================================
  Files          19       19              
  Lines        1911     1909       -2     
  Branches      468      467       -1     
==========================================
- Hits         1458     1456       -2     
  Misses        305      305              
  Partials      148      148              
Impacted Files Coverage Δ
ord_schema/message_helpers.py 84.75% <100.00%> (-0.09%) ⬇️

@skearnes skearnes merged commit 124b479 into open-reaction-database:main Feb 18, 2021
@skearnes skearnes deleted the gzip branch February 18, 2021 18:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants