CommandCodeAI / CommandCodeAI/command-code
Login fails on sandboxed WSL instance
未關閉
還沒有人認領這個 Issue。
- 主要語言
- 沒有語言資料
- 星號
- 4k
- 分支
- 350
- PR 合併指標
- 30 天內沒有已合併 PR
描述
Summary
Command Code immediately quits after launching the first time on an WSL sandboxed image where it does not have access to the host volumes.
Expected Behavior
I disable mounting host volumes in WSL to sandbox my image, install commandcode, and run it to get started. I expect to paste in my API key and go.
Actual Behavior
~$ cmdc
✔ Ready to log in
┌ Command Code Authentication
✖ CRITICAL: Uncaught Exception!
This is an unexpected error. Please file a bug report at https://github.com/CommandCodeAI/command-code/issues/new
✖ ERROR → Error
ℹ REASON → spawn /mnt/c/Windows/System32/WindowsPowerShell/v1.0/powershell.exe ENOENT
ℹ ERROR STACK ↓
Error: spawn /mnt/c/Windows/System32/WindowsPowerShell/v1.0/powershell.exe ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:286:19)
at onErrorNT (node:internal/child_process:507:16)
at process.processTicksAndRejections (node:internal/process/task_queues:90:21)
ℹ Trace ID: unknown
Share this ID with support to help debug your issue.
… Complete login in your browser...
┌────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
│ API Key: Paste your API key... │
└────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
Authorize in browser, or paste API key here
If your browser doesn't open, go to this link:
https://commandcode.ai/studio/auth/cli?callback=rest_of_link
Ctrl+C to cancel
~$
Steps to reproduce the issue
- Install WSL
wsl -u root- Disable auto mounting & appending of Windows paths by setting /etc/wsl.conf to the following:
[boot]
systemd=true
[automount]
enabled=false
[interop]
appendWindowsPath=false
wsl --shutdownwsl- install nvm, then node, then commandcode
- run cmdc for the first time.
Command Code Version
0.35.0
Operating System
Windows
Terminal/IDE
PowerShell
Shell
bash
Additional context
No response
貢獻指南
這個儲存庫沒有索引到貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
研究方向
首先,使用所示的 /etc/wsl.conf 設定重現 cmdc 的首次執行驗證流程,並檢查啟動瀏覽器或產生 PowerShell 程序的進入點。完成條件是在無法存取已掛載 Windows 路徑的沙箱化 WSL 執行個體中可以繼續登入。
由索引模型根據 Issue 內容生成。
評估
- 技術堆疊
- bash, node.js, powershell
- 領域
- authentication, cli, operating-systems
- Issue 類型
- 缺陷
- 難度
- 3/5
- 預估耗時
- 1-2 天
- 活躍度
- 冷清
- 描述清晰度
- 基本清楚
- 新手友好度
- 48/100