You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When caching multiple tasks the second task cache seems to get confused with the first tasks cache and the second task isn't run. Running the flow without caching and a LocalResultHandler generates the correct output.
Expected Behavior
In the flow below I expected to get output from the write_data task with the data transformed.
The log shows that a cached state was found for the task even if it is the first time the flow has been run. First run = run with a fresh local server.
[2020-04-16 14:40:03,832] INFO - prefect.CloudTaskRunner | Task 'xform_data': Starting task run...
[2020-04-16 14:40:03,855] DEBUG - prefect.CloudTaskRunner | Task 'xform_data': 1 candidate cached states were found
[2020-04-16 14:40:03,855] DEBUG - prefect.LocalResultHandler | Starting to read result from /home/nate/projects/ed/ed-prefect/trial/cache-checkpoint/data/int/prefect-result-2020-04-16t14-40-03-648495-00-00...
[2020-04-16 14:40:03,856] DEBUG - prefect.LocalResultHandler | Finished reading result from /home/nate/projects/ed/ed-prefect/trial/cache-checkpoint/data/int/prefect-result-2020-04-16t14-40-03-648495-00-00...
[2020-04-16 14:40:03,857] DEBUG - prefect.CloudTaskRunner | Task 'xform_data': Handling state change from Pending to Cached
[2020-04-16 14:40:03,913] DEBUG - prefect.CloudTaskRunner | Task 'xform_data': can't set state to Running because it isn't Pending; ending run.
[2020-04-16 14:40:03,921] INFO - prefect.CloudTaskRunner | Task 'xform_data': finished task run for task with final state: 'Cached
Workaround:
Per Slack conversation with Josh, setting the cache_key on the xform_data task resolves the problem.
Description
When caching multiple tasks the second task cache seems to get confused with the first tasks cache and the second task isn't run. Running the flow without caching and a LocalResultHandler generates the correct output.
Expected Behavior
In the flow below I expected to get output from the write_data task with the data transformed.
but I get the untransformed data.
The log shows that a cached state was found for the task even if it is the first time the flow has been run. First run = run with a fresh local server.
Workaround:
Per Slack conversation with Josh, setting the cache_key on the xform_data task resolves the problem.
Reproduction
Environment
Ubuntu: 18.04
Prefect: 0.10.2
Backend: Server
The text was updated successfully, but these errors were encountered: