Skip to content

ci: fix @types/node resolution in CI and add OpenSSF Scorecard#8

Merged
sanjayshukla98 merged 2 commits into
mainfrom
fix/ci-types-and-scorecard
Jun 29, 2026
Merged

ci: fix @types/node resolution in CI and add OpenSSF Scorecard#8
sanjayshukla98 merged 2 commits into
mainfrom
fix/ci-types-and-scorecard

Conversation

@sanjayshukla98

Copy link
Copy Markdown
Contributor

What & why

CI was failing on main (the source of the red CI badge): the strict typecheck reported TS2591: Cannot find name 'process' because @types/node global types were not being auto-included in the GitHub runner environment.

Fixes

  • tsconfig: explicitly set compilerOptions.types to ["node", "jest"] so node + jest ambient globals load deterministically across environments (ts-jest shares this config, so jest is included to keep tests typing).
  • OpenSSF Scorecard: add .github/workflows/scorecard.yml that runs Scorecard and publish_results: true, which populates the public Scorecard API and turns the invalid repo path badge green.

Verified locally

  • tsc --noEmit
  • jest — 16 tests, 5 snapshots ✅
  • biome ✅

🤖 Generated with Claude Code

sanjayshukla98 and others added 2 commits June 29, 2026 12:04
The strict typecheck failed in CI with TS2591 "Cannot find name 'process'"
because @types/node global types were not auto-included in the runner's
environment. Explicitly set compilerOptions.types to ["node", "jest"] so the
node and jest ambient globals load deterministically (ts-jest shares this
config, hence jest is included).

Also add an OpenSSF Scorecard workflow that publishes results, which powers the
Scorecard badge (previously "invalid repo path" because no analysis had run).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The snapshot test failed in CI because the DEV personal-stage disambiguator
defaults to process.env.USER (e.g. 'runner' in Actions vs a developer's
username locally), so synthesized resource names differed from the committed
baseline. Pin USER='test' in both test files and regenerate the snapshots so
the suite is reproducible everywhere.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@sanjayshukla98 sanjayshukla98 merged commit 87ab206 into main Jun 29, 2026
1 check passed
@sanjayshukla98 sanjayshukla98 deleted the fix/ci-types-and-scorecard branch June 29, 2026 19:08
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