Skip to content

gh-135335: flush stdout/stderr in forkserver after preloading modules #135338

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 15 commits into from
Jun 18, 2025
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Don't write an newline to avoid any implicit flushes that might happen
  • Loading branch information
duaneg committed Jun 18, 2025
commit da4df4416105e8fcf5f1992da28ec9c7b5526fbb
4 changes: 2 additions & 2 deletions Lib/test/_test_multiprocessing.py
Original file line number Diff line number Diff line change
Expand Up @@ -6816,8 +6816,8 @@ def test_std_streams_flushed_after_preload(self):
with open(init_name, "w") as f:
cmd = '''if 1:
import sys
print('stderr', file=sys.stderr)
print('stdout', file=sys.stdout)
print('stderr', end='', file=sys.stderr)
print('stdout', end='', file=sys.stdout)
'''
f.write(cmd)

Expand Down
Loading