diff options
| author | Raymond Hettinger <python@rcn.com> | 2016-12-27 01:07:13 -0800 |
|---|---|---|
| committer | Raymond Hettinger <python@rcn.com> | 2016-12-27 01:07:13 -0800 |
| commit | f45e858c60cf38a988749b8ce863cb3f171782d0 (patch) | |
| tree | 38e2721806e7cd021cfa7c5f207d3b6835a94a46 /Lib | |
| parent | 426b140fc57f2c8f6b0af778736751165386a7ef (diff) | |
| parent | bb2839b680b565f99e463921f3c28fb3c7368096 (diff) | |
| download | cpython-git-f45e858c60cf38a988749b8ce863cb3f171782d0.tar.gz | |
merge
Diffstat (limited to 'Lib')
| -rw-r--r-- | Lib/random.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/random.py b/Lib/random.py index 49b0f149a5..ad1c9167b0 100644 --- a/Lib/random.py +++ b/Lib/random.py @@ -254,7 +254,7 @@ class Random(_random.Random): try: i = self._randbelow(len(seq)) except ValueError: - raise IndexError('Cannot choose from an empty sequence') + raise IndexError('Cannot choose from an empty sequence') from None return seq[i] def shuffle(self, x, random=None): |
