From 0bba31130b9af44489da6b31799e9e9359675ec3 Mon Sep 17 00:00:00 2001 From: rafaelcuca <71181786+rafaelcuca@users.noreply.github.com> Date: Fri, 30 Oct 2026 15:21:25 -0300 Subject: [PATCH] Run the CopilotKit CLI on Windows when making a Learning container Node refuses to spawn npx.cmd without a shell on Windows (EINVAL), so every CLI step in the Learning setup failed there. Spawn it through the shell on win32 only. Also ignore .copilotkit/ (the CLI's project selection for one machine and login) and .playwright-mcp/ (browser snapshots a coding agent writes). Co-Authored-By: Claude Opus 5.5 --- .gitignore | 6 ++++++ server/src/learning/ensure-container.ts | 2 ++ 2 files changed, 8 insertions(+) diff --git a/.gitignore b/.gitignore index 5b6adc7865..6014dbebfe 100644 --- a/.gitignore +++ b/.gitignore @@ -56,3 +56,9 @@ venv/ # The Recorder extension's signing key never enters the repository (Decision 9). extension/**/*.pem + +# Added by CopilotKit CLI: browser snapshots a coding agent writes. +.playwright-mcp/ + +# The CopilotKit CLI's project selection for this checkout belongs to one machine and login. +.copilotkit/ diff --git a/server/src/learning/ensure-container.ts b/server/src/learning/ensure-container.ts index 812eea97d7..5031f5c30d 100644 --- a/server/src/learning/ensure-container.ts +++ b/server/src/learning/ensure-container.ts @@ -139,6 +139,8 @@ export const runCli: RunCli = (args, directory) => { cwd: directory, env: cliEnvironment(), + // Node refuses to spawn .cmd files without a shell on Windows (EINVAL). + shell: process.platform === "win32", stdio: ["ignore", "pipe", "pipe"], }, );