Skip to content

chore: add zizmor (pre-commit) and fix its auditor findings - #210

Merged
fstagni merged 4 commits into
DIRACGrid:mainfrom
fstagni:zizmor-auditor
Nov 18, 2026
Merged

fstagni merged 4 commits into
DIRACGrid:mainfrom
fstagni:zizmor-auditor

Conversation

@fstagni

@fstagni fstagni commented Nov 15, 2026

Copy link
Copy Markdown
Contributor

Part of DIRACGrid/.github#5 (add zizmor everywhere as pre-commit), same as DIRACGrid/intercede#43.

  • pre-commit: zizmor hook (--no-online-audits).
  • Both workflows brought zizmor-clean with the auditor persona (zizmor --no-online-audits --persona=auditor):
    • persist-credentials: false on all checkouts (artipacked)
    • workflow/job permissions minimized with comments (excessive-permissions)
    • concurrency groups (concurrency-limits) and job name (anonymous-definition)
    • template expansions in run: blocks moved to env (template-injection)
  • One documented suppression: GH_TOKEN in release.yaml (secrets-outside-env) — release creation needs no GitHub environment.

zizmor v1.32.0 reports no findings with both the default and the auditor persona.

@fstagni fstagni closed this Nov 16, 2026
@fstagni fstagni reopened this Nov 16, 2026
@fstagni
fstagni marked this pull request as ready for review November 16, 2026 16:23
fstagni and others added 3 commits November 17, 2026 17:44
The installer only bundles micromamba, so 'conda env export' fails with
'conda: command not found'. Reproduce the same conda-style environment.yaml
(the format parsed by scripts/make_release.py) from 'micromamba list --json'.
…rt with DIRACGrid#211

- trailing-whitespace, end-of-file-fixer, check-yaml, check-added-large-files
  and black were dropped together with their 2021 pins; restore them at
  current versions (pre-commit-hooks v6.0.0, black 26.10.1) and apply their
  three small fixes
- default_language_version python3: no hook needs exactly Python 3.11
- use the same one-line micromamba env export as DIRACGrid#211, so
  the two PRs merge in either order

Assisted-by: Claude:claude-opus-5-5
- build-and-test: cancel superseded runs only on PRs; a push to main must
  not cancel the nightly run whose artifacts a release uses
- release: the release is created with secrets.GH_TOKEN, so the
  GITHUB_TOKEN only needs contents: read; fix the concurrency comment
  (GitHub keeps one pending run per group, a newer dispatch replaces it)

Assisted-by: Claude:claude-opus-5-5
@fstagni
fstagni merged commit cc3263e into DIRACGrid:main Nov 18, 2026
31 of 32 checks passed
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.

2 participants