summaryrefslogtreecommitdiffstats
path: root/Lib/contextlib.py
diff options
context:
space:
mode:
authorYury Selivanov <yury@magic.io>2018-06-08 00:31:26 (GMT)
committerGitHub <noreply@github.com>2018-06-08 00:31:26 (GMT)
commit52698c7ad9eae9feb35839fde17a7d1da8036a9b (patch)
tree1db0d329f430f5eda34575454d35b0b7e5570249 /Lib/contextlib.py
parent378c53cc3187dba57c7560ccc2557f516c8a7bc8 (diff)
downloadcpython-52698c7ad9eae9feb35839fde17a7d1da8036a9b.zip
cpython-52698c7ad9eae9feb35839fde17a7d1da8036a9b.tar.gz
cpython-52698c7ad9eae9feb35839fde17a7d1da8036a9b.tar.bz2
bpo-33786: Fix asynchronous generators to handle GeneratorExit in athrow() (GH-7467)
Diffstat (limited to 'Lib/contextlib.py')
-rw-r--r--Lib/contextlib.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/contextlib.py b/Lib/contextlib.py
index 1a58b50..c06ec73 100644
--- a/Lib/contextlib.py
+++ b/Lib/contextlib.py
@@ -187,7 +187,7 @@ class _AsyncGeneratorContextManager(_GeneratorContextManagerBase,
# in this implementation
try:
await self.gen.athrow(typ, value, traceback)
- raise RuntimeError("generator didn't stop after throw()")
+ raise RuntimeError("generator didn't stop after athrow()")
except StopAsyncIteration as exc:
return exc is not value
except RuntimeError as exc: