Skip to content

Commit f545433

Browse files
authored
Revert "Recognize numbers with comma separators" (astanin#111)
1 parent db98023 commit f545433

File tree

1 file changed

+1
-9
lines changed

1 file changed

+1
-9
lines changed

tabulate.py

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -610,16 +610,8 @@ def _isnumber(string):
610610
False
611611
>>> _isnumber("inf")
612612
True
613-
>>> _isnumber("1,234.56")
614-
True
615-
>>> _isnumber("1,234,578.0")
616-
True
617613
"""
618-
if isinstance(string, (_text_type)) and "," in string and (
619-
_isconvertible(float, string.replace(",",""))
620-
):
621-
return True
622-
elif not _isconvertible(float, string):
614+
if not _isconvertible(float, string):
623615
return False
624616
elif isinstance(string, (_text_type, _binary_type)) and (
625617
math.isinf(float(string)) or math.isnan(float(string))

0 commit comments

Comments
 (0)