cdecimal.Decimal v. decimal.Decimal

Skip Montanaro skip.montanaro at gmail.com
Tue Jun 20 21:45:22 EDT 2017


Shouldn't these beasts compare equal?

It seems like it, although I don't think they were ever intended to be
used side-by-side. cdecimal isn't part of the standard library and is
supposed to be a drop-in replacement. As of CPython 3.3, the decimal
module *is* cdecimal.


Got it, thanks. I have a feeling that "conda install pyodbc" snuck cdecimal
in without me noticing. When I saw that the value disputed as
"Decimal('2226.84')" I imported the decimal module. It took awhile to
figure out I wasn't dealing with identical modules.

Skip



More information about the Python-list mailing list