Repository navigation
Commit 405a5ef
fix(drivers): kill the npm process tree on timeout, and quote the last install hint
Kilo Code's review, which finally ran after its provider rate limit cleared.
**A timed-out install kept running.** `runNpm` spawns with `shell: true`, so the
child is the shell and npm is its descendant; `child.kill()` therefore reaped the
shell and left npm writing to the shared driver directory after the promise had
already resolved with a timeout error. The in-flight map cannot help here — it
serializes promises, not processes — so a subsequent install could overlap an
orphan. POSIX runs now get their own process group (`detached`) and are killed
group-wide; Windows, which has no process groups, uses `taskkill /T /F`.
**One install hint was still unquoted.** `warehouse_install_driver`'s failure
branch interpolated the directory raw while the two equivalents in
`DriverNotInstalledError` and `driverReadinessNote` were already wrapped in
`shellQuote`. That is the branch a user reads precisely when the automatic
install has failed them, and on a path like `C:\Users\John Doe\...` the copied
command splits and npm receives the wrong prefix. A test now asserts every
printed `--prefix` is quoted.
Also merges origin/main (12 commits). The only conflict was in the driver
externals list, where main had reformatted it one-per-line while this branch
added mongodb, @clickhouse/client, trino-client and @azure/identity; the
resolution keeps main's formatting and this branch's four additions.
Tests: 186 drivers unit, 4,696 opencode. Typecheck clean.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>1 parent 8573f73 commit 405a5ef
3 files changed
Lines changed: 60 additions & 4 deletions
File tree
- packages
- drivers
- src
- test
- opencode/src/altimate/tools
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
399 | 399 | | |
400 | 400 | | |
401 | 401 | | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
| 412 | + | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
402 | 427 | | |
403 | 428 | | |
404 | 429 | | |
405 | | - | |
406 | | - | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
| 435 | + | |
| 436 | + | |
| 437 | + | |
| 438 | + | |
407 | 439 | | |
408 | 440 | | |
409 | 441 | | |
| |||
413 | 445 | | |
414 | 446 | | |
415 | 447 | | |
416 | | - | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
417 | 454 | | |
418 | 455 | | |
419 | 456 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
578 | 578 | | |
579 | 579 | | |
580 | 580 | | |
| 581 | + | |
| 582 | + | |
| 583 | + | |
| 584 | + | |
| 585 | + | |
| 586 | + | |
| 587 | + | |
| 588 | + | |
| 589 | + | |
| 590 | + | |
| 591 | + | |
| 592 | + | |
| 593 | + | |
| 594 | + | |
| 595 | + | |
| 596 | + | |
| 597 | + | |
| 598 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| 5 | + | |
5 | 6 | | |
6 | 7 | | |
7 | 8 | | |
| |||
96 | 97 | | |
97 | 98 | | |
98 | 99 | | |
99 | | - | |
| 100 | + | |
100 | 101 | | |
101 | 102 | | |
102 | 103 | | |
| |||
0 commit comments