mirror of
https://github.com/langchain-ai/langgraph.git
synced 2026-08-25 09:02:25 +02:00
The `version="v3"` overloads of `stream_events`/`astream_events` returned `Any`, and `GraphRunStream`/`AsyncGraphRunStream` attached native projections via a runtime `setattr` loop invisible to type checkers. - Return `GraphRunStream` / `Awaitable[AsyncGraphRunStream]` from the v3 overloads. - Declare the always-registered native projections (`values`, `messages`, `lifecycle`, `subgraphs`) as typed class attributes on both run streams. - Add `assert_type` checks in `test_stream_events_v3.py`. Opt-in native projections (`updates`, `custom`, `checkpoints`, `debug`, `tasks`) are only present when their transformer is registered, so they remain reached via `extensions[...]` rather than annotated as always-present.