From 4016be7c9892b4c80943a809502da91c48b331ce Mon Sep 17 00:00:00 2001 From: Alexander Vasin Date: Sat, 25 Aug 2018 05:38:11 +0300 Subject: [PATCH] Fixed typo with asynccontextmanager code example (GH-8845) `yield conn`, instead of just `yield`. (cherry picked from commit 416cbce22d5d8879986125f07b3e293421bc975d) Co-authored-by: Alexander Vasin --- Doc/library/contextlib.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/library/contextlib.rst b/Doc/library/contextlib.rst index 793bd63f673f6a..7dc5b2989f9c0c 100644 --- a/Doc/library/contextlib.rst +++ b/Doc/library/contextlib.rst @@ -116,7 +116,7 @@ Functions and classes provided: async def get_connection(): conn = await acquire_db_connection() try: - yield + yield conn finally: await release_db_connection(conn)