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

Console UX: tracing warnings tend to screw with repaints and offset superconsole #332

Open
thoughtpolice opened this issue Jul 7, 2023 · 0 comments

Comments

@thoughtpolice
Copy link
Contributor

This is a follow up to #316 and #321. Let's look at a fresh build of buck2-with-buck2 on my WSL machine, with no buck-out/, right after running reindeer buckify:

Recording.2023-07-07.161522.mp4

This is a really bad example of what #316 can cause: it basically ruins the UX on the first build entirely. In this case, it only ruins the first build because of the HTTP throttling in #316, and subsequent builds won't download and hammer https://crates.io, so it won't appear unless you like completely regenerate the Cargo.lock file I guess.

But, of course, #316 is just an example of what can cause this. Pretty much any warn!() call or things that use tracing in the codebase are going to cause this to happen. I think those warnings should probably not be silenced (or turned into buck events), but the UX definitely needs fixes to handle this better.

Frankly, I would much rather see the superconsole UX here split into two "draw boxes", split horizontally, the top one being the build output, and the bottom one being warnings, if they appear. The reason for this choice is very simple: because you will always see the build output appear first, and warnings will only happen mid flight in the middle of the build, if they happen at all. The build UX is up and running first, so it shouldn't be pushed down just because a possible transient warning happened. The UX should follow the temporal series of events, in some sense.

But really anything that could get rid of this would be nice, if you ask me.


There is a related bug here that I also don't like, which is that superconsole doesn't seem to detect or resize properly in WSL/Windows Terminal. Note that my console is +120 columns wide, yet even on startup, superconsole doesn't draw past 80 columns, and it doesn't resize if you change the dimensions mid-flight.

I don't know if this is a limitation on all platforms right now, or if some weird WSL/Terminal interaction that needs to be handled.


NOTE: @cjhopman asked in #321 for a recording of my "violent repainting" where warnings would make the UX repaint harshly, which actually I think is both a combination of this and also a bug in Windows Terminal, that makes it look worse; that issue has been fixed in the latest Windows Terminal Insider build, and it also fixes related applications for me, such as nushell, which flickered constantly, so I just moved over to the Insider build. It may have just been evil ghosts or spirits haunting me too.

Possible upstream issue that is now closed: microsoft/terminal#13710

@thoughtpolice thoughtpolice changed the title Console UX: tracing warnings tend to screw with repaints, offset superconsole, and should be redesigned Console UX: tracing warnings tend to screw with repaints and offset superconsole Jul 9, 2023
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

No branches or pull requests

1 participant