Creates and signals a structured deputy error using cli formatting.
All deputy errors include a message, optional context, and inherit
from the deputy_error condition class.
Usage
abort_deputy(message, class = NULL, ..., .envir = parent.frame())Examples
if (FALSE) { # \dontrun{
# Signal an error
abort_deputy("Something went wrong", class = "custom")
# Catch deputy errors
tryCatch(
abort_deputy("test"),
deputy_error = function(e) message("Caught: ", conditionMessage(e))
)
} # }