Never stop coding. Free MIT AI gateway: one endpoint, 375 providers (150+ free), 1,400+ models Kimi, Claude, GPT, Gemini, GLM, DeepSeek, MiniMax. Works with Claude Code, Codex, Cursor, OpenCode, Cline & Copilot. Quota-aware auto-fallback, RTK+Caveman compression saves 15-95% tokens, MCP/A2A, Desktop/PWA. Built by 900+ contributors
TypeScript a2aai-agentsai-gatewayanthropicclaudeclaude-codeclinecodexcopilotcursordeepseekfree-aigeminikimillm-gatewaymcpopenaiopenai-proxyqwentoken-saver
fix(infrastructure): move wreq-js to optionalDependencies and add Node 25/26 to secure runtime policy (#1924)
diegosouzapw0083d643bc01
diff --git a/bin/nodeRuntimeSupport.mjs b/bin/nodeRuntimeSupport.mjsindex 8c203f0722..0dfdd81424 100644--- a/bin/nodeRuntimeSupport.mjs+++ b/bin/nodeRuntimeSupport.mjs@@ -4,12 +4,14 @@ export const SECURE_NODE_LINES = Object.freeze([Object.freeze({ major: 20, minor: 20, patch: 2 }),Object.freeze({ major: 22, minor: 22, patch: 2 }),Object.freeze({ major: 24, minor: 0, patch: 0 }),+ Object.freeze({ major: 25, minor: 0, patch: 0 }),+ Object.freeze({ major: 26, minor: 0, patch: 0 }),]);export const RECOMMENDED_NODE_VERSION = "24.14.1";-export const SUPPORTED_NODE_RANGE = ">=20.20.2 <21 || >=22.22.2 <23 || >=24.0.0 <25";+export const SUPPORTED_NODE_RANGE = ">=20.20.2 <21 || >=22.22.2 <23 || >=24.0.0 <27";export const SUPPORTED_NODE_DISPLAY =- "Node.js 20.20.2+ (20.x LTS), 22.22.2+ (22.x LTS), or 24.0.0+ (24.x LTS)";+ "Node.js 20.20.2+ (20.x LTS), 22.22.2+ (22.x LTS), 24.0.0+ (24.x LTS), 25.0.0+ (25.x), or 26.0.0+ (26.x)";function formatVersion(version) {return `${version.major}.${version.minor}.${version.patch}`;@@ -52,7 +54,7 @@ export function getNodeRuntimeSupport(version = process.versions.node) {reason = "supported";} else if (secureFloor) {reason = "below-security-floor";- } else if (parsed.major >= 25) {+ } else if (parsed.major >= 27) {reason = "unreleased-major";}@@ -76,7 +78,7 @@ export function getNodeRuntimeWarning(version = process.versions.node) {}if (support.reason === "unreleased-major") {- return `Node.js ${support.nodeVersion} is outside the supported LTS lines. OmniRoute currently supports Node.js 20.x, 22.x, and 24.x.`;+ return `Node.js ${support.nodeVersion} is outside the supported LTS lines. OmniRoute currently supports Node.js 20.x, 22.x, 24.x, 25.x, and 26.x.`;}return `Node.js ${support.nodeVersion} is outside OmniRoute's approved secure runtime policy.`;diff --git a/package.json b/package.jsonindex 12d4fc61f0..2d3b92aee7 100644--- a/package.json+++ b/package.json@@ -36,7 +36,7 @@"open-sse"],"engines": {- "node": ">=20.20.2 <21 || >=22.22.2 <23 || >=24.0.0 <25"+ "node": ">=20.20.2 <21 || >=22.22.2 <23 || >=24.0.0 <27"},"keywords": ["ai",@@ -145,14 +145,14 @@"tsx": "^4.21.0","undici": "^8.1.0","uuid": "^14.0.0",- "wreq-js": "^2.0.1","xxhash-wasm": "^1.1.0","yazl": "^3.3.1","zod": "^4.3.6","zustand": "^5.0.10"},"optionalDependencies": {- "keytar": "^7.9.0"+ "keytar": "^7.9.0",+ "wreq-js": "^2.0.1"},"devDependencies": {"@playwright/test": "^1.58.2",diff --git a/src/shared/utils/nodeRuntimeSupport.ts b/src/shared/utils/nodeRuntimeSupport.tsindex 98daa345d0..d8b24f5ecc 100644--- a/src/shared/utils/nodeRuntimeSupport.ts+++ b/src/shared/utils/nodeRuntimeSupport.ts@@ -11,12 +11,14 @@ export const SECURE_NODE_LINES = Object.freeze([Object.freeze({ major: 20, minor: 20, patch: 2 }),Object.freeze({ major: 22, minor: 22, patch: 2 }),Object.freeze({ major: 24, minor: 0, patch: 0 }),+ Object.freeze({ major: 25, minor: 0, patch: 0 }),+ Object.freeze({ major: 26, minor: 0, patch: 0 }),]);export const RECOMMENDED_NODE_VERSION = "24.14.1";-export const SUPPORTED_NODE_RANGE = ">=20.20.2 <21 || >=22.22.2 <23 || >=24.0.0 <25";+export const SUPPORTED_NODE_RANGE = ">=20.20.2 <21 || >=22.22.2 <23 || >=24.0.0 <27";export const SUPPORTED_NODE_DISPLAY =- "Node.js 20.20.2+ (20.x LTS), 22.22.2+ (22.x LTS), or 24.0.0+ (24.x LTS)";+ "Node.js 20.20.2+ (20.x LTS), 22.22.2+ (22.x LTS), 24.0.0+ (24.x LTS), 25.0.0+ (25.x), or 26.0.0+ (26.x)";export interface NodeVersionInfo {major: number;@@ -80,7 +82,7 @@ export function getNodeRuntimeSupport(version: string = process.versions.node):reason = "supported";} else if (secureFloor) {reason = "below-security-floor";- } else if (parsed.major >= 25) {+ } else if (parsed.major >= 27) {reason = "unreleased-major";}@@ -104,7 +106,7 @@ export function getNodeRuntimeWarning(version: string = process.versions.node):}if (support.reason === "unreleased-major") {- return `Node.js ${support.nodeVersion} is outside the supported LTS lines. OmniRoute currently supports Node.js 20.x, 22.x, and 24.x.`;+ return `Node.js ${support.nodeVersion} is outside the supported LTS lines. OmniRoute currently supports Node.js 20.x, 22.x, 24.x, 25.x, and 26.x.`;}return `Node.js ${support.nodeVersion} is outside OmniRoute's approved secure runtime policy.`;diff --git a/tests/unit/node-runtime-support.test.ts b/tests/unit/node-runtime-support.test.tsindex cf13684a5e..37a2fe531a 100644--- a/tests/unit/node-runtime-support.test.ts+++ b/tests/unit/node-runtime-support.test.ts@@ -28,7 +28,8 @@ test("getNodeRuntimeSupport accepts patched Node 24, 22 and 20 LTS lines", () =>nodeCompatible: true,reason: "supported",supportedRange: SUPPORTED_NODE_RANGE,- supportedDisplay: "Node.js 20.20.2+ (20.x LTS), 22.22.2+ (22.x LTS), or 24.0.0+ (24.x LTS)",+ supportedDisplay:+ "Node.js 20.20.2+ (20.x LTS), 22.22.2+ (22.x LTS), 24.0.0+ (24.x LTS), 25.0.0+ (25.x), or 26.0.0+ (26.x)",recommendedVersion: "v24.14.1",minimumSecureVersion: "v22.22.2",});@@ -39,7 +40,8 @@ test("getNodeRuntimeSupport accepts patched Node 24, 22 and 20 LTS lines", () =>nodeCompatible: true,reason: "supported",supportedRange: SUPPORTED_NODE_RANGE,- supportedDisplay: "Node.js 20.20.2+ (20.x LTS), 22.22.2+ (22.x LTS), or 24.0.0+ (24.x LTS)",+ supportedDisplay:+ "Node.js 20.20.2+ (20.x LTS), 22.22.2+ (22.x LTS), 24.0.0+ (24.x LTS), 25.0.0+ (25.x), or 26.0.0+ (26.x)",recommendedVersion: "v24.14.1",minimumSecureVersion: "v24.0.0",});@@ -56,22 +58,22 @@ test("getNodeRuntimeSupport rejects versions below the secure floor in a supporttest("getNodeRuntimeSupport rejects unsupported major lines", () => {const node18 = getNodeRuntimeSupport("18.20.8");- const node25 = getNodeRuntimeSupport("25.1.0");+ const node27 = getNodeRuntimeSupport("27.1.0");assert.equal(node18.nodeCompatible, false);assert.equal(node18.reason, "unsupported-major");assert.match(getNodeRuntimeWarning("18.20.8") || "", /outside OmniRoute's approved secure/i);- assert.equal(node25.nodeCompatible, false);- assert.equal(node25.reason, "unreleased-major");+ assert.equal(node27.nodeCompatible, false);+ assert.equal(node27.reason, "unreleased-major");assert.match(- getNodeRuntimeWarning("25.1.0") || "",- /currently supports Node\.js 20\.x, 22\.x, and 24\.x/i+ getNodeRuntimeWarning("27.1.0") || "",+ /currently supports Node\.js 20\.x, 22\.x, 24\.x, 25\.x, and 26\.x/i);});test("CLI runtime support stays aligned with the shared runtime policy", () => {assert.deepEqual(getCliNodeRuntimeSupport("24.1.0"), getNodeRuntimeSupport("24.1.0"));assert.deepEqual(getCliNodeRuntimeSupport("22.22.2"), getNodeRuntimeSupport("22.22.2"));- assert.equal(getCliNodeRuntimeWarning("25.1.0"), getNodeRuntimeWarning("25.1.0"));+ assert.equal(getCliNodeRuntimeWarning("27.1.0"), getNodeRuntimeWarning("27.1.0"));});