Make Android streams respect the unbuffered (-u) option#138806
Merged
freakboy3742 merged 1 commit intopython:mainfrom Sep 18, 2025
Merged
Make Android streams respect the unbuffered (-u) option#138806freakboy3742 merged 1 commit intopython:mainfrom
-u) option#138806freakboy3742 merged 1 commit intopython:mainfrom
Conversation
freakboy3742
approved these changes
Sep 18, 2025
Contributor
freakboy3742
left a comment
There was a problem hiding this comment.
Agreed that there isn't much utility in an unbuffered output streaming mode, but it doesn't hurt to support it just in case it's useful somewhere.
|
Thanks @mhsmith for the PR, and @freakboy3742 for merging it 🌮🎉.. I'm working now to backport this PR to: 3.13, 3.14. |
miss-islington
pushed a commit
to miss-islington/cpython
that referenced
this pull request
Sep 18, 2025
…38806) Android pipes stdout/stderr to the log, which means every write to the log becomes a separate log line. As a result, most practical uses of stdout/stderr should be buffered; but it doesn't hurt to preserve unbuffered handling in case it's useful. (cherry picked from commit 0ac377f) Co-authored-by: Malcolm Smith <[email protected]>
miss-islington
pushed a commit
to miss-islington/cpython
that referenced
this pull request
Sep 18, 2025
…38806) Android pipes stdout/stderr to the log, which means every write to the log becomes a separate log line. As a result, most practical uses of stdout/stderr should be buffered; but it doesn't hurt to preserve unbuffered handling in case it's useful. (cherry picked from commit 0ac377f) Co-authored-by: Malcolm Smith <[email protected]>
|
GH-139108 is a backport of this pull request to the 3.14 branch. |
|
GH-139110 is a backport of this pull request to the 3.13 branch. |
Yhg1s
pushed a commit
that referenced
this pull request
Sep 18, 2025
…138806) (#139110) Android pipes stdout/stderr to the log, which means every write to the log becomes a separate log line. As a result, most practical uses of stdout/stderr should be buffered; but it doesn't hurt to preserve unbuffered handling in case it's useful. (cherry picked from commit 0ac377f) Co-authored-by: Malcolm Smith <[email protected]>
hugovk
pushed a commit
that referenced
this pull request
Sep 29, 2025
…138806) (#139108) Co-authored-by: Malcolm Smith <[email protected]>
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.
While working on #138805, I updated the Android stream tests to be compatible with unbuffered mode. However, this mode isn't very readable on Android, because it causes lines to be split into multiple log messages. So the Android CI and buildbots are still not using unbuffered mode, but we might as well be compatible with it anyway.
I'm putting this in a separate PR from #138805 because neither change depends on the other.