Repository navigation
Hash-pin the bundled Python packages and let Dependabot update them - #259
Merged
Merged
Conversation
The pins move to frontend/bundled-python/requirements.txt with every release file hashed, bundle_tools.sh installs with --require-hashes, and dependabot.yml gets a pip entry for that folder next to the github-actions one, both weekly and grouped.
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 and why
Dependabot cannot update pip installs written inline in a workflow, so the pins of the Python packages in the release app live in a requirements file it can read.
frontend/tools/bundled-python-requirements.txtmoves tofrontend/bundled-python/requirements.txt, now with every release file of each pinned version hashed.bundle_tools.shinstalls from it with--require-hashes(and still--only-binary)..github/dependabot.ymlhas two ecosystems,pipfor/frontend/bundled-pythonandgithub-actionsfor/(the workflows pin every action to a commit SHA with its tag in a comment, so Dependabot moves both). Weekly, one grouped PR per ecosystem, labelsdependenciesplusbuild(pip) orci(actions), commit prefixesbuildandci. Thedependencieslabel is created.dm/,scripts/,docs/,ref/orpatches/: upstream's pins there are not ours to change.pipPackages), which that test compares against the file.Not covered by Dependabot: the bundled CPython and the native tools (zstd, spirv-cross, glslangValidator, xcodegen) are pinned by source and checksum in
frontend/tools/bundle_tools.sh.Stacked on #258 (base
v0lumehi/bundle-zbic), because it moves the file that PR adds zbic to. Retarget tomainafter #258 merges.Checked
swift test --filter BundledToolsTests(24 tests, 0 failures).python3 scripts/patches.py checkOK.pip download --require-hashes --only-binary :all:for CPython 3.13 and macosx_11_0_arm64 resolves all 13 packages against the hashes.Screenshots
None.
Scope
dm/,scripts/,docs/,ref/,AGENTS.md) is edited directly