Document capi.enableWebSocketResponses as a resume option - #2578
Open
1fanwang wants to merge 1 commit into
Open
Conversation
The resume options table listed capi.autoTier but omitted capi.enableWebSocketResponses, which ResumeSessionConfig also accepts through SessionConfigBase. Callers hitting WebSocket transport failures on resume had no way to discover it from the docs. Signed-off-by: 1fanwang <1fannnw@gmail.com>
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
The documentation-only change is complete, validated, and has no unresolved issues.
Pull request overview
Documents WebSocket transport configuration when resuming persisted sessions.
Changes:
- Adds
capi.enableWebSocketResponsesto the resume options table. - Documents defaults, Python syntax, usage, and environment-variable equivalence.
File summaries
| File | Description |
|---|---|
docs/features/session-persistence.md |
Documents response transport selection for resumed sessions. |
Review details
- Files reviewed: 1/1 changed files
- Comments generated: 0
- Review effort level: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
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.
Why
Someone resumes a session and it starts returning
400 input item ID does not belong to this connection, or their proxy refuses WebSocket connections so resume never gets off the ground. Both are transport problems, and the SDK already lets them pick the transport on the resume call. They go to the session persistence guide, read the table of what can be reconfigured on resume, and the option is not there. Nothing in the docs suggests it exists, so the reasonable conclusion is that it does not and the session is lost.The option is real. The resume config accepts it through the shared base config, every language binding exposes it, and it is covered by tests. Only the documentation was missing, and the table already lists its sibling
capi.autoTier, which is what makes the omission read as deliberate.After this change the reader finds the option in the same table they were already looking at, with a short section showing how to pass it.
What changed
One row in the resume options table, plus a section giving the default, the Python spelling, a resume example, and how it relates to the equivalent environment variable.
Testing Done
Documentation only, no code paths touched.
The option was absent from the docs before this change and present after:
The added example is also compiled by the existing docs validation, so a wrong option name or type would fail the build rather than render quietly.
Raw logs: docs validation (tail)