We are writing a book where we want to show the error message from some code but not a traceback. For example
library(tidyverse)
tibble(x = 1:2) %>%
map_dbl(sort)
where we specified the chunk with {r, error=TRUE}.
How can we get the error message without the traceback?
Thanks