- using R version 4.5.2 Patched (2026-01-31 r89382)
- using platform: aarch64-apple-darwin20
- R was compiled by
Apple clang version 16.0.0 (clang-1600.0.26.6)
GNU Fortran (GCC) 14.2.0
- running under: macOS Ventura 13.7.8
- using session charset: UTF-8
- checking for file ‘loo/DESCRIPTION’ ... OK
- checking extension type ... Package
- this is package ‘loo’ version ‘2.10.0’
- package encoding: UTF-8
- checking package namespace information ... OK
- checking package dependencies ... OK
- checking if this is a source package ... OK
- checking if there is a namespace ... OK
- checking for executable files ... OK
- checking for hidden files and directories ... OK
- checking for portable file names ... OK
- checking for sufficient/correct file permissions ... OK
- checking whether package ‘loo’ can be installed ... [1s/2s] OK
See the install log for details.
- checking installed package size ... OK
- checking package directory ... OK
- checking ‘build’ directory ... OK
- checking DESCRIPTION meta-information ... OK
- checking top-level files ... OK
- checking for left-over files ... OK
- checking index information ... OK
- checking package subdirectories ... OK
- checking code files for non-ASCII characters ... OK
- checking R files for syntax errors ... OK
- checking whether the package can be loaded ... [0s/0s] OK
- checking whether the package can be loaded with stated dependencies ... [0s/0s] OK
- checking whether the package can be unloaded cleanly ... [0s/0s] OK
- checking whether the namespace can be loaded with stated dependencies ... [0s/0s] OK
- checking whether the namespace can be unloaded cleanly ... [0s/0s] OK
- checking loading without being on the library search path ... [0s/0s] OK
- checking whether startup messages can be suppressed ... [0s/0s] OK
- checking dependencies in R code ... OK
- checking S3 generic/method consistency ... OK
- checking replacement functions ... OK
- checking foreign function calls ... OK
- checking R code for possible problems ... [2s/2s] OK
- checking Rd files ... [0s/0s] OK
- checking Rd metadata ... OK
- checking Rd cross-references ... OK
- checking for missing documentation entries ... OK
- checking for code/documentation mismatches ... OK
- checking Rd \usage sections ... OK
- checking Rd contents ... OK
- checking for unstated dependencies in examples ... OK
- checking contents of ‘data’ directory ... OK
- checking data for non-ASCII characters ... [0s/0s] OK
- checking LazyData ... OK
- checking data for ASCII and uncompressed saves ... OK
- checking R/sysdata.rda ... OK
- checking installed files from ‘inst/doc’ ... OK
- checking files in ‘vignettes’ ... OK
- checking examples ... [0s/0s] OK
- checking for unstated dependencies in ‘tests’ ... OK
- checking tests ... [14s/7s] ERROR
Running ‘testthat.R’ [14s/7s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
> library(loo)
This is loo version 2.10.0
- Online documentation and vignettes at mc-stan.org/loo
- As of v2.0.0 loo defaults to 1 core but we recommend using as many as possible. Use the 'cores' argument or set options(mc.cores = NUM_CORES) for an entire session.
> library(testthat)
Attaching package: 'testthat'
The following object is masked from 'package:loo':
compare
> Sys.setenv("R_TESTS" = "")
> test_check("loo")
Starting 2 test processes.
> test_loo_and_waic.R:
> test_loo_and_waic.R: *** caught segfault ***
> test_loo_and_waic.R: address 0x110, cause 'invalid permissions'
> test_loo_and_waic.R:
> test_loo_and_waic.R: *** caught segfault ***
> test_loo_and_waic.R: address 0x110, cause 'invalid permissions'
> test_loo_and_waic.R:
> test_loo_and_waic.R: Traceback:
> test_loo_and_waic.R: 1: outer(X, Y)
> test_loo_and_waic.R: 2: -theta %o% x
> test_loo_and_waic.R: 3: posterior::gpdfit(exp(x) - exp_cutoff, sort_x = FALSE)
> test_loo_and_waic.R: 4: psis_smooth_tail(lw_tail, cutoff)
> test_loo_and_waic.R: 5: is_fun(log_ratios_i = log_ratios[, i], tail_len_i = tail_len[i])
> test_loo_and_waic.R: 6: FUN(X[[i]], ...)
> test_loo_and_waic.R: 7: lapply(X = S, FUN = FUN, ...)
> test_loo_and_waic.R: 8: doTryCatch(return(expr), name, parentenv, handler)
> test_loo_and_waic.R: 9: tryCatchOne(expr, names, parentenv, handlers[[1L]])
> test_loo_and_waic.R: 10: tryCatchList(expr, classes, parentenv, handlers)
> test_loo_and_waic.R: 11: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ") LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (is.na(w)) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))})
> test_loo_and_waic.R: Traceback:
> test_loo_and_waic.R: 1: outer(X, Y)
> test_loo_and_waic.R: 2: -theta %o% x
> test_loo_and_waic.R: 3: posterior::gpdfit(exp(x) - exp_cutoff, sort_x = FALSE)
> test_loo_and_waic.R: 4: psis_smooth_tail(lw_tail, cutoff)
> test_loo_and_waic.R: 5: is_fun(log_ratios_i = log_ratios[, i], tail_len_i = tail_len[i])
> test_loo_and_waic.R: 12: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
> test_loo_and_waic.R: 13:
> test_loo_and_waic.R: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) 6:
> test_loo_and_waic.R: 14: FUN(X[[i]], ...)
> test_loo_and_waic.R: FUN(X[[i]], ...)
> test_loo_and_waic.R: 7: lapply(X = S, FUN = FUN, ...)
> test_loo_and_waic.R: 8: doTryCatch(return(expr), name, parentenv, handler)
> test_loo_and_waic.R: 9: tryCatchOne(expr, names, parentenv, handlers[[1L]])
> test_loo_and_waic.R: 10: tryCatchList(expr, classes, parentenv, handlers)
> test_loo_and_waic.R: 11: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ") LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (is.na(w)) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))})
> test_loo_and_waic.R: 12: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
> test_loo_and_waic.R: 13: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
> test_loo_and_waic.R: 14: FUN(X[[i]], ...)
> test_loo_and_waic.R: 15: lapply(seq_len(cores), inner.do)
> test_loo_and_waic.R: 16: parallel::mclapply(X = seq_len(N), mc.cores = cores, FUN = function(i) is_fun(log_ratios_i = log_ratios[, i], tail_len_i = tail_len[i]))
> test_loo_and_waic.R: 17: do_importance_sampling(log_ratios, r_eff = r_eff, cores = cores, method = method)
> test_loo_and_waic.R: 18: 15: lapply(seq_len(cores), inner.do)
> test_loo_and_waic.R: importance_sampling.array(log_ratios = -x, r_eff = r_eff, cores = cores, method = is_method)
> test_loo_and_waic.R: 19: loo.array(LLarr, r_eff = r_eff_arr, cores = 2)
> test_loo_and_waic.R: 20: loo(LLarr, r_eff = r_eff_arr, cores = 2)
> test_loo_and_waic.R: 21: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
> test_loo_and_waic.R: 22: suppressWarnings(loo(LLarr, r_eff = r_eff_arr, cores = 2))
> test_loo_and_waic.R: 23: eval(code, test_env)
> test_loo_and_waic.R: 24: eval(code, test_env)
> test_loo_and_waic.R: 25: withCallingHandlers({ eval(code, test_env) new_expectations <- the$test_expectations > starting_expectations if (snapshot_skipped) { skip("On CRAN") } else if (!new_expectations && skip_on_empty) { skip_empty() }}, expectation = handle_expectation, packageNotFoundError = function(e) {16: parallel::mclapply(X = seq_len(N), mc.cores = cores, FUN = function(i) is_fun(log_ratios_i = log_ratios[, i], tail_len_i = tail_len[i])) if (on_cran()) { skip(paste0("{", e$package, "} is not installed.")) }}, snapshot_on_cran = function(cnd) { snapshot_skipped <<- TRUE
> test_loo_and_waic.R: 17: do_importance_sampling(log_ratios, r_eff = r_eff, cores = cores, method = method)
> test_loo_and_waic.R: invokeRestart("muffle_cran_snapshot")}, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error, interrupt = handle_interrupt)
> test_loo_and_waic.R: 26: doTryCatch(return(expr), name, parentenv, handler)18: importance_sampling.array(log_ratios = -x, r_eff = r_eff, cores = cores, method = is_method)
> test_loo_and_waic.R: 19: loo.array(LLarr, r_eff = r_eff_arr, cores = 2)
> test_loo_and_waic.R: 27: tryCatchOne(expr, names, parentenv, handlers[[1L]])
> test_loo_and_waic.R: 28: tryCatchList(expr, classes, parentenv, handlers)
> test_loo_and_waic.R: 20: loo(LLarr, r_eff = r_eff_arr, cores = 2)
> test_loo_and_waic.R: 21: withCallingHandlers(expr, warning = function(w) if (inherits(w,
> test_loo_and_waic.R: 29: tryCatch(withCallingHandlers({
> test_loo_and_waic.R: eval(code, test_env) new_expectations <- the$test_expectations > starting_expectations if (snapshot_skipped) { classes)) tryInvokeRestart("muffleWarning"))
> test_loo_and_waic.R: 22: suppressWarnings(loo(LLarr, r_eff = r_eff_arr, cores = 2))
> test_loo_and_waic.R: 23: eval(code, test_env)
> test_loo_and_waic.R: skip("On CRAN") } else if (!new_expectations && skip_on_empty) { skip_empty() }24: eval(code, test_env)
> test_loo_and_waic.R: 25: withCallingHandlers({}, expectation = handle_expectation, packageNotFoundError = function(e) { if (on_cran()) { skip(paste0("{", e$package, "} is not installed.")) }}, snapshot_on_cran = function(cnd) { eval(code, test_env) snapshot_skipped <<- TRUE new_expectations <- the$test_expectations > starting_expectations invokeRestart("muffle_cran_snapshot")}, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error, interrupt = handle_interrupt), error = handle_fatal)
> test_loo_and_waic.R: 30: doWithOneRestart(return(expr), restart)
> test_loo_and_waic.R: 31: withOneRestart(expr, restarts[[1L]]) if (snapshot_skipped) { skip("On CRAN") } else if (!new_expectations && skip_on_empty) { skip_empty()
> test_loo_and_waic.R: 32: withRestarts(tryCatch(withCallingHandlers({ eval(code, test_env) new_expectations <- the$test_expectations > starting_expectations if (snapshot_skipped) { skip("On CRAN") } else if (!new_expectations && skip_on_empty) { }}, expectation = handle_expectation, packageNotFoundError = function(e) { if (on_cran()) { skip(paste0("{", e$package, "} is not installed.")) } skip_empty() }}, expectation = handle_expectation, packageNotFoundError = function(e) { if (on_cran()) { skip(paste0("{", e$package, "} is not installed.")) }}, snapshot_on_cran = function(cnd) { snapshot_skipped <<- TRUE invokeRestart("muffle_cran_snapshot")}, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error, interrupt = handle_interrupt)}, snapshot_on_cran = function(cnd) { snapshot_skipped <<- TRUE invokeRestart("muffle_cran_snapshot")}, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error, interrupt = handle_interrupt), error = handle_fatal), end_test = function() { })
> test_loo_and_waic.R:
> test_loo_and_waic.R: 26: doTryCatch(return(expr), name, parentenv, handler)
> test_loo_and_waic.R: 33: test_code(code, parent.frame())
> test_loo_and_waic.R: 34: test_that("loo with cores=1 and cores=2 gives same results", 27: tryCatchOne(expr, names, parentenv, handlers[[1L]])
> test_loo_and_waic.R: 28: tryCatchList(expr, classes, parentenv, handlers)
> test_loo_and_waic.R: 29: tryCatch(withCallingHandlers({ eval(code, test_env) { loo2 <- suppressWarnings(loo(LLarr, r_eff = r_eff_arr, cores = 2)) expect_equal(loo1$estimates, loo2$estimates) }) new_expectations <- the$test_expectations > starting_expectations if (snapshot_skipped) { skip("On CRAN") } else if (!new_expectations && skip_on_empty) { skip_empty()
> test_loo_and_waic.R: 35: eval(code, test_env)
> test_loo_and_waic.R: 36: }}, expectation = handle_expectation, packageNotFoundError = function(e) { if (on_cran()) { skip(paste0("{", e$package, "} is not installed.")) }eval(code, test_env)
> test_loo_and_waic.R: 37: withCallingHandlers({ eval(code, test_env) new_expectations <- the$test_expectations > starting_expectations if (snapshot_skipped) { skip("On CRAN") }}, snapshot_on_cran = function(cnd) { snapshot_skipped <<- TRUE invokeRestart("muffle_cran_snapshot")}, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error, interrupt = handle_interrupt), error = handle_fatal) else if (!new_expectations && skip_on_empty) { skip_empty() }}, expectation = handle_expectation, packageNotFoundError = function(e) { if (on_cran()) { skip(paste0("{", e$package, "} is not installed."))
> test_loo_and_waic.R: 30: doWithOneRestart(return(expr), restart)
> test_loo_and_waic.R: 31: }}, snapshot_on_cran = function(cnd) { snapshot_skipped <<- TRUE invokeRestart("muffle_cran_snapshot")}, skip = handle_skip, warning = handle_warning, message = handle_message, withOneRestart(expr, restarts[[1L]]) error = handle_error, interrupt = handle_interrupt)
> test_loo_and_waic.R:
> test_loo_and_waic.R: 38: doTryCatch(return(expr), name, parentenv, handler)
> test_loo_and_waic.R: 39: tryCatchOne(expr, names, parentenv, handlers[[1L]])
> test_loo_and_waic.R: 40: tryCatchList(expr, classes, parentenv, handlers)
> test_loo_and_waic.R: 32: withRestarts(tryCatch(withCallingHandlers({ eval(code, test_env) new_expectations <- the$test_expectations > starting_expectations if (snapshot_skipped) {41: tryCatch(withCallingHandlers({ eval(code, test_env) new_expectations <- the$test_expectations > starting_expectations if (snapshot_skipped) { skip("On CRAN") } else if (!new_expectations && skip_on_empty) { skip_empty() }}, expectation = handle_expectation, packageNotFoundError = function(e) { skip("On CRAN") } else if (!new_expectations && skip_on_empty) { skip_empty() }}, expectation = handle_expectation, packageNotFoundError = function(e) { if (on_cran()) { skip(paste0("{", e$package, "} is not installed.")) }}, snapshot_on_cran = function(cnd) { snapshot_skipped <<- TRUE invokeRestart("muffle_cran_snapshot") if (on_cran()) { skip(paste0("{", e$package, "} is not installed.")) }}, snapshot_on_cran = function(cnd) { snapshot_skipped <<- TRUE invokeRestart("muffle_cran_snapshot")}, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error, interrupt = handle_interrupt), error = handle_fatal)
> test_loo_and_waic.R: 42: doWithOneRestart(return(expr), restart)
> test_loo_and_waic.R: }, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error, interrupt = handle_interrupt), error = handle_fatal), end_test = function() { })
> test_loo_and_waic.R: 43: withOneRestart(expr, restarts[[1L]])
> test_loo_and_waic.R: 44: withRestarts(tryCatch(withCallingHandlers({ eval(code, test_env)33: test_code(code, parent.frame())
> test_loo_and_waic.R: 34: test_that("loo with cores=1 and cores=2 gives same results", { new_expectations <- the$test_expectations > starting_expectations if (snapshot_skipped) { skip("On CRAN") } else if (!new_expectations && skip_on_empty) { loo2 <- suppressWarnings(loo(LLarr, r_eff = r_eff_arr, cores = 2)) expect_equal(loo1$estimates, loo2$estimates) })
> test_loo_and_waic.R: skip_empty() }}, expectation = handle_expectation, packageNotFoundError = function(e) { if (on_cran()) { skip(paste0("{", e$package, "} is not installed.")) }35: eval(code, test_env)
> test_loo_and_waic.R: 36: eval(code, test_env)
> test_loo_and_waic.R: }, snapshot_on_cran = function(cnd) { snapshot_skipped <<- TRUE invokeRestart("muffle_cran_snapshot")}, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error, interrupt = handle_interrupt), error = handle_fatal), end_test = function() { })
> test_loo_and_waic.R: 45: test_code(code = exprs, env = env, reporter = get_reporter() %||% 37: withCallingHandlers({ eval(code, test_env) new_expectations <- the$test_expectations > starting_expectations if (snapshot_skipped) { skip("On CRAN") } StopReporter$new())
> test_loo_and_waic.R: 46: source_file(path, env = env(env), desc = desc, shuffle = shuffle, error_call = error_call)
> test_loo_and_waic.R: else if (!new_expectations && skip_on_empty) { skip_empty() }}, expectation = handle_expectation, packageNotFoundError = function(e) { if (on_cran()) {47: skip(paste0("{", e$package, "} is not installed.")) }}, snapshot_on_cran = function(cnd) { snapshot_skipped <<- TRUE invokeRestart("muffle_cran_snapshot")}, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error, interrupt = handle_interrupt)
> test_loo_and_waic.R: 38: doTryCatch(return(expr), name, parentenv, handler)test_one_file(path, env = the$testing_env, shuffle = shuffle)
> test_loo_and_waic.R: 48: doTryCatch(return(expr), name, parentenv, handler)
> test_loo_and_waic.R: 49:
> test_loo_and_waic.R: 39: tryCatchOne(expr, names, parentenv, handlers[[1L]])
> test_loo_and_waic.R: 40: tryCatchList(expr, classes, parentenv, handlers)
> test_loo_and_waic.R: 41: tryCatch(withCallingHandlers({ eval(code, test_env) new_expectations <- the$test_expectations > starting_expectations if (snapshot_skipped) { skip("On CRAN") } else if (!new_expectations && skip_on_empty) {tryCatchOne(expr, names, parentenv, handlers[[1L]]) skip_empty() }}, expectation = handle_expectation, packageNotFoundError = function(e) {
> test_loo_and_waic.R: 50: tryCatchList(expr, classes, parentenv, handlers)
> test_loo_and_waic.R: if (on_cran()) { skip(paste0("{", e$package, "} is not installed.")) }}, snapshot_on_cran = function(cnd) { snapshot_skipped <<- TRUE invokeRestart("muffle_cran_snapshot")}, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error, interrupt = handle_interrupt), error = handle_fatal)
> test_loo_and_waic.R: 42: doWithOneRestart(return(expr), restart)
> test_loo_and_waic.R: 51: 43: tryCatch(code, testthat_abort_reporter = function(cnd) { cat(conditionMessage(cnd), "\n") NULL})withOneRestart(expr, restarts[[1L]])
> test_loo_and_waic.R: 44: withRestarts(tryCatch(withCallingHandlers({ eval(code, test_env)
> test_loo_and_waic.R: new_expectations <- the$test_expectations > starting_expectations52: if (snapshot_skipped) {with_reporter(multi, test_one_file(path, env = the$testing_env, skip("On CRAN") shuffle = shuffle)) }
> test_loo_and_waic.R: else if (!new_expectations && skip_on_empty) {53: skip_empty()asNamespace("testthat")$queue_task(path, shuffle) }
> test_loo_and_waic.R: }, expectation = handle_expectation, packageNotFoundError = function(e) {54: if (on_cran()) {(function (path, shuffle) skip(paste0("{", e$package, "} is not installed.")){ } asNamespace("testthat")$queue_task(path, shuffle)}, snapshot_on_cran = function(cnd) {})(base::quote("test_loo_and_waic.R"), base::quote(FALSE)) snapshot_skipped <<- TRUE
> test_loo_and_waic.R: invokeRestart("muffle_cran_snapshot")55: }, skip = handle_skip, warning = handle_warning, message = handle_message, (function (what, args, quote = FALSE, envir = parent.frame()) error = handle_error, interrupt = handle_interrupt), error = handle_fatal), { end_test = function() { if (!is.list(args)) }) stop("second argument must be a list")
> test_loo_and_waic.R: if (quote) args <- lapply(args, enquote) .Internal(do.call(what, args, envir))})(base::quote(function (path, shuffle) 45: test_code(code = exprs, env = env, reporter = get_reporter() %||% StopReporter$new())
> test_loo_and_waic.R: 46: {source_file(path, env = env(env), desc = desc, shuffle = shuffle, asNamespace("testthat")$queue_task(path, shuffle) error_call = error_call)}), base::quote(list("test_loo_and_waic.R", FALSE)), envir = base::quote(<environment>), quote = base::quote(TRUE))
> test_loo_and_waic.R: 56:
> test_loo_and_waic.R: 47: test_one_file(path, env = the$testing_env, shuffle = shuffle)
> test_loo_and_waic.R: 48: base::do.call(base::do.call, base::c(base::readRDS("/Volumes/Temp/tmp/RtmpJAuokU/callr-fun-13515dc73eea"), base::list(envir = .GlobalEnv, quote = TRUE)), envir = .GlobalEnv, quote = TRUE)
> test_loo_and_waic.R: 57: doTryCatch(return(expr), name, parentenv, handler)base::saveRDS(base::do.call(base::do.call, base::c(base::readRDS("/Volumes/Temp/tmp/RtmpJAuokU/callr-fun-13515dc73eea"),
> test_loo_and_waic.R: base::list(envir = .GlobalEnv, quote = TRUE)), envir = .GlobalEnv, 49: quote = TRUE), file = "/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-1351513f37bb7", tryCatchOne(expr, names, parentenv, handlers[[1L]]) compress = FALSE)
> test_loo_and_waic.R:
> test_loo_and_waic.R: 50: 58: tryCatchList(expr, classes, parentenv, handlers)base::withCallingHandlers({
> test_loo_and_waic.R: {51: NULLtryCatch(code, testthat_abort_reporter = function(cnd) { NULL cat(conditionMessage(cnd), "\n") } NULL base::saveRDS(base::do.call(base::do.call, base::c(base::readRDS("/Volumes/Temp/tmp/RtmpJAuokU/callr-fun-13515dc73eea"), }) base::list(envir = .GlobalEnv, quote = TRUE)), envir = .GlobalEnv,
> test_loo_and_waic.R: quote = TRUE), file = "/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-1351513f37bb7", 52: compress = FALSE)with_reporter(multi, test_one_file(path, env = the$testing_env, base::flush(base::stdout()) shuffle = shuffle)) base::flush(base::stderr())
> test_loo_and_waic.R: {53: NULLasNamespace("testthat")$queue_task(path, shuffle) NULL
> test_loo_and_waic.R: }54: base::invisible()(function (path, shuffle) }, error = function(e) {{ { asNamespace("testthat")$queue_task(path, shuffle) callr_data <- base::as.environment("tools:callr")$`__callr_data__`})(base::quote("test_loo_and_waic.R"), base::quote(FALSE)) err <- callr_data$err
> test_loo_and_waic.R: if (FALSE) {55: base::assign(".Traceback", base::.traceback(4), envir = callr_data)(function (what, args, quote = FALSE, envir = parent.frame()) utils::dump.frames("__callr_dump__"){ base::assign(".Last.dump", .GlobalEnv$`__callr_dump__`, if (!is.list(args)) envir = callr_data) stop("second argument must be a list") base::rm("__callr_dump__", envir = .GlobalEnv) if (quote) } args <- lapply(args, enquote) e <- err$process_call(e) .Internal(do.call(what, args, envir)) e2 <- err$new_error("error in callr subprocess")})(base::quote(function (path, shuffle) class <- base::class{ class(e2) <- base::c("callr_remote_error", class(e2)) asNamespace("testthat")$queue_task(path, shuffle) e2 <- err$add_trace_back(e2)}), base::quote(list("test_loo_and_waic.R", FALSE)), envir = base::quote(<environment>), quote = base::quote(TRUE))
> test_loo_and_waic.R: 56: base::do.call(base::do.call, base::c(base::readRDS("/Volumes/Temp/tmp/RtmpJAuokU/callr-fun-13515dc73eea"), base::list(envir = .GlobalEnv, quote = TRUE)), envir = .GlobalEnv, quote = TRUE) cut <- base::which(e2$trace$scope == "global")[1] if (!base::is.na(cut)) { e2$trace <- e2$trace[-(1:cut), ] }
> test_loo_and_waic.R: 57: base::saveRDS(base::do.call(base::do.call, base::c(base::readRDS("/Volumes/Temp/tmp/RtmpJAuokU/callr-fun-13515dc73eea"), if (callr_data$has_otel) { callr_data$otel_span$record_exception(e2) } base::saveRDS(base::list("error", e2, e), file = base::paste0("/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-1351513f37bb7", ".error")) base::list(envir = .GlobalEnv, quote = TRUE)), envir = .GlobalEnv, } quote = TRUE), file = "/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-1351513f37bb7", }, interrupt = function(e) { compress = FALSE) {
> test_loo_and_waic.R: callr_data <- base::as.environment("tools:callr")$`__callr_data__`58: err <- callr_data$errbase::withCallingHandlers({ if (FALSE) { { base::assign(".Traceback", base::.traceback(4), envir = callr_data) NULL utils::dump.frames("__callr_dump__") NULL base::assign(".Last.dump", .GlobalEnv$`__callr_dump__`, } envir = callr_data) base::saveRDS(base::do.call(base::do.call, base::c(base::readRDS("/Volumes/Temp/tmp/RtmpJAuokU/callr-fun-13515dc73eea"), base::rm("__callr_dump__", envir = .GlobalEnv) base::list(envir = .GlobalEnv, quote = TRUE)), envir = .GlobalEnv, } quote = TRUE), file = "/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-1351513f37bb7", e <- err$process_call(e) compress = FALSE) e2 <- err$new_error("error in callr subprocess") base::flush(base::stdout()) class <- base::class base::flush(base::stderr()) class(e2) <- base::c("callr_remote_error", class(e2)) { e2 <- err$add_trace_back(e2) NULL cut <- base::which(e2$trace$scope == "global")[1] NULL if (!base::is.na(cut)) { e2$trace <- e2$trace[-(1:cut), ] } if (callr_data$has_otel) { } base::invisible()}, error = function(e) { { callr_data <- base::as.environment("tools:callr")$`__callr_data__` callr_data$otel_span$record_exception(e2) err <- callr_data$err } if (FALSE) { base::saveRDS(base::list("error", e2, e), file = base::paste0("/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-1351513f37bb7", base::assign(".Traceback", base::.traceback(4), envir = callr_data) ".error")) utils::dump.frames("__callr_dump__") } base::assign(".Last.dump", .GlobalEnv$`__callr_dump__`, }, callr_message = function(e) { envir = callr_data) base::try({ base::rm("__callr_dump__", envir = .GlobalEnv) callr_data <- base::as.environment("tools:callr")$`__callr_data__` } pxlib <- callr_data$pxlib e <- err$process_call(e) if (base::is.null(e$code)) { e2 <- err$new_error("error in callr subprocess") e$code <- "301" class <- base::class } class(e2) <- base::c("callr_remote_error", class(e2)) msg <- base::paste0("base64::", pxlib$base64_encode(base::serialize(e, e2 <- err$add_trace_back(e2) NULL))) cut <- base::which(e2$trace$scope == "global")[1] data <- base::paste0(e$code, " ", base::nchar(msg), "\n", if (!base::is.na(cut)) { msg) e2$trace <- e2$trace[-(1:cut), ] if (callr_data$has_otel) { } callr_data$otel_span$add_event("callr message", attributes = list(status_code = e$code)) } pxlib$write_fd(3L, data) if (base::inherits(e, "cli_message") && !base::is.null(base::findRestart("cli_message_handled"))) { base::invokeRestart("cli_message_handled") } else if (base::inherits(e, "message") && !base::is.null(base::findRestart("muffleMessage"))) { base::invokeRestart("muffleMessage") } if (callr_data$has_otel) { }) callr_data$otel_span$record_exception(e2) } base::saveRDS(base::list("error", e2, e), file = base::paste0("/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-1351513f37bb7", ".error")) }}, interrupt = function(e) { { callr_data <- base::as.environment("tools:callr")$`__callr_data__` err <- callr_data$err}) if (FALSE) {
> test_loo_and_waic.R: base::assign(".Traceback", base::.traceback(4), envir = callr_data)59: utils::dump.frames("__callr_dump__")doTryCatch(return(expr), name, parentenv, handler)
> test_loo_and_waic.R: 60: tryCatchOne(expr, names, parentenv, handlers[[1L]])
> test_loo_and_waic.R: base::assign(".Last.dump", .GlobalEnv$`__callr_dump__`, 61: envir = callr_data)tryCatchList(expr, names[-nh], parentenv, handlers[-nh]) base::rm("__callr_dump__", envir = .GlobalEnv)
> test_loo_and_waic.R: }62: e <- err$process_call(e)doTryCatch(return(expr), name, parentenv, handler) e2 <- err$new_error("error in callr subprocess")
> test_loo_and_waic.R: class <- base::class63: class(e2) <- base::c("callr_remote_error", class(e2))tryCatchOne(tryCatchList(expr, names[-nh], parentenv, handlers[-nh]), e2 <- err$add_trace_back(e2) names[nh], parentenv, handlers[[nh]]) cut <- base::which(e2$trace$scope == "global")[1]
> test_loo_and_waic.R: if (!base::is.na(cut)) {64: e2$trace <- e2$trace[-(1:cut), ]tryCatchList(expr, classes, parentenv, handlers) }
> test_loo_and_waic.R: if (callr_data$has_otel) {65: callr_data$otel_span$record_exception(e2)base::tryCatch(base::withCallingHandlers({ } { base::saveRDS(base::list("error", e2, e), file = base::paste0("/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-1351513f37bb7", NULL ".error")) NULL } }}, callr_message = function(e) { base::saveRDS(base::do.call(base::do.call, base::c(base::readRDS("/Volumes/Temp/tmp/RtmpJAuokU/callr-fun-13515dc73eea"), base::try({ base::list(envir = .GlobalEnv, quote = TRUE)), envir = .GlobalEnv, callr_data <- base::as.environment("tools:callr")$`__callr_data__` quote = TRUE), file = "/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-1351513f37bb7", pxlib <- callr_data$pxlib compress = FALSE) if (base::is.null(e$code)) { base::flush(base::stdout()) e$code <- "301" base::flush(base::stderr()) } { msg <- base::paste0("base64::", pxlib$base64_encode(base::serialize(e, NULL NULL))) NULL data <- base::paste0(e$code, " ", base::nchar(msg), "\n", } msg) base::invisible() if (callr_data$has_otel) {}, error = function(e) { callr_data$otel_span$add_event("callr message", attributes = list(status_code = e$code)) } pxlib$write_fd(3L, data) if (base::inherits(e, "cli_message") && !base::is.null(base::findRestart("cli_message_handled"))) { { callr_data <- base::as.environment("tools:callr")$`__callr_data__` err <- callr_data$err if (FALSE) { base::assign(".Traceback", base::.traceback(4), envir = callr_data) base::invokeRestart("cli_message_handled") utils::dump.frames("__callr_dump__") } base::assign(".Last.dump", .GlobalEnv$`__callr_dump__`, else if (base::inherits(e, "message") && !base::is.null(base::findRestart("muffleMessage"))) { envir = callr_data) base::invokeRestart("muffleMessage") base::rm("__callr_dump__", envir = .GlobalEnv) } } }) e <- err$process_call(e)}) e2 <- err$new_error("error in callr subprocess")
> test_loo_and_waic.R: class <- base::class59: class(e2) <- base::c("callr_remote_error", class(e2))doTryCatch(return(expr), name, parentenv, handler) e2 <- err$add_trace_back(e2)
> test_loo_and_waic.R: cut <- base::which(e2$trace$scope == "global")[1]60: if (!base::is.na(cut)) { e2$trace <- e2$trace[-(1:cut), ]
> test_loo_and_waic.R: tryCatchOne(expr, names, parentenv, handlers[[1L]])
> test_loo_and_waic.R: 61: tryCatchList(expr, names[-nh], parentenv, handlers[-nh])
> test_loo_and_waic.R: 62: doTryCatch(return(expr), name, parentenv, handler)
> test_loo_and_waic.R: } if (callr_data$has_otel) { callr_data$otel_span$record_exception(e2) }63: tryCatchOne(tryCatchList(expr, names[-nh], parentenv, handlers[-nh]), names[nh], parentenv, handlers[[nh]])
> test_loo_and_waic.R: 64: base::saveRDS(base::list("error", e2, e), file = base::paste0("/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-1351513f37bb7", tryCatchList(expr, classes, parentenv, handlers) ".error"))
> test_loo_and_waic.R: }65: }, interrupt = function(e) {base::tryCatch(base::withCallingHandlers({ { { callr_data <- base::as.environment("tools:callr")$`__callr_data__` NULL err <- callr_data$err NULL if (FALSE) { } base::assign(".Traceback", base::.traceback(4), envir = callr_data) base::saveRDS(base::do.call(base::do.call, base::c(base::readRDS("/Volumes/Temp/tmp/RtmpJAuokU/callr-fun-13515dc73eea"), utils::dump.frames("__callr_dump__") base::list(envir = .GlobalEnv, quote = TRUE)), envir = .GlobalEnv, base::assign(".Last.dump", .GlobalEnv$`__callr_dump__`, quote = TRUE), file = "/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-1351513f37bb7", envir = callr_data) compress = FALSE) base::rm("__callr_dump__", envir = .GlobalEnv) base::flush(base::stdout()) } base::flush(base::stderr()) e <- err$process_call(e) { e2 <- err$new_error("error in callr subprocess") NULL class <- base::class NULL class(e2) <- base::c("callr_remote_error", class(e2)) } e2 <- err$add_trace_back(e2) base::invisible() cut <- base::which(e2$trace$scope == "global")[1]}, error = function(e) { if (!base::is.na(cut)) { { e2$trace <- e2$trace[-(1:cut), ] callr_data <- base::as.environment("tools:callr")$`__callr_data__` } err <- callr_data$err if (callr_data$has_otel) { if (FALSE) { callr_data$otel_span$record_exception(e2) base::assign(".Traceback", base::.traceback(4), envir = callr_data) } utils::dump.frames("__callr_dump__") base::saveRDS(base::list("error", e2, e), file = base::paste0("/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-1351513f37bb7", ".error")) }}, callr_message = function(e) { base::try({ base::assign(".Last.dump", .GlobalEnv$`__callr_dump__`, envir = callr_data) base::rm("__callr_dump__", envir = .GlobalEnv) } e <- err$process_call(e) callr_data <- base::as.environment("tools:callr")$`__callr_data__` e2 <- err$new_error("error in callr subprocess") pxlib <- callr_data$pxlib class <- base::class if (base::is.null(e$code)) { class(e2) <- base::c("callr_remote_error", class(e2)) e$code <- "301" e2 <- err$add_trace_back(e2) } cut <- base::which(e2$trace$scope == "global")[1] msg <- base::paste0("base64::", pxlib$base64_encode(base::serialize(e, if (!base::is.na(cut)) { NULL))) e2$trace <- e2$trace[-(1:cut), ] data <- base::paste0(e$code, " ", base::nchar(msg), "\n", } msg) if (callr_data$has_otel) { if (callr_data$has_otel) { callr_data$otel_span$record_exception(e2) callr_data$otel_span$add_event("callr message", attributes = list(status_code = e$code)) } } base::saveRDS(base::list("error", e2, e), file = base::paste0("/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-1351513f37bb7", pxlib$write_fd(3L, data) ".error")) if (base::inherits(e, "cli_message") && !base::is.null(base::findRestart("cli_message_handled"))) { base::invokeRestart("cli_message_handled") } else if (base::inherits(e, "message") && !base::is.null(base::findRestart("muffleMessage"))) { base::invokeRestart("muffleMessage") } }}, interrupt = function(e) { { callr_data <- base::as.environment("tools:callr")$`__callr_data__` err <- callr_data$err if (FALSE) { }) base::assign(".Traceback", base::.traceback(4), envir = callr_data)}), error = function(e) { { NULL NULL } utils::dump.frames("__callr_dump__") base::assign(".Last.dump", .GlobalEnv$`__callr_dump__`, envir = callr_data) base::rm("__callr_dump__", envir = .GlobalEnv) } if (FALSE) { e <- err$process_call(e) base::try(base::stop(e)) e2 <- err$new_error("error in callr subprocess") } class <- base::class if (FALSE) { class(e2) <- base::c("callr_remote_error", class(e2)) base::q(save = "no", status = 1) e2 <- err$add_trace_back(e2) } cut <- base::which(e2$trace$scope == "global")[1] base::invisible() if (!base::is.na(cut)) {}, interrupt = function(e) { e2$trace <- e2$trace[-(1:cut), ] { } NULL if (callr_data$has_otel) { NULL callr_data$otel_span$record_exception(e2) } } if (FALSE) { base::saveRDS(base::list("error", e2, e), file = base::paste0("/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-1351513f37bb7", base::q(save = "no", status = 1) ".error")) } } base::invisible()}, callr_message = function(e) {}) base::try({
> test_loo_and_waic.R: callr_data <- base::as.environment("tools:callr")$`__callr_data__`An irrecoverable exception occurred. R is aborting now ...
> test_loo_and_waic.R: pxlib <- callr_data$pxlib if (base::is.null(e$code)) { e$code <- "301" } msg <- base::paste0("base64::", pxlib$base64_encode(base::serialize(e, NULL))) data <- base::paste0(e$code, " ", base::nchar(msg), "\n", msg) if (callr_data$has_otel) { callr_data$otel_span$add_event("callr message", attributes = list(status_code = e$code)) } pxlib$write_fd(3L, data) if (base::inherits(e, "cli_message") && !base::is.null(base::findRestart("cli_message_handled"))) { base::invokeRestart("cli_message_handled") } else if (base::inherits(e, "message") && !base::is.null(base::findRestart("muffleMessage"))) { base::invokeRestart("muffleMessage") } })}), error = function(e) { { NULL NULL } if (FALSE) { base::try(base::stop(e)) } if (FALSE) { base::q(save = "no", status = 1) } base::invisible()}, interrupt = function(e) { { NULL NULL } if (FALSE) { base::q(save = "no", status = 1) } base::invisible()})
> test_loo_and_waic.R: An irrecoverable exception occurred. R is aborting now ...
Saving _problems/test_loo_and_waic-30.R
> test_loo_predictive_metric.R:
> test_loo_predictive_metric.R: *** caught segfault ***
> test_loo_predictive_metric.R: address 0x110, cause 'invalid permissions'
> test_loo_predictive_metric.R:
> test_loo_predictive_metric.R: *** caught segfault ***
> test_loo_predictive_metric.R: address 0x110, cause 'invalid permissions'
> test_loo_predictive_metric.R:
> test_loo_predictive_metric.R: Traceback:
> test_loo_predictive_metric.R: 1: outer(X, Y)
> test_loo_predictive_metric.R: 2: -theta %o% x
> test_loo_predictive_metric.R: 3: posterior::gpdfit(exp(x) - exp_cutoff, sort_x = FALSE)
> test_loo_predictive_metric.R: 4: psis_smooth_tail(lw_tail, cutoff)
> test_loo_predictive_metric.R: 5: is_fun(log_ratios_i = log_ratios[, i], tail_len_i = tail_len[i])
> test_loo_predictive_metric.R: 6: FUN(X[[i]], ...)
> test_loo_predictive_metric.R: 7: lapply(X = S, FUN = FUN, ...)
> test_loo_predictive_metric.R: 8: doTryCatch(return(expr), name, parentenv, handler)
> test_loo_predictive_metric.R: 9: tryCatchOne(expr, names, parentenv, handlers[[1L]])
> test_loo_predictive_metric.R: 10: tryCatchList(expr, classes, parentenv, handlers)
> test_loo_predictive_metric.R: 11: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ") LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (is.na(w)) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))})
> test_loo_predictive_metric.R: 12: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
> test_loo_predictive_metric.R: 13: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
> test_loo_predictive_metric.R: 14: FUN(X[[i]], ...)
> test_loo_predictive_metric.R: 15: lapply(seq_len(cores), inner.do)
> test_loo_predictive_metric.R: 16: parallel::mclapply(X = seq_len(N), mc.cores = cores, FUN = function(i) is_fun(log_ratios_i = log_ratios[, i], tail_len_i = tail_len[i]))
> test_loo_predictive_metric.R: 17: do_importance_sampling(log_ratios, r_eff = r_eff, cores = cores, method = method)
> test_loo_predictive_metric.R: 18: importance_sampling.matrix(log_ratios, ..., r_eff = r_eff, cores = cores, method = "psis")
> test_loo_predictive_metric.R: 19: psis.matrix(-LL, r_eff = r_eff, cores = 2)
> test_loo_predictive_metric.R: 20: psis(-LL, r_eff = r_eff, cores = 2)
> test_loo_predictive_metric.R: 21: eval(code, test_env)
> test_loo_predictive_metric.R: 22: eval(code, test_env)
> test_loo_predictive_metric.R: 23: withCallingHandlers({ eval(code, test_env) new_expectations <- the$test_expectations > starting_expectations if (snapshot_skipped) { skip("On CRAN") } else if (!new_expectations && skip_on_empty) { skip_empty() }}, expectation = handle_expectation, packageNotFoundError = function(e) { if (on_cran()) { skip(paste0("{", e$package, "} is not installed.")) }}, snapshot_on_cran = function(cnd) { snapshot_skipped <<- TRUE invokeRestart("muffle_cran_snapshot")}, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error, interrupt = handle_interrupt)
> test_loo_predictive_metric.R: 24: doTryCatch(return(expr), name, parentenv, handler)
> test_loo_predictive_metric.R: 25: tryCatchOne(expr, names, parentenv, handlers[[1L]])
> test_loo_predictive_metric.R: 26: tryCatchList(expr, classes, parentenv, handlers)
> test_loo_predictive_metric.R: 27: tryCatch(withCallingHandlers({ eval(code, test_env) new_expectations <- the$test_expectations > starting_expectations if (snapshot_skipped) { skip("On CRAN") } else if (!new_expectations && skip_on_empty) { skip_empty() }}, expectation = handle_expectation, packageNotFoundError = function(e) { if (on_cran()) { skip(paste0("{", e$package, "} is not installed.")) }}, snapshot_on_cran = function(cnd) { snapshot_skipped <<- TRUE invokeRestart("muffle_cran_snapshot")}, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error, interrupt = handle_interrupt), error = handle_fatal)
> test_loo_predictive_metric.R: 28: doWithOneRestart(return(expr), restart)
> test_loo_predictive_metric.R: 29: withOneRestart(expr, restarts[[1L]])
> test_loo_predictive_metric.R: 30: withRestarts(tryCatch(withCallingHandlers({ eval(code, test_env) new_expectations <- the$test_expectations > starting_expectations if (snapshot_skipped) { skip("On CRAN") } else if (!new_expectations && skip_on_empty) { skip_empty() }}, expectation = handle_expectation, packageNotFoundError = function(e) { if (on_cran()) { skip(paste0("{", e$package, "} is not installed.")) }}, snapshot_on_cran = function(cnd) { snapshot_skipped <<- TRUE invokeRestart("muffle_cran_snapshot")}, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error, interrupt = handle_interrupt), error = handle_fatal), end_test = function() { })
> test_loo_predictive_metric.R: 31: test_code(code = exprs, env = env, reporter = get_reporter() %||% StopReporter$new())
> test_loo_predictive_metric.R: 32: source_file(path, env = env(env), desc = desc, shuffle = shuffle, error_call = error_call)
> test_loo_predictive_metric.R: 33: test_one_file(path, env = the$testing_env, shuffle = shuffle)
> test_loo_predictive_metric.R: 34: doTryCatch(return(expr), name, parentenv, handler)
> test_loo_predictive_metric.R: 35: tryCatchOne(expr, names, parentenv, handlers[[1L]])
> test_loo_predictive_metric.R: 36: tryCatchList(expr, classes, parentenv, handlers)
> test_loo_predictive_metric.R: 37: tryCatch(code, testthat_abort_reporter = function(cnd) { cat(conditionMessage(cnd), "\n") NULL
> test_loo_predictive_metric.R: })
> test_loo_predictive_metric.R: 38: with_reporter(multi, test_one_file(path, env = the$testing_env, shuffle = shuffle))
> test_loo_predictive_metric.R: 39: asNamespace("testthat")$queue_task(path, shuffle)
> test_loo_predictive_metric.R: 40: (function (path, shuffle) { asNamespace("testthat")$queue_task(path, shuffle)})(base::quote("test_loo_predictive_metric.R"), base::quote(FALSE))
> test_loo_predictive_metric.R: 41: (function (what, args, quote = FALSE, envir = parent.frame()) { if (!is.list(args)) stop("second argument must be a list") if (quote) args <- lapply(args, enquote) .Internal(do.call(what, args, envir))})(base::quote(function (path, shuffle) { asNamespace("testthat")$queue_task(path, shuffle)}), base::quote(list("test_loo_predictive_metric.R", FALSE)), envir = base::quote(<environment>), quote = base::quote(TRUE))
> test_loo_predictive_metric.R: 42: base::do.call(base::do.call, base::c(base::readRDS("/Volumes/Temp/tmp/RtmpJAuokU/callr-fun-135153bcbd77"), base::list(envir = .GlobalEnv, quote = TRUE)), envir = .GlobalEnv, quote = TRUE)
> test_loo_predictive_metric.R: 43: base::saveRDS(base::do.call(base::do.call, base::c(base::readRDS("/Volumes/Temp/tmp/RtmpJAuokU/callr-fun-135153bcbd77"), base::list(envir = .GlobalEnv, quote = TRUE)), envir = .GlobalEnv, quote = TRUE), file = "/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-135155c3ad18b", compress = FALSE)
> test_loo_predictive_metric.R: 44: base::withCallingHandlers({ { NULL NULL } base::saveRDS(base::do.call(base::do.call, base::c(base::readRDS("/Volumes/Temp/tmp/RtmpJAuokU/callr-fun-135153bcbd77"), base::list(envir = .GlobalEnv, quote = TRUE)), envir = .GlobalEnv, quote = TRUE), file = "/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-135155c3ad18b", compress = FALSE) base::flush(base::stdout()) base::flush(base::stderr()) { NULL NULL } base::invisible()}, error = function(e) { { callr_data <- base::as.environment("tools:callr")$`__callr_data__` err <- callr_data$err if (FALSE) { base::assign(".Traceback", base::.traceback(4), envir = callr_data) utils::dump.frames("__callr_dump__") base::assign(".Last.dump", .GlobalEnv$`__callr_dump__`, envir = callr_data) base::rm("__callr_dump__", envir = .GlobalEnv) } e <- err$process_call(e) e2 <- err$new_error("error in callr subprocess") class <- base::class class(e2) <- base::c("callr_remote_error", class(e2)) e2 <- err$add_trace_back(e2) cut <- base::which(e2$trace$scope == "global")[1] if (!base::is.na(cut)) { e2$trace <- e2$trace[-(1:cut), ] } if (callr_data$has_otel) { callr_data$otel_span$record_exception(e2) } base::saveRDS(base::list("error", e2, e), file = base::paste0("/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-135155c3ad18b", ".error")) }}, interrupt = function(e) { { callr_data <- base::as.environment("tools:callr")$`__callr_data__` err <- callr_data$err if (FALSE) { base::assign(".Traceback", base::.traceback(4), envir = callr_data) utils::dump.frames("__callr_dump__") base::assign(".Last.dump", .GlobalEnv$`__callr_dump__`, envir = callr_data) base::rm("__callr_dump__", envir = .GlobalEnv) } e <- err$process_call(e) e2 <- err$new_error("error in callr subprocess") class <- base::class class(e2) <- base::c("callr_remote_error", class(e2)) e2 <- err$add_trace_back(e2) cut <- base::which(e2$trace$scope == "global")[1] if (!base::is.na(cut)) { e2$trace <- e2$trace[-(1:cut), ] } if (callr_data$has_otel) { callr_data$otel_span$record_exception(e2) } base::saveRDS(base::list("error", e2, e), file = base::paste0("/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-135155c3ad18b", ".error")) }}, callr_message = function(e) { base::try({ callr_data <- base::as.environment("tools:callr")$`__callr_data__` pxlib <- callr_data$pxlib if (base::is.null(e$code)) { e$code <- "301" } msg <- base::paste0("base64::", pxlib$base64_encode(base::serialize(e, NULL))) data <- base::paste0(e$code, " ", base::nchar(msg), "\n", msg) if (callr_data$has_otel) { callr_data$otel_span$add_event("callr message", attributes = list(status_code = e$code)) } pxlib$write_fd(3L, data) if (base::inherits(e, "cli_message") && !base::is.null(base::findRestart("cli_message_handled"))) { base::invokeRestart("cli_message_handled") } else if (base::inherits(e, "message") && !base::is.null(base::findRestart("muffleMessage"))) { base::invokeRestart("muffleMessage") } })})
> test_loo_predictive_metric.R: 45: doTryCatch(return(expr), name, parentenv, handler)
> test_loo_predictive_metric.R: 46: tryCatchOne(expr, names, parentenv, handlers[[1L]])
> test_loo_predictive_metric.R: 47: tryCatchList(expr, names[-nh], parentenv, handlers[-nh])
> test_loo_predictive_metric.R: 48: doTryCatch(return(expr), name, parentenv, handler)
> test_loo_predictive_metric.R: 49: tryCatchOne(tryCatchList(expr, names[-nh], parentenv, handlers[-nh]), names[nh], parentenv, handlers[[nh]])
> test_loo_predictive_metric.R: 50: tryCatchList(expr, classes, parentenv, handlers)
> test_loo_predictive_metric.R: 51: base::tryCatch(base::withCallingHandlers({ { NULL NULL } base::saveRDS(base::do.call(base::do.call, base::c(base::readRDS("/Volumes/Temp/tmp/RtmpJAuokU/callr-fun-135153bcbd77"), base::list(envir = .GlobalEnv, quote = TRUE)), envir = .GlobalEnv, quote = TRUE), file = "/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-135155c3ad18b", compress = FALSE) base::flush(base::stdout()) base::flush(base::stderr()) { NULL NULL } base::invisible()}, error = function(e) { { callr_data <- base::as.environment("tools:callr")$`__callr_data__` err <- callr_data$err if (FALSE) { base::assign(".Traceback", base::.traceback(4), envir = callr_data) utils::dump.frames("__callr_dump__") base::assign(".Last.dump", .GlobalEnv$`__callr_dump__`, envir = callr_data) base::rm("__callr_dump__", envir = .GlobalEnv) } e <- err$process_call(e) e2 <- err$new_error("error in callr subprocess") class <- base::class class(e2) <- base::c("callr_remote_error", class(e2)) e2 <- err$add_trace_back(e2) cut <- base::which(e2$trace$scope == "global")[1] if (!base::is.na(cut)) { e2$trace <- e2$trace[-(1:cut), ] } if (callr_data$has_otel) { callr_data$otel_span$record_exception(e2) } base::saveRDS(base::list("error", e2, e), file = base::paste0("/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-135155c3ad18b", ".error")) }}, interrupt = function(e) { { callr_data <- base::as.environment("tools:callr")$`__callr_data__` err <- callr_data$err if (FALSE) { base::assign(".Traceback", base::.traceback(4), envir = callr_data) utils::dump.frames("__callr_dump__") base::assign(".Last.dump", .GlobalEnv$`__callr_dump__`, envir = callr_data) base::rm("__callr_dump__", envir = .GlobalEnv) } e <- err$process_call(e) e2 <- err$new_error("error in callr subprocess") class <- base::class class(e2) <- base::c("callr_remote_error", class(e2)) e2 <- err$add_trace_back(e2) cut <- base::which(e2$trace$scope == "global")[1] if (!base::is.na(cut)) { e2$trace <- e2$trace[-(1:cut), ] } if (callr_data$has_otel) { callr_data$otel_span$record_exception(e2) } base::saveRDS(base::list("error", e2, e), file = base::paste0("/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-135155c3ad18b", ".error")) }}, callr_message = function(e) { base::try({ callr_data <- base::as.environment("tools:callr")$`__callr_data__` pxlib <- callr_data$pxlib if (base::is.null(e$code)) { e$code <- "301" } msg <- base::paste0("base64::", pxlib$base64_encode(base::serialize(e, NULL)))
> test_loo_predictive_metric.R: data <- base::paste0(e$code, " ", base::nchar(msg), "\n", msg) if (callr_data$has_otel) { callr_data$otel_span$add_event("callr message", attributes = list(status_code = e$code)) } pxlib$write_fd(3L, data) if (base::inherits(e, "cli_message") && !base::is.null(base::findRestart("cli_message_handled"))) { base::invokeRestart("cli_message_handled") } else if (base::inherits(e, "message") && !base::is.null(base::findRestart("muffleMessage"))) { base::invokeRestart("muffleMessage") } })}), error = function(e) { { NULL NULL } if (FALSE) { base::try(base::stop(e)) } if (FALSE) { base::q(save = "no", status = 1) } base::invisible()}, interrupt = function(e) { { NULL NULL } if (FALSE) { base::q(save = "no", status = 1) } base::invisible()})
> test_loo_predictive_metric.R: An irrecoverable exception occurred. R is aborting now ...
> test_loo_predictive_metric.R:
> test_loo_predictive_metric.R: Traceback:
> test_loo_predictive_metric.R: 1: outer(X, Y)
> test_loo_predictive_metric.R: 2: -theta %o% x
> test_loo_predictive_metric.R: 3: posterior::gpdfit(exp(x) - exp_cutoff, sort_x = FALSE)
> test_loo_predictive_metric.R: 4: psis_smooth_tail(lw_tail, cutoff)
> test_loo_predictive_metric.R: 5: is_fun(log_ratios_i = log_ratios[, i], tail_len_i = tail_len[i])
> test_loo_predictive_metric.R: 6: FUN(X[[i]], ...)
> test_loo_predictive_metric.R: 7: lapply(X = S, FUN = FUN, ...)
> test_loo_predictive_metric.R: 8: doTryCatch(return(expr), name, parentenv, handler)
> test_loo_predictive_metric.R: 9: tryCatchOne(expr, names, parentenv, handlers[[1L]])
> test_loo_predictive_metric.R: 10: tryCatchList(expr, classes, parentenv, handlers)
> test_loo_predictive_metric.R: 11: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ") LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (is.na(w)) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))})
> test_loo_predictive_metric.R: 12: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
> test_loo_predictive_metric.R: 13: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
> test_loo_predictive_metric.R: 14: FUN(X[[i]], ...)
> test_loo_predictive_metric.R: 15: lapply(seq_len(cores), inner.do)
> test_loo_predictive_metric.R: 16: parallel::mclapply(X = seq_len(N), mc.cores = cores, FUN = function(i) is_fun(log_ratios_i = log_ratios[, i], tail_len_i = tail_len[i]))
> test_loo_predictive_metric.R: 17: do_importance_sampling(log_ratios, r_eff = r_eff, cores = cores, method = method)
> test_loo_predictive_metric.R: 18: importance_sampling.matrix(log_ratios, ..., r_eff = r_eff, cores = cores, method = "psis")
> test_loo_predictive_metric.R: 19: psis.matrix(-LL, r_eff = r_eff, cores = 2)
> test_loo_predictive_metric.R: 20: psis(-LL, r_eff = r_eff, cores = 2)
> test_loo_predictive_metric.R: 21: eval(code, test_env)
> test_loo_predictive_metric.R: 22: eval(code, test_env)
> test_loo_predictive_metric.R: 23: withCallingHandlers({ eval(code, test_env) new_expectations <- the$test_expectations > starting_expectations if (snapshot_skipped) { skip("On CRAN") } else if (!new_expectations && skip_on_empty) { skip_empty() }}, expectation = handle_expectation, packageNotFoundError = function(e) { if (on_cran()) { skip(paste0("{", e$package, "} is not installed.")) }}, snapshot_on_cran = function(cnd) { snapshot_skipped <<- TRUE invokeRestart("muffle_cran_snapshot")}, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error, interrupt = handle_interrupt)
> test_loo_predictive_metric.R: 24: doTryCatch(return(expr), name, parentenv, handler)
> test_loo_predictive_metric.R: 25: tryCatchOne(expr, names, parentenv, handlers[[1L]])
> test_loo_predictive_metric.R: 26: tryCatchList(expr, classes, parentenv, handlers)
> test_loo_predictive_metric.R: 27: tryCatch(withCallingHandlers({ eval(code, test_env) new_expectations <- the$test_expectations > starting_expectations if (snapshot_skipped) { skip("On CRAN") } else if (!new_expectations && skip_on_empty) { skip_empty() }}, expectation = handle_expectation, packageNotFoundError = function(e) { if (on_cran()) { skip(paste0("{", e$package, "} is not installed.")) }}, snapshot_on_cran = function(cnd) { snapshot_skipped <<- TRUE invokeRestart("muffle_cran_snapshot")}, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error, interrupt = handle_interrupt), error = handle_fatal)
> test_loo_predictive_metric.R: 28: doWithOneRestart(return(expr), restart)
> test_loo_predictive_metric.R: 29: withOneRestart(expr, restarts[[1L]])
> test_loo_predictive_metric.R: 30: withRestarts(tryCatch(withCallingHandlers({ eval(code, test_env) new_expectations <- the$test_expectations > starting_expectations if (snapshot_skipped) { skip("On CRAN") } else if (!new_expectations && skip_on_empty) { skip_empty() }}, expectation = handle_expectation, packageNotFoundError = function(e) { if (on_cran()) { skip(paste0("{", e$package, "} is not installed.")) }}, snapshot_on_cran = function(cnd) { snapshot_skipped <<- TRUE invokeRestart("muffle_cran_snapshot")}, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error, interrupt = handle_interrupt), error = handle_fatal), end_test = function() { })
> test_loo_predictive_metric.R: 31: test_code(code = exprs, env = env, reporter = get_reporter() %||% StopReporter$new())
> test_loo_predictive_metric.R: 32: source_file(path, env = env(env), desc = desc, shuffle = shuffle, error_call = error_call)
> test_loo_predictive_metric.R: 33: test_one_file(path, env = the$testing_env, shuffle = shuffle)
> test_loo_predictive_metric.R: 34: doTryCatch(return(expr), name, parentenv, handler)
> test_loo_predictive_metric.R: 35: tryCatchOne(expr, names, parentenv, handlers[[1L]])
> test_loo_predictive_metric.R: 36: tryCatchList(expr, classes, parentenv, handlers)
> test_loo_predictive_metric.R: 37: tryCatch(code, testthat_abort_reporter = function(cnd) { cat(conditionMessage(cnd), "\n") NULL})
> test_loo_predictive_metric.R: 38: with_reporter(multi, test_one_file(path, env = the$testing_env, shuffle = shuffle))
> test_loo_predictive_metric.R: 39: asNamespace("testthat")$queue_task(path, shuffle)
> test_loo_predictive_metric.R: 40: (function (path, shuffle) { asNamespace("testthat")$queue_task(path, shuffle)})(base::quote("test_loo_predictive_metric.R"), base::quote(FALSE))
> test_loo_predictive_metric.R: 41: (function (what, args, quote = FALSE, envir = parent.frame()) { if (!is.list(args)) stop("second argument must be a list") if (quote) args <- lapply(args, enquote) .Internal(do.call(what, args, envir))})(base::quote(function (path, shuffle) { asNamespace("testthat")$queue_task(path, shuffle)}), base::quote(list("test_loo_predictive_metric.R", FALSE)), envir = base::quote(<environment>), quote = base::quote(TRUE))
> test_loo_predictive_metric.R: 42: base::do.call(base::do.call, base::c(base::readRDS("/Volumes/Temp/tmp/RtmpJAuokU/callr-fun-135153bcbd77"), base::list(envir = .GlobalEnv, quote = TRUE)), envir = .GlobalEnv, quote = TRUE)
> test_loo_predictive_metric.R: 43: base::saveRDS(base::do.call(base::do.call, base::c(base::readRDS("/Volumes/Temp/tmp/RtmpJAuokU/callr-fun-135153bcbd77"), base::list(envir = .GlobalEnv, quote = TRUE)), envir = .GlobalEnv, quote = TRUE), file = "/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-135155c3ad18b", compress = FALSE)
> test_loo_predictive_metric.R: 44: base::withCallingHandlers({ { NULL NULL } base::saveRDS(base::do.call(base::do.call, base::c(base::readRDS("/Volumes/Temp/tmp/RtmpJAuokU/callr-fun-135153bcbd77"), base::list(envir = .GlobalEnv, quote = TRUE)), envir = .GlobalEnv, quote = TRUE), file = "/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-135155c3ad18b", compress = FALSE) base::flush(base::stdout()) base::flush(base::stderr()) { NULL NULL } base::invisible()}, error = function(e) { { callr_data <- base::as.environment("tools:callr")$`__callr_data__` err <- callr_data$err if (FALSE) { base::assign(".Traceback", base::.traceback(4), envir = callr_data) utils::dump.frames("__callr_dump__") base::assign(".Last.dump", .GlobalEnv$`__callr_dump__`, envir = callr_data) base::rm("__callr_dump__", envir = .GlobalEnv) } e <- err$process_call(e) e2 <- err$new_error("error in callr subprocess") class <- base::class
> test_loo_predictive_metric.R: class(e2) <- base::c("callr_remote_error", class(e2)) e2 <- err$add_trace_back(e2) cut <- base::which(e2$trace$scope == "global")[1] if (!base::is.na(cut)) { e2$trace <- e2$trace[-(1:cut), ] } if (callr_data$has_otel) { callr_data$otel_span$record_exception(e2) } base::saveRDS(base::list("error", e2, e), file = base::paste0("/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-135155c3ad18b", ".error")) }}, interrupt = function(e) { { callr_data <- base::as.environment("tools:callr")$`__callr_data__` err <- callr_data$err if (FALSE) { base::assign(".Traceback", base::.traceback(4), envir = callr_data) utils::dump.frames("__callr_dump__") base::assign(".Last.dump", .GlobalEnv$`__callr_dump__`, envir = callr_data) base::rm("__callr_dump__", envir = .GlobalEnv) } e <- err$process_call(e) e2 <- err$new_error("error in callr subprocess") class <- base::class class(e2) <- base::c("callr_remote_error", class(e2)) e2 <- err$add_trace_back(e2) cut <- base::which(e2$trace$scope == "global")[1] if (!base::is.na(cut)) { e2$trace <- e2$trace[-(1:cut), ] } if (callr_data$has_otel) { callr_data$otel_span$record_exception(e2) } base::saveRDS(base::list("error", e2, e), file = base::paste0("/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-135155c3ad18b", ".error")) }}, callr_message = function(e) { base::try({ callr_data <- base::as.environment("tools:callr")$`__callr_data__` pxlib <- callr_data$pxlib if (base::is.null(e$code)) { e$code <- "301" } msg <- base::paste0("base64::", pxlib$base64_encode(base::serialize(e, NULL))) data <- base::paste0(e$code, " ", base::nchar(msg), "\n", msg) if (callr_data$has_otel) { callr_data$otel_span$add_event("callr message", attributes = list(status_code = e$code)) } pxlib$write_fd(3L, data) if (base::inherits(e, "cli_message") && !base::is.null(base::findRestart("cli_message_handled"))) { base::invokeRestart("cli_message_handled") } else if (base::inherits(e, "message") && !base::is.null(base::findRestart("muffleMessage"))) { base::invokeRestart("muffleMessage") } })})
> test_loo_predictive_metric.R: 45: doTryCatch(return(expr), name, parentenv, handler)
> test_loo_predictive_metric.R: 46: tryCatchOne(expr, names, parentenv, handlers[[1L]])
> test_loo_predictive_metric.R: 47: tryCatchList(expr, names[-nh], parentenv, handlers[-nh])
> test_loo_predictive_metric.R: 48: doTryCatch(return(expr), name, parentenv, handler)
> test_loo_predictive_metric.R: 49: tryCatchOne(tryCatchList(expr, names[-nh], parentenv, handlers[-nh]), names[nh], parentenv, handlers[[nh]])
> test_loo_predictive_metric.R: 50: tryCatchList(expr, classes, parentenv, handlers)
> test_loo_predictive_metric.R: 51: base::tryCatch(base::withCallingHandlers({ { NULL NULL } base::saveRDS(base::do.call(base::do.call, base::c(base::readRDS("/Volumes/Temp/tmp/RtmpJAuokU/callr-fun-135153bcbd77"), base::list(envir = .GlobalEnv, quote = TRUE)), envir = .GlobalEnv, quote = TRUE), file = "/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-135155c3ad18b", compress = FALSE) base::flush(base::stdout()) base::flush(base::stderr()) { NULL NULL } base::invisible()}, error = function(e) { { callr_data <- base::as.environment("tools:callr")$`__callr_data__` err <- callr_data$err if (FALSE) { base::assign(".Traceback", base::.traceback(4), envir = callr_data) utils::dump.frames("__callr_dump__") base::assign(".Last.dump", .GlobalEnv$`__callr_dump__`, envir = callr_data) base::rm("__callr_dump__", envir = .GlobalEnv) } e <- err$process_call(e) e2 <- err$new_error("error in callr subprocess") class <- base::class class(e2) <- base::c("callr_remote_error", class(e2)) e2 <- err$add_trace_back(e2) cut <- base::which(e2$trace$scope == "global")[1] if (!base::is.na(cut)) { e2$trace <- e2$trace[-(1:cut), ] } if (callr_data$has_otel) { callr_data$otel_span$record_exception(e2) } base::saveRDS(base::list("error", e2, e), file = base::paste0("/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-135155c3ad18b", ".error")) }}, interrupt = function(e) { { callr_data <- base::as.environment("tools:callr")$`__callr_data__` err <- callr_data$err if (FALSE) { base::assign(".Traceback", base::.traceback(4), envir = callr_data) utils::dump.frames("__callr_dump__") base::assign(".Last.dump", .GlobalEnv$`__callr_dump__`, envir = callr_data) base::rm("__callr_dump__", envir = .GlobalEnv) } e <- err$process_call(e) e2 <- err$new_error("error in callr subprocess") class <- base::class class(e2) <- base::c("callr_remote_error", class(e2)) e2 <- err$add_trace_back(e2) cut <- base::which(e2$trace$scope == "global")[1] if (!base::is.na(cut)) { e2$trace <- e2$trace[-(1:cut), ] } if (callr_data$has_otel) { callr_data$otel_span$record_exception(e2) } base::saveRDS(base::list("error", e2, e), file = base::paste0("/Volumes/Temp/tmp/RtmpJAuokU/callr-rs-result-135155c3ad18b", ".error")) }}, callr_message = function(e) { base::try({ callr_data <- base::as.environment("tools:callr")$`__callr_data__` pxlib <- callr_data$pxlib if (base::is.null(e$code)) { e$code <- "301" } msg <- base::paste0("base64::", pxlib$base64_encode(base::serialize(e, NULL))) data <- base::paste0(e$code, " ", base::nchar(msg), "\n", msg) if (callr_data$has_otel) { callr_data$otel_span$add_event("callr message", attributes = list(status_code = e$code)) } pxlib$write_fd(3L, data) if (base::inherits(e, "cli_message") && !base::is.null(base::findRestart("cli_message_handled"))) { base::invokeRestart("cli_message_handled") } else if (base::inherits(e, "message") && !base::is.null(base::findRestart("muffleMessage"))) { base::invokeRestart("muffleMessage") } })}), error = function(e) { { NULL NULL } if (FALSE) { base::try(base::stop(e)) } if (FALSE) { base::q(save = "no", status = 1) } base::invisible()}, interrupt = function(e) { { NULL NULL } if (FALSE) { base::q(save = "no", status = 1) } base::invisible()})
> test_loo_predictive_metric.R: An irrecoverable exception occurred. R is aborting now ...
Saving _problems/test_loo_predictive_metric-4.R
[ FAIL 2 | WARN 1 | SKIP 34 | PASS 847 ]
══ Skipped tests (34) ══════════════════════════════════════════════════════════
• On CRAN (32): 'test_loo_subsampling_cases.R:4:3',
'test_loo_subsampling_cases.R:256:3', 'test_E_loo.R:134:1',
'test_E_loo.R:142:1', 'test_compare.R:91:1', 'test_compare.R:122:1',
'test_compare.R:160:1', 'test_crps.R:27:1',
'test_deprecated_extractors.R:8:1', 'test_deprecated_extractors.R:106:1',
'test_gpdfit.R:1:1', 'test_kfold_helpers.R:139:1',
'test_loo_and_waic.R:23:1', 'test_loo_moment_matching.R:157:1',
'test_loo_moment_matching.R:247:1', 'test_loo_moment_matching.R:365:1',
'test_model_weighting.R:69:1', 'test_print_plot.R:41:1',
'test_print_plot.R:45:1', 'test_print_plot.R:151:1',
'test_print_plot.R:169:1', 'test_print_plot.R:175:1',
'test_print_plot.R:181:1', 'test_psis.R:13:1', 'test_psis.R:39:1',
'test_psislw.R:15:1', 'test_relative_eff.R:7:1', 'test_relative_eff.R:43:3',
'test_loo_subsampling.R:896:3', 'test_loo_subsampling.R:1077:3',
'test_tisis.R:76:1', 'test_tisis.R:213:1'
• Sys.info()[["sysname"]] == "Darwin" && R.version$arch == "aarch64" is TRUE
(2): 'test_loo_moment_matching.R:468:3', 'test_psis.R:157:3'
══ Failed tests ════════════════════════════════════════════════════════════════
── Error ('test_loo_and_waic.R:30:3'): loo with cores=1 and cores=2 gives same results ──
Error in `vapply(x, FUN = match.arg(fun), FUN.VALUE = fun_val, item)`: values must be length 1000,
but FUN(X[[1]]) result is length 0
Backtrace:
▆
1. ├─base::suppressWarnings(loo(LLarr, r_eff = r_eff_arr, cores = 2)) at test_loo_and_waic.R:30:3
2. │ └─base::withCallingHandlers(...)
3. ├─loo::loo(LLarr, r_eff = r_eff_arr, cores = 2)
4. └─loo::loo.array(LLarr, r_eff = r_eff_arr, cores = 2)
5. └─loo:::importance_sampling.array(...)
6. └─loo:::do_importance_sampling(...)
7. └─loo:::psis_apply(lw_list, "log_weights", fun_val = numeric(S))
8. └─base::vapply(x, FUN = match.arg(fun), FUN.VALUE = fun_val, item)
── Error ('test_loo_predictive_metric.R:4:1'): (code run outside of `test_that()`) ──
Error in `vapply(x, FUN = match.arg(fun), FUN.VALUE = fun_val, item)`: values must be length 1000,
but FUN(X[[1]]) result is length 0
Backtrace:
▆
1. ├─loo::psis(-LL, r_eff = r_eff, cores = 2) at test_loo_predictive_metric.R:4:1
2. └─loo:::psis.matrix(-LL, r_eff = r_eff, cores = 2)
3. └─loo:::importance_sampling.matrix(...)
4. └─loo:::do_importance_sampling(...)
5. └─loo:::psis_apply(lw_list, "log_weights", fun_val = numeric(S))
6. └─base::vapply(x, FUN = match.arg(fun), FUN.VALUE = fun_val, item)
[ FAIL 2 | WARN 1 | SKIP 34 | PASS 847 ]
Error:
! Test failures.
Execution halted
- checking for unstated dependencies in vignettes ... OK
- checking package vignettes ... OK
- checking re-building of vignette outputs ... [9s/9s] OK
- checking PDF version of manual ... [3s/3s] OK
- DONE
Status: 1 ERROR