[issue44691] bug in interactions between argparse and random
Steven D'Aprano
report at bugs.python.org
Tue Jul 20 19:26:27 EDT 2021
Steven D'Aprano <steve+python at pearwood.info> added the comment:
args.seed if args.seed else SEED is not doing what you think it is doing.
SEED is an *int* but args.seed is a *str*:
>>> random.seed(6385845682483836956)
>>> random.randint(10, 500)
92
>>> random.seed('6385845682483836956')
>>> random.randint(10, 500)
347
----------
nosy: +steven.daprano
resolution: -> not a bug
stage: -> resolved
status: open -> closed
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue44691>
_______________________________________
More information about the Python-bugs-list
mailing list