Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A more informative abort message than "aborting ..." #3

Closed
HenrikBengtsson opened this issue May 13, 2015 · 2 comments
Closed

A more informative abort message than "aborting ..." #3

HenrikBengtsson opened this issue May 13, 2015 · 2 comments

Comments

@HenrikBengtsson
Copy link
Owner

WISH

Use An exceptional error occurred that R could not recover from. The R session is now aborting ... instead of just aborting ..., because from the latter it is not always clear where that messages comes from, i.e. it could have been outputted by something else. Here's an example:

checking tests ... ERROR
Running the tests intests/devEval.Rfailed.
Last 13 lines of output:
1: .External2(C_X11, d$display, d$width, d$height, d$pointsize, d$gamma, d$colortype, d$maxcubesize, d$bg, d$canvas, d$fonts, NA_integer_, d$xpos, d$ypos, d$title, type, antialias, d$family)
[...]
12: tryCatch({ res <- devEval(type, name = "any", aspectRatio = 2/3, scale = 1.2, { plot(100:1) }) printf("Result: %s (%s)\n\n", sQuote(res), attr(res, "type")) devOff()}, error = function(ex) { printf("Failed: %s\n\n", sQuote(ex$message))})
aborting ...
checking for unstated dependencies in vignettes ... OK

ACTIONS TAKEN

@HenrikBengtsson HenrikBengtsson changed the title WISH: A more informative abort message than "aborting ..." A more informative abort message than "aborting ..." Dec 29, 2015
@HenrikBengtsson
Copy link
Owner Author

I just submitted PR #16749.

@HenrikBengtsson
Copy link
Owner Author

PR #16749 closed; Martin Maechler updated R's abort message R devel r70288. In interactive mode, we now get:

[...] 
> Possible actions: 
> 1: abort (with core dump, if enabled) 
> 2: normal R exit 
> 3: exit R without saving workspace 
> 4: exit R saving workspace 
> Selection: 1
R is aborting now ...

and in non-interactive mode (including R CMD check) we get:

An irrecoverable exception occurred. R is aborting now ...

From the R CMD check output of the original example, it should now be a bit more clear that it is R that is aborting, e.g.

checking tests ... ERROR
Running the tests intests/devEval.Rfailed.
Last 13 lines of output:
1: .External2(C_X11, d$display, d$width, d$height, d$pointsize, d$gamma, d$colortype, d$maxcubesize, d$bg, d$canvas, d$fonts, NA_integer_, d$xpos, d$ypos, d$title, type, antialias, d$family)
[...]
12: tryCatch({ res <- devEval(type, name = "any", aspectRatio = 2/3, scale = 1.2, { plot(100:1) }) printf("Result: %s (%s)\n\n", sQuote(res), attr(res, "type")) devOff()}, error = function(ex) { printf("Failed: %s\n\n", sQuote(ex$message))})
An irrecoverable exception occurred. R is aborting now ...
checking for unstated dependencies in vignettes ... OK

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant