Hello, i'm running into an issue were i have tasks...
# prefect-community
f
Hello, i'm running into an issue were i have tasks that are skipped when none of their upstream tasks fail. When looking at the execution schema in the dashboard, i see that the task in charge of loading secrets like api key has been skipped because the first task that needed it has been skipped (this one is an intended behaviour). I suppose that my last task got skipped because the secret it needs as an argument has been previously skipped. Am i right ? if so how can i "force" the task to get the secret ? Here is the schema :
k
I think this is because the
case
raises a SKIP when the condition is not met so the skip propagates. You can set a trigger to force execution
f
ok i thought it was ok because i used a merge after the case but i'll try with the trigger thanks !
k
Set the trigger to
always_run
or something that will ignore the SKIP
f
Hey i tried to force the execution of the extract_data but as the ODS_URL and ODS_API_KEY were skipped, their value was None. So i force the execution of those tasks too but this implied that the first execution of extract_data that was supposed to be skipped was not anymore since its upstream are ODS_URL and ODS_API_KEY. I think i should add the Case also as an upstream of the first extract_data but i don't know how to
Dirty workaround, i created a duplicate of ODS_URL and ODS_API_KEY so each of the extract_data depnds on a different URL/KEY pair.
k
For the case, anything under is a downstream:
Copy code
with case(...):
    task1()
    task2()