Skip to content

Changed behaviour in the way persist_result works #16521

Answered by parkedwards
SantanM asked this question in Q&A
Discussion options

You must be logged in to vote

hey @SantanM -- this is expected behavior. In Prefect 2, the persist_results kwarg used to store the run result into configured storage, and create a reference to that storage location via an Artifact entry

In Prefect 3, we can still use the persist_results kwarg to do the same thing, but a resulting Artifact entry is no longer created (as it used to just hold a reference to the location, which is already information stored on the state object). Depending on your goals, you can either:

(1) continue to use the persist_results kwarg and configure the storage based on your needs, or
(2) use one of the explicit create_<type>_artifact() methods to store any result data as an Artifact

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by parkedwards
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants