feat(sdk-py): add sync scoped subgraphs#7828
Merged
Nick Hollon (nick-hollon-lc) merged 138 commits intoMay 27, 2026
Merged
Conversation
…minor doc/typing tightening
…e; orjson consistency
5faea08 to
57aff9c
Compare
53dc482 to
a250f0a
Compare
57aff9c to
ff5cec8
Compare
a250f0a to
1d14ab4
Compare
Adds `max_queue_size: int = 1024` to `ProtocolSseTransport.__init__` and passes it to `asyncio.Queue(maxsize=...)` in `open_event_stream`, so a slow consumer suspends the pump task rather than allowing unbounded heap growth.
…sync: add run_start_timeout parity
When a lifecycle errored event arrives before the tool-call stream ends, the finally block now waits up to 1 second for _run_done to settle, then reads the terminal error and fails remaining handles with it. Without this, handles received the generic "stream closed" message instead of the run error. Mirrors _ToolCallsProjection in _async/stream.py. Add test: test_sync_tool_calls_run_error_fails_active_handle Add comprehensive sync projection tests (namespace filtering, multiple messages, error events, multiple concurrent tool calls, tool-error event).
…ore yielding Without pre-dispatch, callers accessing str(stream.text) immediately inside a for loop would see empty text because only message-start was dispatched. Add inner read-ahead loop matching the pattern in _SyncMessagesProjection. Add test: test_sync_drain_messages_inbox_pre_dispatches_before_yield.
ff5cec8 to
ebd51dd
Compare
…r, fans out to all matching descendants
… fall back to single active stream only for unkeyed events
1d14ab4 to
d95eb5b
Compare
Josh Rogers (jdrogers940)
approved these changes
May 27, 2026
Base automatically changed from
nh/sdk-py-v3-streaming-pr10-sync-message-tools
to
main
May 27, 2026 18:04
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
Tests