Displaying 1 result from an estimated 1 matches for "res_list".
Did you mean:
req_list
2019 May 22
1
make running on.exit expr uninterruptible
...- 0.00001
repeat {
cntr_f <- 0L
cntr_on.exit <- 0L
# timeout code borrowed from R.utils::withTimeout but with setTimeLimit()
# (correctly) place inside tryCatch (otherwise timeout can occur before it can
# be caught) and with time limit reset before going into the error handler
res_list <- lapply(seq(0, timeout_upper, length.out = 1000), function(timeout) {
on.exit({
setTimeLimit(cpu = Inf, elapsed = Inf, transient = FALSE)
})
tryCatch({
setTimeLimit(cpu = timeout, elapsed = timeout, transient = TRUE)
res <- f()
# avoid timeout whil...