JuliusBrussee/caveman · error · RuntimeError
cave artifact response missing artifact_id
Error message
cave artifact response missing artifact_id
What it means
Error "cave artifact response missing artifact_id" thrown in JuliusBrussee/caveman.
Source
Thrown at packages/sdk/python/caveman_cloud/core.py:1183
``workflow``, and same stub format). :attr:`artifacts` exposes ``page``
as the mirror-named entry point; ``page_artifact`` stays as a
backwards-compatible alias.
"""
if options.get("strategy") == "verbatim":
return value
# `workflow` mirrors the TS SDK body so both SDKs send the identical wire.
response = self._request(
"/sdk/v1/artifacts",
{"value": value, "options": options, "workflow": self.workflow},
extra_headers={
"x-cave-artifact-envelope": "value-v1",
"x-cave-artifact-source": str(options["source"]),
},
)
if response.get("stored") is False:
return value
if response.get("stored") is not True or not isinstance(response.get("artifact_id"), str) or not response["artifact_id"].strip():
raise RuntimeError("cave artifact response missing artifact_id")
content_type = options.get("content_type") or "application/json"
return (
f"[cave-artifact id={response['artifact_id']} source={options['source']} type={content_type}]\n"
f"summary: artifact stored.\n"
f"retrieve: authenticated GET /sdk/v1/artifacts/{response['artifact_id']} or trace.artifacts.get(\"{response['artifact_id']}\").\n"
f"[/cave-artifact]"
)
def get_artifact(self, artifact_id: str) -> Any:
"""Retrieve and JSON-decode one artifact produced by :meth:`page_artifact`."""
if not isinstance(artifact_id, str) or not artifact_id.strip():
raise ValueError("artifact_id is required")
return self._get(f"/sdk/v1/artifacts/{quote(artifact_id, safe='')}")
@property
def artifacts(self) -> "_Artifacts":
"""Artifact handle mirroring the TS ``trace.artifacts`` namespace.
View on GitHub (pinned to 27d5a3981a)
Solutions
- The cave artifact response lacked artifact_id; verify the server version and retry.
When it happens
Trigger: Thrown at packages/sdk/python/caveman_cloud/core.py:1183 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of JuliusBrussee/caveman@27d5a3981a (2026-08-15).
Data as JSON: /api/errors/4caa7d2774b0d631.
Report an issue: GitHub.