Skip to content

fix(ci): add the SPDX headers the workflow linter requires - #689

Merged
hyperpolymath merged 1 commit into
mainfrom
fix/workflow-spdx-headers
Aug 7, 2026
Merged

fix(ci): add the SPDX headers the workflow linter requires#689
hyperpolymath merged 1 commit into
mainfrom
fix/workflow-spdx-headers

Conversation

@hyperpolymath

Copy link
Copy Markdown
Owner

All 27 workflows lacked # SPDX-License-Identifier: on line 1 — the actual cause of governance / Workflow security linter failing on every open hypatia PR. The check name suggests a pinning problem; the pin and lockfile checks in that job already pass.

MPL-2.0, matching the 135 source files that already carry it.

Verified locally

  • all 27 workflows still parse
  • estate duplicate-key scanner: 27 files clean
  • gh actions-lock --verify-local: complete lockfile coverage retained
  • the linter's SPDX + permissions checks pass when reproduced

⚠ Header inserted at line 1 only, and each file parsed after editing — blind positional insertion is what produced 100 unparseable workflows in an earlier estate sweep.

🤖 Generated with Claude Code

All 27 workflows were missing `# SPDX-License-Identifier:` on line 1, which is
what `governance / Workflow security linter` was failing on across every open
hypatia pull request. The check name reads as a pinning problem; it was not one
— the pin and lockfile checks in that same job already pass.

MPL-2.0, matching the 135 source files that already carry it.

⚠ Inserted at line 1 ONLY. A comment is valid there in every YAML document,
including one opening with `---`. Positional insertion anywhere else is what
produced 100 unparseable workflows across the estate in an earlier sweep, so
each file is parsed after the edit rather than assumed.

Verified: all 27 parse; the estate duplicate-key scanner reports them clean;
`gh actions-lock --verify-local` still reports complete lockfile coverage (the
header does not disturb the managed region); and the linter's own SPDX and
permissions checks pass when reproduced locally.
@gitar-bot

This comment has been minimized.

@gitar-bot
gitar-bot Bot enabled auto-merge (squash) August 7, 2026 10:21

@gitar-bot gitar-bot Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Gitar has auto-approved this PR and enabled auto-merge (configure)

@gitar-bot gitar-bot Bot added the gitar-approved Added by Gitar label Aug 7, 2026
@hyperpolymath
hyperpolymath merged commit d10456b into main Aug 7, 2026
59 of 83 checks passed
@hyperpolymath
hyperpolymath deleted the fix/workflow-spdx-headers branch August 7, 2026 10:22
hyperpolymath added a commit that referenced this pull request Aug 7, 2026
`#689` added `# SPDX-License-Identifier: MPL-2.0` to 27 workflows on the
premise they had no SPDX header. They all had one — just not on **line
1**, the only place the linter looks (`head -1 | grep`).

24 already declared MPL-2.0 (duplicate, harmless). **Three declared
`PMPL-1.0-or-later`**, where the added line shadowed the real licence as
the first declaration:

- `.github/workflows/governance.yml`
- `.github/workflows/hypatia-scan.yml`
- `.github/workflows/scorecard.yml`

Each file's own identifier is moved to line 1 and the duplicate removed
— no licence restated, none changed.

**Verified**: 0 duplicate SPDX lines · 0 missing on line 1 · the 3 PMPL
files keep PMPL · all 27 parse · `gh actions-lock --verify-local`
reports complete coverage.

🤖 Generated with [Claude Code](https://claude.com/claude-code)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

gitar-approved Added by Gitar

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant