paperclipai/paperclip · error
Plugin worker "${pluginId}" is not running for the duplex ch
Error message
Plugin worker "${pluginId}" is not running for the duplex channel. What it means
Thrown by the plugin sandbox driver's openDuplexChannel when pluginWorkerManager.getWorker(pluginId) returns null — the lease names a plugin whose worker process is not currently running on the host. The duplex route must bind to the same worker session the sandbox runner streams through, so a stopped/crashed/never-started worker is a hard failure for the channel open.
Source
Thrown at server/src/services/environment-runtime.ts:2493
async openDuplexChannel(input) {
// Plugin-backed sandbox providers only: open the host-owned duplex route on
// the plugin worker. The lease scope mirrors the sandbox execute path — the
// provider driver key, the company, the environment, and the provider lease
// id — so the route binds to the same worker session the runner streams.
if (!input.lease.metadata?.sandboxProviderPlugin || !pluginWorkerManager) {
throw new Error("Sandbox driver does not support duplex channels for this lease.");
}
const pluginId = readString(input.lease.metadata?.pluginId);
const providerKey = readString(input.lease.metadata?.provider);
const providerLeaseId = readString(input.lease.providerLeaseId);
if (!pluginId || !providerKey || !providerLeaseId) {
throw new Error(
"Sandbox duplex channel needs a plugin id, a provider key, and a provider lease id on the lease.",
);
}
const worker = pluginWorkerManager.getWorker(pluginId);
if (!worker) {
throw new Error(`Plugin worker "${pluginId}" is not running for the duplex channel.`);
}
const managerInput: WorkerManagerDuplexChannelOpenInput = {
driverKey: providerKey,
companyId: input.lease.companyId,
environmentId: input.environment.id,
providerLeaseId,
command: input.command,
};
const session = await worker.openDuplexChannel(managerInput);
return adaptDuplexChannelHostSession(session);
},
async effectiveSandboxCapabilities(input) {
const metadata = input.lease.metadata ?? {};
const providerKey =
readString(metadata.provider) ??
(input.environment.driver === "sandbox"
? readString((parseEnvironmentDriverConfig(input.environment).config as SandboxEnvironmentConfig).provider)View on GitHub (pinned to a7e689b3c3)
Solutions
- Check plugin worker status on the server (plugin registry/manager logs) for the named pluginId.
- Restart or re-enable the plugin so its worker boots, then retry the channel open.
- If the worker keeps dying, inspect the plugin worker logs for the crash cause and fix the plugin before retrying.
- If the lease outlived a plugin upgrade, acquire a fresh sandbox lease from the current plugin version.
Defensive patterns
Strategy: retry
Validate before calling
const worker = pluginWorkerManager.getWorker(pluginId);
if (!worker) { await pluginWorkerManager.ensureWorkerStarted(pluginId); } // start the worker before opening the channel Try / catch
try { return await driver.openDuplexChannel(input); } catch (err) { if (/is not running for the duplex channel/.test((err as Error).message)) { await restartPluginWorker(pluginId); return await driver.openDuplexChannel(input); } throw err; } Prevention
- Ensure plugin workers are started (or eagerly warmed) before agents begin duplex sessions.
- Monitor plugin worker health and auto-restart crashed workers.
- Acquire fresh leases after plugin upgrades rather than reusing leases bound to a dead worker session.
When it happens
Trigger: openDuplexChannel with valid lease metadata while the plugin's worker process is down: the plugin was disabled or failed to boot, the worker crashed earlier and was not restarted, or the channel open races worker startup right after server boot.
Common situations: Plugin worker crashed (OOM, unhandled error) leaving leases valid but workers dead; server restarted and lazy worker start has not happened yet for that plugin; plugin uninstalled/updated between lease creation and channel open.
Related errors
- DUPLEX_CHANNEL_OPEN_FAILED
- Daytona duplex channel: no cached sandbox resolves the provi
- Sandbox driver does not support duplex channels for this lea
- Sandbox duplex channel needs a plugin id, a provider key, an
- DUPLEX_CHANNEL_CAPABILITY_DENIED
AI-assisted analysis of paperclipai/paperclip@a7e689b3c3 (2026-08-21).
Data as JSON: /api/errors/60551e42af0b5de7.
Report an issue: GitHub.