Skip to content

ci: fix semgrep crash and accept 3 unfixable OSV advisories - #172

Merged
zircote merged 2 commits into
mainfrom
chore/ci-semgrep-osv
Oct 8, 2026
Merged

zircote merged 2 commits into
mainfrom
chore/ci-semgrep-osv

Conversation

@zircote

@zircote zircote commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Fixes the two pre-existing failures on main CI.

semgrep / sast-code

Semgrep 1.139.0 crashes on pydantic 2.14 (ImportError: eval_type_backport) on every run. Re-pins reusable-semgrep.yml in quality-gates.yml from 5c856f8 to .github main 63155e10b6f837069f71442f2e49186dd91d6509, which carries modeled-information-format/.github#90 (default Semgrep 1.180.0). Diffing the reusable workflow between the two SHAs shows only the semgrep-version default and an upload-sarif action bump; inputs, outputs, secrets, and permissions are unchanged, so the caller still matches.

release.yml's gate-semgrep gets the same re-pin (from the review pass), so the release attestation doesn't crash the same way and runs the same engine as the merge gate. attest-semgrep still gets the same sarif-artifact/sarif-filename outputs. The quality-gates.yml header comment no longer claims all gates share one pin SHA.

sca / osv-scanner

Adds osv-scanner.toml next to the only lockfile (repo root), modelled on MIF's, with justified [[IgnoredVulns]] for three advisories whose fix can't be reached within upstream ranges:

Advisory Package Path Why it can't be fixed
GHSA-vfj7-8cjw-p6xm braces 3.0.3 starlight-llms-txt → micromatch no fixed release exists
GHSA-238p-pmpm-9mq7 katex 0.16.47 astro-mermaid → mermaid fix 0.18.2, mermaid pins ^0.16
GHSA-rj75-hqrm-r3gf postcss-selector-parser 6.1.4 starlight → expressive-code → postcss-nested 6.2.0 fix 7.1.6, postcss-nested pins ^6.1.1

braces and postcss-selector-parser only run at build time, on repo-authored input. katex is only reachable through client-side mermaid on math in diagram labels. The site's one diagram is repo-authored and has no math, and the advisory also needs prototype pollution that already exists in the page.

package.json

Removes the stale "sharp@0.35.3": true allowScripts entry. The lock resolves sharp 0.35.5, which has no install script. The esbuild@0.28.1 entry stays because esbuild is still overridden to 0.28.1.

Verification (local)

  • osv-scanner scan source -r .: Filtered 3 vulnerabilities from output / No issues found
  • actionlint: clean
  • rm -rf node_modules && npm ci && npm run build: Complete! (8 pages)
  • claude plugin validate .: Validation passed

🤖 Generated with Claude Code

zircote and others added 2 commits October 8, 2026 15:27
- quality-gates.yml: re-pin reusable-semgrep.yml from 5c856f8 to .github
  main 63155e1, which defaults to Semgrep 1.180.0 (.github PR #90). Semgrep
  1.139.0 crashes on pydantic 2.14 (ImportError: eval_type_backport), failing
  `semgrep / sast-code` on every run. Inputs/outputs/permissions are unchanged
  between the two SHAs.
- osv-scanner.toml: add justified [[IgnoredVulns]] for braces 3.0.3
  (GHSA-vfj7-8cjw-p6xm, no fixed release), katex 0.16.47
  (GHSA-238p-pmpm-9mq7, fix outside mermaid's ^0.16 range) and
  postcss-selector-parser 6.1.4 (GHSA-rj75-hqrm-r3gf, fix outside
  postcss-nested 6.x's range), modelled on MIF's osv-scanner.toml.
- package.json: drop the stale `sharp@0.35.3` allowScripts entry; the lock
  resolves sharp 0.35.5, which has no install script.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Apply the same reusable-semgrep.yml re-pin (63155e1, Semgrep 1.180.0) to
release.yml's gate-semgrep so the release attestation does not crash on the
same pydantic ImportError and runs the same engine as the merge gate.
Outputs consumed by attest-semgrep are unchanged between the SHAs. Correct
the quality-gates.yml header that claimed one shared pin SHA.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@zircote
zircote merged commit a1596bc into main Oct 8, 2026
23 checks passed
@zircote
zircote deleted the chore/ci-semgrep-osv branch October 8, 2026 21:42
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.

1 participant