Open tekumara opened 1 year ago
The prefect.runtime API has not been exported, and so errors in vscode/pyright with:
error: "task_run" is not a known member of module "prefect.runtime"
from prefect import flow, task import prefect.runtime @flow(log_prints=True) def my_flow(x): print("my name is", prefect.runtime.flow_run.name) print("i belong to deployment", prefect.runtime.deployment.name) my_task(2) @task def my_task(y): print("my name is", prefect.runtime.task_run.name) print("flow run got parameters", prefect.runtime.flow_run.parameters) my_flow(1)
error: "flow_run" is not a known member of module "prefect.runtime"
prefect 2.9.0
This also means there's no autocomplete for functions in the prefect.runtime module.
Is this issue still up?
yes this is still an issue as of 2.14.9
First check
Bug summary
The prefect.runtime API has not been exported, and so errors in vscode/pyright with:
Reproduction
Error
Versions
Additional context
This also means there's no autocomplete for functions in the prefect.runtime module.