Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upreport status to stderr instead of stdout #2693
Conversation
rust-highfive
assigned
alexcrichton
May 14, 2016
This comment has been minimized.
This comment has been minimized.
rust-highfive
commented
May 14, 2016
|
(rust_highfive has picked a reviewer for you, use r? to override) |
This comment has been minimized.
This comment has been minimized.
... on the stable compiler. There should be even for failures for nightly |
matklad
added a commit
to matklad/intellij-rust
that referenced
this pull request
May 15, 2016
matklad
added a commit
to matklad/intellij-rust
that referenced
this pull request
May 15, 2016
This comment has been minimized.
This comment has been minimized.
|
91 failures left :) |
This comment has been minimized.
This comment has been minimized.
|
Hm, I found an interesting phenomena: some tests before this changed asserted |
matklad
force-pushed the
matklad:status-2-stderr
branch
from
b0f72f9
to
5574ca2
May 15, 2016
This comment has been minimized.
This comment has been minimized.
|
@matklad yeah that's probably a split between "intentionally ignored", "too lazy to write out the output", or "oops forgot to assert that output". It should be fine to either add the assertions or switch to Also cc @rust-lang/tools, a somewhat large-ish semantic change to Cargo! |
This comment has been minimized.
This comment has been minimized.
Nice, I indeed feel a little uneasy because of the scope of the change (Although I personally think that stderr is the right stream for the status messages). I'll then wait for an explicit approval before I continue fixing the tests :) |
This comment has been minimized.
This comment has been minimized.
|
+1 for more disciplined use of stderr/out |
This comment has been minimized.
This comment has been minimized.
|
I agree that stderr is the right place for status messages. How will this affect |
This comment has been minimized.
This comment has been minimized.
|
@brson in theory it won't affect |
This comment has been minimized.
This comment has been minimized.
|
Discussed during tools triage we were all on board, so let's do this! Wanna fix up the few remaining tests @matklad and I'll merge? |
This comment has been minimized.
This comment has been minimized.
Yeah, I'll do it, but I can't give a precise ETA (this weak perheps?). The remaining tests most likely all require some manual intervention. |
This comment has been minimized.
This comment has been minimized.
|
Ah yeah no worries, and if you run out of time I can help out as well |
matklad
added some commits
May 14, 2016
matklad
force-pushed the
matklad:status-2-stderr
branch
from
5574ca2
to
97f91a1
May 18, 2016
matklad
added some commits
May 18, 2016
alexcrichton
added
the
relnotes
label
May 19, 2016
matklad
added some commits
May 20, 2016
matklad
reviewed
May 20, 2016
| @@ -722,7 +722,7 @@ test!(dev_deps_no_rebuild_lib { | |||
| "#) | |||
| .file("src/lib.rs", r#" | |||
| #[cfg(test)] extern crate bar; | |||
| #[cfg(not(test))] fn foo() { env!("FOO"); } | |||
| #[cfg(not(test))] pub fn foo() { env!("FOO"); } | |||
This comment has been minimized.
This comment has been minimized.
matklad
May 20, 2016
•
Author
Member
@alexcrichton this tests looks a bit strange. Looks like it should set and read an environmental variable, but it actually is never asserted (and "unused function foo" is printed during the compilation).
Perhaps the test doesn't test what it is supposed to?
This comment has been minimized.
This comment has been minimized.
alexcrichton
May 20, 2016
Member
I believe the env! macro fails compilation if the env var isn't defined
This comment has been minimized.
This comment has been minimized.
|
@alexcrichton I think I have fixed all the tests except the cross compile ones (one does not simply link stuff on nixos :) ). Can you please finish the work here? I think the commits should be squashed before merge, but it may be simpler to review them one by one. |
matklad commentedMay 14, 2016
•
edited
All status messages are printed to stderr instead of stdout now.
This changes exactly three letters of code and breaks 211 tests😨
I will hopefully fix all the tests here, but I decided to submit PR early in case somebody comes up with a less laborious way to do this.
Fixes #1473, #2661