Skip to content

Commit

Permalink
build: Fix build reproducibility.
Browse files Browse the repository at this point in the history
Without going the extra length of exporting `PYTHONHASHSEED=0` or
similar, the built sdist and wheel for a given version of the project
would have inconsistent random ordering of extras_require entries
between builds.

This was observed attempting to lock a VCS requirement on this project
here: pantsbuild/pants#21145
On the bright side, it led to Pex fixing its building and locking code
to be robust to this sort of (unintended) bad behavior:
pex-tool/pex#2554
  • Loading branch information
jsirois committed Oct 9, 2024
1 parent 06c8523 commit 6c76e26
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ def load_requirements(file_list: Optional[Union[str, List[str]]] = None) -> List
tsv_reqs = load_requirements("requirements/extra-csv.in")
xlsx_reqs = load_requirements("requirements/extra-xlsx.in")

all_doc_reqs = list(
all_doc_reqs = sorted(
set(
csv_reqs
+ docx_reqs
Expand Down

0 comments on commit 6c76e26

Please sign in to comment.