Last updated on 2026-01-06 09:51:50 CET.
| Package | ERROR | OK |
|---|---|---|
| cbcTools | 13 | |
| logitr | 1 | 12 |
| surveydown | 13 |
Current CRAN status: OK: 13
Current CRAN status: ERROR: 1, OK: 12
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'
*** 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))
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({
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) 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 }
An irrecoverable exception occurred. R is aborting now ...
})
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, ": ")
*** caught segfault ***
address 0x110, cause 'invalid permissions'
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"))
*** caught segfault ***
address 0x110, cause 'invalid permissions'
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:
*** caught segfault ***
address 0x110, cause 'invalid permissions'
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)
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2:
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
eval_f(x0, ...)14: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) {
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler) 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")
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
if (is.na(w)) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } 6: tryCatchList(expr, classes, parentenv, handlers)
else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) { 7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = 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)15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solutionsendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: 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: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)20: withCallingHandlers(expr, warning = function(w) if (inherits(w,
Traceback:
classes)) tryInvokeRestart("muffleWarning"))14: 1: 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 ")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)
21: 4: } else prefix <- "Error : "doTryCatch(return(expr), name, parentenv, handler)suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: msg <- paste0(prefix, conditionMessage(e), "\n")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 ...
.Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) } 5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ invisible(structure(msg, class = "try-error", condition = e))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 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)
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"))14: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch)))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: 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")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 ...
.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 ***
*** caught segfault ***
address 0x110, cause 'invalid permissions'
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:
Traceback:
parallel::mclapply(miList, runModel, mc.cores = numCores) 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
2:
20: 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: eval_f(x0, ...)doTryCatch(return(expr), name, parentenv, handler)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: 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)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,
Traceback:
5: mi = mi, opts = mi$options)}, error = function(e) {})25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)
26: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 1: eval(expr, envir)
mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
27: eval(expr, envir)
2: 6: eval_f(x0, ...)28: tryCatchList(expr, classes, parentenv, handlers)
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) { 7: withVisible(eval(expr, envir)) 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, })
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)tryCatch({
4: 29: model$status <- result$status result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output()doTryCatch(return(expr), name, parentenv, handler) if (on_message$capture) {
5: model$message <- result$message}, error = function(e) {tryCatchOne(expr, names, parentenv, handlers[[1L]])})
} watcher$push(cnd) }})
9:
FUN(X[[i]], ...)
10: 6: tryCatchList(expr, classes, parentenv, handlers)
8: lapply(X = S, FUN = FUN, ...)system.time({ model <- mi$model result <- NULL
*** caught segfault ***
address 0x110, cause 'invalid permissions'
7: 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$solutiontryCatch({ model$logLik <- as.numeric(-1 * result$objective) if (on_message$silence) { model$iterations <- result$iterations 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 invokeRestart("muffleMessage") 8: system.time({11: } } model <- mi$model}, warning = function (cnd) })
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
doTryCatch(return(expr), name, parentenv, handler)
result <- NULL{12: tryCatch({12: tryCatchOne(expr, names, parentenv, handlers[[1L]]) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { })
if (!is.null(result)) { if (getOption("warn") >= 2 || getOption("warn") < 0) {13: tryCatchList(expr, classes, parentenv, handlers) model$fail <- FALSEtryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: return() }
watcher$capture_plot_and_output()tryCatch(expr, error = function(e) {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) if (on_warning$capture) { model$coefficients <- result$solution prefix <- paste("Error in", dcall, ": ") model$logLik <- as.numeric(-1 * result$objective) cnd <- sanitize_call(cnd) watcher$push(cnd) model$iterations <- result$iterations LONG <- 75L model$status <- result$status call <- conditionCall(e) sm <- strsplit(conditionMessage(e), "\n")[[1L]] model$message <- result$message 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 (on_warning$silence) { if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) if (w > LONG) call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ") invokeRestart("muffleWarning") LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") } }}, 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)}) if (is.na(w))
})
9: w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], 30: eval(call)
31: type = "b") prefix <- paste0(prefix, "\n ")FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
if (w > LONG) eval(call)11: prefix <- paste0(prefix, "\n ")doTryCatch(return(expr), name, parentenv, handler)
} else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n")
.Internal(seterrmessage(msg[1L]))12: } 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))}) if (!silent && isTRUE(getOption("show.error.messages"))) {tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: 32: tryCatch(expr, error = function(e) {
call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) cat(msg, file = outFile) .Internal(printDeferredWarnings())with_handlers({ dcall <- deparse(call, nlines = 1L)
Traceback:
15: prefix <- paste("Error in", dcall, ": ") }try(lapply(X = S, FUN = FUN, ...), silent = TRUE) for (expr in tle$exprs) { invisible(structure(msg, class = "try-error", condition = e)) ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output()
1: watcher$print_value(ev$value, ev$visible, envir)mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: })16: }sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (is.na(w)) eval_f(x0, ...) TRUE
*** caught segfault ***
}, handlers)
*** caught segfault ***
w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], lapply(seq_len(cores), inner.do)
*** caught segfault ***
address 0x110, cause 'invalid permissions'
type = "b")
*** caught segfault ***
address 0x110, cause 'invalid permissions'
if (w > LONG) prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: 33:
*** caught segfault ***
19: doTryCatch(return(expr), name, parentenv, handler)address 0x110, cause 'invalid permissions'
.Internal(seterrmessage(msg[1L]))address 0x110, cause 'invalid permissions'
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))address 0x110, cause 'invalid permissions'
if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) }doWithOneRestart(return(expr), restart)
17: FUN(X[[i]], ...)parallel::mclapply(miList, runModel, mc.cores = numCores) invisible(structure(msg, class = "try-error", condition = e)) 5: })tryCatchOne(expr, names, parentenv, handlers[[1L]])
34:
18: withOneRestart(expr, restarts[[1L]]) 6: lapply(seq_len(cores), inner.do)
35: 20:
Traceback:
withRestartList(expr, restarts[-nr])19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
withCallingHandlers(expr, warning = function(w) if (inherits(w, 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({ 1: classes)) tryInvokeRestart("muffleWarning"))
model <- mi$model
mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) result <- NULL tryCatch({21: 21: result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) }, error = function(e) {
22: withCallingHandlers(expr, message = function(c) if (inherits(c, }) 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$status36: 22: 15: model$message <- result$messagewithCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))try(lapply(X = S, FUN = FUN, ...), silent = TRUE)doWithOneRestart(return(expr), restart)suppressMessages(suppressWarnings(parallel::mclapply(miList,
24: runMultistart(modelInputs) }
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10)
runModel, mc.cores = numCores)))16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17:
FUN(X[[i]], ...)
})
2: 24: 37: 18: lapply(seq_len(cores), inner.do)
19: 26: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])eval(expr, envir)
Traceback:
27: eval(expr, envir)runMultistart(modelInputs)eval_f(x0, ...)
9: 1: parallel::mclapply(miList, runModel, mc.cores = numCores)FUN(X[[i]], ...)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) 3: 25: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", 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) {})
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) {
Traceback:
38:
Traceback:
"brand"), scalePar = "price", numMultiStarts = 10)
26: eval(expr, envir)
1: 10: withRestartList(expr, restarts)lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
Traceback:
8: watcher$capture_plot_and_output() 1:
mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)13:
mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
cnd <- sanitize_call(cnd)39: system.time({ 1: 4: 2: tryCatchList(expr, classes, parentenv, handlers) 2:
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)) eval_f(x0, ...)
27: eval(expr, envir)
28: model <- mi$modelmi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 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 }})
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 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) { watcher$push(cnd) mi = mi, opts = mi$options)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)
2: eval_f(x0, ...)
if (getOption("warn") >= 2 || getOption("warn") < 0) {
4: eval_f(x0, ...) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") }
22:
withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: 9: 5:
return() 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective,
23: 43: FUN(X[[i]], ...)in_input_dir(evaluate(code, envir = env, new_device = FALSE, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler) switch(on_error, continue = invokeRestart("eval_continue"), else prefix <- "Error : "
tryCatchOne(expr, names, parentenv, handlers[[1L]]) }
stop = invokeRestart("eval_stop"), error = NULL) keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, 3:
watcher$capture_plot_and_output() msg <- paste0(prefix, conditionMessage(e), "\n") if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) .Internal(seterrmessage(msg[1L]))
keep_message = if (is.numeric(options$message)) TRUE else options$message, 5: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, suppressMessages(suppressWarnings(parallel::mclapply(miList, 10: 6: stop_on_error = if (is.numeric(options$error)) options$error else { }})tryCatchList(expr, classes, parentenv, handlers)lapply(X = S, FUN = FUN, ...)tryCatchOne(expr, names, parentenv, handlers[[1L]]) mi = mi, opts = mi$options) if (on_warning$silence) {
4: doTryCatch(return(expr), name, parentenv, handler)
runModel, mc.cores = numCores))) if (options$error && options$include) tryCatchList(expr, classes, parentenv, handlers) 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:
5: if (!silent && isTRUE(getOption("show.error.messages"))) { 7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)tryCatchOne(expr, names, parentenv, handlers[[1L]]) invokeRestart("muffleWarning")
with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),
11: }}, 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: 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) {30: eval(call)doTryCatch(return(expr), name, parentenv, handler) cat(msg, file = outFile)
31: eval(call)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output()}, error = function (cnd) 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() 7:
{ .Internal(printDeferredWarnings())
12: watcher$print_value(ev$value, ev$visible, envir) watcher$capture_plot_and_output() 6: 6: tryCatchOne(expr, names, parentenv, handlers[[1L]]) if (getOption("warn") >= 2 || getOption("warn") < 0) {tryCatch({ cnd <- sanitize_call(cnd)tryCatchList(expr, classes, parentenv, handlers) if (is_R_CMD_build() || is_R_CMD_check()) }tryCatchList(expr, classes, parentenv, handlers) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, watcher$push(cnd) } return() invisible(structure(msg, class = "try-error", condition = e))
mi = mi, opts = mi$options) error <<- format(e) TRUE
tryCatchList(expr, classes, parentenv, handlers)
13: tryCatchList(expr, classes, parentenv, handlers)14: tryCatch(expr, error = function(e) { switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})}, handlers) } watcher$capture_plot_and_output() if (on_warning$capture) {
}), list(rlang_trace_top_env = knit_global())), function(loc) { call <- conditionCall(e) cnd <- sanitize_call(cnd)
}) 7: 7: if (!is.null(call)) {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"))
30: eval(call)
tryCatch({
}, 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 ")
33: doWithOneRestart(return(expr), restart) if (identical(call[[1L]], quote(doTryCatch))) setwd(wd) watcher$push(cnd) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective,
}tryCatch({15: 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, write_utf8(res, output %n% stdout()) runModel, mc.cores = numCores)))
24: runMultistart(modelInputs) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, try(lapply(X = S, FUN = FUN, ...), silent = TRUE) mi = mi, opts = mi$options) call <- sys.call(-4L) else prefix <- "Error : "
mi = mi, opts = mi$options)
}, error = function(e) { }
25: }, error = function(e) {31: msg <- paste0(prefix, conditionMessage(e), "\n")eval(call)16: .Internal(seterrmessage(msg[1L]))logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", if (on_warning$silence) {34:
if (!silent && isTRUE(getOption("show.error.messages"))) {}) "brand"), scalePar = "price", numMultiStarts = 10) invokeRestart("muffleWarning") paste0("\nQuitting from ", loc, if (!is.null(error)) sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) cat(msg, file = outFile)
} 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(...)
8: dcall <- deparse(call, nlines = 1L)26: withOneRestart(expr, restarts[[1L]])32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() prefix <- paste("Error in", dcall, ": ")
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")35: .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) LONG <- 75Leval(expr, envir) if (is.na(w))
withRestartList(expr, restarts[-nr])}, error = function (cnd) 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: watcher$print_value(ev$value, ev$visible, 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) { } 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))
{16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
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: 17:
55: runMultistart(modelInputs)
watcher$push(cnd) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], system.time({36: doWithOneRestart(return(expr), restart)
37: model <- mi$modelengine$weave(file, quiet = quiet, encoding = enc)FUN(X[[i]], ...) }18: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) result <- NULL
watcher$capture_plot_and_output()with_handlers({ watcher$print_value(ev$value, ev$visible, envir) }lapply(seq_len(cores), inner.do) 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)25: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) {56:
doTryCatch(return(expr), name, parentenv, handler) if (on_message$silence) { }) TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
38:
type = "b") if (!is.null(result)) {withRestartList(expr, restarts)
39: withRestarts(with_handlers({ invokeRestart("muffleMessage")
57: if (w > LONG) model$fail <- FALSE prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " } model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$statuslogitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir))18: 19: model$message <- result$message40: parallel::mclapply(miList, runModel, mc.cores = numCores) 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, lapply(seq_len(cores), inner.do) "brand"), scalePar = "price", numMultiStarts = 10)
26: eval(expr, envir)
27: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({
evaluate::evaluate(...) msg <- paste0(prefix, conditionMessage(e), "\n")}, warning = function (cnd) keep_message = if (is.numeric(options$message)) TRUE else options$message, .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]], ...)
stop_on_error = if (is.numeric(options$error)) options$error else {{ engine$weave(file, quiet = quiet, encoding = enc)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()
20: if (getOption("warn") >= 2 || getOption("warn") < 0) { return() }19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) watcher$capture_plot_and_output()withCallingHandlers(expr, warning = function(w) if (inherits(w,
setwd(startdir)
if (on_message$capture) {33: if (on_warning$capture) {41: output <- find_vignette_product(name, by = "weave", engine = engine)18: if (options$error && options$include) classes)) tryInvokeRestart("muffleWarning")) cnd <- sanitize_call(cnd)evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning,
lapply(seq_len(cores), inner.do)21: 21: watcher$push(cnd) keep_message = if (is.numeric(options$message)) TRUE else options$message, 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: } }
}) 0L if (on_warning$silence) { invokeRestart("muffleWarning") } stop_on_error = if (is.numeric(options$error)) options$error else { else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43: watcher$push(cnd)withRestartList(expr, restarts)suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) if (!have.makefile && vignette_is_tex(output)) { if (options$error && options$include) in_input_dir(evaluate(code, envir = env, new_device = FALSE,
keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))}, error = function (cnd) texi2pdf(file = output, clean = FALSE, quiet = quiet)
19: } 0L
39: 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)
parallel::mclapply(miList, runModel, mc.cores = numCores){ output <- find_vignette_product(name, by = "texi2pdf", else 2L
withRestarts(with_handlers({ if (on_message$silence) { watcher$capture_plot_and_output()
engine = engine)22: 25: 9: keep_message = if (is.numeric(options$message)) TRUE else options$message, }, output_handler = knit_handlers(options$render, options))withCallingHandlers(expr, message = function(c) if (inherits(c, } invokeRestart("muffleMessage")logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", FUN(X[[i]], ...) for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE
10: lapply(X = S, FUN = FUN, ...)
11: }, 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)
stop_on_error = if (is.numeric(options$error)) options$error else {20: 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) 0L else 2L if (options$error && options$include) }withCallingHandlers(expr, warning = function(w) if (inherits(w, doTryCatch(return(expr), name, parentenv, handler) cnd <- sanitize_call(cnd){ classes)) tryInvokeRestart("muffleWarning")) 0L "brand"), scalePar = "price", numMultiStarts = 10) }, output_handler = knit_handlers(options$render, options)) watcher$push(cnd)
42: in_dir(input_dir(), expr) else 2L
watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
31: eval(call)
}, error = function(e) {}, warning = function (cnd) }, 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())) 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)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: 43: {
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) {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)32: watcher$push(cnd)42: return() }in_input_dir(evaluate(code, envir = env, new_device = FALSE, if (getOption("warn") >= 2 || getOption("warn") < 0) {
in_dir(input_dir(), expr)50: with_handlers({ OK <<- FALSE }
43: if (on_warning$silence) { invokeRestart("muffleWarning") } watcher$push(cnd)12: 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)xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),
in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, if (on_warning$capture) { 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: 33: 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) 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 (cnd) cnd <- sanitize_call(cnd) keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, doWithOneRestart(return(expr), restart) }process_file(text, output){ switch(on_error, continue = invokeRestart("eval_continue"), message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", 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)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
}), list(rlang_trace_top_env = knit_global())), function(loc) { keep_message = if (is.numeric(options$message)) TRUE else options$message, stop = invokeRestart("eval_stop"), error = NULL)
file, conditionMessage(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: 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) })
tryCatchOne(expr, names, parentenv, handlers[[1L]])53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: vweave_rmarkdown(...)
55: 34: watcher$capture_plot_and_output()}) setwd(wd)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)) withOneRestart(expr, restarts[[1L]])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({ write_utf8(res, output %n% stdout())
35: if (on_warning$silence) { cnd <- sanitize_call(cnd) engine$weave(file, quiet = quiet, encoding = enc)withRestartList(expr, restarts[-nr])
invokeRestart("muffleWarning") paste0("\nQuitting from ", loc, if (!is.null(error)) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
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(), ...)
}36: }) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
if (!have.makefile && vignette_is_tex(output)) {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) texi2pdf(file = output, clean = FALSE, quiet = quiet)
doWithOneRestart(return(expr), restart)
37:
withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
}, error = function (cnd) {
output <- find_vignette_product(name, by = "texi2pdf", 60: 51: 30: 38: withRestartList(expr, restarts)30: 13: watcher$capture_plot_and_output()eval(call) 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",
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() cnd <- sanitize_call(cnd)59: 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)
32: tryCatch({ watcher$push(cnd) watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
41: TRUE, FALSE, "basic_usage", "UTF-8", "/Volumes/Temp/tmp/RtmptxoWky/file2eaf5592d71c.rds")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/RtmptxoWky/file2eaf5592d71c.rds")40: eval(call) engine$weave(file, quiet = quiet, encoding = enc)evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, process_file(text, output)
tryCatchList(expr, classes, parentenv, handlers)
switch(on_error, continue = invokeRestart("eval_continue"), evaluate::evaluate(...)
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)An irrecoverable exception occurred. R is aborting now ...
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, setwd(startdir)14: with_handlers({
stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
stop_on_error = if (is.numeric(options$error)) options$error else {An irrecoverable exception occurred. R is aborting now ...
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) if (options$error && options$include) 0LtryCatch(expr, error = function(e) {
39: else 2LwithRestarts(with_handlers({ output <- find_vignette_product(name, by = "weave", engine = engine)31:
for (expr in tle$exprs) { 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: 40: keep_message = if (is.numeric(options$message)) TRUE else options$message, eval(call)tools:::.buildOneVignette("basic_usage.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", 52:
32: with_handlers({ }, output_handler = knit_handlers(options$render, options))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: ev <- withVisible(eval(expr, envir)) call <- conditionCall(e)
evaluate::evaluate(...) watcher$capture_plot_and_output()
stop_on_error = if (is.numeric(options$error)) options$error else { if (!is.null(call)) { for (expr in tle$exprs) {engine$weave(file, quiet = quiet, encoding = enc) if (identical(call[[1L]], quote(doTryCatch))) 41: 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 ")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) TRUE, FALSE, "basic_usage", "UTF-8", "/Volumes/Temp/tmp/RtmptxoWky/file2eaf5592d71c.rds") }
An irrecoverable exception occurred. R is aborting now ...
ev <- withVisible(eval(expr, envir)) }
watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) else prefix <- "Error : "56: 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 2LdoTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]]) }, output_handler = knit_handlers(options$render, options)) if (options$error && options$include) TRUE msg <- paste0(prefix, conditionMessage(e), "\n")}, 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, 42:
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc)in_dir(input_dir(), expr)
43: } stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0Lin_input_dir(evaluate(code, envir = env, new_device = FALSE, .Internal(seterrmessage(msg[1L])) TRUE
else 2L 0L}, handlers) 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)) else 2L }, output_handler = knit_handlers(options$render, options)) setwd(startdir) }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
if (!silent && isTRUE(getOption("show.error.messages"))) {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)) output <- find_vignette_product(name, by = "weave", engine = engine)42: cat(msg, file = outFile) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check())
if (!have.makefile && vignette_is_tex(output)) { 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)) texi2pdf(file = output, clean = FALSE, quiet = quiet)
42: 42: in_dir(input_dir(), expr) output <- find_vignette_product(name, by = "texi2pdf", .Internal(printDeferredWarnings())33: }doWithOneRestart(return(expr), restart)
pb$interrupt()in_dir(input_dir(), expr)in_dir(input_dir(), expr) engine = engine)
}}, error = function(e) {43: invisible(structure(msg, class = "try-error", condition = e))
43: 43: 34: 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, OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", in_input_dir(evaluate(code, envir = env, new_device = FALSE, stop_on_error = if (is.numeric(options$error)) options$error else { file, conditionMessage(e)))withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
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) 38: if (is_R_CMD_build() || is_R_CMD_check()) 15: 0L if (options$error && options$include) withRestartList(expr, restarts) error <<- format(e)
39: 0L else 2L})try(lapply(X = S, FUN = FUN, ...), silent = TRUE) }, output_handler = knit_handlers(options$render, options)))
in_input_dir(evaluate(code, envir = env, new_device = FALSE,
}), list(rlang_trace_top_env = knit_global())) else 2L keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message,
withRestarts(with_handlers({60: for (expr in tle$exprs) {16: tools:::.buildOneVignette("basic_usage.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 { if (options$error && options$include) sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))44: 50: ev <- withVisible(eval(expr, envir))
17: eng_r(options) }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
TRUE, FALSE, "basic_usage", "UTF-8", "/Volumes/Temp/tmp/RtmptxoWky/file2eaf5592d71c.rds") watcher$capture_plot_and_output()FUN(X[[i]], ...) 0L
45: block_exec(params)
xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),
An irrecoverable exception occurred. R is aborting now ...
error = function(e) {18: watcher$print_value(ev$value, ev$visible, envir) else 2L } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
45: if (progress && is.function(pb$interrupt)) 46: call_block(x)
47: process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), }, output_handler = knit_handlers(options$render, options)))block_exec(params) pb$interrupt()
44: eng_r(options)lapply(seq_len(cores), inner.do) error = function(e) {
40: if (progress && is.function(pb$interrupt)) 45:
evaluate::evaluate(...) if (is_R_CMD_build() || is_R_CMD_check()) block_exec(params)
pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) 19: error <<- format(e)
46: error <<- format(e)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 })46: call_block(x)call_block(x)
47: parallel::mclapply(miList, runModel, mc.cores = numCores) else 2L
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: 47: process_group(group)
48: }), list(rlang_trace_top_env = knit_global())), function(loc) {withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), process_group(group) setwd(wd)
write_utf8(res, output %n% stdout())48: }, output_handler = knit_handlers(options$render, options)) paste0("\nQuitting from ", loc, if (!is.null(error)) withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage")) error = function(e) {
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()
23: 49: if (is_R_CMD_build() || is_R_CMD_check()) if (progress && is.function(pb$interrupt)) pb$interrupt()suppressMessages(suppressWarnings(parallel::mclapply(miList, paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: 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/RtmptxoWky/file2eaf5592d71c.rds")
An irrecoverable exception occurred. R is aborting now ...
with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 42: process_file(text, output) runModel, mc.cores = numCores)))
error = function(e) { error <<- format(e)in_dir(input_dir(), expr)52: }), list(rlang_trace_top_env = knit_global()))
if (progress && is.function(pb$interrupt)) 50: 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, 24: pb$interrupt()knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, error = function(e) {
if (progress && is.function(pb$interrupt)) if (is_R_CMD_build() || is_R_CMD_check()) runMultistart(modelInputs)53: pb$interrupt() keep_message = if (is.numeric(options$message)) TRUE else options$message, rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) error <<- format(e) output_dir = getwd(), ...)
}), list(rlang_trace_top_env = knit_global())) }), list(rlang_trace_top_env = knit_global())), function(loc) {25:
logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", stop_on_error = if (is.numeric(options$error)) options$error else { setwd(wd) "brand"), scalePar = "price", numMultiStarts = 10) if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: write_utf8(res, output %n% stdout())54: paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)vweave_rmarkdown(...)
26: eval(expr, envir)
27:
50: eval(expr, envir)xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {
55: 51: engine$weave(file, quiet = quiet, encoding = enc)process_file(text, output)eng_r(options)
if (progress && is.function(pb$interrupt)) 45: block_exec(params)
46: call_block(x)
52: 56:
knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), 28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) output_dir = getwd(), ...)doTryCatch(return(expr), name, parentenv, handler)
rlang::entrace(e), message = function (cnd) 47: 54: process_group(group)57: { 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))
watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) }48: paste0("\n", rule(), error, "\n", rule()))tryCatchOne(expr, names, parentenv, handlers[[1L]])withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), if (on_message$silence) {}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) invokeRestart("muffleMessage")
vweave_rmarkdown(...) error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e)51: process_file(text, output)
})
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return()
55: engine$weave(file, quiet = quiet, encoding = enc)
error = function(e) { }56:
doTryCatch(return(expr), name, parentenv, handler)
watcher$capture_plot_and_output()57: 52: if (progress && is.function(pb$interrupt)) pb$interrupt() if (on_warning$capture) {knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)tryCatchOne(expr, names, parentenv, handlers[[1L]])58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ cnd <- sanitize_call(cnd) engine$weave(file, quiet = quiet, encoding = enc)
setwd(startdir) watcher$push(cnd)58: if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e)53: tryCatchList(expr, classes, parentenv, handlers) }), list(rlang_trace_top_env = knit_global()))
rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
} 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", 50: if (on_warning$silence) {xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),
54: vweave_rmarkdown(...)
error = function(e) {55: if (progress && is.function(pb$interrupt)) invokeRestart("muffleWarning") pb$interrupt() }59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir)}, error = function (cnd) {engine$weave(file, quiet = quiet, encoding = enc) engine = engine)
if (is_R_CMD_build() || is_R_CMD_check()) watcher$capture_plot_and_output() }56: cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)})
doTryCatch(return(expr), name, parentenv, handler) error <<- format(e)30: }), list(rlang_trace_top_env = knit_global())), function(loc) {}, error = function(e) { OK <<- FALSEeval(call) message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s",
57:
setwd(wd) output <- find_vignette_product(name, by = "weave", engine = engine) write_utf8(res, output %n% stdout()) file, conditionMessage(e)))tryCatchOne(expr, names, parentenv, handlers[[1L]]) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule())) if (!have.makefile && vignette_is_tex(output)) {}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
51: 58: })31: tryCatchList(expr, classes, parentenv, handlers)process_file(text, output)eval(call)
52: texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }
knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)32: }, error = function(e) {
with_handlers({53:
rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), OK <<- FALSE
for (expr in tle$exprs) {59: ev <- withVisible(eval(expr, envir))tryCatch({ message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", 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/RtmptxoWky/file2eaf5592d71c.rds") engine$weave(file, quiet = quiet, encoding = enc) watcher$capture_plot_and_output() setwd(startdir) output_dir = getwd(), ...) output <- find_vignette_product(name, by = "weave", engine = engine) file, conditionMessage(e)))
watcher$print_value(ev$value, ev$visible, envir)})
An irrecoverable exception occurred. R is aborting now ...
} TRUE}, handlers)
if (!have.makefile && vignette_is_tex(output)) {33: texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine)60: }doWithOneRestart(return(expr), restart)}, error = function(e) {
OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))34: withOneRestart(expr, restarts[[1L]])
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/RtmptxoWky/file2eaf5592d71c.rds")
35: An irrecoverable exception occurred. R is aborting now ...
withRestartList(expr, restarts[-nr])
})
36: doWithOneRestart(return(expr), restart)
37: 54: 60: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
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/RtmptxoWky/file2eaf5592d71c.rds")
An irrecoverable exception occurred. R is aborting now ...
38: withRestartList(expr, restarts)
vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
57: 39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output()tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) watcher$print_value(ev$value, ev$visible, envir) } TRUE 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)))}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: })
60: 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))
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/RtmptxoWky/file2eaf5592d71c.rds")
An irrecoverable exception occurred. R is aborting now ...
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("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/RtmptxoWky/file2eaf5592d71c.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'
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)})
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.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/RtmptxoWky/file2eaf44e6c581.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, 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)})
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)
*** caught segfault ***
address 0x110, cause 'invalid permissions'
}), 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/RtmptxoWky/file2eaf44e6c581.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, ...)
*** caught segfault ***
address 0x110, cause 'invalid permissions'
*** caught segfault ***
address 0x110, cause 'invalid permissions'
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)})
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.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/RtmptxoWky/file2eaf44e6c581.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 = 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)})
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
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: }, 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)))
Traceback:
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)) 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2:
*** caught segfault ***
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)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
tryCatchOne(expr, names, parentenv, handlers[[1L]]) 6:
tryCatchList(expr, classes, parentenv, handlers)
pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }) 7: 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 <- NULL49: 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) { 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)) { if (progress && is.function(pb$interrupt)) model$fail <- FALSE pb$interrupt() 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_R_CMD_build() || is_R_CMD_check()) error <<- format(e) 9: tryCatch({FUN(X[[i]], ...)
10: result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: 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: }), 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)) tryCatch(expr, error = function(e) {system.time({ model <- mi$model result <- NULL 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)) 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 paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], 51: 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))
Traceback:
1: }) model$logLik <- as.numeric(-1 * result$objective)process_file(text, output) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
9:
15:
FUN(X[[i]], ...) 3: 52: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
10: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)lapply(X = S, FUN = FUN, ...) mi = mi, opts = mi$options)
11:
4: doTryCatch(return(expr), name, parentenv, handler)53: 17: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)doTryCatch(return(expr), name, parentenv, handler)
*** caught segfault ***
54: FUN(X[[i]], ...)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6:
vweave_rmarkdown(...)
tryCatchList(expr, classes, parentenv, handlers)55: 18:
12: address 0x110, cause 'invalid permissions'
tryCatchOne(expr, names, parentenv, handlers[[1L]])engine$weave(file, quiet = quiet, encoding = enc) 7:
lapply(seq_len(cores), inner.do)
56: 19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: doTryCatch(return(expr), name, parentenv, handler)withCallingHandlers(expr, warning = function(w) if (inherits(w,
classes)) tryInvokeRestart("muffleWarning"))57: tryCatch({tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective,
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: 58: mi = mi, opts = mi$options)}, error = function(e) {tryCatchList(expr, classes, parentenv, handlers)withCallingHandlers(expr, message = function(c) if (inherits(c, })
14: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) classes)) tryInvokeRestart("muffleMessage")) dcall <- deparse(call, nlines = 1L)
prefix <- paste("Error in", dcall, ": ") LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]]tryCatchList(expr, classes, parentenv, handlers) 8:
w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w")59: if (is.na(w)) 23: tryCatch({system.time({suppressMessages(suppressWarnings(parallel::mclapply(miList, engine$weave(file, quiet = quiet, encoding = enc) model <- mi$model setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], runModel, mc.cores = numCores)))
24: type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)runMultistart(modelInputs) if (!have.makefile && vignette_is_tex(output)) { .Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) {
}, error = function(e) { }) cat(msg, file = outFile) if (!is.null(result)) { .Internal(printDeferredWarnings()) } model$fail <- FALSE25: model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
9: 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)FUN(X[[i]], ...)
19: texi2pdf(file = output, clean = FALSE, quiet = quiet)logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate) output <- find_vignette_product(name, by = "texi2pdf",
Traceback:
10: 1:
mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)26: parallel::mclapply(miList, runModel, mc.cores = numCores)lapply(X = S, FUN = FUN, ...) engine = engine)eval(expr, envir)
}20: withCallingHandlers(expr, warning = function(w) if (inherits(w, }, error = function(e) { classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
11: OK <<- FALSE22:
message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", withCallingHandlers(expr, message = function(c) if (inherits(c, 27: classes)) tryInvokeRestart("muffleMessage")) file, conditionMessage(e)))eval(expr, envir)})
60: tools:::.buildOneVignette("mnl_models.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr",
doTryCatch(return(expr), name, parentenv, handler)28: 2: TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/RtmptxoWky/file2eaf44e6c581.rds")
eval_f(x0, ...)23: withVisible(eval(expr, envir))suppressMessages(suppressWarnings(parallel::mclapply(miList,
12:
runModel, mc.cores = numCores)))
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4: doTryCatch(return(expr), name, parentenv, handler)29: An irrecoverable exception occurred. R is aborting now ...
withCallingHandlers(code, error = function (e) 24: rlang::entrace(e), message = function (cnd) 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)
*** caught segfault ***
}, error = function(e) {tryCatchOne(expr, names, parentenv, handlers[[1L]])
{runMultistart(modelInputs)13:
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)address 0x110, cause 'invalid permissions'
watcher$capture_plot_and_output()tryCatchList(expr, classes, parentenv, handlers) if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) {
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
14: })
29:
withCallingHandlers(code, error = function (e) 8: invokeRestart("muffleMessage")system.time({tryCatch(expr, error = function(e) { model <- mi$model result <- NULLrlang::entrace(e), message = function (cnd) tryCatch({ call <- conditionCall(e) 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) if (!is.null(call)) {{ model$iterations <- result$iterations }}, warning = function (cnd) model$status <- result$status{ if (getOption("warn") >= 2 || getOption("warn") < 0) { watcher$capture_plot_and_output() return() if (identical(call[[1L]], quote(doTryCatch))) model$message <- result$message } call <- sys.call(-4L)})
} watcher$capture_plot_and_output() 9: if (on_warning$capture) { if (on_message$capture) { watcher$push(cnd)FUN(X[[i]], ...) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } dcall <- deparse(call, nlines = 1L)
watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) if (on_warning$capture) { cnd <- sanitize_call(cnd)
*** caught segfault ***
address 0x110, cause 'invalid permissions'
prefix <- paste("Error in", dcall, ": ") watcher$push(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }10: }lapply(X = S, FUN = FUN, ...) LONG <- 75L if (on_warning$silence) {
}, error = function (cnd) {11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
watcher$capture_plot_and_output() sm <- strsplit(conditionMessage(e), "\n")[[1L]] cnd <- sanitize_call(cnd)13: watcher$push(cnd) invokeRestart("muffleWarning") switch(on_error, continue = invokeRestart("eval_continue"), w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w")tryCatchList(expr, classes, parentenv, handlers)
14: if (is.na(w)) tryCatch(expr, error = function(e) { stop = invokeRestart("eval_stop"), error = NULL) call <- conditionCall(e) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], }})
}, error = function (cnd) if (!is.null(call)) {30: eval(call) type = "b") if (w > LONG) { prefix <- paste0(prefix, "\n ") } watcher$capture_plot_and_output() else prefix <- "Error : "
Traceback:
msg <- paste0(prefix, conditionMessage(e), "\n") if (identical(call[[1L]], quote(doTryCatch))) .Internal(seterrmessage(msg[1L])) call <- sys.call(-4L) 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, cnd <- sanitize_call(cnd) dcall <- deparse(call, nlines = 1L) mi = mi, opts = mi$options) prefix <- paste("Error in", dcall, ": ")31: LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] if (!silent && isTRUE(getOption("show.error.messages"))) {eval(call) watcher$push(cnd)
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output()
w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") watcher$print_value(ev$value, ev$visible, envir) if (is.na(w)) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], } 4: cat(msg, file = outFile) TRUE type = "b") switch(on_error, continue = invokeRestart("eval_continue"), if (w > LONG) prefix <- paste0(prefix, "\n ") }}, handlers) else prefix <- "Error : " .Internal(printDeferredWarnings())
}doTryCatch(return(expr), name, parentenv, handler) invisible(structure(msg, class = "try-error", condition = e))33:
Traceback:
doWithOneRestart(return(expr), restart) stop = invokeRestart("eval_stop"), error = NULL)
34: withOneRestart(expr, restarts[[1L]]) 1: msg <- paste0(prefix, conditionMessage(e), "\n")})
.Internal(seterrmessage(msg[1L]))})
if (!silent && isTRUE(getOption("show.error.messages"))) {mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 5: tryCatchOne(expr, names, parentenv, handlers[[1L]]) cat(msg, file = outFile)30:
15: .Internal(printDeferredWarnings())35: withRestartList(expr, restarts[-nr])
36:
try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: eval(call) }doWithOneRestart(return(expr), restart)
invisible(structure(msg, class = "try-error", condition = e))sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
6:
})31: 37: eval(call)17:
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
tryCatchList(expr, classes, parentenv, handlers) 2:
eval_f(x0, ...)
withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])16: FUN(X[[i]], ...)sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir))38: withRestartList(expr, restarts)
3: 18: watcher$capture_plot_and_output() 7: watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: lapply(seq_len(cores), inner.do)nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 39: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: mi = mi, opts = mi$options)19: doWithOneRestart(return(expr), restart)parallel::mclapply(miList, runModel, mc.cores = numCores)system.time({withRestarts(with_handlers({
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
model <- mi$model
6: }, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)tryCatchList(expr, classes, parentenv, handlers)
doWithOneRestart(return(expr), restart)
result <- NULL20: 40:
7: 17: tryCatch({ tryCatch({FUN(X[[i]], ...)
result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 37: withCallingHandlers(expr, warning = function(w) if (inherits(w, evaluate::evaluate(...)
result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) classes)) tryInvokeRestart("muffleWarning"))
41: mi = mi, opts = mi$options)21: 18:
suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, lapply(seq_len(cores), inner.do)evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, classes)) tryInvokeRestart("muffleMessage"))
}, error = function(e) {23: 38: withRestartList(expr, restarts) }) keep_message = if (is.numeric(options$message)) TRUE else options$message, 19: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24:
stop_on_error = if (is.numeric(options$error)) options$error else {runMultistart(modelInputs) 8: system.time({ if (!is.null(result)) { model <- mi$model result <- NULL tryCatch({ if (options$error && options$include) 39: 0LwithRestarts(with_handlers({ model$fail <- FALSE else 2L for (expr in tle$exprs) {parallel::mclapply(miList, runModel, mc.cores = numCores)
model$coefficients <- result$solution result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, }, output_handler = knit_handlers(options$render, options)) ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } mi = mi, opts = mi$options)20: }, error = function(e) {
withCallingHandlers(expr, warning = function(w) if (inherits(w, }) if (!is.null(result)) {25:
42: in_dir(input_dir(), expr)
logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", 43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate) keep_message = if (is.numeric(options$message)) TRUE else options$message, model$logLik <- as.numeric(-1 * result$objective)
26: eval(expr, envir)
27: stop_on_error = if (is.numeric(options$error)) options$error else { classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
model$fail <- FALSE model$iterations <- result$iterations model$status <- result$status model$message <- result$messageeval(expr, envir) TRUE
28: withVisible(eval(expr, envir))
22: }withCallingHandlers(expr, message = function(c) if (inherits(c, }, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE) if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
classes)) tryInvokeRestart("muffleMessage")) model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective)})
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", model$iterations <- result$iterations "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate)
26: 29:
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)eval(expr, envir)
withCallingHandlers(code, error = function (e)
44: rlang::entrace(e), message = function (cnd) {
27: model$status <- result$status model$message <- result$message watcher$capture_plot_and_output()eval(expr, envir)
28: 11: eng_r(options)doTryCatch(return(expr), name, parentenv, handler)
}})
40: if (on_message$capture) {12: withVisible(eval(expr, envir))
watcher$push(cnd) 9: 45:
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) {FUN(X[[i]], ...) } if (on_message$silence) { invokeRestart("muffleMessage") }evaluate::evaluate(...)tryCatchOne(expr, names, parentenv, handlers[[1L]])
}, warning = function (cnd)
10: lapply(X = S, FUN = FUN, ...) watcher$push(cnd)block_exec(params)13:
tryCatchList(expr, classes, parentenv, handlers)
46: }{ if (on_message$silence) {14: call_block(x)
47: process_group(group)tryCatch(expr, error = function(e) {
if (getOption("warn") >= 2 || getOption("warn") < 0) {41: 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") }
return() } watcher$capture_plot_and_output() if (on_warning$capture) {11: }, error = function (cnd) cnd <- sanitize_call(cnd) watcher$push(cnd)evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, { 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) keep_message = if (is.numeric(options$message)) TRUE else options$message, doTryCatch(return(expr), name, parentenv, handler) }
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, ": ") stop_on_error = if (is.numeric(options$error)) options$error else {48: LONG <- 75L 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: 12: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), if (on_warning$silence) { sm <- strsplit(conditionMessage(e), "\n")[[1L]]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)
tryCatchOne(expr, names, parentenv, handlers[[1L]])eng_r(options)33: error = function(e) {
doWithOneRestart(return(expr), restart) 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) {
invokeRestart("muffleWarning") if (progress && is.function(pb$interrupt)) w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w")13: tryCatchList(expr, classes, parentenv, handlers) if (is.na(w))
14:
tryCatch(expr, error = function(e) { w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], }34: 45: }, error = function (cnd) 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) 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]] type = "b") write_utf8(res, output %n% stdout())block_exec(params) paste0("\nQuitting from ", loc, if (!is.null(error)) if (w > LONG) withOneRestart(expr, restarts[[1L]]) 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) w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") prefix <- paste0(prefix, "\n ")
if (is.na(w)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
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") }46: call_block(x)})35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: else prefix <- "Error : "
51: process_file(text, output)
52: 30: withRestartList(expr, restarts)knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: msg <- paste0(prefix, conditionMessage(e), "\n")
eval(call) .Internal(seterrmessage(msg[1L]))
if (!silent && isTRUE(getOption("show.error.messages"))) { .Internal(seterrmessage(msg[1L]))39: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), if (!silent && isTRUE(getOption("show.error.messages"))) { output_dir = getwd(), ...) cat(msg, file = outFile)withRestarts(with_handlers({ cat(msg, file = outFile) .Internal(printDeferredWarnings())47: 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) .Internal(printDeferredWarnings()) } }
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc) invisible(structure(msg, class = "try-error", condition = e))process_group(group) } invisible(structure(msg, class = "try-error", condition = e))})
}) for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) }
TRUE TRUE15:
}, handlers)
33: doWithOneRestart(return(expr), restart)56: 48: }, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) if (progress && is.function(pb$interrupt))
40: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)evaluate::evaluate(...)
41: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, doTryCatch(return(expr), name, parentenv, handler)
16:
keep_message = if (is.numeric(options$message)) TRUE else options$message, 16:
stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0LsendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: tryCatchList(expr, classes, parentenv, handlers)
sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) pb$interrupt() else 2L34:
17: FUN(X[[i]], ...)
}, output_handler = knit_handlers(options$render, options))withOneRestart(expr, restarts[[1L]])18:
42: in_dir(input_dir(), expr)
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)))lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: 35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])}) error <<- format(e)
60: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))43: 17: })FUN(X[[i]], ...)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, tools:::.buildOneVignette("mnl_models.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr",
38: withRestartList(expr, restarts)18: 49:
lapply(seq_len(cores), inner.do)
19: 21: 39: TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/RtmptxoWky/file2eaf44e6c581.rds")with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
stop_on_error = if (is.numeric(options$error)) options$error else {withRestarts(with_handlers({ error = function(e) {An irrecoverable exception occurred. R is aborting now ...
for (expr in tle$exprs) { if (options$error && options$include) ev <- withVisible(eval(expr, envir))parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) 0L watcher$capture_plot_and_output()
if (progress && is.function(pb$interrupt)) watcher$print_value(ev$value, ev$visible, envir) pb$interrupt()23: } if (is_R_CMD_build() || is_R_CMD_check()) else 2L error <<- format(e) }), list(rlang_trace_top_env = knit_global()))
21: }, output_handler = knit_handlers(options$render, options)))
44: 50: TRUEeng_r(options)suppressMessages(suppressWarnings(parallel::mclapply(miList,
xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
runModel, mc.cores = numCores)))40: 45: evaluate::evaluate(...)
41:
24: runMultistart(modelInputs)
block_exec(params) error = function(e) {22: withCallingHandlers(expr, message = function(c) if (inherits(c,
46: 25: if (progress && is.function(pb$interrupt)) evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, classes)) tryInvokeRestart("muffleMessage")) keep_message = if (is.numeric(options$message)) TRUE else options$message,
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))) stop_on_error = if (is.numeric(options$error)) options$error else {logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", if (options$error && options$include) call_block(x)
47: process_group(group)
48: 0L pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error <<- format(e) error = function(e) { }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd) "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate) write_utf8(res, output %n% stdout())
if (progress && is.function(pb$interrupt)) 24: paste0("\nQuitting from ", loc, if (!is.null(error)) runMultistart(modelInputs) else 2L }, output_handler = knit_handlers(options$render, options))
26: eval(expr, envir) paste0("\n", rule(), error, "\n", rule()))
pb$interrupt()
if (is_R_CMD_build() || is_R_CMD_check()) 25: }, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) error <<- format(e) })
logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", 49: "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate)
with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {42:
in_dir(input_dir(), expr)
43: 27: eval(expr, envir)
51: in_input_dir(evaluate(code, envir = env, new_device = FALSE, if (progress && is.function(pb$interrupt)) 26: pb$interrupt() keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, eval(expr, envir) if (is_R_CMD_build() || is_R_CMD_check()) process_file(text, output)28: keep_message = if (is.numeric(options$message)) TRUE else options$message,
stop_on_error = if (is.numeric(options$error)) options$error else {
error <<- format(e) }), list(rlang_trace_top_env = knit_global()))27:
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)) 52: 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: if (options$error && options$include) pb$interrupt()knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)withVisible(eval(expr, envir))
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) 0L
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) {eval(call) else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
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
45: block_exec(params)
46: call_block(x)
47: process_group(group)
48: watcher$capture_plot_and_output() 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)) pb$interrupt()}, handlers) error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { if (is_R_CMD_build() || is_R_CMD_check()) if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage")
error <<- format(e)
59: } })33: setwd(wd)
tryCatch({doWithOneRestart(return(expr), restart)49: write_utf8(res, output %n% stdout())
with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), engine$weave(file, quiet = quiet, encoding = enc) error = function(e) {34: setwd(startdir) if (progress && is.function(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) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
withOneRestart(expr, restarts[[1L]])}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } pb$interrupt() paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
35: withRestartList(expr, restarts[-nr])60: if (is_R_CMD_build() || is_R_CMD_check())
error <<- format(e)51: process_file(text, output)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
tools:::.buildOneVignette("mnl_models.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", }), list(rlang_trace_top_env = knit_global())) watcher$capture_plot_and_output()
36: 50: if (on_warning$capture) {doWithOneRestart(return(expr), restart) cnd <- sanitize_call(cnd) TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/RtmptxoWky/file2eaf44e6c581.rds")
An irrecoverable exception occurred. R is aborting now ...
53:
xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), 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)
watcher$push(cnd) } output_dir = getwd(), ...)37: 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: 51: eval(call)
31: eval(call)
process_file(text, output)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) }withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
39: 54: TRUE}, handlers)
33: vweave_rmarkdown(...)withRestarts(with_handlers({
55: engine$weave(file, quiet = quiet, encoding = enc)
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)
doWithOneRestart(return(expr), restart)
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
53: 56: doTryCatch(return(expr), name, parentenv, handler)
57:
40: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), evaluate::evaluate(...)tryCatchOne(expr, names, parentenv, handlers[[1L]])34: output_dir = getwd(), ...)withOneRestart(expr, restarts[[1L]])
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 {
54: if (options$error && options$include) 35: 0L58: 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)vweave_rmarkdown(...) output <- find_vignette_product(name, by = "texi2pdf", else 2L }, output_handler = knit_handlers(options$render, options))
withRestartList(expr, restarts[-nr])
36:
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doWithOneRestart(return(expr), restart)doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58:
42: tryCatchList(expr, classes, parentenv, handlers)in_dir(input_dir(), expr)37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
engine = engine)
43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, }}, error = function(e) { OK <<- FALSE38: withRestartList(expr, restarts)59:
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)
tryCatch({ message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", 39: 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/RtmptxoWky/file2eaf44e6c581.rds")
withRestarts(with_handlers({ engine$weave(file, quiet = quiet, encoding = enc)45: block_exec(params)
46: call_block(x)
47: An irrecoverable exception occurred. R is aborting now ...
process_group(group) setwd(startdir) for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() output <- find_vignette_product(name, by = "weave", engine = engine) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet) watcher$print_value(ev$value, ev$visible, envir) output <- find_vignette_product(name, by = "texi2pdf",
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)) } engine = engine) } 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: TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: }, error = function(e) { OK <<- FALSEevaluate::evaluate(...) 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/RtmptxoWky/file2eaf44e6c581.rds")
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 {rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), if (options$error && options$include) output_dir = getwd(), ...) 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: An irrecoverable exception occurred. R is aborting now ...
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:
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/RtmptxoWky/file2eaf44e6c581.rds")
An irrecoverable exception occurred. R is aborting now ...
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/RtmptxoWky/file2eaf44e6c581.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'
*** 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)
*** caught segfault ***
address 0x110, cause 'invalid permissions'
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6:
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
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) {})
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
8: system.time({ model <- mi$model result <- NULL 4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { })tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution 7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
8: model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }})
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: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
}, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE13: tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) { call <- conditionCall(e) 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]], ...) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) 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: 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)) 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]], ...)})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18:
18: lapply(seq_len(cores), inner.do)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))
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"))
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, 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) {
*** caught segfault ***
address 0x110, cause 'invalid permissions'
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:
} TRUE 1: runModel, mc.cores = numCores)))
*** caught segfault ***
address 0x110, cause 'invalid permissions'
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)
}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
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)
*** caught segfault ***
address 0x110, cause 'invalid permissions'
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({26: 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)))})
result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})eval(expr, envir)
60:
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)
*** caught segfault ***
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", 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/RtmptxoWky/file2eaf37970973.rds")
An irrecoverable exception occurred. R is aborting now ...
address 0x110, cause 'invalid permissions'
"bev150", "american", "japanese", "chinese", "skorean",
Traceback:
1: "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), 27: eval(expr, envir)
28: withVisible(eval(expr, envir))
mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: 29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() scalePar = "price", robust = TRUE, numMultiStarts = 10)
26: eval(expr, envir)
27: eval(expr, envir)
28: withVisible(eval(expr, envir))
eval_f(x0, ...) if (on_message$capture) {29:
withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) }
Traceback:
}, 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) 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...) } 3:
Traceback:
{ if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) 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, cnd <- sanitize_call(cnd) mi = mi, opts = mi$options)
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: 4: watcher$push(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)}) } 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:
30: eval(call)
doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
tryCatchList(expr, classes, parentenv, handlers)
6: tryCatchList(expr, classes, parentenv, handlers)
7: 31: eval(call)
32: with_handlers({eval(call) 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
tryCatch({ for (expr in tle$exprs) { result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
31: }, error = function(e) { ev <- withVisible(eval(expr, envir))}) watcher$capture_plot_and_output() 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
eval(call) result <- NULL tryCatch({
4: doTryCatch(return(expr), name, parentenv, handler)
8: result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
Traceback:
system.time({ model <- mi$model result <- NULL mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution 1: tryCatch({32: model$logLik <- as.numeric(-1 * result$objective)with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) model$iterations <- result$iterations result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, watcher$capture_plot_and_output() 7: watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers)
33: watcher$print_value(ev$value, ev$visible, envir)doWithOneRestart(return(expr), restart)
model$status <- result$status } TRUE}, handlers) model$message <- result$message }})
34: mi = mi, opts = mi$options)
33: doWithOneRestart(return(expr), restart)
mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: withOneRestart(expr, restarts[[1L]]) 9: 34: withOneRestart(expr, restarts[[1L]])
eval_f(x0, ...)35: withRestartList(expr, restarts[-nr])
36: FUN(X[[i]], ...)
35: doWithOneRestart(return(expr), restart)
withRestartList(expr, restarts[-nr]) 3:
nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective,
10: }, error = function(e) {tryCatch({lapply(X = S, FUN = FUN, ...) })36:
result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, doWithOneRestart(return(expr), restart) mi = mi, opts = mi$options)11: doTryCatch(return(expr), name, parentenv, handler)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
37: 4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]]) mi = mi, opts = mi$options)withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
}, error = function(e) {})
8: system.time({ if (!is.null(result)) {38: 38: model <- mi$modelwithRestartList(expr, restarts) model$fail <- FALSE result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, model$coefficients <- result$solutionwithRestartList(expr, restarts)
39: model$logLik <- as.numeric(-1 * result$objective)
6: tryCatchList(expr, classes, parentenv, handlers) model$iterations <- result$iterations
mi = mi, opts = mi$options) model$status <- result$status model$message <- result$message }})
9: 12:
39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) }, error = function(e) {FUN(X[[i]], ...)
10: })withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output()lapply(X = S, FUN = FUN, ...)
watcher$print_value(ev$value, ev$visible, envir) 7: tryCatch({ if (!is.null(result)) { result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, model$fail <- FALSEtryCatchOne(expr, names, parentenv, handlers[[1L]])11: mi = mi, opts = mi$options)}, error = function(e) {
} watcher$capture_plot_and_output()doTryCatch(return(expr), name, parentenv, handler)
watcher$print_value(ev$value, ev$visible, envir) }}) model$coefficients <- result$solution TRUE model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status
}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
8: system.time({ model$message <- result$message }13: 12: TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
tryCatchOne(expr, names, parentenv, handlers[[1L]])tryCatchList(expr, classes, parentenv, handlers) model <- mi$model
13: tryCatchList(expr, classes, parentenv, handlers)
})41:
9: 14: 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,
result <- NULL14: 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)FUN(X[[i]], ...)tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch)))
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
prefix <- paste("Error in", dcall, ": ") tryCatch({ call <- sys.call(-4L) LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(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))
42: in_dir(input_dir(), expr)12: 40: evaluate::evaluate(...)
tryCatchOne(expr, names, parentenv, handlers[[1L]])
dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ") LONG <- 75L43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, 41:
*** caught segfault ***
address 0x110, cause 'invalid permissions'
sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") }) 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 (is.na(w))
w <- 14L + nchar(dcall, type = "b") + nchar(sm[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") }})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)13: tryCatchList(expr, classes, parentenv, handlers)
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) 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) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) if (w > LONG) 14: 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 { .Internal(printDeferredWarnings()) dcall <- deparse(call, nlines = 1L) } prefix <- paste0(prefix, "\n ") 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 } 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))})tryCatch(expr, error = function(e) { prefix <- paste("Error in", dcall, ": ") LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") }, output_handler = knit_handlers(options$render, options)))
44: invisible(structure(msg, class = "try-error", condition = e)) if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))
42: })
if (is.na(w)) eng_r(options)
45: block_exec(params)15:
try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], in_dir(input_dir(), expr)
46:
call <- conditionCall(e)15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
call_block(x)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
43: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
type = "b")17: if (!is.null(call)) { if (w > LONG) in_input_dir(evaluate(code, envir = env, new_device = FALSE, prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L]))47: FUN(X[[i]], ...) if (!silent && isTRUE(getOption("show.error.messages"))) { 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)
if (options$error && options$include) 0L else 2L if (identical(call[[1L]], quote(doTryCatch))) }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
17: 18: lapply(seq_len(cores), inner.do)
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, cat(msg, file = outFile)45: FUN(X[[i]], ...) classes)) tryInvokeRestart("muffleWarning"))
call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) .Internal(printDeferredWarnings()) prefix <- paste("Error in", dcall, ": ") LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]]
Traceback:
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") error = function(e) {block_exec(params)
if (progress && is.function(pb$interrupt)) 46: call_block(x) 1: pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) })47:
if (is.na(w)) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], withCallingHandlers(expr, message = function(c) if (inherits(c, invisible(structure(msg, class = "try-error", condition = e))18: classes)) tryInvokeRestart("muffleMessage"))
23: type = "b")lapply(seq_len(cores), inner.do)}) 2:
eval_f(x0, ...) if (w > LONG) prefix <- paste0(prefix, "\n ")49:
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: process_group(group)
48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), suppressMessages(suppressWarnings(parallel::mclapply(miList, 15: else prefix <- "Error : "try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: runModel, mc.cores = numCores)))
24: runMultistart(modelInputs)
25: logitr(data = cars_us, outcome = "choice", obsID = "obsnum",
pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { 4: msg <- paste0(prefix, conditionMessage(e), "\n") "bev150", "american", "japanese", "chinese", "skorean", .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))})FUN(X[[i]], ...)doTryCatch(return(expr), name, parentenv, handler)
withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
error = function(e) {18: 21: 5: tryCatchOne(expr, names, parentenv, handlers[[1L]])lapply(seq_len(cores), inner.do)suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
22: withCallingHandlers(expr, message = function(c) if (inherits(c,
if (progress && is.function(pb$interrupt)) pb$interrupt()15: classes)) tryInvokeRestart("muffleMessage"))
6: tryCatchList(expr, classes, parentenv, handlers)
if (is_R_CMD_build() || is_R_CMD_check())
try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
7: 19: "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), error <<- format(e) if (progress && is.function(pb$interrupt)) scalePar = "price", robust = TRUE, numMultiStarts = 10)tryCatch({
26: eval(expr, envir)parallel::mclapply(miList, runModel, mc.cores = numCores) pb$interrupt() }), list(rlang_trace_top_env = knit_global())) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective,
if (is_R_CMD_build() || is_R_CMD_check()) 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))20: error <<- format(e) mi = mi, opts = mi$options)
withCallingHandlers(expr, warning = function(w) if (inherits(w,
27:
}, error = function(e) {})
8: 24: eval(expr, envir)16: 50: classes)) tryInvokeRestart("muffleWarning"))sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
*** caught segfault ***
})address 0x110, cause 'invalid permissions'
runMultistart(modelInputs)18: lapply(seq_len(cores), inner.do)
xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {28: withVisible(eval(expr, envir))
if (progress && is.function(pb$interrupt))
25: logitr(data = cars_us, outcome = "choice", obsID = "obsnum", pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", "bev150", "american", "japanese", "chinese", "skorean", 21: 29: 49: withCallingHandlers(code, error = function (e) pb$interrupt()system.time({suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) model <- mi$model result <- NULL19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) tryCatch({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) {with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), if (is_R_CMD_build() || is_R_CMD_check()) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, error = function(e) {
if (getOption("warn") >= 2 || getOption("warn") < 0) {
error <<- format(e)22: 21: mi = mi, opts = mi$options) return()suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
"phevFastcharge", "bevFastcharge", "opCost", "accelTime"), if (progress && is.function(pb$interrupt)) }, error = function(e) { }), list(rlang_trace_top_env = knit_global())), function(loc) { }) setwd(wd) if (!is.null(result)) {23:
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)
22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))) pb$interrupt()
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, } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd)
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
*** caught segfault ***
if (is_R_CMD_build() || is_R_CMD_check()) scalePar = "price", robust = TRUE, numMultiStarts = 10)
} 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 stop_on_error = if (is.numeric(options$error)) options$error else {
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)) 53: suppressMessages(suppressWarnings(parallel::mclapply(miList, if (options$error && options$include) if (on_warning$silence) { 3: address 0x110, cause 'invalid permissions'
0L 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: } 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: })rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), eval(expr, envir) pb$interrupt()26: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, if (is_R_CMD_build() || is_R_CMD_check()) output_dir = getwd(), ...)
invokeRestart("muffleWarning")27: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error <<- format(e)
eval(expr, envir) 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: }), 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) 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"), stop = invokeRestart("eval_stop"), error = NULL)})
30: eval(call)
31: eval(call)
32: 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(), tryCatchList(expr, classes, parentenv, handlers)
with_handlers({ 9: 7:
27: eval(expr, envir) output_dir = getwd(), ...)tryCatch({
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() } for (expr in tle$exprs) {
watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning")54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
4: 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: FUN(X[[i]], ...) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 51: 57: 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: tryCatchList(expr, classes, parentenv, handlers)eval(expr, envir) }
28: withVisible(eval(expr, envir))
29: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) {tryCatchOne(expr, names, parentenv, handlers[[1L]])doTryCatch(return(expr), name, parentenv, handler) mi = mi, opts = mi$options)
vweave_rmarkdown(...)}, error = function(e) { watcher$capture_plot_and_output()
if (on_message$capture) {}, error = function (cnd)
})10: 58: 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)tryCatchList(expr, classes, parentenv, handlers)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) 5:
{ }lapply(X = S, FUN = FUN, ...)
59:
watcher$capture_plot_and_output()
if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output()tryCatchOne(expr, names, parentenv, handlers[[1L]]) watcher$print_value(ev$value, ev$visible, envir) } cnd <- sanitize_call(cnd)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/RtmptxoWky/file2eaf37970973.rds")
An irrecoverable exception occurred. R is aborting now ...
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)11: 59: 59:
TRUE cnd <- sanitize_call(cnd) watcher$push(cnd)}, handlers)tryCatch({
tryCatch({doTryCatch(return(expr), name, parentenv, handler) switch(on_error, continue = invokeRestart("eval_continue"),
6: stop = invokeRestart("eval_stop"), error = NULL) engine$weave(file, quiet = quiet, encoding = enc)12: watcher$push(cnd) setwd(startdir)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)33: 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)))})
doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: switch(on_error, continue = invokeRestart("eval_continue"), dcall <- deparse(call, nlines = 1L)tryCatchList(expr, classes, parentenv, handlers)})
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/RtmptxoWky/file2eaf37970973.rds")
An irrecoverable exception occurred. R is aborting now ...
engine$weave(file, quiet = quiet, encoding = enc) prefix <- paste("Error in", dcall, ": ")
withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) 7: setwd(startdir)tryCatch({
LONG <- 75L output <- find_vignette_product(name, by = "weave", engine = engine)12: 30: sm <- strsplit(conditionMessage(e), "\n")[[1L]] if (!have.makefile && vignette_is_tex(output)) { stop = invokeRestart("eval_stop"), error = NULL) 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$modeltryCatchOne(expr, names, parentenv, handlers[[1L]]) texi2pdf(file = output, clean = FALSE, quiet = quiet)}) w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (is.na(w)) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], eval(call) output <- find_vignette_product(name, by = "texi2pdf", 38:
31: eval(call)
32: engine = engine)
13: tryCatchList(expr, classes, parentenv, handlers)
result <- NULL
with_handlers({14: withRestartList(expr, restarts) type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") for (expr in tle$exprs) {tryCatch(expr, error = function(e) { 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: call <- conditionCall(e) tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(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))30: }) .Internal(seterrmessage(msg[1L]))
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 (!is.null(result)) {17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do) if (!silent && isTRUE(getOption("show.error.messages"))) { 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options) model$fail <- FALSE cat(msg, file = outFile) model$coefficients <- result$solution
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:
}, error = function(e) {
19: parallel::mclapply(miList, runModel, mc.cores = numCores)
20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))
21: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))})eval(call)suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
OK <<- FALSE keep_message = if (is.numeric(options$message)) TRUE else options$message,
message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", 45: 22: model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterationswithCallingHandlers(expr, message = function(c) if (inherits(c,
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) stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 31: 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/RtmptxoWky/file2eaf37970973.rds")
An irrecoverable exception occurred. R is aborting now ...
classes)) tryInvokeRestart("muffleMessage"))
block_exec(params)
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) 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,
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) { 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 call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) 15: call <- sys.call(-4L)
try(lapply(X = S, FUN = FUN, ...), silent = TRUE)46: 26: eval(expr, envir)
27: call_block(x)
47: process_group(group)
eval(call) }, output_handler = knit_handlers(options$render, options)))
32: 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
with_handlers({
eval(expr, envir)17: FUN(X[[i]], ...)
18: for (expr in tle$exprs) {48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 44: lapply(seq_len(cores), inner.do)eng_r(options)
dcall <- deparse(call, nlines = 1L)45: ev <- withVisible(eval(expr, envir))28:
error = function(e) {19: parallel::mclapply(miList, runModel, mc.cores = numCores)block_exec(params) if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) withVisible(eval(expr, envir)) error <<- format(e)
prefix <- paste("Error in", dcall, ": ") })20:
29: 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], watcher$capture_plot_and_output() type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") watcher$print_value(ev$value, ev$visible, envir)withCallingHandlers(expr, warning = function(w) if (inherits(w, }46: TRUE classes)) tryInvokeRestart("muffleWarning"))
withCallingHandlers(code, error = function (e) 49: 21: }, handlers)with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))call_block(x)rlang::entrace(e), message = function (cnd)
{ error = function(e) {33: 47: }process_group(group) watcher$capture_plot_and_output()
48: 22: doWithOneRestart(return(expr), restart)withCallingHandlers(expr, message = function(c) if (inherits(c, if (on_message$capture) { else prefix <- "Error : " classes)) tryInvokeRestart("muffleMessage")) watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage")
if (progress && is.function(pb$interrupt)) msg <- paste0(prefix, conditionMessage(e), "\n") }34:
withOneRestart(expr, restarts[[1L]]) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e)withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),
23: suppressMessages(suppressWarnings(parallel::mclapply(miList, 35: }), list(rlang_trace_top_env = knit_global()))}, warning = function (cnd) runModel, mc.cores = numCores)))
withRestartList(expr, restarts[-nr])
.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)) error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt(){24: if (is_R_CMD_build() || is_R_CMD_check())
runMultistart(modelInputs)50: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),
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)) 36: if (getOption("warn") >= 2 || getOption("warn") < 0) { return() error = function(e) {25: if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) })
doWithOneRestart(return(expr), restart) } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
watcher$push(cnd)15: 39: } error <<- format(e) }), list(rlang_trace_top_env = knit_global())), function(loc) { setwd(wd)try(lapply(X = S, FUN = FUN, ...), silent = TRUE) if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) pb$interrupt()logitr(data = cars_us, outcome = "choice", obsID = "obsnum", write_utf8(res, output %n% stdout())
if (is_R_CMD_build() || is_R_CMD_check()) paste0("\nQuitting from ", loc, if (!is.null(error)) withRestarts(with_handlers({16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: 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), for (expr in tle$exprs) { pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", paste0("\n", rule(), error, "\n", rule())) error = function(e) { ev <- withVisible(eval(expr, envir)){ watcher$capture_plot_and_output()}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) if (progress && is.function(pb$interrupt)) "bev150", "american", "japanese", "chinese", "skorean", cnd <- sanitize_call(cnd) watcher$push(cnd) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), FUN(X[[i]], ...)
18: } scalePar = "price", robust = TRUE, numMultiStarts = 10)
TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)51: switch(on_error, continue = invokeRestart("eval_continue"), lapply(seq_len(cores), inner.do)process_file(text, output) stop = invokeRestart("eval_stop"), error = NULL)
26:
19: pb$interrupt()
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, 52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
if (is_R_CMD_build() || is_R_CMD_check()) })
30: 53: eval(expr, envir)
27: eval(expr, envir)
28: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)
54: withVisible(eval(expr, envir))40: evaluate::evaluate(...)
vweave_rmarkdown(...)
55:
error <<- format(e)engine$weave(file, quiet = quiet, encoding = enc)41: 29: }), list(rlang_trace_top_env = knit_global())), function(loc) {evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, withCallingHandlers(code, error = function (e)
setwd(wd) keep_message = if (is.numeric(options$message)) TRUE else options$message, 56: stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) eval(call) 0L else 2LdoTryCatch(return(expr), name, parentenv, handler)
classes)) tryInvokeRestart("muffleMessage"))rlang::entrace(e), message = function (cnd) write_utf8(res, output %n% stdout())
23:
paste0("\nQuitting from ", loc, if (!is.null(error)) { watcher$capture_plot_and_output() }, output_handler = knit_handlers(options$render, options))31: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)))
24: runMultistart(modelInputs) paste0("\n", rule(), error, "\n", rule()))
if (on_message$capture) {eval(call)
}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)25:
watcher$push(cnd)51: 57: 32: logitr(data = cars_us, outcome = "choice", obsID = "obsnum", tryCatchOne(expr, names, parentenv, handlers[[1L]])
with_handlers({
58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) for (expr in tle$exprs) {42: process_file(text, output) setwd(startdir) } pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", 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, ev <- withVisible(eval(expr, envir)) 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) { "bev150", "american", "japanese", "chinese", "skorean", "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), scalePar = "price", robust = TRUE, numMultiStarts = 10)
26: OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
keep_message = if (is.numeric(options$message)) TRUE else options$message, watcher$capture_plot_and_output()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/RtmptxoWky/file2eaf37970973.rds")
An irrecoverable exception occurred. R is aborting now ...
stop_on_error = if (is.numeric(options$error)) options$error else {eval(expr, envir) watcher$print_value(ev$value, ev$visible, envir) if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)
if (on_message$silence) {
52: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)45:
invokeRestart("muffleMessage")
block_exec(params)
53: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) }46: call_block(x)
47: }, warning = function (cnd) } TRUE27: }, handlers)
33: doWithOneRestart(return(expr), restart)
{ if (getOption("warn") >= 2 || getOption("warn") < 0) {
34: withOneRestart(expr, restarts[[1L]])
process_group(group)35:
54: 48: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
38: 56: error = function(e) {eval(expr, envir)
withRestartList(expr, restarts)
39: return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) if (progress && is.function(pb$interrupt)) withRestarts(with_handlers({ pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) }) for (expr in tle$exprs) { watcher$push(cnd) }28: ev <- withVisible(eval(expr, envir))withVisible(eval(expr, envir))
doTryCatch(return(expr), name, parentenv, handler)
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 29: watcher$capture_plot_and_output() if (on_warning$silence) { watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: invokeRestart("muffleWarning") }}, error = function (cnd)
error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) 57: error <<- format(e)tryCatchOne(expr, names, parentenv, handlers[[1L]]) }), list(rlang_trace_top_env = knit_global()))withCallingHandlers(code, error = function (e) evaluate::evaluate(...)
58: tryCatchList(expr, classes, parentenv, handlers)
{ watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd)
switch(on_error, continue = invokeRestart("eval_continue"), rlang::entrace(e), message = function (cnd) stop = invokeRestart("eval_stop"), error = NULL)
{ watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) {})
30: eval(call)
31: eval(call)
32: with_handlers({41: for (expr in tle$exprs) {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()) 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)) {evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, error <<- format(e) texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) } keep_message = if (is.numeric(options$message)) TRUE else options$message, invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { ev <- withVisible(eval(expr, envir)) return() stop_on_error = if (is.numeric(options$error)) options$error else {}, error = function(e) { }), list(rlang_trace_top_env = knit_global())), function(loc) { if (options$error && options$include) setwd(wd) write_utf8(res, output %n% stdout()) OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})
0L60: 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/RtmptxoWky/file2eaf37970973.rds")
else 2L } 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)}) watcher$capture_plot_and_output() }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr) watcher$print_value(ev$value, ev$visible, envir)An irrecoverable exception occurred. R is aborting now ...
}
TRUE
}, handlers)
33: doWithOneRestart(return(expr), restart)30: eval(call)
43: paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
34: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, withOneRestart(expr, restarts[[1L]]) keep_message = if (is.numeric(options$message)) TRUE else options$message,
35: withRestartList(expr, restarts[-nr])51: process_file(text, output)31:
eval(call)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)
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: doTryCatch(return(expr), name, parentenv, handler)
36:
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
58: 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) }eng_r(options)
TRUE}, handlers)
33: doWithOneRestart(return(expr), restart)
34: withOneRestart(expr, restarts[[1L]])tryCatchList(expr, classes, parentenv, handlers)45: block_exec(params)
doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
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)) {46: texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) {
call_block(x)
47: process_group(group)
48: OK <<- FALSE39: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), withRestarts(with_handlers({ message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s",
35: withRestartList(expr, restarts[-nr])
error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) 36: doWithOneRestart(return(expr), restart)
37: 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/RtmptxoWky/file2eaf37970973.rds")
An irrecoverable exception occurred. R is aborting now ...
withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: error <<- format(e) for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir))withRestartList(expr, restarts)
watcher$capture_plot_and_output()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(...)
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()) watcher$print_value(ev$value, ev$visible, envir) } TRUE error <<- format(e) }), list(rlang_trace_top_env = knit_global()))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
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())}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
40: evaluate::evaluate(...)
41: 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(), ...) else 2L }, output_handler = knit_handlers(options$render, options))
54: vweave_rmarkdown(...)
55: engine$weave(file, quiet = quiet, encoding = enc)
56: doTryCatch(return(expr), name, parentenv, handler)
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) 0L42: in_dir(input_dir(), expr) else 2L }, output_handler = knit_handlers(options$render, options))
42: in_dir(input_dir(), expr)
43:
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)))
in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, 44: eng_r(options)
45: block_exec(params) 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
46: call_block(x)
}, output_handler = knit_handlers(options$render, options)))
44: eng_r(options)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)47: output <- find_vignette_product(name, by = "texi2pdf", 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: engine = engine) }}, error = function(e) {with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s",
45: block_exec(params)
46: call_block(x)
47: file, conditionMessage(e)))})
process_group(group)
48: 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/RtmptxoWky/file2eaf37970973.rds")
An irrecoverable exception occurred. R is aborting now ...
withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 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())) error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(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) })
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())
56: doTryCatch(return(expr), name, parentenv, handler)
57: tryCatchOne(expr, names, parentenv, handlers[[1L]])
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()))58: tryCatchList(expr, classes, parentenv, handlers)
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc)}, 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: setwd(startdir)engine$weave(file, quiet = quiet, encoding = enc)
56: 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", 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) engine = engine) }}, error = function(e) { OK <<- FALSE 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/RtmptxoWky/file2eaf37970973.rds")
An irrecoverable exception occurred. R is aborting now ...
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/RtmptxoWky/file2eaf37970973.rds")
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:
*** 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 = 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/RtmptxoWky/file2eaf64e95401.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/RtmptxoWky/file2eaf64e95401.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 = 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/RtmptxoWky/file2eaf64e95401.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)) 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)
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)
*** caught segfault ***
address 0x110, cause 'invalid permissions'
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)
4:
59: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir)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, 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 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: 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/RtmptxoWky/file2eaf64e95401.rds")
An irrecoverable exception occurred. R is aborting now ...
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/RtmptxoWky/file2eaf64e95401.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 = 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/RtmptxoWky/file2eaf64e95401.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'
*** 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:
Traceback:
1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2: eval_f(x0, ...)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/RtmptxoWky/file2eaf64e95401.rds")
Traceback:
Traceback:
1: 3: 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: An irrecoverable exception occurred. R is aborting now ...
2: doTryCatch(return(expr), name, parentenv, handler) 1: eval_f(x0, ...)mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)
2:
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, eval_f(x0, ...)
3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective,
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ mi = mi, opts = mi$options)}, error = function(e) { mi = mi, opts = mi$options) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})
}) 8:
8: system.time({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) model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, }, error = function(e) { 4: mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solutiondoTryCatch(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) {}) }) if (!is.null(result)) { model$fail <- FALSE
8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- 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 mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message } model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status}) 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)})
9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler)
12: model$message <- result$message }tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) {})
9: FUN(X[[i]], ...)
prefix <- paste("Error in", dcall, ": ")10: lapply(X = S, FUN = FUN, ...)
11: doTryCatch(return(expr), name, parentenv, handler) LONG <- 75L
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
sm <- strsplit(conditionMessage(e), "\n")[[1L]] call <- conditionCall(e)13: 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 (!is.null(call)) { } 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))})tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) {
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
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")16: if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ")sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) 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 : " 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], msg <- paste0(prefix, conditionMessage(e), "\n") type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ")
}17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do) else prefix <- "Error : " .Internal(seterrmessage(msg[1L])) 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))})
if (!silent && isTRUE(getOption("show.error.messages"))) {19: cat(msg, file = outFile) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))parallel::mclapply(miList, runModel, mc.cores = numCores)})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
16:
sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))20: 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
17: FUN(X[[i]], ...)
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, 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)) runModel, mc.cores = numCores)))withCallingHandlers(expr, warning = function(w) if (inherits(w,
29: withCallingHandlers(code, error = function (e) 24: classes)) tryInvokeRestart("muffleWarning"))
21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))
runMultistart(modelInputs)22: rlang::entrace(e), message = function (cnd)
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: { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) 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) {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 (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) if (on_warning$silence) { watcher$push(cnd) invokeRestart("muffleMessage") }}, warning = function (cnd) switch(on_error, continue = invokeRestart("eval_continue"), invokeRestart("muffleWarning") 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) 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)34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
}, 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)38:
32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir))withRestartList(expr, restarts) watcher$capture_plot_and_output()}) watcher$print_value(ev$value, ev$visible, envir)
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) }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))
TRUE42: 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, }, 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)) keep_message = if (is.numeric(options$message)) TRUE else options$message, 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 { 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:
if (options$error && options$include) 33: 0LdoWithOneRestart(return(expr), restart) else 2L }, output_handler = knit_handlers(options$render, 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) })
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)))
49:
34: withOneRestart(expr, restarts[[1L]])
35: withRestartList(expr, restarts[-nr])44: eng_r(options)
45: block_exec(params)
46: call_block(x)
47:
36: doWithOneRestart(return(expr), restart)
37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
38: withRestartList(expr, restarts)
process_group(group)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)))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),
44: eng_r(options) error = function(e) {
if (progress && is.function(pb$interrupt))
45: block_exec(params)
46: call_block(x)
47: process_group(group)
48: 48: pb$interrupt()withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) if (is_R_CMD_build() || is_R_CMD_check()) pb$interrupt() if (is_R_CMD_build() || is_R_CMD_check()) error <<- format(e) })
49: error <<- format(e)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()) }), 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: error = function(e) { if (progress && is.function(pb$interrupt)) 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)process_file(text, output)
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:
pb$interrupt()52: if (is_R_CMD_build() || is_R_CMD_check()) tryCatchList(expr, classes, parentenv, handlers)
59: 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) error <<- format(e) 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)tryCatch({ }) engine$weave(file, quiet = quiet, encoding = enc) 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)))})
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/RtmptxoWky/file2eaf64e95401.rds")
An irrecoverable exception occurred. R is aborting now ...
49: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {60: if (progress && is.function(pb$interrupt)) 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/RtmptxoWky/file2eaf64e95401.rds")
An irrecoverable exception occurred. R is aborting now ...
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/RtmptxoWky/file2eaf64e95401.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
Current CRAN status: OK: 13