Skip to content

chore: skip TypeScript 7.0 in Renovate until 7.1 ships an API - #581

Merged
kylehoehns merged 1 commit into
mainfrom
chore/pin-typescript-below-7
Sep 9, 2026
Merged

chore: skip TypeScript 7.0 in Renovate until 7.1 ships an API#581
kylehoehns merged 1 commit into
mainfrom
chore/pin-typescript-below-7

Conversation

@kylehoehns

Copy link
Copy Markdown
Contributor

Tells Renovate to skip TypeScript 7.0 but take 7.1 as soon as it comes out. This closes out #576, which cannot pass today.

The problem

TypeScript 7 is a rewrite of the compiler in Go. It is much faster, but it shipped on purpose without a programmatic API, meaning other tools cannot call into it from JavaScript. If you load it, this is everything you get:

Object.keys(require('typescript')) // [ 'version', 'versionMajorMinor' ]

Two of our tools are built on that missing API:

  • typescript-eslint throws the moment it is imported, so pnpm lint dies. That is what chore: update dependency typescript to v7 #576 has been failing on.
  • ts-jest would break next. It says it works with typescript: >=4.3 <7. We have not seen this failure yet only because lint runs first and stops the build.

So #576 is not one broken thing we could patch around. It is two, and neither is ours to fix.

What upstream says

Both maintainers have answered this directly, and both are waiting on the same thing.

typescript-eslint (issue #10940), 2026-07-09:

For now - there is nothing we can do to support tsgo / TSv7 [...] there is currently no stable JS API.

They locked that thread to keep the noise down, so it looks quiet. It is not abandoned.

ts-jest (issue #5366), 2026-07-29:

We'll essentially need to wait for 7.1 (assuming the stable programmatic api will land in 7.1)

Microsoft's own TypeScript 7.0 announcement says the same, and names typescript-eslint as one of the tools it affects:

While TypeScript 7.0 is here, it does not ship with an API. We expect TypeScript 7.1 to ship with a new (and different) API [...]

The change

One new rule in renovate.json:

{
  "matchPackageNames": ["typescript"],
  "allowedVersions": "<7.0.0 || >=7.1.0"
}

The range is <7.0.0 || >=7.1.0 rather than a plain <7 on purpose. A plain <7 would block TypeScript forever until a person noticed and removed it. This version skips only the broken 7.0.x releases and starts offering upgrades again by itself the day 7.1 ships.

I checked the range against real version numbers:

Version Offered?
6.0.0 yes
6.9.9 yes
7.0.0 no
7.0.2 no
7.1.0-dev.20260909.1 no
7.1.0 yes
7.2.0 yes

The 7.1.0-dev line matters. TypeScript is publishing nightly builds of 7.1 right now, and this range leaves them alone. We will get 7.1.0 proper, not a nightly.

The rule carries a description field explaining why it exists and linking both upstream issues, so whoever finds it later does not have to work this out again.

How I checked

  • renovate-config-validator --strict passes.
  • pnpm verify passes: lint, format, type-check, build, and 34 test suites / 265 tests.

When to remove this

Once TS 7.1 is out and both typescript-eslint and ts-jest support it, delete the rule. TypeScript 7.1 is currently expected in autumn 2026, so this may be a short wait.

Also

Please close #576. It cannot pass, and once this merges Renovate will stop proposing that upgrade.

🤖 Generated with Claude Code

https://claude.ai/code/session_019dUo24dvyCizU9GbU9dTww

TypeScript 7.0 is the native (tsgo) port and deliberately shipped with no
programmatic compiler API. Its entire JS export surface is `version` and
`versionMajorMinor`, so every tool built on the old API breaks:

  - typescript-eslint throws at import time, failing `pnpm lint`
  - ts-jest declares peer `typescript: >=4.3 <7`, which would fail
    `pnpm test` next

Both maintainers have said they are waiting on the API expected in TS 7.1,
and typescript-eslint has locked its thread in the meantime.

Use `<7.0.0 || >=7.1.0` rather than a flat `<7` so the upgrade flows again
on its own once 7.1 is released. The range excludes 7.1.0-dev prereleases,
so this will not pull nightlies.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019dUo24dvyCizU9GbU9dTww
@kylehoehns
kylehoehns merged commit 84b349e into main Sep 9, 2026
1 check passed
@kylehoehns
kylehoehns deleted the chore/pin-typescript-below-7 branch September 9, 2026 14:41
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