[bug] update: exits 0 after the upgrade actually failed
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Idoneità per principianti
- 72/100
- Tipo di issue
- Bug
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- node.js, typescript
- Ambito
- cli
Direzione di ricerca
Inizia dal percorso di errore di bl update che stampa «Automatic update failed»; l’issue non indica alcun file sorgente né alcun test. Segui come quel ramo gestisce l’errore di npm e lo stato di uscita del processo, poi esegui i test di aggiornamento pertinenti oppure riproduci il problema con un prefisso globale npm di sola lettura. Il risultato è raggiunto quando un aggiornamento non riuscito restituisce un codice diverso da zero e un aggiornamento riuscito continua ad avere esito positivo.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Environment
- CLI: bl 2.0.1 at the time of failure (Skill: 2.0.1)
- Node: v22.23.3
- OS: Linux 5.15.0-198-generic x86_64 (Ubuntu)
- Install channel: npm global (
npm prefix -g→/home/lin/.npm-global) - Region: cn (domestic)
Reproduce
- Install
blglobally via npm. - Make the npm global prefix read-only (here: a read-only filesystem sandbox).
- With a newer version available (2.0.1 → 2.1.0), run:
bl update; echo "exit=$?"
Expected
A failed upgrade exits non-zero.
Actual
The upgrade failed with EROFS, the CLI printed Automatic update failed. Please run manually: — and still exited 0.
Any driver that checks only the exit code (CI, cron, agent) will record the
upgrade as successful while the old version is still installed. In this case the
caller believed 2.0.1 was the latest until it re-read bl --version.
Full output
Current version: 2.0.1
Install method: npm
Checking for updates...
Latest version: 2.1.0
Updating bailian-cli via npm...
npm error code EROFS
npm error syscall rename
npm error path /home/lin/.npm-global/lib/node_modules/bailian-cli
npm error dest /home/lin/.npm-global/lib/node_modules/.bailian-cli-RC0fMVNr
npm error errno -30
npm error rofs EROFS: read-only file system, rename '/home/lin/.npm-global/lib/node_modules/bailian-cli' -> '/home/lin/.npm-global/lib/node_modules/.bailian-cli-RC0fMVNr'
npm error rofs Often virtualized file systems, or other file systems
npm error rofs that don't support symlinks, give this error.
npm error A complete log of this run can be found in: <npm debug log>
Automatic update failed. Please run manually:
npm install -g bailian-cli@latest
exit=0
Already tried
- Confirmed the exit code with both
echo $?and${PIPESTATUS[0]}— both 0 - The failure is not shell-related:
bl updateitself returns 0 - Same behaviour regardless of whether npm's cache/logs directories are writable
- After granting write access, the retry succeeded (2.0.1 → 2.1.0) and printed
the skill-update result normally — so only the failure branch reports success
Notes
- Frequency: always on the failure path
- Related: #229 reports
--config <profile>also exiting 0 on failure
(exits 0 unauthenticated). Same class of defect: the process exit code does
not reflect the outcome, and the CLI's own documented contract treats exit 0 as
SUCCESS. - Suggested fix: propagate npm's exit code from the
bl updatefailure branch
(or return a dedicated non-zero code), sobl update && ...and agent drivers
can detect the failure.
- Lingua principale
- TypeScript
- Stelle
- 540
- Fork
- 35
- Merge medio
- 6h 43m
- PR unite (30g)
- 23
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di modelstudioai/cli
-
[bug] vision describe: default base URL is the Coding Plan endpoint → HTTP 404 for all VL/OCR modelsAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
modelstudioai/cli#241 ·
I maintainer di solito rispondono entro 1 giorno
-
[bug] bl update: darwin-arm64 binary ships invalid ad-hoc signature, killed by macOS (Killed: 9)Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
modelstudioai/cli#223 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 35/100
modelstudioai/cli#240 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 57/100
modelstudioai/cli#239 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 68/100
modelstudioai/cli#231 · 2 commenti · 1 reazione ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di modelstudioai/cli
Issue simili
-
area/frontend area/v2 kind/bug priority/needs-triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
kubeflow/notebooks#1498 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
I maintainer di solito rispondono entro 1 giorno
-
P1
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
SuruchBoss/Cwork#90 ·
-
bug cli service
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 85/100
521xueweihan/HelloGitHub#3922 ·