n8n-io/n8n · error
Instance AI runtime sandbox does not support command…
Error message
Instance AI runtime sandbox does not support command execution.
What it means
The sandbox object resolved by the runtime workspace has no executeCommand method, so this deployment's sandbox backend does not support shell command execution. The guard fires in executeCommand before any command runs; filesystem-based APIs are the only supported I/O path here.
Solutions
- Use filesystem read/write APIs instead of shell commands
- Enable a command-execution-capable sandbox backend on the instance
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at packages/@n8n/instance-ai/src/workspace/lazy-runtime-workspace.ts:334 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of n8n-io/n8n@5ac6606e81 (2026-08-12).
Data as JSON: /api/errors/5c0dd1663ec39a04.
Report an issue: GitHub.
Appendix: source
Thrown at packages/@n8n/instance-ai/src/workspace/lazy-runtime-workspace.ts:334
this.syncStatus(sandbox);
}
override async destroy(): Promise<void> {
await this.resolver.destroyResolvedWorkspace();
}
getDefaultCommandEnv(): NodeJS.ProcessEnv {
return this.resolver.current?.sandbox?.getDefaultCommandEnv?.() ?? {};
}
override async executeCommand(
command: string,
args: string[] = [],
options?: ExecuteCommandOptions,
): Promise<CommandResult> {
const sandbox = await this.getSandbox(options?.abortSignal);
if (!sandbox.executeCommand) {
throw new Error('Instance AI runtime sandbox does not support command execution.');
}
const defaultEnv = sandbox.getDefaultCommandEnv?.();
try {
return await sandbox.executeCommand(command, args, {
...options,
...(defaultEnv ? { env: { ...defaultEnv, ...options?.env } } : {}),
});
} finally {
this.syncStatus(sandbox);
}
}
override getInstructions(): string {
// Prefer the caller-provided stable text: it is returned regardless of
// resolution state so the agent's cached prompt prefix stays byte-stable
// across rebuilds/resumes. Branching on the live sandbox (which is only
// resolved once a workspace tool runs in this rebuilt instance) wouldView on GitHub (pinned to 5ac6606e81)