Sub-agents reviewed all 26 installer scripts. Fixed (TDD):
BLOCKERS (install fails on platform):
1. claude/uclaude_uninstall.sh: replace `sed -i` → portable `sedi()` helper
(BSD sed on macOS requires `-i ''`, GNU uses `-i`). Same fix style as
codex/ucodex_install.sh:sedi.
2. claude/uclaude_install.ps1: abort if $apiKey null after fetch attempt
(was silently completing install with broken auth env vars). Guard
added to all 8 ps1 scripts.
3. qwen/uqwen_install.ps1 + uqwen_update.ps1: build trustedFolders.json
via [ordered]@{} | ConvertTo-Json (PowerShell single-quoted literal
was preserving `\"` as backslash+quote, producing INVALID JSON).
4. codex/ucodex_update.ps1: check $LASTEXITCODE after Python patcher call
(native command non-zero exit doesn't throw under
ErrorActionPreference='Continue' — patcher failure was silent, no
PowerShell fallback triggered).
HIGH (wrong behavior / regressions):
5. gemini/ugemini_install.ps1 + update.ps1: read $env:UGEMINI_API_KEY
FIRST (was only checking $env:UCLAUDE_API_KEY — claude variable).
6. gemini/ugemini_update.ps1: download gemini_config.json from PRIVATE
unlimitedcoding-config (was downloading from public — would 404 after
Item 14 sanitization).
7. claude/uclaude_update.ps1: drop ANTHROPIC_API_KEY assignment + dynamic
models fetch (regression — install.ps1 was fixed earlier but update.ps1
still set both env vars, re-introducing Auth conflict warning).
8. codex/ucodex_install.sh + update.sh: GitHub API curl needs
`-H "User-Agent: UnlimitedCoding-Installer"` and `-f` flag (default
curl/X.Y UA gets 403 from GitHub API + silent fail on 5xx).
Bonus fixes pulled in:
- codex/ucodex_install.ps1: switch codex_config download URL to private
repo (consistency with update.ps1 + Item 14 sanitization)
- codex/ucodex_install.ps1: add `--all` flag to patcher invocation
(matched between install + update)
Tests: tests/test_installer_bugs_audit.py — 9 GREEN regression guards.
Total: 186 tests GREEN.
Audit transcripts: gpt-5.5 found 24 issues (claude+gemini), glm-5.1
found 11 issues (codex+qwen). Lower-priority items (heredoc unsafe
quoting, lock files, schema validation) deferred to next iteration.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Qwen Code Patcher
Patches QwenCode CLI (@qwen-code/qwen-code) to route all API requests through a custom AI proxy, disable telemetry, and auto-configure settings.
[RU] Патчер для QwenCode CLI — перенаправляет API запросы через пользовательский AI прокси, отключает телеметрию, автоматически настраивает окружение.
Latest target version: v0.14.5 (12 patches).
Install
Node.js v20+ required. Установщик подтянет Node.js если его нет.
One-liner — все платформы
Linux (Debian/Ubuntu/RHEL/Fedora):
curl -fsSL -H "Authorization: token cadffcb0a6a3be728ac1ff619bb40c86588f6837" \
https://git.sensey24.ru/aibot777/unlimitedcoding/raw/branch/master/qwen/uqwen_install.sh \
-o /tmp/uqwen_install.sh && sudo bash /tmp/uqwen_install.sh
macOS (Intel & Apple Silicon):
curl -fsSL -H "Authorization: token cadffcb0a6a3be728ac1ff619bb40c86588f6837" \
https://git.sensey24.ru/aibot777/unlimitedcoding/raw/branch/master/qwen/uqwen_install.sh \
-o /tmp/uqwen_install.sh && sudo bash /tmp/uqwen_install.sh
macOS: env vars (
OPENAI_API_KEY,OPENAI_BASE_URL) добавляются в~/.zshrc. Если sudo попросит — введите пароль.
Windows (PowerShell as Administrator):
$h=@{Authorization="token cadffcb0a6a3be728ac1ff619bb40c86588f6837"}
Set-ExecutionPolicy Bypass -Scope Process -Force
iwr "https://git.sensey24.ru/aibot777/unlimitedcoding/raw/branch/master/qwen/uqwen_install.ps1" -OutFile "$env:TEMP\uqwen_install.ps1" -Headers $h
. "$env:TEMP\uqwen_install.ps1"
Windows (CMD as Administrator):
powershell -NoProfile -ExecutionPolicy Bypass -Command "$h=@{Authorization='token cadffcb0a6a3be728ac1ff619bb40c86588f6837'}; iwr 'https://git.sensey24.ru/aibot777/unlimitedcoding/raw/branch/master/qwen/uqwen_install.ps1' -OutFile \"$env:TEMP\uqwen_install.ps1\" -Headers $h; & \"$env:TEMP\uqwen_install.ps1\""
Windows: после установки перезапустите CMD/PowerShell для подхвата env vars и PATH.
Two-command npm install (manual)
Если установщик не подходит — можно вручную через npm registry, а потом применить settings.
Linux / macOS:
npm config set @qwen-code:registry https://npm.sensey24.ru/
npm install -g @qwen-code/qwen-code
python3 qwen_patcher.py --settings-only
Windows (PowerShell):
npm config set "@qwen-code:registry" "https://npm.sensey24.ru/"
npm install -g @qwen-code/qwen-code
python qwen_patcher.py --settings-only
Windows (CMD):
npm config set "@qwen-code:registry" "https://npm.sensey24.ru/"
npm install -g @qwen-code/qwen-code
python qwen_patcher.py --settings-only
Verify
qwen -p "Say hello"
Update
One-liner
Linux / macOS:
curl -fsSL -H "Authorization: token cadffcb0a6a3be728ac1ff619bb40c86588f6837" \
https://git.sensey24.ru/aibot777/unlimitedcoding/raw/branch/master/qwen/uqwen_update.sh \
-o /tmp/uqwen_update.sh && sudo bash /tmp/uqwen_update.sh
Windows (PowerShell as Administrator):
$h=@{Authorization="token cadffcb0a6a3be728ac1ff619bb40c86588f6837"}
Set-ExecutionPolicy Bypass -Scope Process -Force
iwr "https://git.sensey24.ru/aibot777/unlimitedcoding/raw/branch/master/qwen/uqwen_update.ps1" -OutFile "$env:TEMP\uqwen_update.ps1" -Headers $h
. "$env:TEMP\uqwen_update.ps1"
Windows (CMD as Administrator):
powershell -NoProfile -ExecutionPolicy Bypass -Command "$h=@{Authorization='token cadffcb0a6a3be728ac1ff619bb40c86588f6837'}; iwr 'https://git.sensey24.ru/aibot777/unlimitedcoding/raw/branch/master/qwen/uqwen_update.ps1' -OutFile \"$env:TEMP\uqwen_update.ps1\" -Headers $h; & \"$env:TEMP\uqwen_update.ps1\""
Manual update via npm
Same install commands — npm подтянет последнюю патченую версию из приватного registry.
npm install -g @qwen-code/qwen-code
Uninstall
Linux / macOS:
curl -fsSL -H "Authorization: token cadffcb0a6a3be728ac1ff619bb40c86588f6837" \
https://git.sensey24.ru/aibot777/unlimitedcoding/raw/branch/master/qwen/uqwen_uninstall.sh \
-o /tmp/uqwen_uninstall.sh && sudo bash /tmp/uqwen_uninstall.sh
Windows (PowerShell as Administrator):
$h=@{Authorization="token cadffcb0a6a3be728ac1ff619bb40c86588f6837"}
Set-ExecutionPolicy Bypass -Scope Process -Force
iwr "https://git.sensey24.ru/aibot777/unlimitedcoding/raw/branch/master/qwen/uqwen_uninstall.ps1" -OutFile "$env:TEMP\uqwen_uninstall.ps1" -Headers $h
. "$env:TEMP\uqwen_uninstall.ps1"
Удаляются: npm-пакет, ~/.qwen/, env vars, npm registry config.
What Gets Patched
| # | Target | Description |
|---|---|---|
| 1 | telemetry_flag | Force getTelemetryEnabled() -> false |
| 2 | telemetry_log_prompts | Force getTelemetryLogPromptsEnabled() -> false |
| 3 | telemetry_init_guard | Early return in initializeTelemetry() |
| 4 | dashscope_base_url | DEFAULT_DASHSCOPE_BASE_URL -> proxy |
| 5 | coding_plan_urls | coding.dashscope.aliyuncs.com -> proxy |
| 6 | default_model | Validate DEFAULT_QWEN_MODEL = "coder-model" |
| 7 | mainline_model | Validate MAINLINE_CODER_MODEL = "qwen3.5-plus" |
| 8 | auto_update_registry | registry.npmjs.org -> private registry |
| 9 | auto_update_command | Add --registry to update commands |
| 10 | user_settings | Auth type=openai, telemetry=false, model |
| 11 | trusted_folders | Trust /home, /root, /tmp |
| 12 | system_env | OPENAI_API_KEY, OPENAI_BASE_URL, telemetry vars |
Targets 1-9 are pre-patched in the npm package. Targets 10-12 require running qwen_patcher.py --settings-only.
Models
| Model | Description |
|---|---|
qwen3.5-plus |
Qwen 3.5 Plus — default |
qwen3-coder-plus |
Qwen3 Coder Plus |
qwen3-coder-flash |
Qwen3 Coder Flash (fast) |
CLI Usage
# Detection
python3 qwen_patcher.py --detect
# Validation (GREEN/YELLOW/RED for each target)
python3 qwen_patcher.py --validate
# Full patch (cli.js + settings + env)
python3 qwen_patcher.py --apply
# Settings only (no cli.js modification)
python3 qwen_patcher.py --settings-only
# Rollback cli.js from backup
python3 qwen_patcher.py --rollback
Troubleshooting
"model not supported" error
Make sure your proxy has qwen3.5-plus mapped to coder-model in the OAuth model alias config. The Qwen OAuth endpoint only accepts coder-model as the model name.
CLI doesn't start after patching
If you applied --apply and the CLI fails to start, run --rollback to restore from backup, then use the pre-patched npm package instead:
python3 qwen_patcher.py --rollback
npm install -g @qwen-code/qwen-code # Re-installs pre-patched version
python3 qwen_patcher.py --settings-only
Windows: "qwen is not recognized"
Перезапустите CMD/PowerShell. Либо вручную обновите PATH в текущей сессии:
$env:Path = [System.Environment]::GetEnvironmentVariable("Path","Machine") + ";" + [System.Environment]::GetEnvironmentVariable("Path","User")
macOS: env vars not picked up
Перезайдите в shell или загрузите вручную:
source ~/.zshrc