Hi team, I am new to prefect and I have a question...
# prefect-community
m
Hi team, I am new to prefect and I have a question. If I am running a flow daily and it failed for yesterday and now when I will be retrying it today, is there any date parameter which gives me yesterday's date instead of today's date as I will be fetching some values based on date from the api in my flow.
1
r
I use a json block to store the last successful run time as a checkpoint which then allows me to make decisions on the next run
gratitude thank you 1
m
what if I want to retry a task after two days or three days how can I do that as I need the past date only? For example If I want to retry a task of 14th Nov on 17th nov and I want the date as 14th in my code
where can I get that date
r
well the flow picks up the checkpoint and does what it needs to do
m
can you please share a dummy code?
r
on successful completion the last thing we do is store some checkpoint datetime/id....the next run uses that date to add a where > clause
I wouldn't rely on a last flow run date for a few reasons
m
Thank you so much!!
👍 1