feat: improve stdio handling with async writers#160
Merged
branchseer merged 3 commits intomainfrom Feb 15, 2026
Merged
Conversation
…nsistency The Statistics line in the execution summary had a trailing space that was preserved on macOS but trimmed by Windows ConPTY. Also updates the task-list 'vp run in script' E2E test to use expect-milestone + enter instead of timing out.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
Extends the existing "stdin suggestion" system to a full "stdio" system. Previously, only stdin was conditionally inherited vs null. Now, all three stdio FDs (stdin, stdout, stderr) are conditionally inherited vs piped, and the reporter provides
Box<dyn AsyncWrite + Unpin>streams for receiving child process output.Changes
New types and API
StdioSuggestionreplacesStdinSuggestion— two modes:Piped(stdin=null, stdout/stderr piped into AsyncWrite streams) andInherited(all three inherited from parent)StdioConfigreturned byLeafExecutionReporter::start()— contains the suggestion plusstdout_writerandstderr_writerasync streamsstdin_suggestion()andoutput(kind, content)fromLeafExecutionReportertraitOutputKindfromevent.rs(onlyspawn.rskeeps its ownOutputKind)Reporter changes
Wgeneric from all reporters (PlainReporter,LabeledReporterBuilder,LabeledGraphReporter,LabeledLeafReporter,SharedReporterState)std::io::stdout()using sync writestokio::io::stdout()/tokio::io::stderr()provided as theAsyncWritestreams inStdioConfigPlainReporterreturnstokio::io::sink()writers whensilent_if_cache_hit && is_cache_hitExecution flow
spawn_with_tracking()— stdin is alwaysStdio::null(), takes&mut dyn AsyncWritefor stdout/stderr instead of anon_outputcallbackspawn_inherited()— inherits all three stdio FDs, no fspy tracking, justcmd.spawn()+wait()InheritedANDcache_metadata.is_none()(caching fully disabled)StdioConfigwritersstdout_writerfromStdioConfigTest updates
start()+ assertStdioConfig.suggestiontask-listE2E "vp run in script" test: innervp runnow sees a terminal (inherited stdout) and shows interactive selector — test usesexpect-milestone+ Enter to select and run a task