How do I cancel a flow run in prefect 2 cloud? I c...
# prefect-ui
How do I cancel a flow run in prefect 2 cloud? I can see how to delete it, but I want to keep the logs but not have it run any more.
👍 2
if you have access to the infra, you could cancel it there e.g. by killing the process on that machine or the K8s job
It's running on fargate, so it's not easy to kill the process on the machine. Will deleting the flow run also cancel it? I'd rather keep the logs in prefect cloud if possible, but definitely want to cancel the run!
we are aware of the problem, but this is hard to do in a hybrid model, we'll likely add better support for handling that in the future but this is not on the immediate roadmap, to be transparent. if you delete a flow run, deleting a flow run will actually also trigger an interruption to the flow run process, so it will cancel it but yes, your logs would be gone
👍 1
yup it should
Ok, thanks. Was this feature not in prefect 1? I thought I remembered cancelling runs in the UI before.
let's focus on the future, forget 1.0 :)
we are aware and we'll tackle it at some point for sure because it's important
Cancellation can be tricky because interrupting running code is either not possible or very complicated in Python. Many libraries choose not to allow cancellation of tasks once they’ve started running. Other times, they can perform “soft cancellation” in which the rest of the code moves on but the task continues running in the background. There’s a lot of variance in user expectations for cancellation and we’re still figuring out the best way to meet the majority of our user’s expectations while providing a robust and consistent cancellation method.
👍 6
🙏 3