can1357/oh-my-pi · error

lsp mux smoke failed: no ping response (${proc.peekStderr().

Error message

lsp mux smoke failed: no ping response (${proc.peekStderr().slice(-500) || "no stderr"})

What it means

The LSP mux smoke test spawns a mux process, sends a ping over the framed link, and waits for a pong within a polling window. If no ping response arrives, the daemon can't be considered healthy; the error includes the last 500 bytes of the child's stderr (or "no stderr") to expose why the process didn't answer.

Source

Thrown at packages/coding-agent/src/lsp/mux/daemon.ts:342

		cwd: spawn.cwd,
		env: workerEnvFromParent({
			[LSP_MUX_SOCKET_ENV]: endpoint,
			[LSP_MUX_PROJECT_DIR_ENV]: process.cwd(),
		}),
	});
	try {
		const deadline = Date.now() + SMOKE_TEST_TIMEOUT_MS;
		let alive = false;
		while (Date.now() < deadline) {
			if (proc.exitCode !== null) break;
			if (await probeMux(endpoint)) {
				alive = true;
				break;
			}
			await Bun.sleep(200);
		}
		if (!alive) {
			throw new Error(`lsp mux smoke failed: no ping response (${proc.peekStderr().slice(-500) || "no stderr"})`);
		}
	} finally {
		proc.kill();
		await proc.exited.catch(() => {});
	}
}

View on GitHub (pinned to 9690622007)

Solutions

  1. Inspect the stderr excerpt in the message for the child's actual failure (bind error, missing binary, exception)
  2. Remove stale socket/pipe files at the endpoint and retry
  3. Verify the mux binary/entry point runs standalone
  4. Check permissions on the socket directory and that no firewall/AV blocks local IPC
Defensive patterns

Strategy: try-catch

Validate before calling

// Pre-check the endpoint before spawning the mux daemon
import * as fs from 'node:fs';
if (process.platform !== 'win32' && fs.existsSync(sockPath)) {
  fs.unlinkSync(sockPath); // clear stale socket
}

Try / catch

try {
  await smokeTestLspMux(endpoint);
} catch (err) {
  if (err.message.startsWith('lsp mux smoke failed: no ping response')) {
    logger.error('mux daemon failed smoke test', { stderr: err.message });
    // retry once after clearing endpoint, then surface stderr to the user
  }
  throw err;
}

Prevention

When it happens

Trigger: runSmokeTest → smokeTestLspMux: the spawned mux process fails to bind its socket/pipe, crashes on startup, or hangs, so the ping loop exhausts its retries without a response.

Common situations: Port/socket path conflicts or stale socket files; mux binary incompatible or missing; insufficient permissions on the Unix socket path; platform-specific named-pipe issues on Windows; resource exhaustion preventing process startup.

Related errors


AI-assisted analysis of can1357/oh-my-pi@9690622007 (2026-08-31). Data as JSON: /api/errors/39136acf97fa9d4b. Report an issue: GitHub.