Last updated on 2026-04-23 01:52:26 CEST.
| Flavor | Version | Tinstall | Tcheck | Ttotal | Status | Flags |
|---|---|---|---|---|---|---|
| r-devel-linux-x86_64-debian-clang | 1.1.3 | 5.00 | 152.03 | 157.03 | OK | |
| r-devel-linux-x86_64-debian-gcc | 1.1.3 | 3.51 | 111.54 | 115.05 | OK | |
| r-devel-linux-x86_64-fedora-clang | 1.1.3 | 8.00 | 226.95 | 234.95 | OK | |
| r-devel-linux-x86_64-fedora-gcc | 1.1.3 | 8.00 | 249.29 | 257.29 | OK | |
| r-devel-macos-arm64 | 1.1.3 | 1.00 | 47.00 | 48.00 | OK | |
| r-devel-windows-x86_64 | 1.1.3 | 8.00 | 214.00 | 222.00 | OK | |
| r-patched-linux-x86_64 | 1.1.3 | 5.99 | 143.05 | 149.04 | OK | |
| r-release-linux-x86_64 | 1.1.3 | 4.94 | 139.13 | 144.07 | OK | |
| r-release-macos-arm64 | 1.1.3 | 1.00 | 45.00 | 46.00 | ERROR | |
| r-release-macos-x86_64 | 1.1.3 | 4.00 | 179.00 | 183.00 | OK | |
| r-release-windows-x86_64 | 1.1.3 | 9.00 | 204.00 | 213.00 | OK | |
| r-oldrel-macos-arm64 | 1.1.3 | 1.00 | 51.00 | 52.00 | OK | |
| r-oldrel-macos-x86_64 | 1.1.3 | 4.00 | 205.00 | 209.00 | OK | |
| r-oldrel-windows-x86_64 | 1.1.3 | 11.00 | 255.00 | 266.00 | OK |
Version: 1.1.3
Check: examples
Result: ERROR
Running examples in ‘logitr-Ex.R’ failed
The error most likely occurred in:
> ### Name: logitr
> ### Title: The main function for estimating logit models
> ### Aliases: logitr
> ### Keywords: logit logitr mixed mnl mxl willingness-to-pay wtp
>
> ### ** Examples
>
> # For more detailed examples, visit
> # https://jhelvy.github.io/logitr/articles/
>
> library(logitr)
>
> # Estimate a MNL model in the Preference space
> mnl_pref <- logitr(
+ data = yogurt,
+ outcome = "choice",
+ obsID = "obsID",
+ pars = c("price", "feat", "brand")
+ )
Running model...
Done!
>
> # Estimate a MNL model in the WTP space, using a 5-run multistart
> mnl_wtp <- logitr(
+ data = yogurt,
+ outcome = "choice",
+ obsID = "obsID",
+ pars = c("feat", "brand"),
+ scalePar = "price",
+ numMultiStarts = 5
+ )
Running multistart...
Random starting point iterations: 5
Number of cores: 15
*** caught segfault ***
address 0x110, cause 'invalid permissions'
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: 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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 5)
An irrecoverable exception occurred. R is aborting now ...
*** caught segfault ***
address 0x110, cause 'invalid permissions'
*** caught segfault ***
address 0x110, cause 'invalid permissions'
Traceback:
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: 8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) {tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }}) 8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) {
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$messagedoTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: }})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L)tryCatchList(expr, classes, parentenv, handlers) 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 ") }
14: else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) {tryCatch(expr, error = function(e) { call <- conditionCall(e) cat(msg, file = outFile) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = 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)) })
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: 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"))) {suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 5)
An irrecoverable exception occurred. R is aborting now ...
cat(msg, file = outFile) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16:
*** caught segfault ***
address 0x110, cause 'invalid permissions'
sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 5)
An irrecoverable exception occurred. R is aborting now ...
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: 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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 5)
An irrecoverable exception occurred. R is aborting now ...
*** caught segfault ***
address 0x110, cause 'invalid permissions'
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: 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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 5)
An irrecoverable exception occurred. R is aborting now ...
Error in names(x) <- value :
'names' attribute [3] must be the same length as the vector [0]
Calls: logitr -> getMultistartSummary -> colnames<-
Execution halted
Flavor: r-release-macos-arm64
Version: 1.1.3
Check: re-building of vignette outputs
Result: ERROR
Error(s) in re-building vignettes:
--- re-building ‘basic_usage.Rmd’ using rmarkdown
*** caught segfault ***
address 0x110, cause 'invalid permissions'
*** caught segfault ***
address 0x110, cause 'invalid permissions'
*** caught segfault ***
address 0x110, cause 'invalid permissions'
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: 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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)
26: eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) }
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective)
Traceback:
model$iterations <- result$iterations model$status <- result$status model$message <- result$message41: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) }})
0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective,
44: eng_r(options)
45: 9: FUN(X[[i]], ...)
10: mi = mi, opts = mi$options)block_exec(params)lapply(X = S, FUN = FUN, ...)
11:
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})46:
8: system.time({ model <- mi$model result <- NULL
call_block(x)
47: process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {13: tryCatchList(expr, classes, parentenv, handlers)
14: if (progress && is.function(pb$interrupt)) pb$interrupt() tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) }) pb$interrupt() dcall <- deparse(call, nlines = 1L) if (is_R_CMD_build() || is_R_CMD_check()) if (!is.null(result)) { error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { prefix <- paste("Error in", dcall, ": ") LONG <- 75L if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }}) 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") paste0("\nQuitting from ", loc, if (!is.null(error))
9: FUN(X[[i]], ...) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52:
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
.Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) }13: tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) {knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 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, ": ")
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc) invisible(structure(msg, class = "try-error", condition = e))})
15:
try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]]56: w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w")16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)58: tryCatchList(expr, classes, parentenv, handlers)
59: 22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)23: suppressMessages(suppressWarnings(parallel::mclapply(miList,
*** caught segfault ***
runModel, mc.cores = numCores)))19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: address 0x110, cause 'invalid permissions'
withCallingHandlers(expr, warning = function(w) if (inherits(w,
output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) classes)) tryInvokeRestart("muffleWarning")) }
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)
21: 26: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))}, error = function(e) {eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) {
file, conditionMessage(e)))})
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: 60: tools:::.buildOneVignette("basic_usage.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "basic_usage", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211ccb2701.rds")
An irrecoverable exception occurred. R is aborting now ...
suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) {24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)
cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) {26: eval(expr, envir)
27: eval(expr, envir)
28: invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) {30: eval(call)
31: eval(call) invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() }
32: with_handlers({ watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]]) cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
39: withRestarts(with_handlers({
31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
*** caught segfault ***
*** caught segfault ***
address 0x110, cause 'invalid permissions'
address 0x110, cause 'invalid permissions'
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
39: withRestarts(with_handlers({ for (expr in tle$exprs) {40: evaluate::evaluate(...)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output()
Traceback:
watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ model <- mi$model41: keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: block_exec(params)
46: call_block(x)
47: process_group(group)
48: result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))
pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) mi = mi, opts = mi$options) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule())) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
model$status <- result$status model$message <- result$message }})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)42: in_dir(input_dir(), expr)52:
12: 43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: 0L else 2LtryCatch(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")knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) }, output_handler = knit_handlers(options$render, options)))
Traceback:
if (w > LONG) prefix <- paste0(prefix, "\n ") }
else prefix <- "Error : "
*** caught segfault ***
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))})
address 0x110, cause 'invalid permissions'
44: eng_r(options)
45: block_exec(params)
46: call_block(x)
47: process_group(group)
1: 48: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)15:
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)54: eval_f(x0, ...)
3:
withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
16: 49: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))vweave_rmarkdown(...) 2: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {
if (progress && is.function(pb$interrupt)) eval_f(x0, ...)nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective,
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
mi = mi, opts = mi$options)
pb$interrupt()
57: if (is_R_CMD_build() || is_R_CMD_check()) 17: tryCatchOne(expr, names, parentenv, handlers[[1L]]) mi = mi, opts = mi$options)
58: tryCatchList(expr, classes, parentenv, handlers)
error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
59:
FUN(X[[i]], ...)50: tryCatch({
18: lapply(seq_len(cores), inner.do) engine$weave(file, quiet = quiet, encoding = enc)xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),
19: 4: error = function(e) { if (progress && is.function(pb$interrupt)) 4: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
doTryCatch(return(expr), name, parentenv, handler)21: doTryCatch(return(expr), name, parentenv, handler)
setwd(startdir)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]]) pb$interrupt() output <- find_vignette_product(name, by = "weave", engine = engine)
if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine)suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) 6: if (is_R_CMD_build() || is_R_CMD_check()) 5: }tryCatchOne(expr, names, parentenv, handlers[[1L]])tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
*** caught segfault ***
8:
error <<- format(e)system.time({ }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd)}, error = function(e) {address 0x110, cause 'invalid permissions'
write_utf8(res, output %n% stdout()) 6: tryCatchList(expr, classes, parentenv, handlers)
OK <<- FALSE22: model <- mi$model paste0("\nQuitting from ", loc, if (!is.null(error)) message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) file, conditionMessage(e))) result <- NULL
tryCatch({}) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, withCallingHandlers(expr, message = function(c) if (inherits(c, mi = mi, opts = mi$options) 7:
Traceback:
60: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, }, error = function(e) {51: 2: tools:::.buildOneVignette("basic_usage.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", }) mi = mi, opts = mi$options) if (!is.null(result)) { classes)) tryInvokeRestart("muffleMessage"))}, error = function(e) { TRUE, FALSE, "basic_usage", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211ccb2701.rds")
process_file(text, output)
23: model$fail <- FALSEsuppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))) model$coefficients <- result$solution
}) model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$messageAn irrecoverable exception occurred. R is aborting now ...
52: }eval_f(x0, ...)
8: })system.time({
knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), 24: 3: output_dir = getwd(), ...)
runMultistart(modelInputs)
9: 25: FUN(X[[i]], ...)
model <- mi$modellogitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 54: vweave_rmarkdown(...)
mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: 55: tryCatchOne(expr, names, parentenv, handlers[[1L]]) "brand"), scalePar = "price", numMultiStarts = 10)engine$weave(file, quiet = quiet, encoding = enc)
26: eval(expr, envir)
27:
10: lapply(X = S, FUN = FUN, ...)
eval(expr, envir) result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective,
6: mi = mi, opts = mi$options)tryCatchList(expr, classes, parentenv, handlers) }, error = function(e) {
11: 7: tryCatch({doTryCatch(return(expr), name, parentenv, handler)
12:
*** caught segfault ***
56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) })doTryCatch(return(expr), name, parentenv, handler) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective,
13: tryCatchList(expr, classes, parentenv, handlers)address 0x110, cause 'invalid permissions'
mi = mi, opts = mi$options)}, error = function(e) {
Traceback:
14: 1: 28: if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution57: 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)) mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) model$logLik <- as.numeric(-1 * result$objective)})
2: eval_f(x0, ...) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L],
type = "b") if (w > LONG) 3:
model$iterations <- result$iterationsnloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, tryCatchOne(expr, names, parentenv, handlers[[1L]]) 8: model$status <- result$statussystem.time({ mi = mi, opts = mi$options) model$message <- result$message prefix <- paste0(prefix, "\n ")
}58: tryCatchList(expr, classes, parentenv, handlers)
model <- mi$model
4: doTryCatch(return(expr), name, parentenv, handler)
else prefix <- "Error : "withVisible(eval(expr, envir)) 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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: 59: result <- NULL tryCatch({ }
29: withCallingHandlers(code, error = function (e) }) 5: rlang::entrace(e), message = function (cnd) {tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) engine$weave(file, quiet = quiet, encoding = enc)tryCatchOne(expr, names, parentenv, handlers[[1L]]) }, error = function(e) { })
watcher$capture_plot_and_output()
9: FUN(X[[i]], ...)
if (!is.null(result)) { if (on_message$capture) { watcher$push(cnd) model$fail <- FALSE }FUN(X[[i]], ...)
if (on_message$silence) { setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { invokeRestart("muffleMessage") texi2pdf(file = output, clean = FALSE, quiet = quiet) 6: model$coefficients <- result$solution18: 10: lapply(X = S, FUN = FUN, ...) }
11: doTryCatch(return(expr), name, parentenv, handler) model$logLik <- as.numeric(-1 * result$objective)
model$iterations <- result$iterationslapply(seq_len(cores), inner.do)
}, warning = function (cnd) 12: output <- find_vignette_product(name, by = "texi2pdf", tryCatchList(expr, classes, parentenv, handlers)19: model$status <- result$status
model$message <- result$message{ }})tryCatchOne(expr, names, parentenv, handlers[[1L]]) if (getOption("warn") >= 2 || getOption("warn") < 0) { engine = engine)
7: tryCatch({parallel::mclapply(miList, runModel, mc.cores = numCores) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, return()13:
}}, error = function(e) {
Traceback:
mi = mi, opts = mi$options) 9: OK <<- FALSE20: } 1: FUN(X[[i]], ...) message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s",
tryCatchList(expr, classes, parentenv, handlers)10: }, error = function(e) {mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: withCallingHandlers(expr, warning = function(w) if (inherits(w, watcher$capture_plot_and_output()eval_f(x0, ...)})
if (on_warning$capture) {14: file, conditionMessage(e))) classes)) tryInvokeRestart("muffleWarning"))tryCatch(expr, error = function(e) {
lapply(X = S, FUN = FUN, ...)21: cnd <- sanitize_call(cnd) watcher$push(cnd)suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
3: }
if (on_warning$silence) {
call <- conditionCall(e)nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, })
60: tools:::.buildOneVignette("basic_usage.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "basic_usage", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211ccb2701.rds")
22: withCallingHandlers(expr, message = function(c) if (inherits(c, 8: invokeRestart("muffleWarning") classes)) tryInvokeRestart("muffleMessage"))
23: An irrecoverable exception occurred. R is aborting now ...
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: mi = mi, opts = mi$options) if (!is.null(call)) { }}, error = function (cnd) system.time({ if (identical(call[[1L]], quote(doTryCatch))) suppressMessages(suppressWarnings(parallel::mclapply(miList,
model <- mi$model runModel, mc.cores = numCores)))tryCatch(expr, error = function(e) { 4: call <- sys.call(-4L)
call <- conditionCall(e)doTryCatch(return(expr), name, parentenv, handler){ result <- NULL tryCatch({ if (!is.null(call)) { result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, dcall <- deparse(call, nlines = 1L) watcher$capture_plot_and_output() mi = mi, opts = mi$options) prefix <- paste("Error in", dcall, ": ") cnd <- sanitize_call(cnd) }, error = function(e) {24: watcher$push(cnd) LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]]
switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: if (identical(call[[1L]], quote(doTryCatch))) w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w")eval(call)runMultistart(modelInputs)
call <- sys.call(-4L)31: }) if (!is.null(result)) { dcall <- deparse(call, nlines = 1L) 5: if (is.na(w))
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)
26: eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))eval(call)
tryCatchOne(expr, names, parentenv, handlers[[1L]]) model$fail <- FALSE29: model$coefficients <- result$solutionwithCallingHandlers(code, error = function (e) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], prefix <- paste("Error in", dcall, ": ")
32: with_handlers({ LONG <- 75L model$logLik <- as.numeric(-1 * result$objective) for (expr in tle$exprs) { model$iterations <- result$iterations 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])) model$status <- result$status 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"))) {
*** caught segfault ***
ev <- withVisible(eval(expr, envir))
model$message <- result$message }})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: cat(msg, file = outFile)address 0x110, cause 'invalid permissions'
watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) 6: if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings())doTryCatch(return(expr), name, parentenv, handler)rlang::entrace(e), message = function (cnd) tryCatchList(expr, classes, parentenv, handlers){ watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { } TRUE}, handlers)
.Internal(printDeferredWarnings())
33: } invokeRestart("muffleMessage") }}, warning = function (cnd) 12: invisible(structure(msg, class = "try-error", condition = e))}){ }
if (getOption("warn") >= 2 || getOption("warn") < 0) {15: 7: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)doWithOneRestart(return(expr), restart)tryCatchOne(expr, names, parentenv, handlers[[1L]]) return() invisible(structure(msg, class = "try-error", condition = e))
tryCatch({}) }13:
watcher$capture_plot_and_output() if (on_warning$capture) {tryCatchList(expr, classes, parentenv, handlers)
14: 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
tryCatch(expr, error = function(e) {34: 17: 15: withOneRestart(expr, restarts[[1L]])try(lapply(X = S, FUN = FUN, ...), silent = TRUE) call <- conditionCall(e) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, FUN(X[[i]], ...) mi = mi, opts = mi$options)
if (!is.null(call)) { cnd <- sanitize_call(cnd)
}, error = function(e) {
18: 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))})35:
if (identical(call[[1L]], quote(doTryCatch))) watcher$push(cnd)lapply(seq_len(cores), inner.do)
withRestartList(expr, restarts[-nr])17: FUN(X[[i]], ...)
18: 8: system.time({
}lapply(seq_len(cores), inner.do)
19: if (on_warning$silence) {36: call <- sys.call(-4L) invokeRestart("muffleWarning")doWithOneRestart(return(expr), restart) model <- mi$model dcall <- deparse(call, nlines = 1L)
result <- NULL tryCatch({
parallel::mclapply(miList, runModel, mc.cores = numCores) } prefix <- paste("Error in", dcall, ": ")}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd)
19: 37: result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, switch(on_error, continue = invokeRestart("eval_continue"), LONG <- 75Lparallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: stop = invokeRestart("eval_stop"), error = NULL) sm <- strsplit(conditionMessage(e), "\n")[[1L]] mi = mi, opts = mi$options)20: }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w")}) 9: withCallingHandlers(expr, warning = function(w) if (inherits(w,
Traceback:
classes)) tryInvokeRestart("muffleWarning"))
1:
mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
22: 21: 30: eval(call)
withCallingHandlers(expr, message = function(c) if (inherits(c, 31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
classes)) tryInvokeRestart("muffleMessage"))38:
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
37: FUN(X[[i]], ...)withRestartList(expr, restarts)runMultistart(modelInputs)
3: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)
26: eval(expr, envir)
39: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) {
22: withCallingHandlers(expr, message = function(c) if (inherits(c, mi = mi, opts = mi$options) watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) {10: withRestarts(with_handlers({38: if (is.na(w))
invokeRestart("muffleMessage")withRestartList(expr, restarts) for (expr in tle$exprs) { } 4: lapply(X = S, FUN = FUN, ...) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L],
ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir)doTryCatch(return(expr), name, parentenv, handler) type = "b")
classes)) tryInvokeRestart("muffleMessage")) }}, warning = function (cnd) 11:
23: doTryCatch(return(expr), name, parentenv, handler){39: if (getOption("warn") >= 2 || getOption("warn") < 0) { TRUEwithRestarts(with_handlers({}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
if (w > LONG) for (expr in tle$exprs) { return()
12: 5: prefix <- paste0(prefix, "\n ") ev <- withVisible(eval(expr, envir)) }suppressMessages(suppressWarnings(parallel::mclapply(miList, tryCatchOne(expr, names, parentenv, handlers[[1L]]) runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
tryCatchOne(expr, names, parentenv, handlers[[1L]]) } watcher$capture_plot_and_output() watcher$capture_plot_and_output()
watcher$print_value(ev$value, ev$visible, envir)25: 13: tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) }logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", else prefix <- "Error : " TRUE 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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE) if (on_warning$capture) {
40: "brand"), scalePar = "price", numMultiStarts = 10)evaluate::evaluate(...)
cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"),
40: evaluate::evaluate(...)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L stop = invokeRestart("eval_stop"), error = NULL) call <- sys.call(-4L) 6:
26: else 2L dcall <- deparse(call, nlines = 1L)
tryCatchList(expr, classes, parentenv, handlers)41: eval(expr, envir) }, output_handler = knit_handlers(options$render, options)))}) prefix <- paste("Error in", dcall, ": ")17: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, FUN(X[[i]], ...)
LONG <- 75L 7: tryCatch({
44: eng_r(options)
45: block_exec(params)
30: eval(call)
keep_message = if (is.numeric(options$message)) TRUE else options$message, result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 31: mi = mi, opts = mi$options)18: eval(call) stop_on_error = if (is.numeric(options$error)) options$error else {}, error = function(e) { sm <- strsplit(conditionMessage(e), "\n")[[1L]] if (options$error && options$include) }) 0Llapply(seq_len(cores), inner.do) else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr) w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w")27: eval(expr, envir)
32: with_handlers({ if (is.na(w)) for (expr in tle$exprs) { w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], ev <- withVisible(eval(expr, envir))28: type = "b")
withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE if (w > LONG) 8:
29: withCallingHandlers(code, error = function (e) 43: prefix <- paste0(prefix, "\n ")46: rlang::entrace(e), message = function (cnd) system.time({}, handlers)in_input_dir(evaluate(code, envir = env, new_device = FALSE, model <- mi$model
call_block(x) } result <- NULL keep_warning = if (is.numeric(options$warning)) TRUE else options$warning,
19: keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
{ else prefix <- "Error : "33: parallel::mclapply(miList, runModel, mc.cores = numCores) msg <- paste0(prefix, conditionMessage(e), "\n") tryCatch({
doWithOneRestart(return(expr), restart)
34: 20: withOneRestart(expr, restarts[[1L]]) watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, invokeRestart("muffleMessage")
47: process_group(group)
.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))})48: }}, warning = function (cnd) withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
{
44: eng_r(options)25:
45: block_exec(params)logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
error = function(e) { "brand"), scalePar = "price", numMultiStarts = 10)
26: eval(expr, envir)
27: eval(expr, envir)
mi = mi, opts = mi$options)46: if (progress && is.function(pb$interrupt)) 28: 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
}, error = function(e) {withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) 35: 17: if (getOption("warn") >= 2 || getOption("warn") < 0) { }){withRestartList(expr, restarts[-nr]) pb$interrupt() watcher$capture_plot_and_output()FUN(X[[i]], ...) if (!is.null(result)) { return() model$fail <- FALSE if (on_message$capture) {
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: call_block(x)
if (is_R_CMD_build() || is_R_CMD_check())
model$coefficients <- result$solution watcher$push(cnd)47: error <<- format(e) })
process_group(group) }
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { watcher$capture_plot_and_output() if (on_warning$capture) { if (progress && is.function(pb$interrupt)) 18: model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$messagelapply(seq_len(cores), inner.do)withRestartList(expr, restarts) }
19: cnd <- sanitize_call(cnd)49: pb$interrupt()
}with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), parallel::mclapply(miList, runModel, mc.cores = numCores) if (on_message$silence) {}) if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
watcher$push(cnd) error = function(e) {
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), if (progress && is.function(pb$interrupt)) 20:
9: FUN(X[[i]], ...) pb$interrupt()39: withRestarts(with_handlers({ for (expr in tle$exprs) { invokeRestart("muffleMessage")withCallingHandlers(expr, warning = function(w) if (inherits(w, } ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE
} if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd)}, warning = function (cnd) classes)) tryInvokeRestart("muffleWarning")) watcher$push(cnd) error = function(e) {10: }, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) {
if (progress && is.function(pb$interrupt)) switch(on_error, continue = invokeRestart("eval_continue"), pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) if (is_R_CMD_build() || is_R_CMD_check()) call <- conditionCall(e)
stop = invokeRestart("eval_stop"), error = NULL)})
30: if (!is.null(call)) { }), list(rlang_trace_top_env = knit_global())){ error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }21: eval(call)
31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { if (identical(call[[1L]], quote(doTryCatch))) xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))41:
call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L)
evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, 50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)22: error = function(e) { ev <- withVisible(eval(expr, envir))
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
withCallingHandlers(expr, message = function(c) if (inherits(c, watcher$capture_plot_and_output()}, error = function (cnd) keep_message = if (is.numeric(options$message)) TRUE else options$message, classes)) tryInvokeRestart("muffleMessage")) watcher$print_value(ev$value, ev$visible, envir)54: vweave_rmarkdown(...)
prefix <- paste("Error in", dcall, ": "){ watcher$capture_plot_and_output() LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (is.na(w)) 55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers) cnd <- sanitize_call(cnd) } stop_on_error = if (is.numeric(options$error)) options$error else { TRUE if (progress && is.function(pb$interrupt)) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], watcher$push(cnd)}, handlers)
switch(on_error, continue = invokeRestart("eval_continue"), type = "b")
59: pb$interrupt() stop = invokeRestart("eval_stop"), error = NULL)33: })
30: eval(call)
31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
35: 23: if (options$error && options$include) tryCatch({ if (w > LONG) engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { prefix <- paste0(prefix, "\n ")withRestartList(expr, restarts[-nr]) if (is_R_CMD_build() || is_R_CMD_check()) doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
}
35: 0L else 2L }, output_handler = knit_handlers(options$render, options))36: error <<- format(e)
withRestartList(expr, restarts[-nr]) else prefix <- "Error : "suppressMessages(suppressWarnings(parallel::mclapply(miList, texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) } msg <- paste0(prefix, conditionMessage(e), "\n") runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)doWithOneRestart(return(expr), restart) .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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))42:
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)}, error = function(e) {in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: block_exec(params)
46: call_block(x)
OK <<- FALSE47: message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("basic_usage.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "basic_usage", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211ccb2701.rds")
An irrecoverable exception occurred. R is aborting now ...
26: eval(expr, envir)
27: eval(expr, envir)
process_group(group)20: }), list(rlang_trace_top_env = knit_global())), function(loc) {36: 37: setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
withCallingHandlers(expr, warning = function(w) if (inherits(w, 52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), doWithOneRestart(return(expr), restart)28:
classes)) tryInvokeRestart("muffleWarning"))
output_dir = getwd(), ...)
54: withVisible(eval(expr, envir))48: vweave_rmarkdown(...)21: 41:
evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 37:
29: keep_message = if (is.numeric(options$message)) TRUE else options$message, error = function(e) {suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) stop_on_error = if (is.numeric(options$error)) options$error else {
withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE if (progress && is.function(pb$interrupt)) 55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
22: withCallingHandlers(expr, message = function(c) if (inherits(c, if (options$error && options$include) classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)
26: 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: {
58: tryCatchList(expr, classes, parentenv, handlers) watcher$capture_plot_and_output() pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt()}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE) if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
31: eval(call)
eval(expr, envir)
block_exec(params) if (is_R_CMD_build() || is_R_CMD_check())
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("basic_usage.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "basic_usage", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211ccb2701.rds")
An irrecoverable exception occurred. R is aborting now ...
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)40: error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {
evaluate::evaluate(...)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: block_exec(params)
46: call_block(x)
46:
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage")43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: block_exec(params)
46: call_block(x)
47: process_group(group)
}47: }, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt()call_block(x)
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: 60: tools:::.buildOneVignette("basic_usage.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "basic_usage", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211ccb2701.rds")
An irrecoverable exception occurred. R is aborting now ...
doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: tryCatchList(expr, classes, parentenv, handlers)
47: process_file(text, output)process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check())
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("basic_usage.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "basic_usage", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211ccb2701.rds")
An irrecoverable exception occurred. R is aborting now ...
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: 31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("basic_usage.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "basic_usage", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211ccb2701.rds")
An irrecoverable exception occurred. R is aborting now ...
error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55:
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
engine$weave(file, quiet = quiet, encoding = enc)39: withRestarts(with_handlers({
56: for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) }doTryCatch(return(expr), name, parentenv, handler) TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
}, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)60: tools:::.buildOneVignette("basic_usage.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "basic_usage", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211ccb2701.rds")
An irrecoverable exception occurred. R is aborting now ...
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: block_exec(params)
46: call_block(x)
47: process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("basic_usage.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "basic_usage", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211ccb2701.rds")
An irrecoverable exception occurred. R is aborting now ...
Quitting from basic_usage.Rmd:82-91 [unnamed-chunk-7]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
<error/rlang_error>
Error in `names(x) <- value`:
! 'names' attribute [3] must be the same length as the vector [0]
---
Backtrace:
▆
1. └─logitr::logitr(...)
2. └─logitr:::getMultistartSummary(allModels)
3. └─base::`colnames<-`(...)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Error: processing vignette 'basic_usage.Rmd' failed with diagnostics:
'names' attribute [3] must be the same length as the vector [0]
--- failed re-building ‘basic_usage.Rmd’
--- re-building ‘benchmark.Rmd’ using rmarkdown
--- finished re-building ‘benchmark.Rmd’
--- re-building ‘convergence.Rmd’ using rmarkdown
--- finished re-building ‘convergence.Rmd’
--- re-building ‘data_formatting.Rmd’ using rmarkdown
--- finished re-building ‘data_formatting.Rmd’
--- re-building ‘interactions.Rmd’ using rmarkdown
--- finished re-building ‘interactions.Rmd’
--- re-building ‘mnl_models.Rmd’ using rmarkdown
*** caught segfault ***
address 0x110, cause 'invalid permissions'
*** caught segfault ***
address 0x110, cause 'invalid permissions'
*** caught segfault ***
address 0x110, cause 'invalid permissions'
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: 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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate)
26: eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: 30: eval(call)
31: eval(call)
32: with_handlers({ for (expr in tle$exprs) {eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: 5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) {
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: 37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUEnloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, }, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { model$fail <- FALSE
*** caught segfault ***
address 0x110, cause 'invalid permissions'
model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }}) if (options$error && options$include) 0L mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 7: 9: FUN(X[[i]], ...)
10: tryCatch({lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
0L result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: block_exec(params)
12: 46: call_block(x)tryCatchOne(expr, names, parentenv, handlers[[1L]])
47: process_group(group)
8: system.time({
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }) model <- mi$model13: tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) {
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) call <- conditionCall(e) error <<- format(e) result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule())) }) if (!is.null(call)) {}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message } if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L)
dcall <- deparse(call, nlines = 1L)51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 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())53: })rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(),
} output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e))) 9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
invisible(structure(msg, class = "try-error", condition = e))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: })
60: tools:::.buildOneVignette("mnl_models.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a2127ba2c9b.rds")
An irrecoverable exception occurred. R is aborting now ...
11: doTryCatch(return(expr), name, parentenv, handler)
FUN(X[[i]], ...)12:
tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) { call <- conditionCall(e)18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20:
Traceback:
withCallingHandlers(expr, warning = function(w) if (inherits(w, if (!is.null(call)) { 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...) classes)) tryInvokeRestart("muffleWarning"))
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]]
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: 5: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, 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") runModel, mc.cores = numCores)))tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7:
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate)
26: eval(expr, envir) 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"))) {
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) cat(msg, file = outFile)tryCatch({rlang::entrace(e), message = function (cnd) .Internal(printDeferredWarnings()){ watcher$capture_plot_and_output() if (on_message$capture) { result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) {system.time({ } return() } invisible(structure(msg, class = "try-error", condition = e)) watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) }
*** caught segfault ***
address 0x110, cause 'invalid permissions'
model <- mi$model result <- NULL if (on_warning$silence) { tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) {})
15: model$fail <- FALSEtry(lapply(X = S, FUN = FUN, ...), silent = TRUE) model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message } invokeRestart("muffleWarning")})
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores) }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd)
20: 13: tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) { watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
30: eval(call)
31: eval(call)25:
call <- conditionCall(e)logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", 32: "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate) if (!is.null(call)) {with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
26: eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ") LONG <- 75L
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: 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")withRestartList(expr, restarts)
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE .Internal(seterrmessage(msg[1L]))}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) watcher$capture_plot_and_output()40: if (on_message$capture) { watcher$push(cnd)
evaluate::evaluate(...)16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17:
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) FUN(X[[i]], ...) 0L }
Traceback:
if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { else 2L 1:
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) if (getOption("warn") >= 2 || getOption("warn") < 0) {mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
*** caught segfault ***
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective,
mi = mi, opts = mi$options)
21: return() 4: }suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) watcher$capture_plot_and_output() }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: if (on_warning$capture) {
doTryCatch(return(expr), name, parentenv, handler) cnd <- sanitize_call(cnd)address 0x110, cause 'invalid permissions'
5: watcher$push(cnd)tryCatchOne(expr, names, parentenv, handlers[[1L]])22: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44:
} if (on_warning$silence) { invokeRestart("muffleWarning")withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
6: 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))tryCatchList(expr, classes, parentenv, handlers)
eng_r(options) }24: }, error = function (cnd) runMultistart(modelInputs) 7: tryCatch({
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, {
watcher$capture_plot_and_output() "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate)45: mi = mi, opts = mi$options)block_exec(params) cnd <- sanitize_call(cnd)}, error = function(e) {
46: call_block(x)})
26: 47: watcher$push(cnd)
eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) process_group(group) 8: switch(on_error, continue = invokeRestart("eval_continue"),
stop = invokeRestart("eval_stop"), error = NULL)})
{ if (getOption("warn") >= 2 || getOption("warn") < 0) {48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), system.time({ error = function(e) {30: if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) eval(call)
model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 31: error = function(e) {eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) return() }})
} watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") if (progress && is.function(pb$interrupt)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE pb$interrupt() }}, error = function (cnd) 9: if (is_R_CMD_build() || is_R_CMD_check()) {}, handlers)
33: doWithOneRestart(return(expr), restart) error <<- format(e) watcher$capture_plot_and_output() }), list(rlang_trace_top_env = knit_global()))
Traceback:
FUN(X[[i]], ...) 1:
*** caught segfault ***
address 0x110, cause 'invalid permissions'
mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) cnd <- sanitize_call(cnd)
34: 10: lapply(X = S, FUN = FUN, ...)
withOneRestart(expr, restarts[[1L]])
2: 50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) 11: watcher$push(cnd) pb$interrupt()
doTryCatch(return(expr), name, parentenv, handler)
35: switch(on_error, continue = invokeRestart("eval_continue"), eval_f(x0, ...) if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) {withRestartList(expr, restarts[-nr])
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 12:
tryCatchOne(expr, names, parentenv, handlers[[1L]])36: stop = invokeRestart("eval_stop"), error = NULL)})
30:
doWithOneRestart(return(expr), restart)
13: setwd(wd)tryCatchList(expr, classes, parentenv, handlers)eval(call)
write_utf8(res, output %n% stdout())37: paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51:
*** caught segfault ***
14:
address 0x110, cause 'invalid permissions'
process_file(text, output) mi = mi, opts = mi$options)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)tryCatch(expr, error = function(e) {
31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
35:
*** caught segfault ***
withRestartList(expr, restarts[-nr]) 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, ": ")
36: doWithOneRestart(return(expr), restart)
37: address 0x110, cause 'invalid permissions'
38: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts) 4: withRestartList(expr, restarts) 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)
doTryCatch(return(expr), name, parentenv, handler) .Internal(printDeferredWarnings())
}
39: 39: 5: withRestarts(with_handlers({54: for (expr in tle$exprs) {vweave_rmarkdown(...)withRestarts(with_handlers({tryCatchOne(expr, names, parentenv, handlers[[1L]])
ev <- withVisible(eval(expr, envir))
Traceback:
for (expr in tle$exprs) {
invisible(structure(msg, class = "try-error", condition = e))55: ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) watcher$capture_plot_and_output() 1: }engine$weave(file, quiet = quiet, encoding = enc)
mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 6: 56: })tryCatchList(expr, classes, parentenv, handlers)doTryCatch(return(expr), name, parentenv, handler) TRUE watcher$print_value(ev$value, ev$visible, envir)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, }, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
}40: evaluate::evaluate(...)57: TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else {15:
tryCatchOne(expr, names, parentenv, handlers[[1L]])try(lapply(X = S, FUN = FUN, ...), silent = TRUE) mi = mi, opts = mi$options)
41:
2:
evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, 16: 58: tryCatchList(expr, classes, parentenv, handlers)
59: if (options$error && options$include) keep_message = if (is.numeric(options$message)) TRUE else options$message, 0LsendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
*** caught segfault ***
stop_on_error = if (is.numeric(options$error)) options$error else {tryCatch({address 0x110, cause 'invalid permissions'
eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
engine$weave(file, quiet = quiet, encoding = enc) 4: doTryCatch(return(expr), name, parentenv, handler)
5:
Traceback:
else 2L }, output_handler = knit_handlers(options$render, options))
42:
}, error = function(e) {17: in_dir(input_dir(), expr)
FUN(X[[i]], ...)43: })
if (options$error && options$include) in_input_dir(evaluate(code, envir = env, new_device = FALSE, tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { 0L
Traceback:
else 2L keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: }, output_handler = knit_handlers(options$render, options))
1:
8: eng_r(options)42:
setwd(startdir)18: in_dir(input_dir(), expr) model$fail <- FALSE45: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)lapply(seq_len(cores), inner.do)
1: output <- find_vignette_product(name, by = "weave", engine = engine)block_exec(params)
system.time({43: model$coefficients <- result$solutionin_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model <- mi$model
if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) {
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) model$status <- result$status
model$message <- result$message 7: 19: OK <<- FALSE if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
Traceback:
tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 2: parallel::mclapply(miList, runModel, mc.cores = numCores)eval_f(x0, ...)13: tryCatchList(expr, classes, parentenv, handlers)
} mi = mi, opts = mi$options)
}, error = function(e) { 0L46: 20:
14: else 2L}) 1:
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 3: tryCatch(expr, error = function(e) {withCallingHandlers(expr, warning = function(w) if (inherits(w, 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 mi = mi, opts = mi$options)}) }, output_handler = knit_handlers(options$render, options)))
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...) message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", classes)) tryInvokeRestart("muffleWarning"))call_block(x)nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective)
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
model$iterations <- result$iterations sm <- strsplit(conditionMessage(e), "\n")[[1L]]11: 47: process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) {22: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
model$status <- result$status file, conditionMessage(e))) }, error = function(e) { 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()) }})doTryCatch(return(expr), name, parentenv, handler) model$message <- result$message
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: 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()) })44: setwd(wd)
write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
} invisible(structure(msg, class = "try-error", condition = e)) if (!is.null(result)) {eng_r(options)51: withCallingHandlers(expr, message = function(c) if (inherits(c,
model$fail <- FALSE 2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
60: })}) classes)) tryInvokeRestart("muffleMessage")) 6:
}tools:::.buildOneVignette("mnl_models.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", invisible(structure(msg, class = "try-error", condition = e))})
model$coefficients <- result$solution
tryCatchList(expr, classes, parentenv, handlers)
process_file(text, output)15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate)
26: eval(expr, envir)
27: eval(expr, envir)
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: 23: 45: model$logLik <- as.numeric(-1 * result$objective)
withCallingHandlers(expr, message = function(c) if (inherits(c, 52:
suppressMessages(suppressWarnings(parallel::mclapply(miList, model$iterations <- result$iterations TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a2127ba2c9b.rds") model$status <- result$status model$message <- result$message }
An irrecoverable exception occurred. R is aborting now ...
})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: classes)) tryInvokeRestart("muffleMessage"))block_exec(params)
46: call_block(x)
47: process_group(group)
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, 7: 28: doTryCatch(return(expr), name, parentenv, handler)withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) {
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
tryCatch({ runModel, mc.cores = numCores))) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) 9: runModel, mc.cores = numCores)))
cnd <- sanitize_call(cnd)FUN(X[[i]], ...)
14: 48: 53: watcher$push(cnd)24: }, error = function(e) {tryCatch(expr, error = function(e) {withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 24: }runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate)
rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), call <- conditionCall(e) if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
runMultistart(modelInputs)26: output_dir = getwd(), ...) }) if (!is.null(call)) { if (!is.null(result)) {10: if (identical(call[[1L]], quote(doTryCatch))) eval(expr, envir)
27: eval(expr, envir)
lapply(X = S, FUN = FUN, ...)31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output()28:
watcher$print_value(ev$value, ev$visible, envir) model$fail <- FALSE
withVisible(eval(expr, envir))
call <- sys.call(-4L) model$coefficients <- result$solution54: 25: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) {logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate)
26: eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") dcall <- deparse(call, nlines = 1L) model$logLik <- as.numeric(-1 * result$objective) prefix <- paste("Error in", dcall, ": ") } OK <<- FALSE
error = function(e) { model$iterations <- result$iterations if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) TRUE } message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", 29: file, conditionMessage(e)))})
60: tools:::.buildOneVignette("mnl_models.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a2127ba2c9b.rds")
An irrecoverable exception occurred. R is aborting now ...
model$status <- result$status model$message <- result$message }})
11: withCallingHandlers(code, error = function (e) LONG <- 75L }), list(rlang_trace_top_env = knit_global())), function(loc) { 9: setwd(wd)FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: 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)) }, warning = function (cnd) sm <- strsplit(conditionMessage(e), "\n")[[1L]]{ if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
31: 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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, rlang::entrace(e), message = function (cnd) eval(call)doTryCatch(return(expr), name, parentenv, handler)}, handlers) write_utf8(res, output %n% stdout()) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], {
paste0("\nQuitting from ", loc, if (!is.null(error)) type = "b")12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, 32: paste0("\n", rule(), error, "\n", rule())) if (w > LONG) }, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) watcher$capture_plot_and_output() classes)) tryInvokeRestart("muffleMessage")) if (identical(call[[1L]], quote(doTryCatch))) prefix <- paste0(prefix, "\n ")
call <- sys.call(-4L) } 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()) } if (on_message$capture) { 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)) 33: with_handlers({
for (expr in tle$exprs) { watcher$push(cnd) ev <- withVisible(eval(expr, envir))doWithOneRestart(return(expr), restart) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], 51: invisible(structure(msg, class = "try-error", condition = e)) } watcher$capture_plot_and_output() if (on_message$silence) {23: process_file(text, output)}) type = "b") watcher$print_value(ev$value, ev$visible, envir) if (w > LONG) prefix <- paste0(prefix, "\n ") }suppressMessages(suppressWarnings(parallel::mclapply(miList,
runModel, mc.cores = numCores))) invokeRestart("muffleMessage") else prefix <- "Error : " }
TRUE
52: 34: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) } msg <- paste0(prefix, conditionMessage(e), "\n")}, handlers)15: withOneRestart(expr, restarts[[1L]])24: }, warning = function (cnd) .Internal(seterrmessage(msg[1L]))
try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
runMultistart(modelInputs)35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) if (!silent && isTRUE(getOption("show.error.messages"))) {
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate)
26: eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) }33:
{53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
if (on_warning$silence) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd)
watcher$capture_plot_and_output()16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) watcher$print_value(ev$value, ev$visible, envir) invokeRestart("muffleWarning")58: cat(msg, file = outFile)doWithOneRestart(return(expr), restart) } } }tryCatchList(expr, classes, parentenv, handlers) .Internal(printDeferredWarnings())
if (on_warning$silence) { TRUE invokeRestart("muffleWarning")
}}, error = function (cnd)
}21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate)
26: eval(expr, envir)
27: eval(expr, envir) invisible(structure(msg, class = "try-error", condition = e))}, error = function (cnd) 34: 59: }, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)tryCatch({{ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir)
output <- find_vignette_product(name, by = "weave", engine = engine){}) watcher$capture_plot_and_output()withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
watcher$capture_plot_and_output()28: cnd <- sanitize_call(cnd)40: evaluate::evaluate(...)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, if (!have.makefile && vignette_is_tex(output)) {16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: watcher$push(cnd)37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
lapply(seq_len(cores), inner.do)withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) {
19: parallel::mclapply(miList, runModel, mc.cores = numCores) cnd <- sanitize_call(cnd) keep_message = if (is.numeric(options$message)) TRUE else options$message, watcher$push(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), OK <<- FALSE switch(on_error, continue = invokeRestart("eval_continue"),
20: stop = invokeRestart("eval_stop"), error = NULL) message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", })
30: eval(call) stop_on_error = if (is.numeric(options$error)) options$error else { } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) }withCallingHandlers(expr, warning = function(w) if (inherits(w, if (options$error && options$include) stop = invokeRestart("eval_stop"), error = NULL) if (on_warning$silence) { invokeRestart("muffleWarning") 0L
31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { file, conditionMessage(e)))})
60: tools:::.buildOneVignette("mnl_models.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a2127ba2c9b.rds")
An irrecoverable exception occurred. R is aborting now ...
else 2L }, output_handler = knit_handlers(options$render, options))
42: classes)) tryInvokeRestart("muffleWarning"))})
30: eval(call)
31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate)
26: eval(expr, envir)
27: 37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { }
38: withRestartList(expr, restarts)
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output()38: watcher$capture_plot_and_output()in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, withRestartList(expr, restarts) ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
if (on_message$capture) { keep_warning = if (is.numeric(options$warning)) TRUE else options$warning,
watcher$push(cnd)}, error = function (cnd) 34: watcher$print_value(ev$value, ev$visible, envir) keep_message = if (is.numeric(options$message)) TRUE else options$message, }39: } stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: block_exec(params)withRestarts(with_handlers({ TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
if (on_message$silence) { for (expr in tle$exprs) {
withOneRestart(expr, restarts[[1L]])
35: ev <- withVisible(eval(expr, envir)){withRestartList(expr, restarts[-nr]) invokeRestart("muffleMessage") watcher$capture_plot_and_output()46: 40: watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd)
watcher$print_value(ev$value, ev$visible, envir)call_block(x)evaluate::evaluate(...)
} }
47: process_group(group)41: }, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd)36: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, TRUE switch(on_error, continue = invokeRestart("eval_continue"), keep_message = if (is.numeric(options$message)) TRUE else options$message, watcher$push(cnd)doWithOneRestart(return(expr), restart) stop = invokeRestart("eval_stop"), error = NULL)
48: })
}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts) }withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),
if (on_warning$silence) { invokeRestart("muffleWarning") } error = function(e) {}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"),
40: evaluate::evaluate(...)
39: 30: eval(call)
31: eval(call) stop_on_error = if (is.numeric(options$error)) options$error else { if (progress && is.function(pb$interrupt)) if (options$error && options$include) withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) pb$interrupt() 0L41:
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() if (is_R_CMD_build() || is_R_CMD_check()) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
stop = invokeRestart("eval_stop"), error = NULL)evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, })
30: eval(call)
31: eval(call)
32: error <<- format(e) else 2L })with_handlers({ for (expr in tle$exprs) {40:
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() ev <- withVisible(eval(expr, envir)) watcher$print_value(ev$value, ev$visible, envir) keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2Levaluate::evaluate(...) }, output_handler = knit_handlers(options$render, options)) watcher$capture_plot_and_output()
}42: }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr) TRUEin_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, watcher$print_value(ev$value, ev$visible, envir)}, handlers) if (is_R_CMD_build() || is_R_CMD_check())
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else {
keep_message = if (is.numeric(options$message)) TRUE else options$message, error <<- format(e) stop_on_error = if (is.numeric(options$error)) options$error else {43: }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt()33: } if (options$error && options$include) in_input_dir(evaluate(code, envir = env, new_device = FALSE, 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L TRUE if (is_R_CMD_build() || is_R_CMD_check()) if (options$error && options$include) keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, error <<- format(e)doWithOneRestart(return(expr), restart)}, handlers)
33: }), list(rlang_trace_top_env = knit_global())), function(loc) { 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: block_exec(params)
46: call_block(x)
47: setwd(wd) else 2L stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0LdoWithOneRestart(return(expr), restart) write_utf8(res, output %n% stdout())
34: withOneRestart(expr, restarts[[1L]])
35: process_group(group)
}, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: block_exec(params)
46: call_block(x)
47: withRestartList(expr, restarts[-nr])
paste0("\nQuitting from ", loc, if (!is.null(error)) 36: process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {34: doWithOneRestart(return(expr), restart)
else 2L
48: withOneRestart(expr, restarts[[1L]])37:
paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) if (progress && is.function(pb$interrupt)) process_file(text, output) }, output_handler = knit_handlers(options$render, options)))35: withRestartList(expr, restarts[-nr]) pb$interrupt()
36: doWithOneRestart(return(expr), restart)
44: eng_r(options)
38: withRestartList(expr, restarts)
if (is_R_CMD_build() || is_R_CMD_check()) withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {
if (progress && is.function(pb$interrupt)) error <<- format(e)52: 39: })
45: block_exec(params)
46: call_block(x)
withRestarts(with_handlers({knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)37:
53: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), pb$interrupt()rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(),
for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output()47: watcher$print_value(ev$value, ev$visible, envir) output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
} TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...) if (is_R_CMD_build() || is_R_CMD_check()) process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {
38: error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) withRestartList(expr, restarts) error <<- format(e)55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("mnl_models.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a2127ba2c9b.rds") paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
41:
53: 39: })withRestarts(with_handlers({An irrecoverable exception occurred. R is aborting now ...
rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) if (progress && is.function(pb$interrupt)) 59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("mnl_models.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a2127ba2c9b.rds")
An irrecoverable exception occurred. R is aborting now ...
pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { 0L if (options$error && options$include)
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) 0Lwith_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() else 2L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: block_exec(params)
46: call_block(x)
47: process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }) }, output_handler = knit_handlers(options$render, options))) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc) if (is_R_CMD_build() || is_R_CMD_check())
error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }49:
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("mnl_models.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a2127ba2c9b.rds")
An irrecoverable exception occurred. R is aborting now ...
with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd)}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("mnl_models.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a2127ba2c9b.rds")
An irrecoverable exception occurred. R is aborting now ...
write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("mnl_models.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a2127ba2c9b.rds")
An irrecoverable exception occurred. R is aborting now ...
44: eng_r(options)
45: block_exec(params)
46: call_block(x)
47: process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("mnl_models.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a2127ba2c9b.rds")
An irrecoverable exception occurred. R is aborting now ...
Quitting from mnl_models.Rmd:85-98 [unnamed-chunk-9]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
<error/rlang_error>
Error in `names(x) <- value`:
! 'names' attribute [3] must be the same length as the vector [0]
---
Backtrace:
▆
1. └─logitr::logitr(...)
2. └─logitr:::getMultistartSummary(allModels)
3. └─base::`colnames<-`(...)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Error: processing vignette 'mnl_models.Rmd' failed with diagnostics:
'names' attribute [3] must be the same length as the vector [0]
--- failed re-building ‘mnl_models.Rmd’
--- re-building ‘mnl_models_weighted.Rmd’ using rmarkdown
*** caught segfault ***
address 0x110, cause 'invalid permissions'
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: 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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = cars_us, outcome = "choice", obsID = "obsnum", pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", "bev150", "american", "japanese", "chinese", "skorean", "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), scalePar = "price", robust = TRUE, numMultiStarts = 10)
26: eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: block_exec(params)
46: call_block(x)
47: process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))
*** caught segfault ***
address 0x110, cause 'invalid permissions'
})
60: tools:::.buildOneVignette("mnl_models_weighted.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models_weighted", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a21639996a8.rds")
An irrecoverable exception occurred. R is aborting now ...
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: 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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = cars_us, outcome = "choice", obsID = "obsnum", pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", "bev150", "american", "japanese", "chinese", "skorean", "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), scalePar = "price", robust = TRUE, numMultiStarts = 10)
26: eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: block_exec(params)
46: call_block(x)
47: process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("mnl_models_weighted.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models_weighted", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a21639996a8.rds")
An irrecoverable exception occurred. R is aborting now ...
*** caught segfault ***
address 0x110, cause 'invalid permissions'
*** caught segfault ***
address 0x110, cause 'invalid permissions'
*** caught segfault ***
address 0x110, cause 'invalid permissions'
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
9: FUN(X[[i]], ...) model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13:
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) { call <- conditionCall(e)
13: tryCatchList(expr, classes, parentenv, handlers)
14: 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], 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"))) { 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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
cat(msg, file = outFile) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21:
*** caught segfault ***
address 0x110, cause 'invalid permissions'
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: 19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25:
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: logitr(data = cars_us, outcome = "choice", obsID = "obsnum", pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", "bev150", "american", "japanese", "chinese", "skorean", "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), scalePar = "price", robust = TRUE, numMultiStarts = 10)
26: eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) }suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = cars_us, outcome = "choice", obsID = "obsnum", nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers) if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", "bev150", "american", "japanese", "chinese", "skorean", "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), scalePar = "price", robust = TRUE, numMultiStarts = 10) if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd)
7: tryCatch({
26: eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
{ watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
31: eval(call)
if (on_message$capture) { watcher$push(cnd) }32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { 8: system.time({ model <- mi$model result <- NULL if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) {33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]]) }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
model$message <- result$message }})
9: FUN(X[[i]], ...)
10: 31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE
35: withRestartList(expr, restarts[-nr])
lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
}, handlers)
33: doWithOneRestart(return(expr), restart)36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) }
Traceback:
39: 12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13:
*** caught segfault ***
address 0x110, cause 'invalid permissions'
tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) {withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
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") 4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
if (is.na(w)) 41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L 6: TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE) 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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)tryCatchList(expr, classes, parentenv, handlers)withCallingHandlers(expr, warning = function(w) if (inherits(w,
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, classes)) tryInvokeRestart("muffleWarning"))
*** caught segfault ***
keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L
address 0x110, cause 'invalid permissions'
21:
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: else 2L }, output_handler = knit_handlers(options$render, options)))
withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)40: evaluate::evaluate(...)
}, error = function(e) {
*** caught segfault ***
address 0x110, cause 'invalid permissions'
41: 23: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))suppressMessages(suppressWarnings(parallel::mclapply(miList, 44: eng_r(options)
45: block_exec(params)
runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)46: call_block(x)
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 47: process_group(group)
48: 0LwithCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) })
else 2L }, output_handler = knit_handlers(options$render, options)))
if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) model$logLik <- as.numeric(-1 * result$objective)44: eng_r(options) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check())
model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
25: logitr(data = cars_us, outcome = "choice", obsID = "obsnum", pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", "bev150", "american", "japanese", "chinese", "skorean", "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), 45: 9: error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: FUN(X[[i]], ...)
10: block_exec(params) scalePar = "price", robust = TRUE, numMultiStarts = 10)
lapply(X = S, FUN = FUN, ...)
11: 2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective,
doTryCatch(return(expr), name, parentenv, handler) mi = mi, opts = mi$options)
46:
26: eval(expr, envir)12: call_block(x)xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),
4: 47:
process_group(group)tryCatchOne(expr, names, parentenv, handlers[[1L]])
error = function(e) { if (progress && is.function(pb$interrupt))
doTryCatch(return(expr), name, parentenv, handler) pb$interrupt()27: eval(expr, envir) if (is_R_CMD_build() || is_R_CMD_check()) 13: 48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { error <<- format(e)
Traceback:
}), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) 1: tryCatchList(expr, classes, parentenv, handlers) paste0("\nQuitting from ", loc, if (!is.null(error)) if (progress && is.function(pb$interrupt)) mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check())
paste0("\n", rule(), error, "\n", rule())) 2: error <<- format(e)eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, }, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) })
Traceback:
1:
49: 51: 5: tryCatchOne(expr, names, parentenv, handlers[[1L]])process_file(text, output)mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) mi = mi, opts = mi$options)with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),
error = function(e) {14: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch)))
2: eval_f(x0, ...) 4: doTryCatch(return(expr), name, parentenv, handler)
5: call <- sys.call(-4L) if (progress && is.function(pb$interrupt))
28: 6:
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
52: dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ")tryCatchList(expr, classes, parentenv, handlers)tryCatchOne(expr, names, parentenv, handlers[[1L]]) pb$interrupt()withVisible(eval(expr, envir)) if (is_R_CMD_build() || is_R_CMD_check()) 4:
error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: 7: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt()doTryCatch(return(expr), name, parentenv, handler)knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)tryCatch({ if (is_R_CMD_build() || is_R_CMD_check()) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, LONG <- 75L
53: sm <- strsplit(conditionMessage(e), "\n")[[1L]] 5: error <<- format(e)rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(),
tryCatchOne(expr, names, parentenv, handlers[[1L]]) w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w")29: if (is.na(w)) withCallingHandlers(code, error = function (e) mi = mi, opts = mi$options)
rlang::entrace(e), message = function (cnd) }), list(rlang_trace_top_env = knit_global())), function(loc) { 6: tryCatchList(expr, classes, parentenv, handlers)
7: 6: w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], {tryCatch({ watcher$capture_plot_and_output() output_dir = getwd(), ...) if (on_message$capture) { result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, setwd(wd) type = "b") write_utf8(res, output %n% stdout()) mi = mi, opts = mi$options) if (w > LONG) watcher$push(cnd)}, error = function(e) { paste0("\nQuitting from ", loc, if (!is.null(error)) }
prefix <- paste0(prefix, "\n ") paste0("\n", rule(), error, "\n", rule()))54: }tryCatchList(expr, classes, parentenv, handlers) else prefix <- "Error : "vweave_rmarkdown(...) msg <- paste0(prefix, conditionMessage(e), "\n")})
8: .Internal(seterrmessage(msg[1L]))
system.time({ if (!silent && isTRUE(getOption("show.error.messages"))) {55: }, error = function(e) {engine$weave(file, quiet = quiet, encoding = enc)}) model <- mi$model
}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, cat(msg, file = outFile)
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})56: doTryCatch(return(expr), name, parentenv, handler)
57: .Internal(printDeferredWarnings())
mi = mi, opts = mi$options) result <- NULL
if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) }, error = function(e) {
*** caught segfault ***
} tryCatch({ 9: FUN(X[[i]], ...)51: invisible(structure(msg, class = "try-error", condition = e)){ if (getOption("warn") >= 2 || getOption("warn") < 0) { return()})address 0x110, cause 'invalid permissions'
} watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
31: eval(call)
})tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) {10: texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine)
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("mnl_models_weighted.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models_weighted", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a21639996a8.rds")
An irrecoverable exception occurred. R is aborting now ...
32: with_handlers({process_file(text, output) mi = mi, opts = mi$options)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations mi = mi, opts = mi$options) if (!have.makefile && vignette_is_tex(output)) { for (expr in tle$exprs) {
lapply(X = S, FUN = FUN, ...) model$status <- result$status texi2pdf(file = output, clean = FALSE, quiet = quiet)15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
11: doTryCatch(return(expr), name, parentenv, handler)
12: output <- find_vignette_product(name, by = "texi2pdf", tryCatchOne(expr, names, parentenv, handlers[[1L]])
ev <- withVisible(eval(expr, envir)) engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("mnl_models_weighted.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models_weighted", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a21639996a8.rds")
An irrecoverable exception occurred. R is aborting now ...
watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } model$message <- result$message
Traceback:
17: 13: } TRUE }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution 1: }, handlers)tryCatchList(expr, classes, parentenv, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])})
14: 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]]mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
9:
2: eval_f(x0, ...)FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: 9: classes)) tryInvokeRestart("muffleMessage"))FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler) w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w")tryCatchList(expr, classes, parentenv, handlers)
38:
12: if (is.na(w))
23: w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], withRestartList(expr, restarts)14: 3: tryCatchOne(expr, names, parentenv, handlers[[1L]])nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)suppressMessages(suppressWarnings(parallel::mclapply(miList,
tryCatch(expr, error = function(e) { type = "b") runModel, mc.cores = numCores)))
call <- conditionCall(e)13: 39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } if (w > LONG) if (!is.null(call)) {tryCatchList(expr, classes, parentenv, handlers)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: 24: if (identical(call[[1L]], quote(doTryCatch))) TRUE
tryCatch({runMultistart(modelInputs)
14: }, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
25: tryCatch(expr, error = function(e) { call <- conditionCall(e) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, prefix <- paste0(prefix, "\n ")40: if (!is.null(call)) { } if (identical(call[[1L]], quote(doTryCatch))) mi = mi, opts = mi$options)logitr(data = cars_us, outcome = "choice", obsID = "obsnum", else prefix <- "Error : "}, error = function(e) {evaluate::evaluate(...) msg <- paste0(prefix, conditionMessage(e), "\n") call <- sys.call(-4L) call <- sys.call(-4L) pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100",
dcall <- deparse(call, nlines = 1L) "bev150", "american", "japanese", "chinese", "skorean", dcall <- deparse(call, nlines = 1L)41: .Internal(seterrmessage(msg[1L]))}) prefix <- paste("Error in", dcall, ": ")evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, 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 ") }
if (!silent && isTRUE(getOption("show.error.messages"))) { "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), prefix <- paste("Error in", dcall, ": ") scalePar = "price", robust = TRUE, numMultiStarts = 10) 8: LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (is.na(w))
system.time({ else prefix <- "Error : " keep_message = if (is.numeric(options$message)) TRUE else options$message, 26: eval(expr, envir)
27: model <- mi$model stop_on_error = if (is.numeric(options$error)) options$error else { w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], eval(expr, envir) if (options$error && options$include) 0L result <- NULL type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") else 2L tryCatch({ }, output_handler = knit_handlers(options$render, options)) } result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective,
42: in_dir(input_dir(), expr)
mi = mi, opts = mi$options)43: msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile)28: }, error = function(e) { else prefix <- "Error : "in_input_dir(evaluate(code, envir = env, new_device = FALSE, .Internal(printDeferredWarnings()) msg <- paste0(prefix, conditionMessage(e), "\n") cat(msg, file = outFile) } keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, })withVisible(eval(expr, envir)) .Internal(printDeferredWarnings()) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations } .Internal(seterrmessage(msg[1L]))
if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) invisible(structure(msg, class = "try-error", condition = e)) stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: invisible(structure(msg, class = "try-error", condition = e))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))eng_r(options)
29: model$status <- result$status .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e)) model$message <- result$messagewithCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd)
}{ watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) }})
45: block_exec(params)})
}) if (on_message$silence) {15:
17: invokeRestart("muffleMessage")FUN(X[[i]], ...)try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 9: }
46: call_block(x)
47: process_group(group)FUN(X[[i]], ...)15:
try(lapply(X = S, FUN = FUN, ...), silent = TRUE)}, warning = function (cnd)
16:
10: 48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))lapply(X = S, FUN = FUN, ...)
error = function(e) {17: FUN(X[[i]], ...)
11: 18:
{ if (getOption("warn") >= 2 || getOption("warn") < 0) {17: if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }) return()doTryCatch(return(expr), name, parentenv, handler)
}lapply(seq_len(cores), inner.do)
19: 18: 12: tryCatchOne(expr, names, parentenv, handlers[[1L]])parallel::mclapply(miList, runModel, mc.cores = numCores) watcher$capture_plot_and_output()
13: tryCatchList(expr, classes, parentenv, handlers)
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),
FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: lapply(seq_len(cores), inner.do)
error = function(e) {20: if (progress && is.function(pb$interrupt)) if (on_warning$capture) { pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) cnd <- sanitize_call(cnd) error <<- format(e) }), list(rlang_trace_top_env = knit_global())) watcher$push(cnd)withCallingHandlers(expr, warning = function(w) if (inherits(w,
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),
}14: parallel::mclapply(miList, runModel, mc.cores = numCores)tryCatch(expr, error = function(e) {
call <- conditionCall(e) if (on_warning$silence) { classes)) tryInvokeRestart("muffleWarning")) error = function(e) {
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage")) if (!is.null(call)) { invokeRestart("muffleWarning")
if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) {23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
19: setwd(wd)25: parallel::mclapply(miList, runModel, mc.cores = numCores) if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L)20:
}}, error = function (cnd) 20: withCallingHandlers(expr, warning = function(w) if (inherits(w, logitr(data = cars_us, outcome = "choice", obsID = "obsnum", {withCallingHandlers(expr, warning = function(w) if (inherits(w, watcher$capture_plot_and_output() write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) classes)) tryInvokeRestart("muffleWarning")) cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
classes)) tryInvokeRestart("muffleWarning")) pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", "bev150", "american", "japanese", "chinese", "skorean", "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), scalePar = "price", robust = TRUE, numMultiStarts = 10)
26: eval(expr, envir)
27: eval(expr, envir)
dcall <- deparse(call, nlines = 1L) paste0("\n", rule(), error, "\n", rule())) prefix <- paste("Error in", dcall, ": ")}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)28: withVisible(eval(expr, envir))21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
LONG <- 75L30: eval(call)
51: process_file(text, output)
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], 22: type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n")
52: 21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
.Internal(seterrmessage(msg[1L]))
31: 29: 23: if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile)withCallingHandlers(code, error = function (e) eval(call) .Internal(printDeferredWarnings())
rlang::entrace(e), message = function (cnd) knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
runModel, mc.cores = numCores)))
{ watcher$capture_plot_and_output()
25: logitr(data = cars_us, outcome = "choice", obsID = "obsnum", }24: pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", if (on_message$capture) {32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) "bev150", "american", "japanese", "chinese", "skorean", invisible(structure(msg, class = "try-error", condition = e)) "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), scalePar = "price", robust = TRUE, numMultiStarts = 10)
26: eval(expr, envir)}) watcher$push(cnd)
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
runMultistart(modelInputs)53: }
watcher$capture_plot_and_output()rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
if (on_message$silence) {54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])27: 25:
eval(expr, envir)16: logitr(data = cars_us, outcome = "choice", obsID = "obsnum", watcher$print_value(ev$value, ev$visible, envir)58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: } invokeRestart("muffleMessage")tools:::.buildOneVignette("mnl_models_weighted.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models_weighted", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a21639996a8.rds")sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
} pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", "bev150", "american", "japanese", "chinese", "skorean",
}, warning = function (cnd) { TRUE28: }, handlers) if (getOption("warn") >= 2 || getOption("warn") < 0) {An irrecoverable exception occurred. R is aborting now ...
"phevFastcharge", "bevFastcharge", "opCost", "accelTime"), 33: 17: withVisible(eval(expr, envir))doWithOneRestart(return(expr), restart) return()
29: FUN(X[[i]], ...)withCallingHandlers(code, error = function (e) }
rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } watcher$capture_plot_and_output() if (on_message$silence) { scalePar = "price", robust = TRUE, numMultiStarts = 10)
18: lapply(seq_len(cores), inner.do)
invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) {19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
34: 21: 26: if (on_warning$capture) { return()suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") } }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) watcher$capture_plot_and_output()suppressMessages(suppressWarnings(parallel::mclapply(miList, eval(expr, envir) switch(on_error, continue = invokeRestart("eval_continue"), runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
if (on_warning$capture) { stop = invokeRestart("eval_stop"), error = NULL)
27: eval(expr, envir) cnd <- sanitize_call(cnd)25: logitr(data = cars_us, outcome = "choice", obsID = "obsnum", pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", "bev150", "american", "japanese", "chinese", "skorean", "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), scalePar = "price", robust = TRUE, numMultiStarts = 10)})
30: eval(call)
31: withOneRestart(expr, restarts[[1L]])
eval(call)
watcher$push(cnd)26:
32: with_handlers({ for (expr in tle$exprs) {
eval(expr, envir)
28: ev <- withVisible(eval(expr, envir))27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) withVisible(eval(expr, envir))
35: withRestartList(expr, restarts[-nr]) }29: if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)
withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output()36: doWithOneRestart(return(expr), restart) watcher$capture_plot_and_output(){ watcher$capture_plot_and_output() if (on_message$capture) {})
watcher$push(cnd) watcher$print_value(ev$value, ev$visible, envir)37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) if (on_message$capture) { } TRUE}, handlers)
33:
doWithOneRestart(return(expr), restart)38:
34: } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return()30: withRestartList(expr, restarts) watcher$push(cnd)eval(call)withOneRestart(expr, restarts[[1L]]) }
}
39: watcher$capture_plot_and_output()31:
if (on_message$silence) {withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE) invokeRestart("muffleMessage")eval(call) if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }
35: }40: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
}, warning = function (cnd) evaluate::evaluate(...)}, error = function (cnd)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, 32: { stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include)
0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
with_handlers({43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, watcher$capture_plot_and_output() keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
{ for (expr in tle$exprs) { cnd <- sanitize_call(cnd) ev <- withVisible(eval(expr, envir))45: if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) {38: block_exec(params)
46: call_block(x)
47: withRestartList(expr, restarts)
watcher$push(cnd) watcher$capture_plot_and_output()process_group(group) switch(on_error, continue = invokeRestart("eval_continue"), cnd <- sanitize_call(cnd) stop = invokeRestart("eval_stop"), error = NULL)
39: withRestarts(with_handlers({}) watcher$push(cnd) } for (expr in tle$exprs) {
watcher$print_value(ev$value, ev$visible, envir) ev <- withVisible(eval(expr, envir))48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (on_warning$silence) { watcher$capture_plot_and_output() if (progress && is.function(pb$interrupt)) } watcher$print_value(ev$value, ev$visible, envir)30: eval(call)
31: eval(call)
32: TRUE pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {}, handlers)with_handlers({
if (progress && is.function(pb$interrupt)) } pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) invokeRestart("muffleWarning") for (expr in tle$exprs) { TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE) ev <- withVisible(eval(expr, envir))
40: evaluate::evaluate(...) watcher$capture_plot_and_output() }}, error = function (cnd) { watcher$print_value(ev$value, ev$visible, envir) watcher$capture_plot_and_output() } cnd <- sanitize_call(cnd)33: doWithOneRestart(return(expr), restart)
34: watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
withOneRestart(expr, restarts[[1L]]) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), TRUE error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt()
if (is_R_CMD_build() || is_R_CMD_check())
}, handlers)41: 35: 30: eval(call)
31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) error <<- format(e)
watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) }withRestartList(expr, restarts[-nr]) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))
TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])36: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, }, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)33:
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: doWithOneRestart(return(expr), restart) keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) doWithOneRestart(return(expr), restart)
0L
34:
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), 37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
else 2LwithOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
}, output_handler = knit_handlers(options$render, options)) output_dir = getwd(), ...)39: withOneRestart(expr, restarts[[1L]])39:
withRestarts(with_handlers({42: in_dir(input_dir(), expr)
for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir))
watcher$capture_plot_and_output()withRestarts(with_handlers({ watcher$print_value(ev$value, ev$visible, envir) } TRUE for (expr in tle$exprs) {35: withRestartList(expr, restarts[-nr])
36: }, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
ev <- withVisible(eval(expr, envir))
40: evaluate::evaluate(...)
41: watcher$capture_plot_and_output()54: watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)doWithOneRestart(return(expr), restart)
vweave_rmarkdown(...)43:
55: engine$weave(file, quiet = quiet, encoding = enc)
in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L
}, output_handler = knit_handlers(options$render, options)))
44: 56: 37: eng_r(options)evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 40: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: evaluate::evaluate(...)tryCatchList(expr, classes, parentenv, handlers)
45: 38:
block_exec(params)41: 0L59: else 2L }, output_handler = knit_handlers(options$render, options))evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning,
keep_message = if (is.numeric(options$message)) TRUE else options$message, tryCatch({42: stop_on_error = if (is.numeric(options$error)) options$error else { engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { if (options$error && options$include) withRestartList(expr, restarts) texi2pdf(file = output, clean = FALSE, quiet = quiet)
39: withRestarts(with_handlers({ for (expr in tle$exprs) { 0L
ev <- withVisible(eval(expr, envir)) else 2L46: watcher$capture_plot_and_output()in_dir(input_dir(), expr) }, output_handler = knit_handlers(options$render, options))call_block(x)
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L
47: }, output_handler = knit_handlers(options$render, options))) watcher$print_value(ev$value, ev$visible, envir)43:
process_group(group) output <- find_vignette_product(name, by = "texi2pdf", 44: eng_r(options)
engine = engine)48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) 45: block_exec(params) } } pb$interrupt()in_input_dir(evaluate(code, envir = env, new_device = FALSE, TRUE
if (is_R_CMD_build() || is_R_CMD_check()) }, error = function(e) {46: keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, error <<- format(e) keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else {call_block(x) OK <<- FALSE if (options$error && options$include) message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", 0L }) else 2L
file, conditionMessage(e)))
49: }, output_handler = knit_handlers(options$render, options)))})
}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)47: 44:
40: evaluate::evaluate(...)
with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 41: eng_r(options)evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning,
45: block_exec(params)
error = function(e) {60: process_group(group) keep_message = if (is.numeric(options$message)) TRUE else options$message, if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) tools:::.buildOneVignette("mnl_models_weighted.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", stop_on_error = if (is.numeric(options$error)) options$error else { error <<- format(e)46: if (options$error && options$include) }), list(rlang_trace_top_env = knit_global()))
call_block(x) TRUE, FALSE, "mnl_models_weighted", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a21639996a8.rds") 0L else 2L50:
}, output_handler = knit_handlers(options$render, options))48: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 47: error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
42: in_dir(input_dir(), expr)An irrecoverable exception occurred. R is aborting now ...
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check())
error <<- format(e) error = function(e) { })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) if (progress && is.function(pb$interrupt))
pb$interrupt()44: 49: if (is_R_CMD_build() || is_R_CMD_check()) with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), pb$interrupt() error <<- format(e) error = function(e) {eng_r(options) if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) if (is_R_CMD_build() || is_R_CMD_check()) }), list(rlang_trace_top_env = knit_global())), function(loc) { error <<- format(e) setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: }), list(rlang_trace_top_env = knit_global()))
45: 50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), if (progress && is.function(pb$interrupt)) block_exec(params) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check())
46: call_block(x)
output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: error <<- format(e)engine$weave(file, quiet = quiet, encoding = enc)
}), list(rlang_trace_top_env = knit_global())), function(loc) {56: error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) {47: process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }) setwd(wd)
doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({49: setwd(wd) engine$weave(file, quiet = quiet, encoding = enc)with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), write_utf8(res, output %n% stdout()) setwd(startdir) paste0("\nQuitting from ", loc, if (!is.null(error)) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: paste0("\n", rule(), error, "\n", rule())) engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})process_file(text, output) error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)53:
51: process_file(text, output)
52:
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),
60: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), tools:::.buildOneVignette("mnl_models_weighted.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) output_dir = getwd(), ...) TRUE, FALSE, "mnl_models_weighted", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a21639996a8.rds")
54:
error = function(e) {53:
if (progress && is.function(pb$interrupt)) rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), pb$interrupt() output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
if (is_R_CMD_build() || is_R_CMD_check()) vweave_rmarkdown(...)An irrecoverable exception occurred. R is aborting now ...
55: engine$weave(file, quiet = quiet, encoding = enc) error <<- format(e)
}), list(rlang_trace_top_env = knit_global())), function(loc) {55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])56:
setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))doTryCatch(return(expr), name, parentenv, handler)
58: 57: }, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("mnl_models_weighted.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", tryCatchList(expr, classes, parentenv, handlers) TRUE, FALSE, "mnl_models_weighted", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a21639996a8.rds")
59:
51: An irrecoverable exception occurred. R is aborting now ...
process_file(text, output)tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s",
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: file, conditionMessage(e)))engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE})
60: tools:::.buildOneVignette("mnl_models_weighted.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models_weighted", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a21639996a8.rds")
message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("mnl_models_weighted.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models_weighted", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a21639996a8.rds")An irrecoverable exception occurred. R is aborting now ...
An irrecoverable exception occurred. R is aborting now ...
Quitting from mnl_models_weighted.Rmd:64-80 [unnamed-chunk-3]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
<error/rlang_error>
Error in `names(x) <- value`:
! 'names' attribute [3] must be the same length as the vector [0]
---
Backtrace:
▆
1. └─logitr::logitr(...)
2. └─logitr:::getMultistartSummary(allModels)
3. └─base::`colnames<-`(...)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Error: processing vignette 'mnl_models_weighted.Rmd' failed with diagnostics:
'names' attribute [3] must be the same length as the vector [0]
--- failed re-building ‘mnl_models_weighted.Rmd’
--- re-building ‘mxl_models.Rmd’ using rmarkdown
--- finished re-building ‘mxl_models.Rmd’
--- re-building ‘predict.Rmd’ using rmarkdown
*** caught segfault ***
address 0x110, cause 'invalid permissions'
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: 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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)
26: eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: block_exec(params)
46: call_block(x)
47: process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("predict.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "predict", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211807b1a5.rds")
An irrecoverable exception occurred. R is aborting now ...
*** caught segfault ***
address 0x110, cause 'invalid permissions'
*** caught segfault ***
address 0x110, cause 'invalid permissions'
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: 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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)
26: eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: block_exec(params)
46: call_block(x)
47: process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error))
*** caught segfault ***
address 0x110, cause 'invalid permissions'
*** caught segfault ***
address 0x110, cause 'invalid permissions'
*** caught segfault ***
address 0x110, cause 'invalid permissions'
paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59:
*** caught segfault ***
address 0x110, cause 'invalid permissions'
tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("predict.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "predict", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211807b1a5.rds")
An irrecoverable exception occurred. R is aborting now ...
*** caught segfault ***
address 0x110, cause 'invalid permissions'
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: 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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)
26: eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: block_exec(params)
46: call_block(x)
47: process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("predict.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "predict", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211807b1a5.rds")
An irrecoverable exception occurred. R is aborting now ...
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4:
Traceback:
1:
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)doTryCatch(return(expr), name, parentenv, handler)
5:
tryCatchOne(expr, names, parentenv, handlers[[1L]])
Traceback:
2: eval_f(x0, ...)
1: 6: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)tryCatchList(expr, classes, parentenv, handlers)
Traceback:
1:
7: tryCatch({ 3:
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective,
*** caught segfault ***
eval_f(x0, ...) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
3: }, error = function(e) { mi = mi, opts = mi$options)nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4:
}) 4: doTryCatch(return(expr), name, parentenv, handler)
doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
address 0x110, cause 'invalid permissions'
doTryCatch(return(expr), name, parentenv, handler)
*** caught segfault ***
6: address 0x110, cause 'invalid permissions'
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 5: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
tryCatchOne(expr, names, parentenv, handlers[[1L]]) mi = mi, opts = mi$options) 6: tryCatchList(expr, classes, parentenv, handlers)
}, error = function(e) {}) 6:
8: system.time({
tryCatchList(expr, classes, parentenv, handlers) model <- mi$model
6: tryCatchList(expr, classes, parentenv, handlers) 8: 7: tryCatch({
system.time({ 7: 7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: system.time({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, result <- NULL model <- mi$model model <- mi$model mi = mi, opts = mi$options)}, error = function(e) {})
result <- NULL 8: system.time({ tryCatch({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, tryCatch({ mi = mi, opts = mi$options) result <- NULL }, error = function(e) { result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) mi = mi, opts = mi$options) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, tryCatch({ }, error = function(e) { }) }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, model$logLik <- as.numeric(-1 * result$objective) if (!is.null(result)) { model$iterations <- result$iterations model$status <- result$status model$message <- result$message mi = mi, opts = mi$options) }}, error = function(e) { mi = mi, opts = mi$options) }, error = function(e) {})}) }, error = function(e) {
model$fail <- FALSE model$coefficients <- result$solution })
if (!is.null(result)) { model$fail <- FALSE 9: }) model$coefficients <- result$solution if (!is.null(result)) { model$logLik <- as.numeric(-1 * result$objective)FUN(X[[i]], ...) 8: model$fail <- FALSE
Traceback:
model$iterations <- result$iterations 1: system.time({ model$status <- result$status model$logLik <- as.numeric(-1 * result$objective)mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) model$coefficients <- result$solution
model$message <- result$message
model <- mi$model model$logLik <- as.numeric(-1 * result$objective)
Traceback:
10: result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { 1: model$iterations <- result$iterations 2: model$fail <- FALSEmi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$status <- result$statuslapply(X = S, FUN = FUN, ...) model$message <- result$message
11: eval_f(x0, ...) model$message <- result$message mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)
} model$iterations <- result$iterationsdoTryCatch(return(expr), name, parentenv, handler) }
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14:
}}) model$status <- result$status})
9: FUN(X[[i]], ...) 5: }) model$message <- result$message
9: FUN(X[[i]], ...)
10:
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler) 3: lapply(X = S, FUN = FUN, ...)
}12: tryCatchOne(expr, names, parentenv, handlers[[1L]])tryCatch(expr, error = function(e) {tryCatchOne(expr, names, parentenv, handlers[[1L]])nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, call <- conditionCall(e)
mi = mi, opts = mi$options)})
6: tryCatchList(expr, classes, parentenv, handlers)11:
9: FUN(X[[i]], ...)
10:
13:
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)lapply(X = S, FUN = FUN, ...)tryCatchList(expr, classes, parentenv, handlers) 7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {
doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
14: 12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) { call <- conditionCall(e)
tryCatch(expr, error = function(e) { if (!is.null(call)) {})
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, if (identical(call[[1L]], quote(doTryCatch))) 4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L)11: mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status 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))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
call <- conditionCall(e)doTryCatch(return(expr), name, parentenv, handler)13: result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, tryCatchList(expr, classes, parentenv, handlers)
14: 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 : " mi = mi, opts = mi$options) msg <- paste0(prefix, conditionMessage(e), "\n")
if (!is.null(call)) { model$message <- result$message }})16: call <- sys.call(-4L)12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
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 ") }13: if (identical(call[[1L]], quote(doTryCatch))) else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L]))
sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) 9: tryCatchList(expr, classes, parentenv, handlers)FUN(X[[i]], ...) call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L)}, error = function(e) {
.Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) {17:
prefix <- paste("Error in", dcall, ": ")10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14:
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()) }14: FUN(X[[i]], ...)tryCatch(expr, error = function(e) { if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile)
cat(msg, file = outFile) .Internal(printDeferredWarnings()) invisible(structure(msg, class = "try-error", condition = e))18: }) } invisible(structure(msg, class = "try-error", condition = e))tryCatch(expr, error = function(e) { call <- conditionCall(e)})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
lapply(seq_len(cores), inner.do)}) .Internal(printDeferredWarnings())
if (!is.null(call)) {15:
if (identical(call[[1L]], quote(doTryCatch))) 19:
}parallel::mclapply(miList, runModel, mc.cores = numCores) invisible(structure(msg, class = "try-error", condition = e))}) 8: call <- conditionCall(e)try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) if (!is.null(call)) {
17: FUN(X[[i]], ...)
18:
if (identical(call[[1L]], quote(doTryCatch))) 19: system.time({ call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ")16:
20: lapply(seq_len(cores), inner.do) call <- sys.call(-4L) LONG <- 75L model <- mi$model result <- NULLwithCallingHandlers(expr, warning = function(w) if (inherits(w, sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { dcall <- deparse(call, nlines = 1L) sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (is.na(w))
17: w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], FUN(X[[i]], ...) type = "b") prefix <- paste("Error in", dcall, ": ")
parallel::mclapply(miList, runModel, mc.cores = numCores)
LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]]18:
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))lapply(seq_len(cores), inner.do) }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status classes)) tryInvokeRestart("muffleWarning"))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, 19: model$message <- result$message classes)) tryInvokeRestart("muffleMessage")) w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w")19: if (w > LONG)
parallel::mclapply(miList, runModel, mc.cores = numCores)23:
}})suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24:
runMultistart(modelInputs)20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c,
prefix <- paste0(prefix, "\n ") classes)) tryInvokeRestart("muffleMessage")) if (is.na(w)) 21: 25: 9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: }suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) else prefix <- "Error : "logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", parallel::mclapply(miList, runModel, mc.cores = numCores) msg <- paste0(prefix, conditionMessage(e), "\n") w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], tryCatch(expr, error = function(e) { "brand"), scalePar = "price", numMultiStarts = 10)
26: eval(expr, envir)
27: eval(expr, envir) .Internal(seterrmessage(msg[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))})
call <- conditionCall(e)23: if (!is.null(call)) { if (!silent && isTRUE(getOption("show.error.messages"))) {15: 20: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
suppressMessages(suppressWarnings(parallel::mclapply(miList, cat(msg, file = outFile)22: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
runModel, mc.cores = numCores))) if (identical(call[[1L]], quote(doTryCatch))) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
call <- sys.call(-4L)16:
dcall <- deparse(call, nlines = 1L)withCallingHandlers(expr, message = function(c) if (inherits(c, sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) classes)) tryInvokeRestart("muffleMessage"))
28:
withVisible(eval(expr, envir))
23: 16:
sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))17:
suppressMessages(suppressWarnings(parallel::mclapply(miList, 24: 23: prefix <- paste("Error in", dcall, ": ")17: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
runModel, mc.cores = numCores)))29: runMultistart(modelInputs)withCallingHandlers(code, error = function (e) LONG <- 75LFUN(X[[i]], ...)rlang::entrace(e), message = function (cnd)
24: 18: lapply(seq_len(cores), inner.do)runMultistart(modelInputs){
19: watcher$capture_plot_and_output()FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w")
parallel::mclapply(miList, runModel, mc.cores = numCores)24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)
26:
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)
eval(expr, envir)
25: classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, if (on_message$capture) { runModel, mc.cores = numCores)))26: watcher$push(cnd)eval(expr, envir) if (is.na(w)) logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)
}27:
24: runMultistart(modelInputs)20:
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)
26: eval(expr, envir)
27: eval(expr, envir) if (on_message$silence) {
withCallingHandlers(expr, warning = function(w) if (inherits(w, 26:
27: eval(expr, envir)
28: classes)) tryInvokeRestart("muffleWarning")) invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], withVisible(eval(expr, envir))
eval(expr, envir)28: 21: }
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { watcher$capture_plot_and_output() 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)eval(expr, envir)suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
.Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))})
withVisible(eval(expr, envir)) invokeRestart("muffleMessage")
29:
29: withCallingHandlers(code, error = function (e) 22: withCallingHandlers(code, error = function (e) 15: rlang::entrace(e), message = function (cnd) }try(lapply(X = S, FUN = FUN, ...), silent = TRUE)27: eval(expr, envir)
withCallingHandlers(expr, message = function(c) if (inherits(c, 16:
if (on_warning$capture) {sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) cnd <- sanitize_call(cnd)
rlang::entrace(e), message = function (cnd) 17: {}, warning = function (cnd) FUN(X[[i]], ...){28: watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) {withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) invokeRestart("muffleMessage") classes)) tryInvokeRestart("muffleMessage")) watcher$push(cnd)
} if (getOption("warn") >= 2 || getOption("warn") < 0) {{{ } return() watcher$capture_plot_and_output()}, warning = function (cnd) 23: if (on_message$capture) {{18: } watcher$capture_plot_and_output() watcher$push(cnd) if (getOption("warn") >= 2 || getOption("warn") < 0) { if (on_warning$capture) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { cnd <- sanitize_call(cnd)suppressMessages(suppressWarnings(parallel::mclapply(miList, }lapply(seq_len(cores), inner.do) watcher$capture_plot_and_output() if (on_message$capture) { invokeRestart("muffleWarning") runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
if (on_warning$silence) { watcher$push(cnd) } if (on_warning$silence) { }
}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
31: watcher$push(cnd) if (on_message$silence) { invokeRestart("muffleMessage") invokeRestart("muffleWarning") invokeRestart("muffleWarning") }eval(call)19: } if (on_message$silence) {}, error = function (cnd) { }25: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) invokeRestart("muffleMessage")}, warning = function (cnd)
}{
}, error = function (cnd) { watcher$capture_plot_and_output() }21: cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL) watcher$capture_plot_and_output()suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))32: }, warning = function (cnd) logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat",
}) cnd <- sanitize_call(cnd)with_handlers({ "brand"), scalePar = "price", numMultiStarts = 10) if (getOption("warn") >= 2 || getOption("warn") < 0) {
for (expr in tle$exprs) {26: { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() }22: return() watcher$capture_plot_and_output() ev <- withVisible(eval(expr, envir))withCallingHandlers(expr, message = function(c) if (inherits(c, } watcher$capture_plot_and_output()eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
29: watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) }
withCallingHandlers(code, error = function (e) if (on_warning$capture) { if (on_warning$capture) { watcher$push(cnd) TRUErlang::entrace(e), message = function (cnd) switch(on_error, continue = invokeRestart("eval_continue"), cnd <- sanitize_call(cnd) watcher$push(cnd)30: cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) {{ classes)) tryInvokeRestart("muffleMessage"))eval(call) }
}, handlers)
33: watcher$capture_plot_and_output() invokeRestart("muffleWarning")
if (on_message$capture) {31: } stop = invokeRestart("eval_stop"), error = NULL) if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
watcher$push(cnd)23: suppressMessages(suppressWarnings(parallel::mclapply(miList, }doWithOneRestart(return(expr), restart) runModel, mc.cores = numCores)))})}, error = function (cnd) 31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output()
30: {eval(call) if (on_message$silence) {eval(call) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
31:
32: with_handlers({34: 24: cnd <- sanitize_call(cnd)eval(call)runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)
invokeRestart("muffleMessage") }32:
for (expr in tle$exprs) {withOneRestart(expr, restarts[[1L]])with_handlers({26: ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } watcher$push(cnd)
TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34:
withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
35: }, warning = function (cnd) switch(on_error, continue = invokeRestart("eval_continue"), 33: withRestartList(expr, restarts[-nr]){doWithOneRestart(return(expr), restart)eval(expr, envir)
stop = invokeRestart("eval_stop"), error = NULL)
38: })
if (getOption("warn") >= 2 || getOption("warn") < 0) { for (expr in tle$exprs) {34: withOneRestart(expr, restarts[[1L]])36: return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }withRestartList(expr, restarts) ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir)
27:
eval(expr, envir)35: }, error = function (cnd) }30: 39: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)doWithOneRestart(return(expr), restart) TRUEeval(call)
withRestarts(with_handlers({28: }, handlers)37: { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd)37:
33: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
doWithOneRestart(return(expr), restart)38: withRestartList(expr, restarts) switch(on_error, continue = invokeRestart("eval_continue"), 38: withRestartList(expr, restarts)withVisible(eval(expr, envir))
40: evaluate::evaluate(...)39:
29: withCallingHandlers(code, error = function (e)
withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output()34: withOneRestart(expr, restarts[[1L]])
35: watcher$print_value(ev$value, ev$visible, envir) stop = invokeRestart("eval_stop"), error = NULL) }withRestartList(expr, restarts[-nr])rlang::entrace(e), message = function (cnd)
41:
39: withRestarts(with_handlers({ for (expr in tle$exprs) {})
30: eval(call)
31: 31: 36: eval(call){evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, eval(call) TRUE watcher$capture_plot_and_output() ev <- withVisible(eval(expr, envir))
}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)doWithOneRestart(return(expr), restart) watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir))41:
watcher$capture_plot_and_output()evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, 32: keep_message = if (is.numeric(options$message)) TRUE else options$message, watcher$print_value(ev$value, ev$visible, envir)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
39: withRestarts(with_handlers({ for (expr in tle$exprs) { stop_on_error = if (is.numeric(options$error)) options$error else {with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } keep_message = if (is.numeric(options$message)) TRUE else options$message, TRUE}, handlers)
33: }doWithOneRestart(return(expr), restart) if (options$error && options$include) ev <- withVisible(eval(expr, envir)) 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr) watcher$capture_plot_and_output() stop_on_error = if (is.numeric(options$error)) options$error else {
} TRUE
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
if (on_message$silence) {}, handlers)
33: 43: if (options$error && options$include) doWithOneRestart(return(expr), restart)in_input_dir(evaluate(code, envir = env, new_device = FALSE, watcher$print_value(ev$value, ev$visible, envir) keep_warning = if (is.numeric(options$warning)) TRUE else options$warning,
watcher$print_value(ev$value, ev$visible, envir)36: 0LdoWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: } keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) } 0L else 2LwithRestartList(expr, restarts)34:
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: TRUE else 2L TRUE invokeRestart("muffleMessage")}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE) }, output_handler = knit_handlers(options$render, options))) }
}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE) }, output_handler = knit_handlers(options$render, options))}, warning = function (cnd)
withOneRestart(expr, restarts[[1L]])44: eng_r(options){40:
35: withRestartList(expr, restarts[-nr])
evaluate::evaluate(...) if (getOption("warn") >= 2 || getOption("warn") < 0) {
42: in_dir(input_dir(), expr)36: evaluate::evaluate(...)doWithOneRestart(return(expr), restart)
return()43: 41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE,
} keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, 45: 41: watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) {40: keep_message = if (is.numeric(options$message)) TRUE else options$message, in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd)37: evaluate::evaluate(...)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))
switch(on_error, continue = invokeRestart("eval_continue"), withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) if (options$error && options$include) evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, 0L42: else 2L }, output_handler = knit_handlers(options$render, options)))block_exec(params)in_dir(input_dir(), expr)
keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L
if (options$error && options$include) stop = invokeRestart("eval_stop"), error = NULL)
else 2L
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: 46: })call_block(x) }, output_handler = knit_handlers(options$render, options))44: eng_r(options) 0L
38:
withRestartList(expr, restarts)
else 2L45: }, output_handler = knit_handlers(options$render, options)))
30: 42: eng_r(options)
45: block_exec(params)
eval(call)39:
31: eval(call)
32: 46: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: call_block(x)
44: withRestarts(with_handlers({block_exec(params)in_dir(input_dir(), expr)
doWithOneRestart(return(expr), restart)eng_r(options) for (expr in tle$exprs) {
45: block_exec(params)
46: call_block(x)
47: process_group(group)
47:
ev <- withVisible(eval(expr, envir))
47: process_group(group)34:
46: 48: 43: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) 48: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else {process_group(group)call_block(x)withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { watcher$capture_plot_and_output()
if (progress && is.function(pb$interrupt)) watcher$print_value(ev$value, ev$visible, envir)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) 40: if (options$error && options$include) withOneRestart(expr, restarts[[1L]]) error = function(e) { if (progress && is.function(pb$interrupt)) evaluate::evaluate(...)47: 0Lprocess_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: block_exec(params)
46: error <<- format(e) pb$interrupt()
pb$interrupt() })35: if (is_R_CMD_build() || is_R_CMD_check()) 49:
41: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: error <<- format(e) if (is_R_CMD_build() || is_R_CMD_check()) evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),
error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))call_block(x) keep_message = if (is.numeric(options$message)) TRUE else options$message,
withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])49:
47: 50: stop_on_error = if (is.numeric(options$error)) options$error else { error <<- format(e) error = function(e) {process_group(group)
38: withRestartList(expr, restarts)
with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),
39: if (options$error && options$include) }), list(rlang_trace_top_env = knit_global())), function(loc) { if (progress && is.function(pb$interrupt)) 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)48: error = function(e) {xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
45: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), setwd(wd) pb$interrupt() error = function(e) { error = function(e) { if (progress && is.function(pb$interrupt)) if (progress && is.function(pb$interrupt)) block_exec(params)
46: call_block(x)
47: process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt()withRestarts(with_handlers({ if (progress && is.function(pb$interrupt)) write_utf8(res, output %n% stdout()) pb$interrupt()50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)engine$weave(file, quiet = quiet, encoding = enc) if (is_R_CMD_build() || is_R_CMD_check()) pb$interrupt() error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), if (is_R_CMD_build() || is_R_CMD_check()) paste0("\nQuitting from ", loc, if (!is.null(error)) for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...) if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e)
output_dir = getwd(), ...) }), list(rlang_trace_top_env = knit_global())), function(loc) {
54: vweave_rmarkdown(...)41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))
setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: 42: 56: error <<- format(e)in_dir(input_dir(), expr) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) process_file(text, output)51:
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
write_utf8(res, output %n% stdout()) 0L58: 58: tryCatchList(expr, classes, parentenv, handlers)
55: paste0("\nQuitting from ", loc, if (!is.null(error)) engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: 59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) else 2L output <- find_vignette_product(name, by = "texi2pdf", paste0("\n", rule(), error, "\n", rule()))doTryCatch(return(expr), name, parentenv, handler)
engine = engine)tryCatch({57: engine$weave(file, quiet = quiet, encoding = enc) }}, error = function(e) {tryCatchOne(expr, names, parentenv, handlers[[1L]])tryCatchList(expr, classes, parentenv, handlers) paste0("\n", rule(), error, "\n", rule())) OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("predict.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "predict", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211807b1a5.rds")
An irrecoverable exception occurred. R is aborting now ...
}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: setwd(startdir)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", output <- find_vignette_product(name, by = "weave", engine = engine) engine = engine)rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), }, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...) if (!have.makefile && vignette_is_tex(output)) {58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("predict.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "predict", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211807b1a5.rds")
An irrecoverable exception occurred. R is aborting now ...
texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("predict.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "predict", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211807b1a5.rds")
An irrecoverable exception occurred. R is aborting now ...
}, output_handler = knit_handlers(options$render, options))) output_dir = getwd(), ...)
}
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", }, error = function(e) {
44: 55: engine = engine) }}, error = function(e) { OK <<- FALSEeng_r(options) message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", engine$weave(file, quiet = quiet, encoding = enc) OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s",
45: block_exec(params) file, conditionMessage(e))) file, conditionMessage(e)))
})46: })call_block(x)56:
47: 60:
60: tools:::.buildOneVignette("predict.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "predict", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211807b1a5.rds")
doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("predict.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "predict", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211807b1a5.rds")
An irrecoverable exception occurred. R is aborting now ...
An irrecoverable exception occurred. R is aborting now ...
process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
60: tools:::.buildOneVignette("predict.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "predict", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211807b1a5.rds")
An irrecoverable exception occurred. R is aborting now ...
tools:::.buildOneVignette("predict.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "predict", "UTF-8", "/Volumes/Temp/tmp/RtmpzdZOVj/file10a211807b1a5.rds")
An irrecoverable exception occurred. R is aborting now ...
Quitting from predict.Rmd:91-109 [unnamed-chunk-5]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
<error/rlang_error>
Error in `names(x) <- value`:
! 'names' attribute [3] must be the same length as the vector [0]
---
Backtrace:
▆
1. └─logitr::logitr(...)
2. └─logitr:::getMultistartSummary(allModels)
3. └─base::`colnames<-`(...)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Error: processing vignette 'predict.Rmd' failed with diagnostics:
'names' attribute [3] must be the same length as the vector [0]
--- failed re-building ‘predict.Rmd’
--- re-building ‘summarizing_results.Rmd’ using rmarkdown
--- finished re-building ‘summarizing_results.Rmd’
--- re-building ‘utility_models.Rmd’ using rmarkdown
--- finished re-building ‘utility_models.Rmd’
SUMMARY: processing the following files failed:
‘basic_usage.Rmd’ ‘mnl_models.Rmd’ ‘mnl_models_weighted.Rmd’
‘predict.Rmd’
Error: Vignette re-building failed.
Execution halted
Flavor: r-release-macos-arm64