[New-bugs-announce] [issue33228] Use Random.choices in tempfile

Wolfgang Maier report at bugs.python.org
Thu Apr 5 04:50:52 EDT 2018


New submission from Wolfgang Maier <wolfgang.maier at biologie.uni-freiburg.de>:

A rather trivial change: tempfile._RandomNameSequence could make use of
random.Random.choices introduced in 3.6.
IMO, the suggested change would give clearer and also faster code.
It also updates the docstring of the class, which currently talks about
a six-character string, when an eight-character string gets returned.

----------
messages: 314969
nosy: wolma
priority: normal
severity: normal
status: open
title: Use Random.choices in tempfile
type: performance
versions: Python 3.8

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


More information about the New-bugs-announce mailing list