Skip to content

Commit 0dec196

Browse files
committed
Record two divergences as intentional, ecosystem-consistent choices
Two interaction-suite divergence notes described their gaps as unenforced spec MUSTs without saying whether closing them was planned. Both are deliberate, and the notes now say so. transport:stdio:stream-purity -- stdio_server does not redirect sys.stdout, so a handler print() corrupts the protocol stream. No MCP SDK redirects stdout, and a redirect would only catch print(), not os.write(1, ...) or C extensions writing to file descriptor 1, so it would be a partial guard rather than a structural fix. docs/tutorial/logging.md already tells server authors to log to stderr and never print() in a stdio server, so no docs change was needed. protocol:progress:monotonic -- no MCP SDK validates sender-side progress monotonicity; the spec MUST is a contract on the handler author, not on the transport, and the test pins the unvalidated pass-through. No code or test behaviour changes.
1 parent d14f6d5 commit 0dec196

1 file changed

Lines changed: 12 additions & 7 deletions

File tree

tests/interaction/_requirements.py

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -656,10 +656,11 @@ def __post_init__(self) -> None:
656656
divergence=Divergence(
657657
note=(
658658
"Intentional, not a gap to close: no MCP SDK (typescript, go, csharp) validates "
659-
"sender-side progress monotonicity, and this one does not either. The spec MUST "
660-
"binds the handler author, not the transport; non-increasing values are forwarded "
661-
"to the callback unchanged so the receiving application sees what the sender sent. "
662-
"docs/tutorial/progress.md states the author's obligation."
659+
"sender-side progress monotonicity, and this one does not either. The spec MUST is "
660+
"a contract on the handler author, not on the transport; non-increasing values are "
661+
"forwarded to the callback unchanged so the receiving application sees what the "
662+
"sender sent, and the test pins that pass-through. docs/tutorial/progress.md "
663+
"states the author's obligation."
663664
),
664665
),
665666
),
@@ -3651,9 +3652,13 @@ def __post_init__(self) -> None:
36513652
note="Only observable over stdio: stdin/stdout purity is stdio-specific.",
36523653
divergence=Divergence(
36533654
note=(
3654-
"stdio_server's own writes satisfy this, but it does not redirect or guard sys.stdout: "
3655-
"handler code that calls print() writes directly to the protocol stream and corrupts the "
3656-
"framing. The spec MUST is satisfied only as long as application code behaves."
3655+
"Intentional, not a gap to close: the SDK's own writes are pure, but sys.stdout is not "
3656+
"redirected, so handler code that calls print() writes into the protocol stream and "
3657+
"corrupts the framing. This matches every other MCP SDK -- none redirects stdout. A "
3658+
"redirect would only catch print(): os.write(1, ...) and C extensions that write to file "
3659+
"descriptor 1 bypass sys.stdout entirely, so it would be a partial guard rather than a "
3660+
"structural fix. docs/tutorial/logging.md tells server authors to log to stderr and "
3661+
"never print() in a stdio server."
36573662
),
36583663
),
36593664
),

0 commit comments

Comments
 (0)