Repository navigation
fix(desktop-gpui): carry a rounded-up minute in the timing cards - #3420
Open
patrickballard wants to merge 1 commit into
Open
patrickballard wants to merge 1 commit into
patrickballard wants to merge 1 commit into
Conversation
The timing cards rounded the seconds after splitting off the minutes, so 59.96 s printed as 0:60.0 and 119.97 s as 1:60.0. Round to tenths first, with the same formatting, then split.
Contributor
|
@patrickballard is attempting to deploy a commit to the Cap Software Inc Team on Vercel. A member of the Team first needs to authorize it. |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of #3419.
format_timeineditor_panels.rsrounded the seconds to tenths after splitting off the minutes, so a time within 0.05 s of a minute boundary printed:60.0. It now rounds the whole time to tenths first (the same{:.1}formatting, so every other value prints exactly as before) and then splits it.0:59.90:59.90:60.01:00.01:60.02:00.059:60.01:00:00.00:09.20:09.2Tests
the_timing_cards_carry_a_rounded_up_minute; the existingthe_timing_cards_print_the_source_clockis unchanged and passes.cargo test --release --bin cap-gpui: 1472 passed. Clippy: nothing on the changed lines.rustfmtclean.

Confidence Score: 5/5
The PR appears safe to merge.Summary
format_timenow rounds the full time to tenths before splitting it into hours, minutes, and seconds.Reviews (1) · Last reviewed commit: "fix(desktop-gpui): carry a rounded-up mi..." · Reviewed by Greptile