Skip to content

Let child process stderr inherit from parent in getNimbleDumpInfo#410

Open
ZoomRmc wants to merge 1 commit into
nim-lang:masterfrom
ZoomRmc:zls
Open

Let child process stderr inherit from parent in getNimbleDumpInfo#410
ZoomRmc wants to merge 1 commit into
nim-lang:masterfrom
ZoomRmc:zls

Conversation

@ZoomRmc
Copy link
Copy Markdown

@ZoomRmc ZoomRmc commented May 15, 2026

getNimbleDumpInfo pipes the child process's stderr but never reads it. This silently discards any diagnostics nimble produces on stderr and needlessly consumes a file descriptor. In extreme cases it could also cause a pipe deadlock if the child writes enough stderr data to fill the pipe buffer before stdout closes.

Fix: use an empty ProcessStreamHandle for stderr instead of piping. The child's stderr inherits from the parent process's stderr, which the editor or MCP host already captures and logs.

getNimbleDumpInfo pipes the child process's stderr but never reads
it. This silently discards any diagnostics nimble produces on stderr
and needlessly consumes a file descriptor. In extreme cases it could
also cause a pipe deadlock if the child writes enough stderr data to
fill the pipe buffer before stdout closes.

Fix: use an empty ProcessStreamHandle for stderr instead of piping.
The child's stderr inherits from the parent process's stderr, which
the editor or MCP host already captures and logs.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant