{"record":{"id":"7b2a7e75da1a67b3","repo":"langchain-ai/deepagents","slug":"this-server-does-not-provide-dcode-s-offload-oper","errorCode":null,"errorMessage":"This server does not provide dcode's /offload operation. Use the built-in dcode server, or upgrade the server to a version that registers it.","messagePattern":"This server does not provide dcode's /offload operation\\. Use the built-in dcode server, or upgrade the server to a version that registers it\\.","errorType":"exception","errorClass":"RuntimeError","httpStatus":null,"severity":"error","filePath":"libs/code/deepagents_code/client/remote_client.py","lineNumber":429,"sourceCode":"                        },\n                    ),\n                    graph=graph,\n                    thread_id=thread_id,\n                    operation_id=operation_id,\n                )\n            except NotFoundError as exc:\n                # The route itself is missing. An unregistered thread cannot\n                # reach here as a 404: the server catches that and answers 409\n                # with its own message. A custom `graph_ref` server, or one\n                # older than this operation, never registers the dcode HTTP app,\n                # and the SDK's bare \"404 Not Found\" names neither the cause nor\n                # a fix.\n                msg = (\n                    \"This server does not provide dcode's /offload operation. \"\n                    \"Use the built-in dcode server, or upgrade the server to a \"\n                    \"version that registers it.\"\n                )\n                raise RuntimeError(msg) from exc\n            if not isinstance(response, dict):\n                msg = \"Offload server returned a non-object response.\"\n                raise TypeError(msg)\n            status = response.get(\"status\")\n            if status == \"complete\":\n                return _validated_offload_result(response.get(\"result\"))\n            request = response.get(\"request\")\n            if status != \"interrupt\" or not is_hook_interrupt_payload(request):\n                msg = \"Offload server returned an invalid operation response.\"\n                raise RuntimeError(msg)\n            invocation = request.get(\"request\")\n            invocation_id = (\n                invocation.get(\"invocation_id\")\n                if isinstance(invocation, dict)\n                else None\n            )\n            if not isinstance(invocation_id, str) or not invocation_id:\n                msg = \"Offload hook request has no invocation id.\"","sourceCodeStart":411,"sourceCodeEnd":447,"githubUrl":"https://github.com/langchain-ai/deepagents/blob/a1af029e6e73cb17c36bff823d227747b28e91e1/libs/code/deepagents_code/client/remote_client.py#L411-L447","documentation":"`aoffload` POSTs to the dcode-specific route `/dcode/threads/{thread_id}/offload`. When the server answers 404 (`langgraph_sdk.errors.NotFoundError`), the client re-raises it as this RuntimeError because the bare SDK 404 names neither the cause nor the fix. The route only exists when the server registers dcode's HTTP app — the built-in dcode server, or a new-enough custom server.","triggerScenarios":"Calling `RemoteAgent.aoffload` against a server that never registers the `/dcode/threads/{id}/offload` route: an older dcode server version, a plain LangGraph server, or a custom `graph_ref` server without the dcode HTTP app.","commonSituations":"Pointing dcode at a stock LangGraph deployment (LangSmith-hosted or self-run `langgraph dev` of a non-dcode graph); running a stale server build after upgrading the client; using a custom server graph_ref that predates the offload operation.","solutions":["Start/use the built-in dcode server (launched by `dcode`) instead of a stock LangGraph server.","Upgrade the server to a version that registers the dcode offload route, then retry.","If you must use a custom server, port/register the dcode HTTP app so `/dcode/threads/{id}/offload` exists.","As a workaround, avoid `aoffload` and run the work client-side or via a code path that does not need server-owned offload."],"exampleFix":"// before\nagent = RemoteAgent(\"http://localhost:2024\", graph_name=\"custom_graph\")\nresult = await agent.aoffload(config=config, context=ctx, fulfill_hook=hook)\n\n// after\n# point the client at the built-in dcode server (or upgrade it) before offloading\nagent = RemoteAgent(dcode_server_url)\nresult = await agent.aoffload(config=config, context=ctx, fulfill_hook=hook)","handlingStrategy":"try-catch","validationCode":"# No cheap pre-check HTTP route exists; ensure the server is the dcode server before offloading.\nif not server_is_builtin_dcode(url):\n    raise RuntimeError(\"Offload requires the built-in dcode server\")","typeGuard":null,"tryCatchPattern":"try:\n    result = await agent.aoffload(config=config, context=ctx, fulfill_hook=hook)\nexcept RuntimeError as exc:\n    if \"does not provide dcode's /offload\" in str(exc):\n        logging.error(\"Server lacks /dcode offload route; start the dcode server or upgrade it\")\n    else:\n        raise","preventionTips":["Only point offload-capable clients at the built-in dcode server.","Pin server and client to compatible versions and upgrade them together.","After deploying a custom server, smoke-test POST /dcode/threads/{id}/offload once."],"tags":["network","http-404","version-mismatch","offload","server"],"backgroundTag":"endpoint-not-found","analyzedSha":"a1af029e6e73cb17c36bff823d227747b28e91e1","analyzedAt":"2026-08-29T11:43:24.718Z","schemaVersion":2},"datasetVersion":"2026-08-29T12:17:43.993Z"}