mirror of
https://github.com/siteboon/claudecodeui.git
synced 2026-06-10 15:55:53 +08:00
Plugin servers are started with a deliberately minimal env (PATH, HOME, NODE_ENV, PLUGIN_NAME). On Windows that drops system variables that child processes need to bootstrap. The one that bit me: without APPDATA, CPython cannot find the per-user site-packages, so a plugin that shells out to a pip install --user CLI launches the tool but it dies with ModuleNotFoundError. SystemRoot, PATHEXT and TEMP cause similar failures for other tools. On win32, pass through a small allowlist of non-secret system variables (SystemRoot, windir, SystemDrive, USERPROFILE, APPDATA, LOCALAPPDATA, TEMP, TMP, PATHEXT) when they are set. No change off Windows, and no host secrets are exposed.