Skip to content

fix(ci): restore main's ability to build under typescript 6.0.3 - #23

Merged
nsheaps-oura merged 2 commits into
mainfrom
nate-ai/fix-main-ci-ts6
Jul 27, 2026
Merged

fix(ci): restore main's ability to build under typescript 6.0.3#23
nsheaps-oura merged 2 commits into
mainfrom
nate-ai/fix-main-ci-ts6

Conversation

@nsheaps-oura

Copy link
Copy Markdown
Collaborator

Summary

main's CI has failed on every push since 2026-07-21 (~10 commits, including the just-merged ADX-525 Grafana jump buttons feature, #4). Three independent, compounding causes, all fixed here:

  • tsconfig.base.json: moduleResolution: "node" (deprecated alias for node10) is a hard error under TypeScript 6.0.3 (TS5107, removed entirely in 7.0). Switched to "bundler", the modern pairing for module: ESNext — no package in this repo does external imports, so this has zero effect on compiled output.
  • packages/github-actions-grafana-jump/tsconfig.json: under moduleResolution: bundler, tsc no longer auto-includes ambient globals from node_modules/@types the way it did under "node". This package's typeof module test-export guard and GM.* API calls need an explicit "types": ["node", "greasemonkey"] to keep resolving.
  • packages/github-actions-grafana-jump/package.json: still declared "typescript": "~5.8.3" — a stale copy from before the org-wide v6 bump, since this package was only added later via the ADX-525 PR and never got Renovate's bump. That mismatch against every other package's ~6.0.3 left yarn.lock without a consistent resolution, so yarn install --immutable (what CI actually runs) failed outright on some runs before ever reaching a TypeScript compile. Bumped to match; yarn.lock regenerated accordingly.

Also cherry-picked 4a38bf0 (from the still-open PR #7) to restore packages/graphite-to-github-button/src/index.ts, which has been missing from main since 4fc2806 renamed it straight to dist/script.user.js without ever compiling it — tsc --build for that package has been failing with "No inputs were found" independent of the typescript v6 issue, since before the v6 bump even landed.

Test plan

  • yarn install --immutable succeeds (this is what CI runs, and was failing before this change)
  • nx run-many --target=build --all --skip-nx-cache succeeds for all 5 packages, cache bypassed
  • github-actions-grafana-jump's existing 14 unit tests pass
  • Confirmed packages/graphite-to-github-button/dist/script.user.js (the already-committed, force-added artifact) is untouched by this change — bringing it back in sync with the now-restored src/index.ts is left to PR fix(graphite-to-github-button): compile dist/script.user.js instead of shipping raw TS #7, which already does that plus its own separate regen-dist workflow generalization
  • CI green on this PR (will confirm once checks run)

🤖 Generated with Claude Code

Commit 4fc2806 renamed src/index.ts straight to dist/script.user.js
without ever compiling it, leaving raw TypeScript (with type
annotations) committed under a .js extension. Recover the original
TypeScript source at its pre-rename content so it can be compiled
properly again.
main's CI has failed on every push since 2026-07-21 (the typescript v6
Renovate bump). Three independent, compounding causes, all fixed here:

- tsconfig.base.json: moduleResolution "node" (deprecated alias for
  node10) is a hard error under TS 6.0.3 (TS5107, removed in 7.0).
  Switch to "bundler", the modern pairing for module: ESNext - no
  package here does external imports, so zero effect on output.

- packages/github-actions-grafana-jump/tsconfig.json: under
  moduleResolution: bundler, tsc no longer auto-includes ambient
  globals from node_modules/@types the way it did under "node" - this
  package's `typeof module` test-export guard and GM.* API calls need
  an explicit `"types": ["node", "greasemonkey"]` to keep resolving.

- packages/github-actions-grafana-jump/package.json: still declared
  "typescript": "~5.8.3" (a stale copy from before the org-wide v6
  bump, since this package was only added later via the ADX-525 PR).
  That mismatch against every other package's ~6.0.3 left yarn.lock
  without a resolution for either range consistently, so `yarn install
  --immutable` (what CI actually runs) failed outright on some runs
  before ever reaching a TypeScript compile. Bumped to match; yarn.lock
  updated accordingly.

Also cherry-picked 4a38bf0 (from the still-open PR #7,
nate-ai/fix-graphite-to-github-build) to restore
packages/graphite-to-github-button/src/index.ts, which has been
missing from main since 4fc2806 renamed it straight to
dist/script.user.js without ever compiling it - `tsc --build` for that
package has been failing with "No inputs were found" independent of
the typescript v6 issue above, since before the v6 bump even landed.

Verified: `yarn install --immutable` succeeds, a full
`nx run-many --target=build --all --skip-nx-cache` (all 5 packages,
cache bypassed) succeeds, and github-actions-grafana-jump's existing
14 unit tests pass. The already-committed
packages/graphite-to-github-button/dist/script.user.js is untouched by
this change (confirmed via git status) - bringing it in sync with the
now-restored src/index.ts is left to PR #7, which already does that
plus its own separate regen-dist workflow generalization.
nsheaps-oura added a commit that referenced this pull request Jul 24, 2026
Merging main (which bumped typescript to ~6.0.3 org-wide) in brought
this package along for the first time on this branch, still carrying
two pre-existing gaps that block a clean build/immutable install:

- package.json still declared typescript ~5.8.3 (this package was
  added later via the ADX-525 merge, after the org-wide v6 bump, and
  never got Renovate's attention). That mismatch against every other
  package's ~6.0.3 left yarn.lock without a consistent resolution, so
  `yarn install --immutable` failed. Bumped to match; yarn.lock
  regenerated.
- tsconfig.json needed an explicit `"types": ["node", "greasemonkey"]`
  override: under this repo's moduleResolution: bundler setting, tsc
  doesn't auto-include @types/node/@types/greasemonkey's ambient
  globals (`module`, `GM`) the way it did under "node".

Same fixes as #23 (opened separately for
main directly); applying them here too since main hadn't merged that
PR yet when this branch picked up the package.
@nsheaps-oura
nsheaps-oura merged commit 2b4cec8 into main Jul 27, 2026
4 checks passed
@nsheaps-oura
nsheaps-oura deleted the nate-ai/fix-main-ci-ts6 branch July 27, 2026 15:44
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