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

"command did not execute successfully" message is too verbose when tool fails to compile #122706

Closed
Noratrieb opened this issue Mar 18, 2024 · 0 comments · Fixed by #122831
Closed
Labels
T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)

Comments

@Noratrieb
Copy link
Member

When making a tool (like tidy) not compile, I get the following error:

<snip full rustc error>
Some errors have detailed explanations: E0277, E0308.
For more information about an error, try `rustc --explain E0277`.
error: could not compile `tidy` (lib) due to 82 previous errors


command did not execute successfully: cd "/home/nils/projects/rust2" && env -u MAKEFLAGS -u MFLAGS AR_x86_64_unknown_linux_gnu="ar" CARGO_INCREMENTAL="1" CARGO_PROFILE_RELEASE_DEBUG="1" CARGO_PROFILE_RELEASE_DEBUG_ASSERTIONS="true" CARGO_PROFILE_RELEASE_OVERFLOW_CHECKS="true" CARGO_PROFILE_RELEASE_STRIP="false" CARGO_TARGET_DIR="/home/nils/projects/rust2/build/x86_64-unknown-linux-gnu/stage0-bootstrap-tools" CC_x86_64_unknown_linux_gnu="gcc" CFG_COMPILER_BUILD_TRIPLE="x86_64-unknown-linux-gnu" CFG_COMPILER_HOST_TRIPLE="x86_64-unknown-linux-gnu" CFG_RELEASE="1.79.0-dev" CFG_RELEASE_CHANNEL="dev" CFG_RELEASE_NUM="1.79.0" CFG_VERSION="1.79.0-dev (\u{1b}[1m\u{1b}[35m💕 i love you 😳🥺\u{1b}[0m)" CFLAGS_x86_64_unknown_linux_gnu="-ffunction-sections -fdata-sections -fPIC -m64" CXXFLAGS_x86_64_unknown_linux_gnu="-ffunction-sections -fdata-sections -fPIC -m64" CXX_x86_64_unknown_linux_gnu="g++" DOC_RUST_LANG_ORG_CHANNEL="https://doc.rust-lang.org/nightly" LIBC_CHECK_CFG="1" LZMA_API_STATIC="1" RANLIB_x86_64_unknown_linux_gnu="ar s" REAL_LIBRARY_PATH_VAR="LD_LIBRARY_PATH" RUSTBUILD_NATIVE_DIR="/home/nils/projects/rust2/build/x86_64-unknown-linux-gnu/native" RUSTC="/home/nils/projects/rust2/build/bootstrap/debug/rustc" RUSTC_ALLOW_FEATURES="binary-dep-depinfo,proc_macro_span,proc_macro_span_shrink,proc_macro_diagnostic" RUSTC_BACKTRACE_ON_ICE="1" RUSTC_BOOTSTRAP="1" RUSTC_BREAK_ON_ICE="1" RUSTC_ERROR_METADATA_DST="/home/nils/projects/rust2/build/tmp/extended-error-metadata" RUSTC_HOST_FLAGS="--cfg=bootstrap -Zunstable-options --check-cfg=cfg(bootstrap) -Clink-arg=-fuse-ld=lld" RUSTC_INSTALL_BINDIR="bin" RUSTC_LIBDIR="/home/nils/projects/rust2/build/x86_64-unknown-linux-gnu/stage0/lib" RUSTC_LINT_FLAGS="-Wrust_2018_idioms -Wunused_lifetimes" RUSTC_REAL="/home/nils/projects/rust2/build/x86_64-unknown-linux-gnu/stage0/bin/rustc" RUSTC_SNAPSHOT="/home/nils/projects/rust2/build/x86_64-unknown-linux-gnu/stage0/bin/rustc" RUSTC_SNAPSHOT_LIBDIR="/home/nils/projects/rust2/build/x86_64-unknown-linux-gnu/stage0/lib" RUSTC_STAGE="0" RUSTC_SYSROOT="/home/nils/projects/rust2/build/x86_64-unknown-linux-gnu/stage0" RUSTC_TLS_MODEL_INITIAL_EXEC="1" RUSTC_VERBOSE="0" RUSTC_WRAPPER="/home/nils/projects/rust2/build/bootstrap/debug/rustc" RUSTDOC="/home/nils/projects/rust2/build/bootstrap/debug/rustdoc" RUSTDOCFLAGS="--cfg=bootstrap -Csymbol-mangling-version=v0 -Zunstable-options --check-cfg=cfg(bootstrap) -Wrustdoc::invalid_codeblock_attributes --crate-version 1.79.0-dev\t(\u{1b}[1m\u{1b}[35m💕\ti\tlove\tyou\t😳🥺\u{1b}[0m) -Clink-arg=-fuse-ld=lld" RUSTDOC_REAL="/path/to/nowhere/rustdoc/not/required" RUSTFLAGS="--cfg=bootstrap -Csymbol-mangling-version=v0 -Zunstable-options --check-cfg=cfg(bootstrap) -Zmacro-backtrace -Csplit-debuginfo=off -Cforce-frame-pointers=true -Cllvm-args=-import-instr-limit=10 -Clink-args=-Wl,-z,origin -Clink-args=-Wl,-rpath,$ORIGIN/../lib -Clink-arg=-fuse-ld=lld -Zunstable-options" RUST_TEST_THREADS="32" SYSROOT="/home/nils/projects/rust2/build/x86_64-unknown-linux-gnu/stage0-sysroot" __CARGO_DEFAULT_LIB_METADATA="bootstrap" "/home/nils/projects/rust2/build/x86_64-unknown-linux-gnu/stage0/bin/cargo" "build" "--target" "x86_64-unknown-linux-gnu" "--release" "-Zcheck-cfg" "-Zbinary-dep-depinfo" "-j" "32" "--manifest-path" "/home/nils/projects/rust2/src/tools/tidy/Cargo.toml"
expected success, got: exit status: 101

