-
Notifications
You must be signed in to change notification settings - Fork 17.7k
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
cmd/go: test mixes stderr and stdout #25241
Comments
This is horrible and next to unusable. Users should be able to opt-in to getting this output, not forced in. |
I'm sorry your benchmarks print so much to standard error. I'm sorry we didn't get to it in Go 1.11. |
#24929 may also affect this behavior. |
7badae8 appears to have made
go test
mix stderr and stdout from tests, which has made go 1.10 a regression for CockroachDB's benchmarks.This issue is related to #18010 :
Not only is the benchmark output not swallowed, but stderr and stdout are now mixed, so, if our binary produces logs (on stderr, as ours does), it's now impossible to see the benchmark results or use tools like
benchstat
.In particular, I believe
benchstat
fails to work because the mixing of stderr and stdout doesn't even use line buffering - so the benchmark measurements lines are mixed with log lines andbenchstat
can't recognize them any more.I generally concur with the folks on #18010 arguing that the swallowing/not swallowing of output is inconsistent (and there's no control over it as far as I can tell). Additionally, now the mixing of stdout and stderr is really a problem. The argument for not doing anything about
go test -bench
not swallowing output was that "we should at least preserve existing behavior as much as possible", but it would appear that existing behavior was changed in a quite significant way by this mixing. So I would kindly ask for the swallowing decision to be re-evaluated.What version of Go are you using (
go version
)?go version go1.10 darwin/amd64
Does this issue reproduce with the latest release?
Yes
What operating system and processor architecture are you using (
go env
)?OS X/ amd64
cc @benesch
The text was updated successfully, but these errors were encountered: