[New-bugs-announce] [issue39096] Description of "Format Specification Mini-Language" not accurate for Decimal

Michael Amrhein report at bugs.python.org
Thu Dec 19 05:11:20 EST 2019


New submission from Michael Amrhein <michael at adrhinum.de>:

The description of the "Format Specification Mini-Language" states for float and Decimal regarding presentation type 'f':
"The default precision is 6."
Regarding presentation type None it reads:
"Similar to 'g', except that fixed-point notation, when used, has at least one digit past the decimal point."
While both statements are accurate for float, they don't hold for Decimal.
In order to preserve the information about the decimal exponent, in both cases Decimal formatting displays as many fractional digits as dictated by it's exponent.

----------
assignee: docs at python
components: Documentation
messages: 358667
nosy: docs at python, mamrhein
priority: normal
severity: normal
status: open
title: Description of "Format Specification Mini-Language" not accurate for Decimal
type: behavior
versions: Python 3.6, Python 3.7, Python 3.8, Python 3.9

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue39096>
_______________________________________


More information about the New-bugs-announce mailing list