Skip to content
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

Flush after println(xs...) (but not after println(stdout, xs...)) #57646

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

antoine-levitt
Copy link
Contributor

Ref #310 #13954 #50718

I just got bitten by this (again), and it was very confusing (again): I converted my interactive job to a slurm job and thought it didn't work properly when I didn't see any debug output in the log file.
@KristofferC you say in #50718 that that PR would flush too much, and I agree this is potentially true for arbitrary IO, but here I propose to just flush on println(x), which is presumably not used for "serious" IO. This would not impact println(io, x). It has the downside that println(x) is not the same as println(stdout, x) but I think that's fair game compared to the confusion caused by not buffering anything.

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