Skip to content

Lock GitHub Actions workflows - #161811

Merged
hugovk merged 4 commits into
python:mainfrom
hugovk:3.16-gha-lockfile
Nov 12, 2026
Merged

hugovk merged 4 commits into
python:mainfrom
hugovk:3.16-gha-lockfile

Conversation

@hugovk

@hugovk hugovk commented Nov 11, 2026

Copy link
Copy Markdown
Member

GitHub Actions now supports lockfiles for workflows.

See https://hugovk.dev/blog/2026/lock-github-actions/


Also update zizmor in prek to support lockfiles (I also updated the other hooks, they don't trigger any code changes).

It has a new finding about new $/ self-repository syntax, let's fix it:

  help[self-repository]: use GitHub's dedicated self-repository syntax
     --> .github/workflows/reusable-docs.yml:107:11
      |
  104 |     name: 'Check for removed HTML IDs'
      |     ---------------------------------- this job
  ...
  107 |     uses: ./.github/workflows/reusable-check-html-ids.yml
      |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ use '$/...' instead of './...'
      |
      = note: audit confidence → High
      = note: this finding has an auto-fix

However, https://github.com/rhysd/actionlint doesn't yet support the $/ syntax (rhysd/actionlint#711), so ignore that in actionlint.

We're already ignoring it's lack of support for ubuntu-26.04* runners (rhysd/actionlint#682).

There are pending PRs, but the tool author isn't active, so we could consider this fork:
rhysd/actionlint#719 (comment). Perhaps when we need to add a third ignore...


Finally, zizmor also flags this:

  help[adhoc-packages]: ad-hoc installation of packages
    --> .github/workflows/new-bugs-announce-notifier.yml:21:14
     |
  21 |       - run: npm install mailgun.js form-data
     |         ---  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ installs a package outside of a lockfile
     |         |
     |         this step
     |
     = note: audit confidence → High

I added a temporary zizmor ignore on that, let's tackle that in a follow up with an npm lockfile or a Python stdlib version.

@hugovk
hugovk requested review from a team, DinoV, Yhg1s, hoodmane and pablogsal as code owners November 11, 2026 16:30
@hugovk hugovk added the infra CI, GitHub Actions, buildbots, Dependabot, etc. label Nov 11, 2026
@hugovk hugovk added the needs backport to 3.15 bugs and security fixes label Nov 12, 2026
@miss-islington-app

Copy link
Copy Markdown

Thanks @hugovk for the PR 🌮🎉.. I'm working now to backport this PR to: 3.15.
🐍🍒⛏🤖

@miss-islington-app

Copy link
Copy Markdown

Sorry, @hugovk, I could not cleanly backport this to 3.15 due to a conflict.

Please backport manually with cherry_picker, see the devguide for more information.

cherry_picker 16b9ac289d655cf88843752af9f9883fe973e2f1 3.15

@bedevere-app

bedevere-app Bot commented Nov 12, 2026

Copy link
Copy Markdown

GH-161882 is a backport of this pull request to the 3.15 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.15 bugs and security fixes label Nov 12, 2026
hugovk added a commit that referenced this pull request Nov 12, 2026
hugovk added a commit to hugovk/cpython that referenced this pull request Nov 12, 2026
(cherry picked from commit 023c3d1)

Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
(cherry picked from commit 16b9ac2)
hugovk added a commit that referenced this pull request Nov 12, 2026
(cherry picked from commit 023c3d1)


(cherry picked from commit 16b9ac2)
hugovk added a commit to hugovk/cpython that referenced this pull request Nov 12, 2026
(cherry picked from commit 023c3d1)

Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
(cherry picked from commit 16b9ac2)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

infra CI, GitHub Actions, buildbots, Dependabot, etc. skip issue skip news

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants