langchain-ai/langgraph · error · ValueError

extension name must be non-empty.

Error message

extension name must be non-empty.

What it means

Error "extension name must be non-empty." thrown in langchain-ai/langgraph.

Source

Thrown at libs/sdk-py/langgraph_sdk/_sync/stream.py:1028

                root_inbox.put_nowait(None)


class _SyncExtensionsProjection:
    """Mapping from extension name to custom event payload stream.

    Repeated access for the same `name` returns the cached projection so that
    callers receive the same subscription handle across multiple references to
    `thread.extensions["foo"]` within one session.
    """

    def __init__(self, thread: SyncThreadStream, namespace: list[str]) -> None:
        self._thread = thread
        self._namespace = namespace
        self._cache: dict[str, _SyncExtensionProjection] = {}

    def __getitem__(self, name: str) -> _SyncExtensionProjection:
        if not name:
            raise ValueError("extension name must be non-empty.")
        if name not in self._cache:
            self._cache[name] = _SyncExtensionProjection(
                self._thread,
                name=name,
                namespace=self._namespace,
            )
        return self._cache[name]


class _SyncExtensionProjection:
    def __init__(
        self,
        thread: SyncThreadStream,
        *,
        name: str,
        namespace: list[str],
    ) -> None:
        self._thread = thread

View on GitHub (pinned to 38031739e5)

When it happens

Trigger: Thrown at libs/sdk-py/langgraph_sdk/_sync/stream.py:1028 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/d602cd4b172b0f5e. Report an issue: GitHub.