fix(cli): route sandbox diagnostic messages to stderr - #1735
Merged
Conversation
Change all diagnostic/progress messages in sandbox.ts from writeStdoutLine to writeStderrLine. This prevents integration test failures in Docker where stdout buffering behavior differs from the Console API. Diagnostic messages like 'Checking for sandbox image' are informational logs that should not interfere with program output that tests or other tools may parse from stdout. Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
tanzhenxin
requested review from
DennisYu07,
LaZzyMan,
Mingholy,
gwinthis and
pomelo-nwu
as code owners
February 6, 2026 02:09
Contributor
📋 Review SummaryThis PR addresses an important issue where sandbox diagnostic messages were incorrectly routed to stdout instead of stderr, causing integration test failures in Docker environments. The fix involves changing all diagnostic messages in 🔍 General Feedback
🎯 Specific Feedback🟡 High
🟢 Medium
✅ Highlights
|
Mingholy
approved these changes
Feb 6, 2026
Contributor
Code Coverage Summary
CLI Package - Full Text ReportCore Package - Full Text ReportFor detailed HTML reports, please see the 'coverage-reports-22.x-ubuntu-latest' artifact from the main CI run. |
xaelistic
pushed a commit
to xaelistic/qwen-code
that referenced
this pull request
Jun 7, 2026
fix(cli): route sandbox diagnostic messages to stderr
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.
TLDR
Route all sandbox diagnostic/progress messages to stderr instead of stdout to prevent integration test failures in Docker environments.
Dive Deeper
In commit 7995c65, sandbox diagnostic messages were migrated from
console.info()towriteStdoutLine()to satisfy ESLintno-consolerules. However, this caused integration test failures in Docker because:process.stdout.write()has different buffering behavior than the Console API in Docker containersThis fix changes all diagnostic messages in
sandbox.tsfromwriteStdoutLinetowriteStderrLine. This is semantically correct because:Reviewer Test Plan
Run integration tests with Docker sandbox:
Verify sandbox operations still display progress messages (now on stderr):
Confirm no
no-consoleESLint violations insandbox.tsTesting Matrix
Tested on macOS with Docker Desktop and Seatbelt
Linked issues / bugs
No linked issues
🤖 Generated with Qwen Code