Repository navigation
feat(lockfiles): lockfile maintenance relocks moved refs in actions.lock - #305
Merged
Merged
Conversation
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
count-patchula | 37ce497 | Commit Preview URL Branch Preview URL |
Nov 14 2026, 03:10 AM |
Lockfile maintenance now plans an Actions job when .github/workflows/actions.lock exists and the github-actions manager is on. It runs gh-actions-lock with --relock over the whole workflow directory, with --no-onboard and --no-narrow as always, and never --accept-moved or --migrate-local-actions. A whole-directory run also prunes listed workflows that no longer exist; with --no-onboard the tool skips unlisted workflows entirely when it writes, so nothing is onboarded. The run uses the update run's environment and token, and the same classification: a retryable finding waits, any other blocking finding (an unreachable-pin in any workflow included) fails with the tool's category and detail. Proof: the regenerated lock must list exactly the listed workflows the repository still holds (a relock may drop only deleted ones, and adds none), then --verify-local over that set (a whole-directory verify would fail on every unlisted workflow), and the commit may hold actions.lock alone; a relock that rewrites a workflow fails. When every listed workflow is gone the tool removes actions.lock, and the maintenance commit deletes it; a removal while a listed workflow remains fails. A failed relock holds only itself: the tree goes back to what the other maintenance jobs left, and the failure is a report warning unless nothing else changed, when it fails the branch. The maintenance PR lists each moved ref under its workflow, read from the lock diff: the tool prints a ref-moved finding for a moved direct ref but not for one inside a composite. With an Actions job, a workflow or action file that is not a regular file (a symlink) stays out of the checkout instead of failing it: the tool fails on what it cannot read, which holds only the Actions work. On the update path a $/ callers walk that reaches one holds the update. A lock without dependencies: (the tool omits an empty map) reads back. Finding.retryable now defaults to false: the tool writes it omitempty, so a non-retryable finding no longer reads as unparseable. Behaviour change: in a repository with .github/workflows/actions.lock, lockfile maintenance advances the refs that moved upstream in the workflows the lockfile lists, drops listed workflows that were deleted, lists the moved refs in the maintenance PR, and deletes actions.lock when every workflow it lists is gone. It never adds a workflow or action, never rewrites a workflow, and applies no release-age wait to what it picks up.
sweepies
force-pushed
the
feat/actions-lock-relock
branch
from
November 14, 2026 03:10
e280952 to
37ce497
Compare
Merged
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.
In a repository that commits
.github/workflows/actions.lock, lockfile maintenance now advances the refs that moved upstream (a floating@v7, or a ref inside a composite action) and lists them in the maintenance PR. This is PR 4 of the actions.lock work, after #300, #302 and #303.Behaviour change
gh-actions-lock --relockover the whole workflow directory, with--no-onboard --no-narrow --ignore-local-actionsas always and never--accept-movedor--migrate-local-actions. It uses the same environment, token and masking as the update run.--no-onboardthe tool skips workflows that have no lock entry when it writes. A real-tool test with an unlisted workflow confirms this.--verify-localpasses over that set, and the commit may hold onlyactions.lock. A relock that rewrites a workflow fails. When every listed workflow is gone, maintenance deletes the lock and the PR says so.unreachable-pinin any workflow: fails with the tool's category and detail.actions/checkout@v7now resolves to3d3c42e; the lock had9c091bb". The list is read from the lock diff, because the tool reports no finding for a ref that moved inside a composite.Finding.retryablenow defaults to false. The tool omits it when false, so a non-retryable hold read as "unparseable findings".Tests
actions/checkout@v7, a transitiveactions/setup-go@v5insidecli/[email protected], and a current lock (no change).actions.lock.corpus:snapshotis unchanged; one transcript row is added; the state rows are rehashed.Follow-ups
uses:line for a private repository that token can read. The next relock would then publish its commit SHA in a bot PR. This needs no update to trigger. On the App server the token is read-only metadata scoped to one repository, so the risk is nil there.fresh-tagwarning is not shown.