n8n-io/n8n · error

Instance AI runtime sandbox does not support command executi

Error message

Instance AI runtime sandbox does not support command execution.

What it means

Error "Instance AI runtime sandbox does not support command execution." thrown in n8n-io/n8n.

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) would

View on GitHub (pinned to 5ac6606e81)

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.