Skip to content

Repin moving action tags after they moved upstream - #987

Merged
epompeii merged 1 commit into
develfrom
ci/repin-setup-mold-v1
Aug 22, 2026
Merged

epompeii merged 1 commit into
develfrom
ci/repin-setup-mold-v1

Conversation

@epompeii

Copy link
Copy Markdown
Member

Problem

Lint / Zizmor Online fails on every pull request with 16 medium ref-version-mismatch findings, exit 13. The job is continue-on-error, so this is red noise rather than a merge blocker, but it hides any real finding that lands later.

Both pins name a moving ref in the trailing comment, and upstream moved that ref out from under the hash. The audit is online only, which is why the offline Zizmor job stays green.

Change

  • rui314/setup-mold, 15 sites. The v1 tag now points at 7e4f20ad28a2e8ca6fd0892ccf72e2abb706b9c3 ("Update default version to 2.42.0"), not the pinned 9c9c13bf.
  • dtolnay/rust-toolchain, 1 site in update_sandbox.yml. This one was not in the original report but is the same audit, and without it the job stays red. The comment said # master, and master moved off the pinned fa04a145. The hash now points at 6c977a6ca4077a0ceb28ffbe03f59d46e9ac8772 with a # v1 comment. Upstream v1 and master are the same commit today, and v1 is the convention every other pin in this repo uses, so this one does not go stale on the next upstream push.

Both hashes were resolved from the GitHub refs API rather than copied from a release page.

Proof

zizmor 1.29.0 locally, against CI's pinned v1.25.2, so CI has the final word.

  • Base tree, online: 315 findings, 16 medium, exit 13
  • This tree, online: 283 findings, 0 medium, exit 12

The 3 remaining low adhoc-packages findings predate this change and are untouched. They are also present in the offline run, which passes CI today, so low findings do not fail the job. Zero medium is the green condition.

`Lint / Zizmor Online` fails on every pull request with 16 medium
`ref-version-mismatch` findings. The job is `continue-on-error`, so this
is red noise rather than a merge blocker, but it hides any real finding
that lands later.

Both pins name a moving ref in the trailing comment, and upstream moved
that ref out from under the hash. The audit is online only, which is why
the offline `Zizmor` job stays green.

- `rui314/setup-mold`, 15 sites: `v1` now points at
  `7e4f20ad28a2e8ca6fd0892ccf72e2abb706b9c3` ("Update default version to
  2.42.0"), not the pinned `9c9c13bf`.
- `dtolnay/rust-toolchain`, 1 site in `update_sandbox.yml`: the comment
  said `# master`, and `master` moved off the pinned `fa04a145`. The
  hash now points at `6c977a6ca4077a0ceb28ffbe03f59d46e9ac8772` and the
  comment says `# v1`. Upstream `v1` and `master` are the same commit
  today, and `v1` is the convention every other pin in this repo uses,
  so this one does not go stale on the next upstream push.

Both hashes were resolved from the GitHub refs API rather than copied
from a release page.

Verified locally with zizmor 1.29.0, against CI's pinned v1.25.2. Online
run on the base tree: 16 medium, exit 13. Online run on this tree: 0
medium, exit 12, matching the offline run that already passes CI.
@epompeii
epompeii marked this pull request as ready for review August 22, 2026 15:28
@epompeii
epompeii merged commit efcfa6b into devel Aug 22, 2026
37 of 38 checks passed
@epompeii
epompeii deleted the ci/repin-setup-mold-v1 branch August 22, 2026 15:46
epompeii added a commit that referenced this pull request Oct 12, 2026
## Problem

`Lint / Zizmor Online` fails on every pull request (for example run
37884500334 on #1153) with one medium finding, exit 13:

```
warning[ref-version-mismatch]: action's hash pin has mismatched or missing version comment
  --> ./.github/workflows/update_sandbox.yml:18:81
18 |       - uses: dtolnay/rust-toolchain@7e38f4b # v1
   |                                                                                 ^^ points to commit e2a55d2ffb04
```

The upstream `v1` tag of `dtolnay/rust-toolchain` moved to
`e2a55d2ffb04f378e9626c28d38b36d230d1e12f` on 2026-10-09 when
dtolnay/rust-toolchain#187 merged. The job is `continue-on-error: true`,
so it does not block a merge, but it is red on every open pull request.

## Change

Repin `update_sandbox.yml` to the commit `v1` points at today and keep
the `# v1` comment. This follows #987, #1045, and #1088, which tracked
`v1` for this same pin, and `v1` is the only tag upstream publishes. The
hash was resolved from the GitHub refs API.

## Upstream range

`7e38f4b4...e2a55d2f` is three commits, all in `action.yml`, fixing the
command injection reported in dtolnay/rust-toolchain#179:

- Every input and the parsed toolchain move out of inline `${{ }}`
expressions in `run:` scripts and into `env:` variables, quoted at each
use.
- The parsed `toolchain` output is written with a heredoc delimiter
instead of `key=value`.
- The separate step that built `--target`, `--component`, and
`--allow-downgrade` strings is folded into the install step as a bash
array.

This call site passes only `toolchain: stable`, no targets or
components, so it was never exposed, and it still runs `rustup toolchain
install stable --profile minimal --no-self-update --force-non-host`
followed by `rustup default stable --force-non-host`. No other workflow
or composite action uses this action.

## Other moving refs

Every other pin whose comment names a moving ref still matches it today:
`rui314/setup-mold@10ca16bf # v1` (14 sites),
`dawidd6/action-download-artifact@b6e2e706 # v21` (2 sites), and
`superfly/flyctl-actions/setup-flyctl@ed8efb33 # master` (3 sites, the
current `master` head). Nothing else needs a change.

## Verification

zizmor 1.25.2, the version CI pins, from the same digest-pinned image
`zizmor-action` runs
(`ghcr.io/zizmorcore/zizmor:1.25.2@sha256:14ea7f5c...`), with the
action's arguments (`--persona=regular --format=github`, plus
`--no-online-audits` for the offline job):

| Tree | Offline | Online |
| --- | --- | --- |
| `devel` | exit 0 | exit 13, `1 medium` (the finding above) |
| this branch | exit 0 | exit 0, `No findings to report` |

CI on this pull request is the final check.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant