Format zero Durations as "0 seconds" instead of "0 microseconds" #744
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.
Summary of changes
While building a visual interface including a duration for a certain procedure, I noticed that calling the following:
...returns the string "0 microseconds". While technically 100% correct, from a "humanized" point of view, this feels a bit odd, as nobody would ever describe a zero-second duration as "zero microseconds".
This pull request is actually a change request, but as the core code change was minimal, opening a PR seemed like a more logical choice than opening an issue.
I'd like to receive feedback on (a) whether this is seen as a valuable functional change, and if so, (b) if you would like me to do the remaining work (fixing tests where needed, adding a CHANGELOG line) or that it is preferred to leave this to a core contributor.
Thanks for a great library!
Checklist