Pass 0.5 to seconds argument of humanize_timedelta.
What were you expecting to happen?
I suppose it would make most sense to get string "less than a second", though I'm not sure if that would be good for all contexts (for example - "This command is on cooldown. Try again in less than a second." might not be good).
What actually happened?
I got empty string.
How can we reproduce this issue?
Technically typing for humanize_timedelta says it only accepts ints but you can pass timedelta to that function instead and timedelta accepts deltas smaller than a second , so I just decided to base the issue on seconds argument.
The text was updated successfully, but these errors were encountered:
I don't think I'd consider this a bug. We should still clear up the usage to note that it drops fractional seconds, and then allow cog creators to decide independently per their use case if it makes more sense to swap that for "about one second", "less than one second", or something else entirely.
# Using the empty response advantageouslytimedelta_str=humanize_timedelta(seconds=some_positive_float) or"less than 1 second"