stdout ----

stderr ----



Build completed unsuccessfully in 0:00:00
aww, you'll get it next time~

This is way too verbose, I do not care about the environment variables and all of these useless empty lines at the end. It obscures the rustc error, especially in a terminal without much scollback like the default VSCode one at the bottom. This information should only be shown when using -v.

@Noratrieb Noratrieb added T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) C-bug Category: This is a bug. labels Mar 18, 2024
@rustbot rustbot added the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label Mar 18, 2024
@Noratrieb Noratrieb removed the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label Mar 18, 2024
@onur-ozkan onur-ozkan removed the C-bug Category: This is a bug. label Mar 18, 2024
jhpratt added a commit to jhpratt/rust that referenced this issue Mar 21, 2024
… r=clubby789

make failure logs less verbose

Resolves rust-lang#122706

Logs without verbose flag:

![image](https://github.com/rust-lang/rust/assets/39852038/f2fc2d35-0954-44b0-bedc-045afedaabe8)

Logs with verbose flag:

![image](https://github.com/rust-lang/rust/assets/39852038/b9308655-ad31-4527-a1be-5a62a78ac469)

I decided to exclude command from the log since it's already included in verbose mode.

cc `@Nilstrieb`
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this issue Mar 21, 2024
… r=clubby789

make failure logs less verbose

Resolves rust-lang#122706

Logs without verbose flag:

![image](https://github.com/rust-lang/rust/assets/39852038/f2fc2d35-0954-44b0-bedc-045afedaabe8)

Logs with verbose flag:

![image](https://github.com/rust-lang/rust/assets/39852038/b9308655-ad31-4527-a1be-5a62a78ac469)

I decided to exclude command from the log since it's already included in verbose mode.

cc ``@Nilstrieb``
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this issue Mar 22, 2024
… r=clubby789

make failure logs less verbose

Resolves rust-lang#122706

Logs without verbose flag:

![image](https://github.com/rust-lang/rust/assets/39852038/f2fc2d35-0954-44b0-bedc-045afedaabe8)

Logs with verbose flag:

![image](https://github.com/rust-lang/rust/assets/39852038/b9308655-ad31-4527-a1be-5a62a78ac469)

I decided to exclude command from the log since it's already included in verbose mode.

cc ```@Nilstrieb```
rust-timer added a commit to rust-lang-ci/rust that referenced this issue Mar 22, 2024
Rollup merge of rust-lang#122831 - onur-ozkan:less-verbose-fail-logs, r=clubby789

make failure logs less verbose

Resolves rust-lang#122706

Logs without verbose flag:

![image](https://github.com/rust-lang/rust/assets/39852038/f2fc2d35-0954-44b0-bedc-045afedaabe8)

Logs with verbose flag:

![image](https://github.com/rust-lang/rust/assets/39852038/b9308655-ad31-4527-a1be-5a62a78ac469)

I decided to exclude command from the log since it's already included in verbose mode.

cc ```@Nilstrieb```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants