Skip to content

test(mutants): throwaway mutation run for #478, not for merging - #479

Closed
TAIPANBOX wants to merge 3 commits into
mainfrom
test/mutants-478-throwaway
Closed

TAIPANBOX wants to merge 3 commits into
mainfrom
test/mutants-478-throwaway

Conversation

@TAIPANBOX

Copy link
Copy Markdown
Owner

Mutation run for #478: seven mutants of the batch refusal, one job each, against the four tests #478 adds. A green job means the mutant was killed. This branch removes ci.yml so the full suite does not run here; it is closed and deleted once the run is read.

🤖 Generated with Claude Code

TAIPANBOX and others added 3 commits October 26, 2026 02:21
…e upstream

Four cases for the MCP broker, added before the fix so CI shows them red
on the current code:

- a JSON-RPC batch of two tools/call over HTTP is refused with 400 and
  -32600, nothing reaches the upstream and the PDP is never asked, with a
  policy that denies every tool;
- the stdio transport refuses the same batch;
- a bare string, a number, null, and an object whose method is not a
  string are refused the same way;
- one request and a client's JSON-RPC response (id and result, no method)
  still reach the upstream, so the fix cannot refuse too much.

Scenarios in features/a-batch-cannot-carry-a-call-past-the-gate.feature,
each bound to its test. README badge and PROGRESS.md count 2418.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Every check the broker makes keys on `method` read from one JSON object.
A batch is an array, so its method read as empty and every tools/call
check was skipped: the policy decision, the identity requirement, drift,
the taint gate, the argument scans and the tool_call record, and a
batched tools/list answer was never scanned. The array was forwarded as
it came, over HTTP and stdio alike.

process_call, which both transports reach, now refuses first, before an
upstream is resolved or a secret read: a message that is not one JSON
object, or whose method is present and not a string, gets JSON-RPC
-32600 with a null id and HTTP 400. MCP removed batching in its
2025-06-18 revision. A JSON-RPC response (no method) is still carried.

Invariant 142 in CLAUDE.md. The previous commit's tests failed on the
unfixed broker in CI (run 40258757907: three refused-case tests red at
the "nothing reached the upstream" assertion, the must-not-fire case
green).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Seven mutants of the batch refusal, one CI job each, against the four
tests #478 adds. ci.yml is removed on this branch only so the full suite
does not run on it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@TAIPANBOX

Copy link
Copy Markdown
Owner Author

Mutation run read: baseline 4/4 passed; M1-M7 all killed (run 40266586803). Closing the throwaway.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant