Author steven.daprano
Recipients David MacIver, bar.harel, benjamin.peterson, josh.r, mark.dickinson, steven.daprano
Date 2015-11-06.01:16:06
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
In-reply-to <>
> Has anyone confirmed that this bug actually exists? 

Confirmed. The initial report is not quite correct: you need three 
values to trigger the overflow, not two:

py> x = 8.988465674311579e+307
py> statistics.mean([x]*2) == x
py> statistics.mean([x]*3) == x
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "./", line 289, in mean
    return _sum(data)/n
  File "./", line 184, in _sum
    return T(total)
  File "/usr/local/lib/python3.3/", line 296, in __float__
    return self.numerator / self.denominator
OverflowError: integer division result too large for a float
Date User Action Args
2015-11-06 01:16:07steven.dapranosetrecipients: + steven.daprano, mark.dickinson, benjamin.peterson, josh.r, David MacIver, bar.harel
2015-11-06 01:16:07steven.dapranolinkissue25177 messages
2015-11-06 01:16:06steven.dapranocreate