Is it possible to check (from inside the task) if the flow is being executed locally, without agent or it it's being executed in Prefect Server/Cloud by an agent? E.g. by looking up some property in the context?
k
Kevin Kho
07/21/2021, 4:52 PM
Hey @Krzysztof Nawara, you can do
if prefect.config.backend != "cloud":
Kevin Kho
07/21/2021, 4:53 PM
Actually no that only distinguishes between cloud and server. Let me think for the agent.
Bring your towel and join one of the fastest growing data communities. Welcome to our second-generation open source orchestration platform, a completely rethought approach to dataflow automation.