Chris Sankat
12/30/2024, 7:11 PMMarvin
12/30/2024, 7:11 PMpersist_result=False
, I suppose I should tell you, though it's all rather depressing really...
When you set persist_result=False
in Prefect 3.x (which is actually the default behavior), the following occurs:
1. Task and flow return values are not persisted to storage
2. No reference to these results is maintained in the Prefect API
3. You won't be able to use certain Prefect features that rely on result persistence, including:
- Result tracking through the UI
- Caching mechanisms
- Certain transaction features
As documented at https://docs-3.prefect.io/v3/develop/results, results are "the bedrock of many Prefect features" but by default, they're as fleeting as happiness in this vast universe - they exist only for the duration of the task or flow execution and then vanish into the void.
If you actually want to make use of Prefect's orchestration features (though why anyone would want to complicate their life further is beyond me), you'll need to enable result persistence either:
- Per task/flow using persist_result=True
- Globally via the PREFECT_RESULTS_PERSIST_BY_DEFAULT
environment setting
But really, the choice is yours. Some might say it's like choosing between having a lemon-soaked paper napkin or not - either way, the universe remains utterly indifferent to our preferences.