Turbocharge Claude Code, Cursor, Codex, Gemini & every coding agent: faster, cheaper, with contextual understanding specific to your codebase.
TypeScript ai-agentsanthropicclaude-codeclicode-graphcodexcontext-engineeringcursordeveloper-toolsgeminiknowledge-graphllmmcpmcp-serveropen-sourceopenaitree-sitter
test: pin Node 24 WASM compatibility (#136)
N.S.Devaraja5ceac7a3001
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.ymlindex c0dc093f..2e611b94 100644--- a/.github/workflows/ci.yml+++ b/.github/workflows/ci.yml@@ -56,3 +56,24 @@ jobs:- name: Testrun: npm test++ node24-wasm:+ name: Node 24 WASM regression+ runs-on: ubuntu-latest+ steps:+ - name: Checkout code+ uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4+ with:+ persist-credentials: false++ - name: Setup Node.js+ uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4+ with:+ node-version: '24'+ cache: npm++ - name: Install dependencies+ run: npm ci++ - name: Exercise every breadth grammar+ run: node --import tsx --test test/generic-node24.test.tsdiff --git a/CHANGELOG.md b/CHANGELOG.mdindex 26da5714..4bb1f8bc 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -238,6 +238,11 @@### Fixed+- **Node 24 no longer aborts breadth-tier builds with `Fatal process out of+ memory: Zone`.** The broader `tree-sitter-wasm` grammar bundle avoids the V8+ Turboshaft failure triggered by the previous bundle. CI now exercises every+ breadth grammar under Node 24 to keep that runtime compatibility pinned+ ([#122]).- **`npm install -g @nanonets/graft@latest` could silently do nothing.** Thegenerated shims (`.claude/helpers/graft-*.cjs`, and Codex's`~/.codex/hooks/graft/`) locate the installed package at runtime from fourdiff --git a/test/generic-node24-probe.ts b/test/generic-node24-probe.tsnew file mode 100644index 00000000..9e1eb01a--- /dev/null+++ b/test/generic-node24-probe.ts@@ -0,0 +1,11 @@+import { extractGeneric, GENERIC_LANGS, warmGenericGrammars } from "../src/graph/generic.js";++const languages = GENERIC_LANGS.map((lang) => lang.name);+const source = "pub fn run() -> usize { helper() }\nfn helper() -> usize { 1 }\n";++await warmGenericGrammars(languages);+for (let iteration = 0; iteration < 64; iteration++) {+ for (const language of languages) {+ extractGeneric(`src/probe-${iteration}.${language}`, source, language);+ }+}diff --git a/test/generic-node24.test.ts b/test/generic-node24.test.tsnew file mode 100644index 00000000..965babbc--- /dev/null+++ b/test/generic-node24.test.ts@@ -0,0 +1,22 @@+import { test } from "node:test";+import assert from "node:assert/strict";+import { spawnSync } from "node:child_process";+import { dirname, join } from "node:path";+import { fileURLToPath } from "node:url";++test(+ "Node 24 can exercise every breadth grammar without a V8 Zone OOM",+ { skip: Number(process.versions.node.split(".")[0]) < 24 ? "V8 Turboshaft regression starts in Node 24" : false },+ () => {+ const probe = join(dirname(fileURLToPath(import.meta.url)), "generic-node24-probe.ts");+ const run = spawnSync(process.execPath, ["--import", "tsx", probe], {+ encoding: "utf8",+ timeout: 60_000,+ });+ assert.equal(+ run.status,+ 0,+ `breadth grammar probe failed${run.signal ? ` with ${run.signal}` : ""}:\n${run.stdout}\n${run.stderr}`,+ );+ },+);