fix: route stable session/resume and session/close - #159
Open
monody0007 wants to merge 1 commit into
Open
monody0007 wants to merge 1 commit into
monody0007 wants to merge 1 commit into
Conversation
The bundled ACP v1 schema has listed session/resume and session/close as stable since v0.12.2, but the agent router still required use_unstable_protocol for them. Agents advertising sessionCapabilities.resume/close answered "Method not found" by default, and the HTTP/WebSocket servers offer no way to enable the flag. Once routed, a resume over Streamable HTTP still could not continue: its response carries no sessionId, so neither peer opened the session SSE stream and the next session/prompt POST returned 404. Treat session/resume like session/load when attaching session streams. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The bundled stable schema includes
session/resumeandsession/close, but the router still requiresuse_unstable_protocol. Agents advertising these capabilities return-32601 Method not foundby default, and the HTTP/WebSocket servers cannot enable that flag.This removes the stale gates, following the stable-method behavior established in #148.
session/forkremains experimental.HTTP resume also needs the same session-stream attachment as load: its response has no
sessionId, so neither peer previously attached the stream and the next prompt returned 404. The client and server now share the load/resume attachment path, including failed-resume cleanup. Web-transport docs are updated.Testing
make check: lock, all 10 hooks, type and dependency checks pass.make docs-test: strict documentation build passes.Session-close stream teardown is a pre-existing limitation outside this change. No schema regeneration is needed.
Implementation and independent review used AI assistance. The checks above were executed locally.