Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

rethrow

Pretty-print error call to be informative for the user.


Description

Pretty-print error call to be informative for the user.

Usage

rethrow(error, call = sys.call(sys.parent()))

rethrow_on_error(expr, call = sys.call(sys.parent()))

Arguments

error

an object of class c("error", "condition") to rethrow

call

the calling context to rethrow the error from, overwriting the error’s current call object

expr

an expression to evaluate inside tryCatch

Value

If it does not throw an error, rethrow_on_error returns the value of evaluating expr.


box

Write Reusable, Composable and Modular R Code

v1.0.2
MIT + file LICENSE
Authors
Konrad Rudolph [aut, cre] (<https://orcid.org/0000-0002-9866-7051>), Michael Schubert [ctb] (<https://orcid.org/0000-0002-6862-5221>)
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.