[issue40286] Add getrandbytes() method to random.Random

Vedran Čačić report at bugs.python.org
Wed Apr 15 04:57:43 EDT 2020


Vedran Čačić <vedgar at gmail.com> added the comment:

I think that the "module owner";-P must decide whether the `random` module should follow the C-namespacing or not. Of course, I'm in the "not" camp, so I believe those two "rand..." functions (randrange is completely redundant with random.choice(range)) should be supplemented with random.int and random.float. And then random.bytes will be completely natural. And people might be gently nudged into the right direction when using Python module namespaces.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue40286>
_______________________________________


More information about the Python-bugs-list mailing list