Repository navigation
Description
Before submitting
- I searched the open and closed issues for a related report.
- I removed credentials, tokens, private paths, and sensitive target data.
Area
MCP or agent integration
Summary
#1212 and #1282 were both closed as fixed on main (#1220, #1227, #1299). The fixes are correct — I verified each replacement against the same strict validator. But none of them are in a published release: npm dist-tags.latest is still rea-agents@6.1.0, published 2026-10-09T01:16Z, which predates all three.
So every npm/npx consumer — i.e. the documented install path — still ships the rejected patterns and still fails on every turn. This is a release gap, not a re-report of the underlying defect.
Observed behavior
Against a strict-schema OpenAI-compatible gateway, a client that loads the published tool list fails before any tool runs, on every turn. Two distinct error shapes, depending on the request path:
HTTP 503 {"error":{"message":"上游返回错误","type":"api_error","code":null}}
HTTP 400 {"code":11133,"msg":"Invalid request parameters",
"extError":{"code":"model_param_invalid",
"message":"the request parameters were rejected by the model provider"}}
The 400/503 names no tool, and the client surfaces it as a generic turn failure. In my case the client retried 10 times over ~110 s and then aborted the turn; the session was unusable, and the error pointed at a tool I had never invoked.
Reproduction
Published artifact audit — a real stdio initialize + tools/list handshake against the npm release:
npx -y rea-agents@6.1.0 mcpResult: 138 tools, 1976 pattern fields, of which 5 distinct patterns / 50 occurrences are rejected by a strict validator:
| occurrences | pattern |
|---|---|
| 44 | ^[^\0]*$ |
| 3 | ^[^\s[\]]+$ |
| 1 | ^[^=\0]+$ |
| 1 | `^(?!/)(?!(?:.*/)?.{1,2}(?:/ |
| 1 | ^(?!REA_PROCESS_RUN_ID(?![\s\S]))[^=\0]+$ |
The npm tarball still carries the pre-fix source, e.g. dist/domain/native/nativeCallObservation.js:10:
.regex(/^[^\s[\]]+$/u, "Use the bare name without spaces or brackets");whereas main src/domain/native/nativeCallObservation.ts:14 has:
.regex(/^[^\s\x5b\x5d]+$/u, "Use the bare name without spaces or brackets");End-to-end, isolating the cause:
| request | result |
|---|---|
| full tool list as published (257 tools) | 503 |
| drop the 138 rea tools, keep the other 119 | 200 |
| keep only the 138 rea tools | 503 |
| keep all 257 tools, remove only the 5 patterns above | 200 |
The last row is 731 KB of tool schemas and passes, so payload size is not a factor — the pattern content is the sole trigger. Removing any other single keyword ($schema, examples, additionalProperties, oneOf, const, …) changes nothing; removing pattern alone fixes it.
Expected behavior
npm i rea-agents / npx -y rea-agents@<latest> mcp should install a build whose advertised pattern values compile under the strict validators already handled on main, so a strict-schema provider accepts the tool list and the session is usable.
Verification that the fix on main is sufficient
Each replacement is accepted by the same validator that rejects the published form, tested in isolation:
| npm 6.1.0 | strict validator | main replacement |
strict validator |
|---|---|---|---|
^[^\0]*$ |
REJECT | ^[^\u0000]*$ |
OK |
^[^=\0]+$ |
REJECT | ^[^=\u0000]+$ |
OK |
^[^\s[\]]+$ |
REJECT | ^[^\s\x5b\x5d]+$ |
OK |
| (look-around form) | REJECT | ^(?!REA_PROCESS_RUN_ID$)[^=]+$ |
OK |
\x00 and \^@ spellings also pass. So no further code change is needed — only a publish.
Impact and scope
- Affected: anyone consuming the npm package (the default install path), on any provider whose tool-schema validator is strict.
- Not affected: running from
main, or a build produced frommain— the issue is purely the published artifact lagging the fix. - Severity: the failure is total and non-recoverable from inside the session, since tool schemas ride on every request. The user cannot even ask the client to help diagnose it.
- No impact on evidence integrity or process isolation.
Workaround
A ~90-line stdio shim between the client and the server that rewrites only the tools/list response (drops the 5 patterns above, passes every other byte through unchanged). Measured: 50 rejected patterns → 0, tool count unchanged at 138, and all requests in the table above return 200.
Ask
Please cut a patch release (e.g. 6.1.1) from main so npm consumers pick up #1220 / #1227 / #1299. Happy to re-run this audit against a prerelease or a next tag and report back.
Activity
CassieFox23 commentedon Oct 9, 2026
TL;DR: I ran the same count. 6.1.0 shows your 50 bad patterns exactly. 6.2.0 has none of them.
Checked the published
rea-agents@6.2.0(now npmlatest) with the same stdioinitialize+tools/listhandshake. I counted everypatternfield in the advertised tool schemas.patternfields6.1.0 gives exactly your counts, so the method matches yours. In 6.2.0's tool list no
patterncontains\0, a lookahead, or the unescaped[/]class either.I only checked the advertised schemas. Not a request against a strict-schema gateway.
Test setup
🤖 Generated with Claude Code (Opus 5.5) 🦊
N0zoM1z0 commentedon Oct 9, 2026
rea-agents@6.2.0is now published as npmlatest, with the fixes from #1220, #1227 and #1299. Release: https://github.com/morluto/rea/releases/tag/rea-agents-6.2.0We verified the public npm artifact through a real stdio MCP handshake (139 tools) and the packaged CLI/update canary. Your follow-up independently confirms zero occurrences of the five rejected patterns in 6.2.0. Actual acceptance by your gateway remains outside our verification.
Closing the published-artifact gap. Upgrade to 6.2.0 and restart the MCP client so it reloads the tool schemas.
ljcyt commentedon Oct 10, 2026
Verified 6.2.0 against the actual strict-schema gateway — the step noted as outside your verification scope.
Method: real stdio
initialize+tools/listagainstnpx -y rea-agents@6.2.0 mcp, then the advertised tools converted to the provider's tool format (inputSchema→parameters) and sent verbatim in a live request. No pattern was edited by me; 6.2.0's schemas went through untouched.Published artifact audit
patternfieldsGateway acceptance (the previously unverified step)
503 上游返回错误503/responsespath5036.2.0 returns a normal completion on all three; 6.1.0 returns 503 on all three, on the same provider, same minute, same key. So the gateway does accept 6.2.0's schemas — the fix is effective end-to-end, not just under a local regex compile.
One note for anyone re-running this: MCP advertises
inputSchema, and a tool entry that forwardsparametersinstead (leaving it empty) is itself rejected by this gateway with the same503. That cost me one wrong intermediate reading — worth watching for if you extend the catalog-wide assertion to a live request.Thanks for the fast turnaround on the release; issue closed on my side.