We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
format duration
Formatting fractional durations appears to do some weird intermediate rounding.
1.07min | format duration ms
64000 ms
64200 ms
1.07 min | format duration sec
64 sec
64.2 sec
Correctly format durations, accounting for the precision of the output unit.
No response
The text was updated successfully, but these errors were encountered:
Interesting, related note: 1.07min / 1sec returns 64, not 64.2
1.07min / 1sec
64
64.2
Sorry, something went wrong.
and 1.07min / 1ms returns 64000, and not the correct 64200. Perhaps it is not format duration, but nushell's internal duration math itself
1.07min / 1ms
Sounds like floats aren't handled right?
Successfully merging a pull request may close this issue.
Describe the bug
Formatting fractional durations appears to do some weird intermediate rounding.
How to reproduce
1.07min | format duration ms
returns64000 ms
, despite the correct answer being64200 ms
.1.07 min | format duration sec
return64 sec
, and not the correct64.2 sec
.Expected behavior
Correctly format durations, accounting for the precision of the output unit.
Screenshots
No response
Configuration
Additional context
No response
The text was updated successfully, but these errors were encountered: