Author boris
Recipients boris
Date 2021-02-01.03:01:44
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
The documentation says:

> class random.Random([seed])ΒΆ

But in reality the parameter is called "x" not "seed" (CPython 3.9):

>>> import random
>>> random.Random(seed=0)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: __init__() got an unexpected keyword argument 'seed'
>>> random.Random(x=0)
<random.Random object at 0x20ddc10>

Same goes for random.SystemRandom

It would be better to rename "x" to "seed" but that's not backwards compatible.
Date User Action Args
2021-02-01 03:01:44borissetrecipients: + boris
2021-02-01 03:01:44borissetmessageid: <>
2021-02-01 03:01:44borislinkissue43089 messages
2021-02-01 03:01:44boriscreate