LangChain Reference home pageLangChain ReferenceLangChain Reference
  • GitHub
  • Main Docs
Deep Agents
LangChain
LangGraph
Integrations
LangSmith
  • Overview
  • LangGraph Checkpoint
    LangGraph Store
    Checkpoint Postgres
    Store Postgres
    Checkpoint SQLite
    LangGraph Prebuilt
    LangGraph CLI
    LangGraph SDK
    LangGraph Supervisor
    LangGraph Swarm
    ⌘I

    Chat LangChain

    What can I help with?

    Enter to send·Shift+Enter new line

    Menu

    LangGraph Checkpoint
    LangGraph Store
    Checkpoint Postgres
    Store Postgres
    Checkpoint SQLite
    LangGraph Prebuilt
    LangGraph CLI
    LangGraph SDK
    LangGraph Supervisor
    LangGraph Swarm
    Language
    Theme
    Pythonlanggraph-sdkstreamerrorsis_non_retryable_stream_error
    Function●Since v0.4

    is_non_retryable_stream_error

    Copy
    is_non_retryable_stream_error(
        error: BaseException | None,
    ) -> bool
    View source on GitHub

    Whether reopening the stream would fail the same way.

    True for a 4xx other than 408 and 429: the status of a refused stream request or WebSocket upgrade, or a WebSocket close code of 4000 plus that status. A server that rejects a WebSocket after accepting it closes with such a code, because a browser can't read the status of a refused upgrade.