paperclipai/paperclip · error
Daytona command failed (exit ) ` : ""}
Error message
Daytona ${label} command failed (exit ${result.exitCode ?? "unknown"})${detail ? `: ${detail}` : ""} What it means
Exit-code check in assertSandboxCommandOk: a command executed inside the Daytona sandbox (e.g. tar/cleanup helpers around sync) returned a non-zero exit code (or timing out maps to non-zero), and its trimmed stdout/stderr is appended as detail. This converts a failed sandbox-side helper step into an aborting error for the enclosing sync operation.
Solutions
- Inspect the exit code and detail in the message; fix the remote command and retry.
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at packages/plugins/sandbox-providers/daytona/src/file-sync.ts:310 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of paperclipai/paperclip@3f1d897a7c (2026-08-18).
Data as JSON: /api/errors/b00b2156ce4bc3f2.
Report an issue: GitHub.
Appendix: source
Thrown at packages/plugins/sandbox-providers/daytona/src/file-sync.ts:314
env: { ...process.env, COPYFILE_DISABLE: "1" },
maxBuffer: 32 * 1024 * 1024,
});
}
async function countHostFiles(root: string, exclude?: string[]): Promise<number> {
const excludeSet = new Set(exclude ?? []);
let total = 0;
const walk = async (dir: string): Promise<void> => {
const entries = await fs.readdir(dir, { withFileTypes: true }).catch(() => []);
for (const entry of entries) {
if (excludeSet.has(entry.name)) continue;
const full = path.join(dir, entry.name);
if (entry.isDirectory()) {
await walk(full);
} else {
total += 1;
}
}
};
await walk(root).catch(() => undefined);
return total;
}
/**
* Run one sandbox command and return its stdout on success. Throws the same
* shaped error as {@link assertSandboxCommandOk} on a non-zero exit. Used by
* the mkdir+zstd-probe round trip, which must read the probe's answer from
* the command's own output rather than only checking the exit code.
*/
async function assertSandboxCommandOkWithOutput(
sandbox: Sandbox,
command: string,
timeoutSeconds: number,
label: string,
): Promise<string> {
const result = await sandbox.process.executeCommand(command, undefined, undefined, timeoutSeconds);View on GitHub (pinned to 3f1d897a7c)