Skip to content

Pin third-party GitHub Actions to commit SHAs to make CI rollback deterministic #163

Closed as duplicate

Description

@ooloth

Why

CI depends on actions/checkout@v4, dtolnay/rust-toolchain@stable, and Swatinem/rust-cache@v2 — all mutable tags that can be silently force-pushed to a different commit, making CI failures from upstream action changes hard to diagnose or reproduce.

Current state

.github/workflows/ci.yml references three third-party actions by mutable floating tags:

  • actions/checkout@v4
  • dtolnay/rust-toolchain@stable
  • Swatinem/rust-cache@v2

A tag can be silently updated by the upstream maintainer, changing CI behaviour without any change to this repo. When that happens there is no way to identify what changed or revert to a known-good action version without an explicit SHA to target.

Ideal state

  • Each action reference in ci.yml includes a full commit SHA (e.g. actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4).
  • A tag or version comment alongside each SHA preserves human-readable context.
  • The exact action set that passed CI on any past commit is reproducible by checking out that commit and re-running CI.

Out of scope

  • Pinning Cargo dependencies (governed by Cargo.lock).
  • Pinning the cargo-audit, cargo-deny, and cargo-nextest tool versions installed inline in CI (a separate concern).

Starting points

  • .github/workflows/ci.yml — the three uses: lines referencing actions/checkout, dtolnay/rust-toolchain, and Swatinem/rust-cache

QA plan

  1. Open .github/workflows/ci.yml — expect all three uses: lines to include a full 40-character commit SHA.
  2. Confirm each SHA line includes a # v<version> or # <tag> comment for human readability.
  3. Push to a branch and confirm CI runs successfully with the pinned SHAs.

Done when

All third-party action references in ci.yml are pinned to commit SHAs with human-readable version comments.

Activity

  1. ooloth commented on Oct 7, 2026

    @ooloth
    OwnerAuthor

    Duplicate of #230.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions