Skip to content

chore: add zizmor to repo checks#3837

Open
d-v-b wants to merge 9 commits intozarr-developers:mainfrom
d-v-b:chore/add-zizimor
Open

chore: add zizmor to repo checks#3837
d-v-b wants to merge 9 commits intozarr-developers:mainfrom
d-v-b:chore/add-zizimor

Conversation

@d-v-b
Copy link
Contributor

@d-v-b d-v-b commented Mar 25, 2026

Zizmor is tool that analyzes github actions and checks for security vulnerabilities.
Running it as part of pre-commit, and part of CI, will help ensure that we don't accidentally
make changes that lead to a security vulnerability.

edit: closes #3834

Zizmor is tool that analyzes github actions and checks for security vulnerabilities.
Running it as part of pre-commit, and part of CI, will help ensure that we don't accidentally
make changes that lead to a security vulnerability.
@github-actions github-actions bot added the needs release notes Automatically applied to PRs which haven't added release notes label Mar 25, 2026
@github-advanced-security
Copy link

You are seeing this message because GitHub Code Scanning has recently been set up for this repository, or this pull request contains the workflow file for the Code Scanning tool.

What Enabling Code Scanning Means:

  • The 'Security' tab will display more code scanning analysis results (e.g., for the default branch).
  • Depending on your configuration and choice of analysis tool, future pull requests will be annotated with code scanning analysis results.
  • You will be able to see the analysis results for the pull request's branch on this overview once the scans have completed and the checks have passed.

For more information about GitHub Code Scanning, check out the documentation.

@github-actions github-actions bot removed the needs release notes Automatically applied to PRs which haven't added release notes label Mar 25, 2026
@d-v-b
Copy link
Contributor Author

d-v-b commented Mar 25, 2026

lots of problems flagged by https://results.pre-commit.ci/run/github/48049137/1774469227.KlX2i8ypRcKQhbh3voSldQ, I will now fix them

@d-v-b d-v-b requested a review from maxrjones March 25, 2026 20:34
Comment on lines +79 to +81
# CODECOV_TOKEN is a low-sensitivity upload token, not a deploy key.
# Using an environment would gate every test run behind approval/deployment UI.
token: ${{ secrets.CODECOV_TOKEN }} # zizmor: ignore[secrets-outside-env]
Copy link
Member

Choose a reason for hiding this comment

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

we can have OIDC with codecov IIRC, which would work without a token. We can also use environments that do not need reviews. I just made the release env review-required because I thought it was a good idea.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

see #3837 (comment). I looked into setting up OIDC for codecov and I didn't get it 🙃 lmk if you know how it works.

Comment on lines +4 to +5
# pull_request_target is needed to label PRs from forks.
# This workflow only runs actions/labeler (no code checkout), so it's safe.
Copy link
Member

Choose a reason for hiding this comment

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

Just to note, the permissions in this workflow do not distinguish between writing code and labels, it's just a "write" permission. We could rethink the value of this labeler vs. a pre-release check for meaningful release notes for every commit if we want to be extra safe, or just leave this.

@d-v-b
Copy link
Contributor Author

d-v-b commented Mar 26, 2026

@maxrjones giving codecov its own environment creates notification spam (see screenshot below), so I'm going to revert that change.

image

@weiji14
Copy link

weiji14 commented Mar 26, 2026

giving codecov its own environment creates notification spam (see screenshot below), so I'm going to revert that change.

Use deployment: false to silence the noise - see
https://github.blog/changelog/2026-03-19-github-actions-late-march-2026-updates/#github-actions-now-allows-developers-to-use-environments-without-auto-deployment

@d-v-b
Copy link
Contributor Author

d-v-b commented Mar 26, 2026

giving codecov its own environment creates notification spam (see screenshot below), so I'm going to revert that change.

Use deployment: false to silence the noise - see https://github.blog/changelog/2026-03-19-github-actions-late-march-2026-updates/#github-actions-now-allows-developers-to-use-environments-without-auto-deployment

thank you @weiji14 that's great

Adds environments back to codecov and nightly wheel uploads, but this time with deployment: false,
which ensures that these workflows don't generate a lot of notifications on github.
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.

statically analyze github workflows

3 participants