Philip MacMenamin
10/25/2021, 2:50 PMraise signals.FAIL('Didn't work')
I do not want the flow to proceed. However, other downstream tasks occur despite the exception being raised. Is this expected behavior?Kevin Kho
FAIL
should propagate though and those downstream ones should FAIL
as well right? You can also raise SKIP
Philip MacMenamin
10/25/2021, 2:55 PMKevin Kho
FAIL
task? Like is the failed task an upstream dependency? If it’s an upstream dependency, the FAIL will propagate and they won’t runPhilip MacMenamin
10/25/2021, 3:01 PMKevin Kho
b
and c
won’t trigger because a
failed:
import prefect
from prefect import task, Flow
from prefect.engine.signals import FAIL
@task()
def abc():
raise FAIL("message")
@task()
def bcd():
return 1
@task()
def cde():
return 1
with Flow("test") as flow:
a = abc()
b = bcd(upstream_tasks=[a])
c = cde(upstream_tasks=[b])
flow.run()
sanity_check
?Philip MacMenamin
10/25/2021, 3:05 PMimport prefect
from prefect import task, Flow
from prefect.engine.signals import FAIL
@task()
def abc():
raise FAIL("message")
@task()
def bcd():
return 1
@task()
def cde():
return 1
with Flow("test") as flow:
a = abc()
b = bcd(a)
c = cde(b)
flow.run()
So, will the above still attempt to run bcd and cde?Kevin Kho
b
and c
will be TriggerFailed
, indicating something upstream failedPhilip MacMenamin
10/25/2021, 3:09 PMKevin Kho
Philip MacMenamin
10/25/2021, 3:12 PMKevin Kho
Philip MacMenamin
10/25/2021, 3:28 PMKevin Kho
Philip MacMenamin
10/25/2021, 3:30 PMKevin Kho
Philip MacMenamin
10/25/2021, 3:52 PMKevin Kho
Philip MacMenamin
10/26/2021, 6:37 PMKevin Kho
Philip MacMenamin
10/26/2021, 6:56 PM{
"config_overrides": {
"server": {
"ui": {
"apollo_url": true
}
}
},
"env_vars": [],
"system_information": {
"platform": "Linux-5.8.0-1035-aws-x86_64-with-glibc2.29",
"prefect_backend": "server",
"prefect_version": "0.15.6",
"python_version": "3.8.10"
}
}
Kevin Kho
flow.run()
or is it only when you run on Cloud?Philip MacMenamin
10/26/2021, 7:21 PMKevin Kho
Philip MacMenamin
10/26/2021, 7:39 PMglb_fps = get_glb_fps(job, upstream_tasks=[chimera_ok, job, files, sanity_ok])
Kevin Kho