chore(core,sdk): move the AI SDK v7 forward-compat typecheck out of CI#3854
Conversation
The forward-compat pass (tsc -p tsconfig.ai-v7.json) remaps `ai` to the ESM-only v7 canary via tsconfig paths, which makes it uniquely sensitive to how dependencies are laid out on disk. A clean install and a restored dependency cache can resolve the canary's module format differently, and when they diverge the pass emits spurious TS1479 errors that block the typecheck job gating the publish, even on a green tree. Drop it from the gating `typecheck` script in both packages; keep it as a standalone `typecheck:ai-v7` for on-demand runs.
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
📜 Recent review details⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (31)
🧰 Additional context used📓 Path-based instructions (1)**/*.{js,ts,tsx,jsx,css,json,md}📄 CodeRabbit inference engine (AGENTS.md)
Files:
🧠 Learnings (21)📓 Common learnings📚 Learning: 2025-11-26T14:40:07.146ZApplied to files:
📚 Learning: 2026-03-02T12:43:34.140ZApplied to files:
📚 Learning: 2026-04-16T14:19:16.330ZApplied to files:
📚 Learning: 2026-06-02T21:20:56.997ZApplied to files:
📚 Learning: 2025-11-27T16:26:44.496ZApplied to files:
📚 Learning: 2025-11-27T16:26:37.432ZApplied to files:
📚 Learning: 2026-06-02T21:20:56.997ZApplied to files:
📚 Learning: 2026-03-02T12:43:34.140ZApplied to files:
📚 Learning: 2025-11-27T16:26:44.496ZApplied to files:
📚 Learning: 2026-06-02T21:20:43.541ZApplied to files:
📚 Learning: 2026-06-02T21:20:48.921ZApplied to files:
📚 Learning: 2025-11-27T16:26:37.432ZApplied to files:
📚 Learning: 2025-11-27T16:26:37.432ZApplied to files:
📚 Learning: 2026-03-02T12:43:34.140ZApplied to files:
📚 Learning: 2026-03-25T15:29:25.889ZApplied to files:
📚 Learning: 2026-06-02T21:20:43.541ZApplied to files:
📚 Learning: 2026-03-25T15:29:25.889ZApplied to files:
📚 Learning: 2026-03-25T15:29:25.889ZApplied to files:
📚 Learning: 2026-03-02T12:43:34.140ZApplied to files:
📚 Learning: 2026-03-25T15:29:25.889ZApplied to files:
🔇 Additional comments (2)
WalkthroughThis PR splits TypeScript type-checking commands across two packages. In 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
The SDK and core packages run a second, forward-compat typecheck pass (
tsc --noEmit -p tsconfig.ai-v7.json) that remaps theaiimport to the ESM-only AI SDK 7 canary so we catch source that only compiles against one major. Because it resolvesaithrough tsconfigpaths, it's uniquely sensitive to how dependencies are laid out on disk: a clean install and a restored dependency cache can resolve the canary's module format differently, and when they diverge the pass emits spuriousTS1479("CommonJS module cannot require an ECMAScript module") errors on theaiimport even though the source is fine in a clean checkout.That pass shares the typecheck job that gates the Docker image publish, so a spurious failure there blocks publishing on an otherwise green tree.
This moves the pass out of the gating
typecheckscript in both packages and into a standalonetypecheck:ai-v7script that can be run on demand. The regulartypechecknow only checks against the installedai, which resolves consistently across install layouts.