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 Git archives reproducible #1338

Conversation

webknjaz
Copy link
Member

Some time ago, it was discovered that Git archives having ref-names: $Format:%D$ in .git_archival.txt may change when references existing in the repository change over time [1]. This means that downloading an archive for a commit from an immutable URL may start yielding slightly different results. This hurts the ability of downstreams to source projects from Git archive URLs.

With that in mind, modern setuptools-scm advises against having this entry in the .git_archival.txt template [2]. And this patch implements said recommendation.

Some time ago, it was discovered that Git archives having
`ref-names: $Format:%D$` in `.git_archival.txt` may change when
references existing in the repository change over time [[1]]. This
means that downloading an archive for a commit from an immutable URL
may start yielding slightly different results. This hurts the ability
of downstreams to source projects from Git archive URLs.

With that in mind, modern `setuptools-scm` advises against having this
entry in the `.git_archival.txt` template [[2]]. And this patch
implements said recommendation.

[1]: pypa/setuptools-scm#806
[2]: https://setuptools-scm.readthedocs.io/en/latest/usage/#git-archives
@webknjaz webknjaz added this pull request to the merge queue Aug 24, 2024
Merged via the queue into python-attrs:main with commit da2333c Aug 24, 2024
17 checks passed
@webknjaz webknjaz deleted the maintenance/setuptools-scm-git-archive-ref-names-reproducibility branch August 24, 2024 05:15
hynek added a commit to hynek/svcs that referenced this pull request Aug 24, 2024
hynek added a commit to pyca/service-identity that referenced this pull request Aug 24, 2024
hynek added a commit to hynek/structlog that referenced this pull request Aug 24, 2024
hynek added a commit to hynek/doc2dash that referenced this pull request Aug 24, 2024
hynek added a commit to hynek/environ-config that referenced this pull request Aug 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants