https://prefect.io logo
Title
k

Kelvin DeCosta

12/21/2022, 9:31 AM
Quick question: If a
task
is configured with
cache_result_in_memory=False
, can its result only be consumed via
state.result()
/
future.result()
? Calling such tasks directly, i.e..
result = my_task()
, seems to raise the
MissingResult
error.
k

Khuyen Tran

12/21/2022, 5:24 PM
I don’t think the error has to do with
cache_result_in_memory=False
. Can you post an example of your code?
k

Kelvin DeCosta

12/23/2022, 10:43 AM
I think the error happened because I didn't explicitly set
persist_result=True
. In my case,
taskA
and
flowB
both have
cache_result_in_memory=False
and
flowB
uses the result of
taskA
, and returns it too.