diff --git a/pep-0550.rst b/pep-0550.rst index ec13025b9..61f9ec074 100644 --- a/pep-0550.rst +++ b/pep-0550.rst @@ -330,7 +330,7 @@ compatibility. The main reason for why tasks inherit the context, and threads do not, is the common usage intent. Tasks are often used for relatively short-running operations which are logically tied to the code that -spawned the tasks (like running a coroutine with a timeout in +spawned the task (like running a coroutine with a timeout in asyncio). OS threads, on the other hand, are normally used for long-running, logically separate code. @@ -378,7 +378,7 @@ Context variable propagation between tasks:: async def sub(): # Sleeping will make sub() run after - # `var` is modified in main(). + # "var" is modified in main(). await asyncio.sleep(1) # The value of "var" is inherited from main(), but any @@ -449,7 +449,7 @@ The context variable object has the following methods and attributes: * ``get(*, topmost=False, default=None)``, if *topmost* is ``False`` (the default), traverses the execution context top-to-bottom, until - the variable value is found, if *topmost* is ``True``, returns + the variable value is found. If *topmost* is ``True``, returns the value of the variable in the topmost logical context. If the variable value was not found, returns the value of *default*.