Files
langgraph/libs
Nick Hollon 5f24a0356a Tighten streaming run stream API and close review footguns
- AsyncGraphRunStream.output/interrupted/interrupts are now methods
  (await run.output()), not properties returning coroutines. Forgetting
  `await` now fails at type-check time and at runtime on the common
  operations (bool/len/iter), instead of silently yielding a live
  coroutine that's truthy, lenless, and never awaited.
- interrupted/interrupts re-raise the run's error on both lanes so a
  failed run doesn't silently return the last-known interrupt state.
- Narrow the async pump catch from BaseException to Exception so
  CancelledError / KeyboardInterrupt propagate.
- Wrap run.extensions with types.MappingProxyType so users can't add
  or remove projection keys behind the mux's back.
- Add ValuesTransformer.error accessor; run stream stops reaching into
  _log._error.
- Tighten StreamingHandler graph type from Any to Pregel and widen
  convert_to_protocol_event to accept StreamPart.
- Projection-conflict ValueError now names the transformer that owns
  each colliding key, not just the incoming transformer.
- Replace deprecated asyncio.get_event_loop() in the async iteration
  test with asyncio.create_task.
- Document wall-clock semantics of ProtocolEvent.params.timestamp,
  the subgraph-namespace drop in MessagesTransformer, and the
  transformer-pipeline bypass for StreamChannel auto-forwarded events.
- Add tests for the new error-raising behavior on interrupted /
  interrupts and for the read-only extensions contract.
2026-04-16 15:54:14 -04:00
..