I was trying to type this example in IPython:
from prefect.client import OrionClient
async with OrionClient() as client:
deployment = await client.read_deployment_by_name("Addition Machine/my-first-deployment")
flow_run = await client.create_flow_run_from_deployment(deployment)
However, typing ENTER after the first line with an await statement stops the multi-line edit too soon and executes the code:
In [16]: async with OrionClient() as client:
...: deployment = await client.read_deployment_by_name("Addition Machine/my-first-deployment")
In [17]:
I think this is a general bug with await, the same bug happens with any other example, e.g.
In [17]: with open():
...: spam = await Thing()
@minrk - related to #13348 ?
I was trying to type this example in IPython:
However, typing ENTER after the first line with an
awaitstatement stops the multi-line edit too soon and executes the code:I think this is a general bug with
await, the same bug happens with any other example, e.g.@minrk - related to #13348 ?