JuliusBrussee/caveman · error · Error
Claude caveman-cloud MCP changed after setup; refusing to…
Error message
Claude caveman-cloud MCP changed after setup; refusing to overwrite user fields
What it means
For Claude, if the caveman-cloud MCP registration exists, is journaled (marker present), but its current fields no longer match the recorded marker (command/args changed), the user or another process modified the journaled entry. Overwriting would destroy those changes, so setup refuses.
Solutions
- Restore the caveman-cloud entry fields to match the marker's recorded command
- Delete the stale marker so setup re-registers the entry fresh (after backing up changes)
- Revert your manual edits to the MCP entry and re-run setup
Defensive patterns
Strategy: validation
Validate before calling
const marker = readMcpServerMarker('claude', 'caveman-cloud');
if (marker && !agentNativeCloudMcpMatches('claude', marker)) {
console.error('caveman-cloud entry differs from marker; revert edits or remove the marker deliberately.');
} Try / catch
try {
runSetup('claude');
} catch (e) {
if (String(e.message).includes('refusing to overwrite user fields')) {
// revert the entry to the marker-recorded command or delete marker + entry for a clean re-register
}
} Prevention
- Avoid editing command/args of journaled MCP entries
- Re-run the Caveman CLI (not manual edits) to change the server command
- Keep Claude config and markers in sync — don't restore configs from backups without markers
When it happens
Trigger: Running setup for claude when the registration is present, a marker exists, and agentNativeCloudMcpMatches('claude', marker) is false — i.e. the live config's server command/args differ from the marker's recorded values.
Common situations: User edited the caveman-cloud entry (different args, env, or binary path); a different Caveman version or channel changed the command; the marker is stale relative to config.
Understand the failure class
Background: Checksum mismatch errors: "checksum verification failed", "digest mismatch", "expected vs actual checksum" — what they mean and how to fix them — this error's family across 41 libraries.
Related errors
- Claude caveman-cloud MCP exists but is not…
- [mcp_servers.caveman-cloud] exists but is not…
- caveman-cloud MCP changed during interrupted setup…
- caveman-cloud MCP changed during interrupted removal…
- cave_claude_output_budget_too_small_for_reasoning
AI-assisted analysis of JuliusBrussee/caveman@3ee70a1026 (2026-09-20).
Data as JSON: /api/errors/2f18a4e8838e04d1.
Report an issue: GitHub.
Appendix: source
Thrown at packages/cli/src/index.ts:2880
if (!existingBundle) {
if (current && !current.equals(Buffer.from(body))) {
throw new Error(`${file} already exists with non-canonical content; refusing to overwrite an unjournaled skill`);
}
continue;
}
const previous = previousSkills.get(file);
if (current && !current.equals(Buffer.from(body)) && (!previous || bytesHash(current) !== previous.after_sha256)) {
throw new Error(`${file} changed after setup; refusing to overwrite user skill edits`);
}
}
if (agent === "claude") {
const actual = claudeMcpRegistration("caveman-cloud");
const marker = readMcpServerMarker("claude", "caveman-cloud");
if (actual.present && !marker) {
throw new Error("Claude caveman-cloud MCP exists but is not Caveman-journaled; refusing overwrite");
}
if (actual.present && marker && !agentNativeCloudMcpMatches("claude", marker)) {
throw new Error("Claude caveman-cloud MCP changed after setup; refusing to overwrite user fields");
}
return;
}
const config = fileBytes(join(codexHomeDir(), "config.toml"))?.toString("utf8") ?? "";
if (!config.includes("[mcp_servers.caveman-cloud]")) return;
if (!readMcpServerMarker("codex", "caveman-cloud")) {
throw new Error("[mcp_servers.caveman-cloud] exists but is not Caveman-journaled; refusing overwrite");
}
}
function installAgentNativeBundleSkills(agent: "claude" | "codex", journal: AgentNativeBundleJournal): void {
const originals = new Map(journal.skills.map((skill) => [skill.file, skill.before_base64]));
journal.skills = agentNativeSkillFiles(agent).map(({ file, body }) => {
mkdirSync(dirname(file), { recursive: true });
atomicWriteFile(file, Buffer.from(body));
return {
file,
before_base64: originals.get(file) ?? null,View on GitHub (pinned to 3ee70a1026)