Hmmm... how would I get the flow name while inside...
# ask-community
t
Hmmm... how would I get the flow name while inside a flow in Prefect 2.0? Is that still something in a context somewhere?
1
z
get_run_context().flow_run.name
might do it
t
do I need to import something for
get_run_context
? I don't seem to have it available in a pdb session.
z
Yeah, sorry:
from prefect.context import get_run_context
t
thank you!