Repository navigation
release: 3.0.1; publish from the tag with README links pinned to it - #19
Merged
Merged
Conversation
PyPI keeps each release's README forever, and 3.0.0's links said blob/master, so its page drifts with master. scripts/pin_readme_links.py rewrites the README's master links to v<version> in the publish job and refuses any other ref, a tag off master, a commit without a green ci.yml run, or a file link left on another ref (ADR 0012). Pinning at build time instead of in git, because pinned links in git would 404 for every document added after the last tag. Also: mypy covers scripts/, twine check --strict and no --skip-existing in the publish job, checkout without persisted credentials.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
blob/masterlinks.scripts/pin_readme_links.py, which rewrites them tov<version>.refs/tags/v<version>;ci.ymlrun;Why at build time and not in git
If
blob/v3.0.1were written into git, every document added after the last tag (the next ADR, say) would 404 from master's README until the next release.Also
scripts/.twine check --strict.--skip-existing: a re-run for a version already on PyPI fails instead of finishing green with nothing uploaded.ChangelogProject-URL stays on master on purpose (ADR 0012).Verification
refs/tags/v3.0.1and built:/masterleft in the shipped README;twine check --strictpassed;refs/heads/masterandrefs/heads/v3.0.1are refused./code-review high: 4 rounds.Named debt (MEDIUM or lower, deliberate)
http://,www.,raw/master, a raw link written asrefs/tags/..., and a bare URL ending in a period.compare/...masterandreleases/latestare not checked. The README has none; ADR 0012 says so.