langchain-ai/langgraph · error · RuntimeError

thread.run.respond: interrupt_id

Error message

thread.run.respond: interrupt_id {interrupt_id!r} does not match any outstanding interrupt in `thread.interrupts`.

What it means

Interrupt-reply guard in AsyncThreadStream.run.respond: an explicit interrupt_id was supplied but it does not match any of the interrupts currently recorded in thread.interrupts. The interrupt may have already been answered, expired, or the id was misread.

Solutions

  1. Re-read thread.interrupts and pass one of the currently listed interrupt_id values
  2. Do not reuse an interrupt_id from a previous exchange; each response consumes its interrupt
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at libs/sdk-py/langgraph_sdk/_async/stream.py:256 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of langchain-ai/langgraph@38031739e5 (2026-08-26). Data as JSON: /api/errors/93df2387a2f148f0. Report an issue: GitHub.

Appendix: source

Thrown at libs/sdk-py/langgraph_sdk/_async/stream.py:256

                        "thread.run.respond: no outstanding interrupt. Provide "
                        "an explicit `interrupt_id` or wait for "
                        "`thread.interrupted`."
                    )
                if len(outstanding) > 1:
                    ids = [p["interrupt_id"] for p in outstanding]
                    raise RuntimeError(
                        f"thread.run.respond: ambiguous — {len(outstanding)} "
                        f"outstanding interrupts ({ids!r}). Provide an explicit "
                        "`interrupt_id`."
                    )
                match = outstanding[0]
            else:
                match = next(
                    (p for p in outstanding if p["interrupt_id"] == interrupt_id),
                    None,
                )
                if match is None:
                    raise RuntimeError(
                        f"thread.run.respond: interrupt_id {interrupt_id!r} does "
                        "not match any outstanding interrupt in "
                        "`thread.interrupts`."
                    )
            params = {
                "interrupt_id": match["interrupt_id"],
                "namespace": match["namespace"],
                "response": response,
            }
            return await self._owner._send_command("input.respond", params)


async def _close_after(handle: EventStreamHandle, *, delay: float = 0.0) -> None:
    """Close a handle, optionally after a brief delay. Used to detach
    closing the old stream from the synchronous rotation step so the new
    stream can absorb server-side replayed events first.
    """
    if delay:

View on GitHub (pinned to 38031739e5)