[docs] [issue18841] math.isfinite fails with Decimal sNAN
report at bugs.python.org
Mon Aug 26 17:38:40 CEST 2013
New submission from Steven D'Aprano:
math.isfinite currently raises ValueError when given a Decimal sNAN (signalling NAN).
I've run into a situation where I'm calling isfinite() on a numeric value which may be a Decimal sNAN, and it would be nice if it returned False.
On the other hand, see the discussion on issue 15544, which possibly leads to the conclusion that raising ValueError is the right thing to do.
Either way, behaviour should be documented.
assignee: docs at python
components: Documentation, Library (Lib)
nosy: docs at python, stevenjd
title: math.isfinite fails with Decimal sNAN
versions: Python 3.4
Python tracker <report at bugs.python.org>
More information about the docs