lemonade: a failed backend install during serve leaves the spawned lemond running
メンテナーはふだん 2 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 2/5
- 見積もり時間
- 1〜3時間
- 初心者へのやさしさ
- 78/100
調査の方向性
engines/lemonade/src/lib.rs の spawn_lemond の後にあるルーター分岐を読み、そのエラー処理を backend_alignment.rs の install_best_llamacpp_backend と比較してください。issue で言及されている既存の serve 準備リカバリーパスを確認し、バックエンドのインストール失敗を発生させる方法を探してください。準備状況の確認またはバックエンドの選択に失敗したとき、起動した子プロセスを停止して終了を待ち、lemond プロセスが残らないことをテストで確認できれば完了です。
索引モデルが issue の本文から書いたものです。
説明
What happens
In the Lemonade engine's serve path (engines/lemonade/src/lib.rs, the router branch after spawn_lemond), two early returns leave the spawned lemond running:
let mut child = crate::process::spawn_lemond(...)?;
...
crate::process::wait_for_lemonade_cli_status(...)
.context("Lemonade server did not become ready")?; // returns, child left running
let backend = crate::backend_alignment::ensure_best_llamacpp_backend(...)
.context("failed to select a supported Lemonade llama.cpp backend")?; // same
The later failure paths in the same function (load_result failing, or the router not reporting the model) do call terminate_pid(child.id(), true) and child.wait() before returning. Its sibling install_best_llamacpp_backend in backend_alignment.rs does the same unconditionally around the same two calls.
Why it matters
When the llama.cpp backend install fails, which is exactly the case rocm serve already retries once and then tells the user to rocm engines install lemonade --reinstall, the engine exits with an error but its lemond keeps running. It still holds the port and its state.
Not verified
Whether anything on the rocm serve side later reaps that lemond, for example a stop through the service record that recorded its pid via write_running_state(..., Some(child.id()), "running"). This was found by reading the code. In the e2e suite the harness's teardown kills it, so no test shows the leak.
Suggested fix
Run both calls inside a closure and terminate the child on its Err, as install_best_llamacpp_backend does. Add a unit or e2e assertion that no lemond survives a failed backend install; @id:serve-lemonade-preparation-recovery already drives that failure with a planted runtime once #351 lands.
Raised in review on #351.
- 主要言語
- Rust
- スター
- 49
- フォーク
- 14
- 平均マージ
- 3日 6時間
- マージ済み PR(30日)
- 183
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
ROCm/rocm-cli のほかの issue
-
bug installation
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
メンテナーはふだん 2 日以内に返信
-
enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 2 日以内に返信
-
bug documentation
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 2 日以内に返信
-
documentation
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
メンテナーはふだん 2 日以内に返信
-
enhancement ux-opportunities
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 2 日以内に返信
似ている issue
-
r-bug
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
servo/rust-smallvec#844 ·
メンテナーはふだん 1 日以内に返信
-
enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
farion1231/cc-switch#9122 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
lbjlaq/Antigravity-Manager#3801 ·
メンテナーはふだん 1 日以内に返信
-
LIMIT inputs are named MIN/MAX instead of the standard MN/MX, so LIMIT(MN := ...) does not resolveオープン
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
Published SDL drops input-field default values: a non-null field with a default renders as requiredオープン
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
メンテナーはふだん 1 日以内に返信