-
-
Notifications
You must be signed in to change notification settings - Fork 80
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
What did you do?
Run a call like humanize.intcomma(12345.111, ndigits=0).
What did you expect to happen?
I expected the return value to be "12,345".
If ndigits=0, I would expect there to be no digits after the decimal place (i.e., 0 decimal digits).
What actually happened?
The return value is "12,345.111".
Alternative Solution
If it is decided that changing this behavior is completely inappropriate, then it is critical that the documentation be updated to explain:
- ndigits must be >0
- If ndigits=0 or ndigits=None, then all digits are kept.
What versions are you using?
- OS: Ubuntu
- Python: 3.9
- Humanize: 4.1.0
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working