9router/open-sse
Hamsa_M 315dcaa37a
fix: strip empty Read pages argument in OpenAI-to-Claude translator (#1354)
Some OpenAI-compatible providers emit optional string tool parameters
as empty strings (e.g. pages: "") instead of omitting them. Claude
Code rejects pages: "" as invalid, breaking the Read tool for
non-PDF files routed through 9router.

Add sanitizeToolArguments() that parses tool-call arguments and
removes known optional empty-string fields before emitting
input_json_delta back to Claude format. Currently handles the
Read tool pages field specifically.

Includes regression test.

Fixes #1278

Co-authored-by: JoJo <noreply@github.com>
2026-05-23 09:27:13 +07:00
..
config fix (#1361) 2026-05-23 09:26:10 +07:00
executors fix: decode Composer cursor thinking output (#1310) 2026-05-21 09:52:30 +07:00
handlers fix(embeddings): forward Gemini output dimensions (#1366) 2026-05-23 09:23:26 +07:00
rtk feat(rtk): add Kiro format support for tool result compression (#1194) 2026-05-17 15:13:37 +07:00
services fix (#1361) 2026-05-23 09:26:10 +07:00
transformer feat: enhance request handling and error management in chatCore and streamToJsonConverter 2026-02-15 12:02:53 +07:00
translator fix: strip empty Read pages argument in OpenAI-to-Claude translator (#1354) 2026-05-23 09:27:13 +07:00
utils Merge PR #1300: tailscale Windows fix, quota pagination, SSE abort handling 2026-05-21 12:15:07 +07:00
.npmignore Update jsconfig.json and package.json to correct open-sse path references from relative to local directory. 2026-01-05 10:37:09 +07:00
index.js Refactor config 2026-03-12 16:20:46 +07:00