Skip to content

Switch versions to SHA - #610

Merged
jeremykubica merged 14 commits into
mainfrom
permissions
Oct 12, 2026
Merged

jeremykubica merged 14 commits into
mainfrom
permissions

Conversation

@jeremykubica

@jeremykubica jeremykubica commented Oct 12, 2026 •

Copy link
Copy Markdown
Collaborator

Closes #581

Changes to use SHA-tagging instead of version tags as recommended by github: https://docs.github.com/en/actions/reference/security/secure-use#using-third-party-actions

Tested via: lincc-frameworks/citation-compass#56

jeremykubica and others added 14 commits October 9, 2026 14:56
Co-Authored-By: Copilot <198982749+Copilot@users.noreply.github.com>
…}.jinja

Co-Authored-By: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-Authored-By: Copilot <198982749+Copilot@users.noreply.github.com>
Co-Authored-By: Copilot <198982749+Copilot@users.noreply.github.com>
Co-Authored-By: Copilot <198982749+Copilot@users.noreply.github.com>
After `persist-credentials: false` the `git ls-remote` would fail. This switches to using show-ref and using the local repositort

Co-Authored-By: Copilot <198982749+Copilot@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The selected setup-uv and action-send-mail SHAs do not match the tags being replaced.

8 open findings
What changed in this PR

Pins GitHub Actions dependencies to immutable commit SHAs to improve workflow supply-chain security.

Changes:

  • Pins actions in repository CI workflows.
  • Applies equivalent pinning to generated project workflow templates.
  • Covers testing, documentation, publishing, benchmarking, and notifications.
File Description
.github/​workflows/​add-issue-to-project.yml Pins project automation.
.github/​workflows/​pre-commit-ci.yml Pins pre-commit workflow actions.
.github/​workflows/​smoke-test.yml Pins smoke-test actions.
.github/​workflows/​testing-and-coverage.yml Pins test and coverage actions.
python-project-template/​.github/​workflows/​pre-commit-ci.yml.jinja Pins generated pre-commit actions.
python-project-template/​.github/​workflows/​{% if include_docs %}build-documentation.yml{% endif %}.jinja Pins documentation actions.
python-project-template/​.github/​workflows/​{% if include_benchmarks %}publish-benchmarks-pr.yml{% endif %}.jinja Pins benchmark-comment actions.
python-project-template/​.github/​workflows/​{% if include_benchmarks %}asv-pr.yml{% endif %}.jinja Pins pull-request benchmark actions.
python-project-template/​.github/​workflows/​{% if include_benchmarks %}asv-nightly.yml{% endif %}.jinja Pins nightly benchmark actions.
python-project-template/​.github/​workflows/​{% if include_benchmarks %}asv-main.yml{% endif %}.jinja Pins benchmark deployment actions.
python-project-template/​.github/​workflows/​{% if contains_code %}testing-and-coverage.yml{% endif %}.jinja Pins generated testing actions.
python-project-template/​.github/​workflows/​{% if contains_code %}smoke-test.yml{% endif %}.jinja Pins generated smoke-test actions.
python-project-template/​.github/​workflows/​{% if contains_code %}publish-to-pypi.yml{% endif %}.jinja Pins publishing prerequisites.

🧠 Review effort: Balanced


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread .github/workflows/pre-commit-ci.yml
Comment thread .github/workflows/smoke-test.yml
Comment thread .github/workflows/testing-and-coverage.yml
Comment thread python-project-template/.github/workflows/pre-commit-ci.yml.jinja
@jeremykubica
jeremykubica marked this pull request as ready for review October 12, 2026 13:42
@jeremykubica
jeremykubica requested a review from hombit October 12, 2026 13:42

@hombit hombit left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Should we do the same with the pre-commit hook versions?

@jeremykubica
jeremykubica merged commit cd59f4f into main Oct 12, 2026
9 checks passed
@jeremykubica
jeremykubica deleted the permissions branch October 12, 2026 14:11
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.

Change third party github actions to target specific commits rather than tags

3 participants