This message was deleted.
# ask-anything
s
This message was deleted.
r
I could raise an exception, but I'd rather do something like
sys.exit()
e
yeah, this is an undocumented feature. you can raise
DAGEarlyStop
and to signal that you wanna stop execution, then ploomber will exit with status 0 https://github.com/ploomber/ploomber/blob/2fe474987ae6fca088e02399dbff99672a17fc95/src/ploomber/exceptions.py#L83
but it wont work on papermill, since it masks the exception and throws its own, it has to be a Python function task
r
Ok great - I think this worked.
meerkat 2
@Eduardo, it definitely worked. I tested in a job running in production today. You are correct, it needs to be in a function. I added an
on_finish
step and it worked perfectly! No more failed job notifications. Super cool trick. Thanks!
e
you're the second user to implement this (first one was me lol) 🎉
I'll ensure we document this
👍 1