Drain subprocess pipes while probing interpreters and standardize probe deadlines
まだ誰も着手していません。
評価
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 初心者へのやさしさ
- 32/100
- issue の種類
- 機能追加
- 明瞭さ
- おおむね明確
- 活発さ
- 活発
- 技術スタック
- rust
- 領域
- testing-qa, tooling
調査の方向性
Start by reading crates/pet-python-utils/src/env.rs, crates/pet-conda/src/conda_info.rs, and crates/pet-poetry/src/environment_locations_spawn.rs to compare the existing probe and subprocess paths. Run the relevant test suite, then verify the shared runner against the listed pipe, timeout, cleanup, output, and Windows/Unix acceptance cases without regressing interpreter discovery or benchmark behavior.
索引モデルが issue の本文から書いたものです。
説明
Tracking plan: #528
Priority: P1. Evidence: pipe backpressure reproduced; other runner gaps confirmed by source inspection.
Problem and evidence
The interpreter probe pipes stdout/stderr, polls for child exit, and only then calls wait_with_output. A child that fills a pipe cannot exit until PET drains it, so a healthy interpreter is killed by the timeout.
A temporary Python startup fixture writing 128 KiB to stderr exited successfully in 217 ms when its output was drained normally. Resolving the same interpreter through PET took 15,111 ms and returned a timeout error. These are Windows debug-build diagnostic measurements, not release budgets.
Sources: interpreter probe, Conda subprocess, Poetry subprocess.
The interpreter deadline currently starts after process creation. Conda/Poetry blocking output calls do not share equivalent timeout/cleanup semantics. Do not claim that a deadline bounds a synchronous OS process-creation call unless the implementation actually does so.
Scope
Introduce the smallest reusable process runner needed for interpreter and manager probes: concurrent pipe draining, bounded retained output, explicit exit/parse/I/O errors, deadlines, and child cleanup. Preserve the file-first discovery policy and do not add new spawn fallbacks. Define behavior for descendants retaining pipe handles and for capture-limit exhaustion; do not silently truncate valid protocol data into success.
The non-UTF-8 panic already belongs to #525 / #526. Reuse that fix rather than duplicating it, and retain its regression tests while changing the runner.
Acceptance criteria
- A healthy fixture emitting more than pipe capacity on stdout and/or stderr completes without waiting for the 15-second timeout.
- Hanging child, malformed output, nonzero exit, invalid UTF-8, and output-limit cases return explicit outcomes without panic or abandoned RPCs.
- Timeout/cleanup behavior has Windows and Unix tests, including an inherited-pipe case; tests clean up every process they create.
- Conda and Poetry probe call sites use the established deadline/error contract, with no unbounded output wait hidden behind an RPC.
- Captured memory stays within a documented limit while pipes continue to be drained or the child is terminated deliberately.
- Quiet successful interpreter probes preserve existing environment output and do not regress the relevant release benchmark budgets.
Dependencies
Coordinate implementation after #525 / #526 because both touch interpreter-output handling. Bounded request scheduling and sharing failed in-flight probes are separate follow-up work in #539. Reuse this runner from the #533 workload harness; the complete plan is #528.
- 主要言語
- Rust
- スター
- 207
- フォーク
- 45
- 平均マージ
- 3日 6時間
- マージ済み PR(30日)
- 12
コントリビューションガイド
このリポジトリのコントリビューションガイドは索引されていません
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
microsoft/python-environment-tools のほかの issue
-
enhancement
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
-
debt
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
microsoft/python-environment-tools#538 · コメント 1 件 ·
-
enhancement
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
-
debt
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
-
enhancement
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
microsoft/python-environment-tools#533 · コメント 2 件 ·
microsoft/python-environment-tools の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
TheLarkInn/aipm#2413 ·
-
documentation
難易度 1/5 1時間未満 初心者へのやさしさ 90/100
alexgorbatchev/simple-ptt#15 ·
-
tooling
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
-
todo:ticket
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
taikoxyz/taiko-mono#22168 · コメント 1 件 ·