Skip to content

Improve error output when a command fails in bootstrap #145089

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

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

Conversation

Kobzol
Copy link
Member

@Kobzol Kobzol commented Aug 8, 2025

I fixed this because it was being an issue for debugging CI failures.

We try to print as much information as possible, just with a slightly less verbose command description in non-verbose mode. The code is now more unified and hopefully simpler to understand.

I also fixed the format_short_cmd logic, it was a bit weird after some recent refactors.

Fixes: #145002

r? @jieyouxu

CC @Shourya742

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) labels Aug 8, 2025
@rust-log-analyzer

This comment has been minimized.

@jieyouxu
Copy link
Member

jieyouxu commented Aug 8, 2025

you got clippy'd 😁

@Kobzol Kobzol force-pushed the bootstrap-cmd-error branch from 96fc1e4 to d9b725a Compare August 8, 2025 13:50
@Kobzol
Copy link
Member Author

Kobzol commented Aug 8, 2025

Ok, should be good now.

Copy link
Contributor

@Shourya742 Shourya742 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK. Some minor non-blocking questions..

Copy link
Member

@jieyouxu jieyouxu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks

@jieyouxu
Copy link
Member

jieyouxu commented Aug 9, 2025

@bors r+ rollup

@bors
Copy link
Collaborator

bors commented Aug 9, 2025

📌 Commit d9b725a has been approved by jieyouxu

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Aug 9, 2025
Zalathar added a commit to Zalathar/rust that referenced this pull request Aug 9, 2025
…ouxu

Improve error output when a command fails in bootstrap

I fixed this because it was being an issue for debugging CI failures.

We try to print as much information as possible, just with a slightly less verbose command description in non-verbose mode. The code is now more unified and hopefully simpler to understand.

I also fixed the `format_short_cmd` logic, it was a bit weird after some recent refactors.

Fixes: rust-lang#145002

r? `@jieyouxu`

CC `@Shourya742`
Zalathar added a commit to Zalathar/rust that referenced this pull request Aug 9, 2025
…ouxu

Improve error output when a command fails in bootstrap

I fixed this because it was being an issue for debugging CI failures.

We try to print as much information as possible, just with a slightly less verbose command description in non-verbose mode. The code is now more unified and hopefully simpler to understand.

I also fixed the `format_short_cmd` logic, it was a bit weird after some recent refactors.

Fixes: rust-lang#145002

r? ``@jieyouxu``

CC ``@Shourya742``
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

If a command fails but does not have stderr/stdout, bootstrap shows no context for what failed
6 participants