CRAN Package Check Results for Package logitr

Last updated on 2025-12-02 01:49:46 CET.

Flavor Version Tinstall Tcheck Ttotal Status Flags
r-devel-linux-x86_64-debian-clang 1.1.3 4.97 149.97 154.94 OK
r-devel-linux-x86_64-debian-gcc 1.1.3 3.48 115.94 119.42 OK
r-devel-linux-x86_64-fedora-clang 1.1.3 11.00 OK
r-devel-linux-x86_64-fedora-gcc 1.1.3 11.00 243.49 254.49 OK
r-devel-windows-x86_64 1.1.2 11.00 207.00 218.00 OK
r-patched-linux-x86_64 1.1.3 4.73 142.81 147.54 OK
r-release-linux-x86_64 1.1.3 5.05 144.50 149.55 OK
r-release-macos-arm64 1.1.3 1.00 45.00 46.00 ERROR
r-release-macos-x86_64 1.1.3 5.00 178.00 183.00 OK
r-release-windows-x86_64 1.1.2 9.00 208.00 217.00 OK
r-oldrel-macos-arm64 1.1.3 1.00 51.00 52.00 OK
r-oldrel-macos-x86_64 1.1.3 7.00 202.00 209.00 OK
r-oldrel-windows-x86_64 1.1.3 12.00 255.00 267.00 OK

Check Details

Version: 1.1.3
Check: examples
Result: ERROR Running examples in ‘logitr-Ex.R’ failed The error most likely occurred in: > ### Name: logitr > ### Title: The main function for estimating logit models > ### Aliases: logitr > ### Keywords: logit logitr mixed mnl mxl willingness-to-pay wtp > > ### ** Examples > > # For more detailed examples, visit > # https://jhelvy.github.io/logitr/articles/ > > library(logitr) > > # Estimate a MNL model in the Preference space > mnl_pref <- logitr( + data = yogurt, + outcome = "choice", + obsID = "obsID", + pars = c("price", "feat", "brand") + ) Running model... Done! > > # Estimate a MNL model in the WTP space, using a 5-run multistart > mnl_wtp <- logitr( + data = yogurt, + outcome = "choice", + obsID = "obsID", + pars = c("feat", "brand"), + scalePar = "price", + numMultiStarts = 5 + ) Running multistart... Random starting point iterations: 5 Number of cores: 15 *** caught segfault *** address 0x110, cause 'invalid permissions' Traceback: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 2: eval_f(x0, ...) 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) 4: doTryCatch(return(expr), name, parentenv, handler) 5: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 6: tryCatchList(expr, classes, parentenv, handlers) 7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {}) 8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }}) 9: FUN(X[[i]], ...) 10: lapply(X = S, FUN = FUN, ...) 11: doTryCatch(return(expr), name, parentenv, handler) 12: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 13: tryCatchList(expr, classes, parentenv, handlers) 14: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ") LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (is.na(w)) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))}) 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) 17: FUN(X[[i]], ...) 18: lapply(seq_len(cores), inner.do) 19: parallel::mclapply(miList, runModel, mc.cores = numCores) 20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) 21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) 22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage")) 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))) 24: runMultistart(modelInputs) 25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 5) An irrecoverable exception occurred. R is aborting now ... *** caught segfault *** address 0x110, cause 'invalid permissions' *** caught segfault *** address 0x110, cause 'invalid permissions' *** 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, ...) Traceback: 1: 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: 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) 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({ 7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {}) 8: result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) Traceback: }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solutionsystem.time({ model$logLik <- as.numeric(-1 * result$objective) 1: Traceback: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) model <- mi$model 2: eval_f(x0, ...) 1: model$iterations <- result$iterations 3: result <- NULL model$status <- result$statusnloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) mi = mi, opts = mi$options) tryCatch({ 4: doTryCatch(return(expr), name, parentenv, handler) 5: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 6: model$message <- result$message result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, } mi = mi, opts = mi$options)}) 2: eval_f(x0, ...) tryCatchList(expr, classes, parentenv, handlers) 9: 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 7: tryCatch({ }, 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 result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, FUN(X[[i]], ...) 10: }lapply(X = S, FUN = FUN, ...)}) mi = mi, opts = mi$options) }, error = function(e) { mi = mi, opts = mi$options) 9: 4: doTryCatch(return(expr), name, parentenv, handler) 5: tryCatchOne(expr, names, parentenv, handlers[[1L]])}) 11: doTryCatch(return(expr), name, parentenv, handler)FUN(X[[i]], ...) 8: 6: system.time({ model <- mi$modeltryCatchList(expr, classes, parentenv, handlers) result <- NULL10: lapply(X = S, FUN = FUN, ...) tryCatch({12: result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, tryCatchOne(expr, names, parentenv, handlers[[1L]])11: 7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) { mi = mi, opts = mi$options)}) }, error = function(e) { })doTryCatch(return(expr), name, parentenv, handler) if (!is.null(result)) { model$fail <- FALSE 12: model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message } tryCatchOne(expr, names, parentenv, handlers[[1L]])13: 8: })13: 9: FUN(X[[i]], ...) 10: lapply(X = S, FUN = FUN, ...) 11: doTryCatch(return(expr), name, parentenv, handler)system.time({tryCatchList(expr, classes, parentenv, handlers) 12: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 13: tryCatchList(expr, classes, parentenv, handlers) model <- mi$model 14: result <- NULLtryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) dcall <- deparse(call, nlines = 1L)tryCatchList(expr, classes, parentenv, handlers) 14: prefix <- paste("Error in", dcall, ": ")14: }, error = function(e) { LONG <- 75LtryCatch(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 <- 75LtryCatch(expr, error = function(e) { }) sm <- strsplit(conditionMessage(e), "\n")[[1L]] if (!is.null(result)) { sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (is.na(w)) call <- conditionCall(e) 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)) { 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 = "b") + nchar(sm[1L], model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") model$status <- result$status type = "b") model$message <- result$message if (w > LONG) } 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") prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L])) .Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) } if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) invisible(structure(msg, class = "try-error", condition = e)) } else prefix <- "Error : "}) msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L])) })15: if (!silent && isTRUE(getOption("show.error.messages"))) { 9: cat(msg, file = outFile)FUN(X[[i]], ...) 10: lapply(X = S, FUN = FUN, ...) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))}) 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)11: .Internal(printDeferredWarnings())try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 16: }16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) 17: FUN(X[[i]], ...) 18: lapply(seq_len(cores), inner.do)17: doTryCatch(return(expr), name, parentenv, handler) 12: tryCatchOne(expr, names, parentenv, handlers[[1L]]) invisible(structure(msg, class = "try-error", condition = e))13: 19: tryCatchList(expr, classes, parentenv, handlers)FUN(X[[i]], ...)})parallel::mclapply(miList, runModel, mc.cores = numCores) 14: tryCatch(expr, error = function(e) {15: 18: 20: lapply(seq_len(cores), inner.do)try(lapply(X = S, FUN = FUN, ...), silent = TRUE)withCallingHandlers(expr, warning = function(w) if (inherits(w, 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, classes)) tryInvokeRestart("muffleWarning")) call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) 21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) runModel, mc.cores = numCores))) 24: 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: runMultistart(modelInputs) prefix <- paste("Error in", dcall, ": ") LONG <- 75L 25: 22: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 5)withCallingHandlers(expr, message = function(c) if (inherits(c, sm <- strsplit(conditionMessage(e), "\n")[[1L]]withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) An irrecoverable exception occurred. R is aborting now ... 21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) classes)) tryInvokeRestart("muffleMessage")) 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))) 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()) }24: runMultistart(modelInputs)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) invisible(structure(msg, class = "try-error", condition = e))25: }) 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 5) An irrecoverable exception occurred. R is aborting now ... 16: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) "brand"), scalePar = "price", numMultiStarts = 5) 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")) An irrecoverable exception occurred. R is aborting now ... 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))) 24: runMultistart(modelInputs) 25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 5) An irrecoverable exception occurred. R is aborting now ... Error in names(x) <- value : 'names' attribute [3] must be the same length as the vector [0] Calls: logitr -> getMultistartSummary -> colnames<- Execution halted Flavor: r-release-macos-arm64

Version: 1.1.3
Check: re-building of vignette outputs
Result: ERROR Error(s) in re-building vignettes: --- re-building ‘basic_usage.Rmd’ using rmarkdown *** caught segfault *** address 0x110, cause 'invalid permissions' 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, 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)))}) 59: 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/Rtmp2hXezs/file35ce1a08b9b.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, 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)))}) 59: 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/Rtmp2hXezs/file35ce1a08b9b.rds") 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) {}) 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) 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, 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)))}) 59: 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/Rtmp2hXezs/file35ce1a08b9b.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 *** *** caught segfault *** *** caught segfault *** address 0x110, cause 'invalid permissions' address 0x110, cause 'invalid permissions' 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) 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) 4: doTryCatch(return(expr), name, parentenv, handler) 5: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 6: tryCatchList(expr, classes, parentenv, handlers) 7: 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) 7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, *** caught segfault *** Traceback: 1: }) Traceback: address 0x110, cause 'invalid permissions' mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 1: mi = mi, opts = mi$options) mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 2: 2: eval_f(x0, ...) 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, Traceback: mi = mi, opts = mi$options) 1: eval_f(x0, ...)}, error = function(e) {mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 2: eval_f(x0, ...) 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, }) 8: system.time({ model <- mi$model mi = mi, opts = mi$options) 4: 8: system.time({ model <- mi$model result <- NULLdoTryCatch(return(expr), name, parentenv, handler) result <- NULL 3: tryCatch({ 4: result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 5: mi = mi, opts = mi$options)tryCatchOne(expr, names, parentenv, handlers[[1L]])doTryCatch(return(expr), name, parentenv, handler) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE 6: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, tryCatchList(expr, classes, parentenv, handlers) 7: 5: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 6: tryCatchList(expr, classes, parentenv, handlers)tryCatch({ tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) 7: }, 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$coefficients <- result$solution mi = mi, opts = mi$options)tryCatch({ model$message <- result$message model$logLik <- as.numeric(-1 * result$objective) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) 4: model$iterations <- result$iterations}, error = function(e) { result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, } mi = mi, opts = mi$options)}) 9: })FUN(X[[i]], ...) model$status <- result$status model$message <- result$message}, error = function(e) {10: }}) 8: lapply(X = S, FUN = FUN, ...)system.time({doTryCatch(return(expr), name, parentenv, handler) 11: 9: FUN(X[[i]], ...) 10: lapply(X = S, FUN = FUN, ...) model <- mi$model 5: result <- NULL}) tryCatchOne(expr, names, parentenv, handlers[[1L]])doTryCatch(return(expr), name, parentenv, handler) tryCatch({ 12: 8: Traceback: system.time({tryCatchOne(expr, names, parentenv, handlers[[1L]]) model <- mi$model 1: result <- NULL 13: 6: result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 11: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)tryCatchList(expr, classes, parentenv, handlers) 14: mi = mi, opts = mi$options)tryCatch(expr, error = function(e) {doTryCatch(return(expr), name, parentenv, handler) call <- conditionCall(e) 2: eval_f(x0, ...) 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) if (!is.null(call)) { }, error = function(e) { if (identical(call[[1L]], quote(doTryCatch))) }) call <- sys.call(-4L) if (!is.null(result)) { dcall <- deparse(call, nlines = 1L)12: model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$statustryCatchOne(expr, names, parentenv, handlers[[1L]]) tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { tryCatchList(expr, classes, parentenv, handlers) model$message <- result$message model$fail <- FALSE }}) prefix <- paste("Error in", dcall, ": ") model$coefficients <- result$solution 9: 13: FUN(X[[i]], ...) LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") 10: lapply(X = S, FUN = FUN, ...) 11: if (is.na(w)) tryCatchList(expr, classes, parentenv, handlers) doTryCatch(return(expr), name, parentenv, handler) 4: model$logLik <- as.numeric(-1 * result$objective)doTryCatch(return(expr), name, parentenv, handler) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") 7: tryCatch({ model$iterations <- result$iterations result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 14: }12: model$status <- result$status model$message <- result$message }tryCatch(expr, error = function(e) { mi = mi, opts = mi$options)}, error = function(e) {tryCatchOne(expr, names, parentenv, handlers[[1L]])}) else prefix <- "Error : " 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) call <- conditionCall(e) 9: FUN(X[[i]], ...) 10: lapply(X = S, FUN = FUN, ...) 11: doTryCatch(return(expr), name, parentenv, handler) 12: tryCatchOne(expr, names, parentenv, handlers[[1L]]) if (!is.null(call)) { msg <- paste0(prefix, conditionMessage(e), "\n") 5: }, error = function(e) {tryCatchOne(expr, names, parentenv, handlers[[1L]]) if (identical(call[[1L]], quote(doTryCatch))) 13: .Internal(seterrmessage(msg[1L])) 6: tryCatchList(expr, classes, parentenv, handlers) 7: })tryCatch({ call <- sys.call(-4L)tryCatchList(expr, classes, parentenv, handlers) if (!is.null(result)) {13: if (!silent && isTRUE(getOption("show.error.messages"))) { dcall <- deparse(call, nlines = 1L) cat(msg, file = outFile) .Internal(printDeferredWarnings()) }14: model$fail <- FALSE result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, tryCatchList(expr, classes, parentenv, handlers) invisible(structure(msg, class = "try-error", condition = e)) model$coefficients <- result$solution}) mi = mi, opts = mi$options) model$logLik <- as.numeric(-1 * result$objective)}, error = function(e) { tryCatch(expr, error = function(e) { prefix <- paste("Error in", dcall, ": ") 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) LONG <- 75L call <- conditionCall(e) model$iterations <- result$iterations}) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) model$status <- result$status model$message <- result$message call <- sys.call(-4L)14: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) {17: } sm <- strsplit(conditionMessage(e), "\n")[[1L]]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")) 8: w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") dcall <- deparse(call, nlines = 1L) *** caught segfault *** }) if (is.na(w)) address 0x110, cause 'invalid permissions' system.time({ if (identical(call[[1L]], quote(doTryCatch))) prefix <- paste("Error in", dcall, ": ") LONG <- 75L21: model <- mi$model call <- sys.call(-4L) 9: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) sm <- strsplit(conditionMessage(e), "\n")[[1L]] result <- NULL dcall <- deparse(call, nlines = 1L)FUN(X[[i]], ...)22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage")) 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, w <- 14L + nchar(dcall, type = "b") + nchar(sm[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) type = "b") tryCatch({ 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 ") runModel, mc.cores = numCores))) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, } if (w > LONG) prefix <- paste0(prefix, "\n ") LONG <- 75L mi = mi, opts = mi$options) else prefix <- "Error : " } }, error = function(e) { else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L]))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) sm <- strsplit(conditionMessage(e), "\n")[[1L]] msg <- paste0(prefix, conditionMessage(e), "\n")24: runMultistart(modelInputs) 25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", }) w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") prefix <- paste("Error in", dcall, ": ") if (!silent && isTRUE(getOption("show.error.messages"))) { 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"))) { "brand"), scalePar = "price", numMultiStarts = 10) cat(msg, file = outFile) .Internal(printDeferredWarnings()) if (is.na(w)) 26: eval(expr, envir) 27: eval(expr, envir) } .Internal(seterrmessage(msg[1L])) if (!is.null(result)) {28: w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], invisible(structure(msg, class = "try-error", condition = e)) if (!silent && isTRUE(getOption("show.error.messages"))) { type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " cat(msg, file = outFile) .Internal(printDeferredWarnings())})withVisible(eval(expr, envir)) model$fail <- FALSE msg <- paste0(prefix, conditionMessage(e), "\n") cat(msg, file = outFile) .Internal(printDeferredWarnings()) .Internal(seterrmessage(msg[1L])) 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]], ...) Traceback: if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings())29: }15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) withCallingHandlers(code, message = function (cnd) }10: 1: { invisible(structure(msg, class = "try-error", condition = e))}) 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) invisible(structure(msg, class = "try-error", condition = e))}) }17: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 2: eval_f(x0, ...) invisible(structure(msg, class = "try-error", condition = e)) watcher$capture_plot_and_output()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: lapply(seq_len(cores), inner.do) 19: parallel::mclapply(miList, runModel, mc.cores = numCores) 3: 18: lapply(seq_len(cores), inner.do)15: lapply(X = S, FUN = FUN, ...)20: if (on_message$capture) { 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: watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage")16: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) }tryCatchList(expr, classes, parentenv, handlers)}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() }withCallingHandlers(expr, warning = function(w) if (inherits(w, 19: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) watcher$capture_plot_and_output() 7: tryCatch({parallel::mclapply(miList, runModel, mc.cores = numCores)16: result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 11: classes)) tryInvokeRestart("muffleWarning"))doTryCatch(return(expr), name, parentenv, handler) if (on_warning$capture) { mi = mi, opts = mi$options) 20: cnd <- sanitize_call(cnd)12: }, error = function(e) {17: FUN(X[[i]], ...) 18: tryCatchOne(expr, names, parentenv, handlers[[1L]]) watcher$push(cnd)21: }) }lapply(seq_len(cores), inner.do) withCallingHandlers(expr, warning = function(w) if (inherits(w, if (on_warning$silence) {sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) 8: 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)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") classes)) tryInvokeRestart("muffleWarning")) system.time({ invokeRestart("muffleWarning") .Internal(seterrmessage(msg[1L])) 19: 17: parallel::mclapply(miList, runModel, mc.cores = numCores) } if (!silent && isTRUE(getOption("show.error.messages"))) {26: cat(msg, file = outFile) .Internal(printDeferredWarnings())}, error = function (cnd) model <- mi$modeleval(expr, envir) result <- NULL21: FUN(X[[i]], ...) 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){ } suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) tryCatch({ 25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", watcher$capture_plot_and_output() invisible(structure(msg, class = "try-error", condition = e))}) 15: result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, cnd <- sanitize_call(cnd) watcher$push(cnd) mi = mi, opts = mi$options) "brand"), scalePar = "price", numMultiStarts = 10) 18: lapply(seq_len(cores), inner.do) 19: parallel::mclapply(miList, runModel, mc.cores = numCores) }, error = function(e) {try(lapply(X = S, FUN = FUN, ...), silent = TRUE) switch(on_error, continue = invokeRestart("eval_continue"), 27: 26: }) if (!is.null(result)) { 20: 22: stop = invokeRestart("eval_stop"), error = NULL) model$fail <- FALSEwithCallingHandlers(expr, warning = function(w) if (inherits(w, eval(expr, envir) eval(expr, envir) model$coefficients <- result$solution classes)) tryInvokeRestart("muffleWarning"))withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage")) 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, 16: 28: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) withVisible(eval(expr, envir))}) model$logLik <- as.numeric(-1 * result$objective) 30: eval(call) 31: eval(call) 32: with_handlers({ for (expr in tle$exprs) {21: model$iterations <- result$iterationssuppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))29: ev <- withVisible(eval(expr, envir)) runModel, mc.cores = numCores))) 27: eval(expr, envir) withCallingHandlers(code, message = function (cnd) { watcher$capture_plot_and_output() model$status <- result$status model$message <- result$message22: }}) watcher$capture_plot_and_output()28: 24: 17: FUN(X[[i]], ...) 18: lapply(seq_len(cores), inner.do) 19: parallel::mclapply(miList, runModel, mc.cores = numCores) withVisible(eval(expr, envir)) if (on_message$capture) {20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) 21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) watcher$push(cnd) watcher$print_value(ev$value, ev$visible, envir) 9: }22: TRUE }, handlers)withCallingHandlers(expr, message = function(c) if (inherits(c, FUN(X[[i]], ...) classes)) tryInvokeRestart("muffleMessage")) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) withCallingHandlers(expr, message = function(c) if (inherits(c, 29: withCallingHandlers(code, message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage"){ if (getOption("warn") >= 2 || getOption("warn") < 0) { }23: 10: lapply(X = S, FUN = FUN, ...) 11: doTryCatch(return(expr), name, parentenv, handler) classes)) tryInvokeRestart("muffleMessage")) 33: suppressMessages(suppressWarnings(parallel::mclapply(miList, runMultistart(modelInputs) return() runModel, mc.cores = numCores))) }}, warning = function (cnd) watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) 24: }23: if (on_warning$silence) {doWithOneRestart(return(expr), restart)suppressMessages(suppressWarnings(parallel::mclapply(miList, 12: 25: invokeRestart("muffleWarning"){ runModel, mc.cores = numCores)))34: withOneRestart(expr, restarts[[1L]]) logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", if (getOption("warn") >= 2 || getOption("warn") < 0) {runMultistart(modelInputs) "brand"), scalePar = "price", numMultiStarts = 10)35: tryCatchOne(expr, names, parentenv, handlers[[1L]]) return() 25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10) }withRestartList(expr, restarts[-nr])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, ": ")}, error = function (cnd) 26: {24: 26: LONG <- 75LrunMultistart(modelInputs) 25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10) 26: eval(expr, envir) eval(expr, envir) eval(expr, envir)27: eval(expr, envir)27: } 28: withVisible(eval(expr, envir)) 36: 27: eval(expr, envir) sm <- strsplit(conditionMessage(e), "\n")[[1L]]29: withCallingHandlers(code, 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() w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") watcher$capture_plot_and_output() watcher$capture_plot_and_output() 28: withVisible(eval(expr, envir)) 29: withCallingHandlers(code, 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) {eval(expr, envir) }doWithOneRestart(return(expr), restart) invokeRestart("muffleWarning") if (is.na(w)) if (on_warning$capture) { watcher$capture_plot_and_output()37: cnd <- sanitize_call(cnd) watcher$push(cnd) 28: withVisible(eval(expr, envir)) cnd <- sanitize_call(cnd) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], if (on_warning$capture) { switch(on_error, continue = invokeRestart("eval_continue"), 29: withCallingHandlers(code, message = function (cnd) type = "b") }}, error = function (cnd) cnd <- sanitize_call(cnd) if (w > LONG) prefix <- paste0(prefix, "\n ") }{withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) else prefix <- "Error : " stop = invokeRestart("eval_stop"), error = NULL) watcher$push(cnd) watcher$capture_plot_and_output() 38: withRestartList(expr, restarts) watcher$push(cnd) } cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)}) msg <- paste0(prefix, conditionMessage(e), "\n")}) 30: eval(call) .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 (on_warning$silence) { invokeRestart("muffleWarning") }39: withRestarts(with_handlers({ for (expr in tle$exprs) {{31: ev <- withVisible(eval(expr, envir))}, error = function (cnd) 30: eval(call){ watcher$capture_plot_and_output() 15: 31: 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)eval(call) if (on_warning$silence) { watcher$capture_plot_and_output()32: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir))eval(call) cnd <- sanitize_call(cnd) 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(...) if (on_message$capture) {20: watcher$capture_plot_and_output() watcher$push(cnd) watcher$print_value(ev$value, ev$visible, envir) watcher$push(cnd)32: } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } switch(on_error, continue = invokeRestart("eval_continue"), 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: invokeRestart("muffleWarning")41: watcher$capture_plot_and_output()evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, withCallingHandlers(expr, warning = function(w) if (inherits(w, keep_message = if (is.numeric(options$message)) TRUE else options$message, } }withOneRestart(expr, restarts[[1L]]) if (on_warning$capture) { stop_on_error = if (is.numeric(options$error)) options$error else { classes)) tryInvokeRestart("muffleWarning")) 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 { 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, 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) { }, error = function (cnd) { watcher$capture_plot_and_output() stop = invokeRestart("eval_stop"), error = NULL)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 if (options$error && options$include) }, 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) cnd <- sanitize_call(cnd)}) cnd <- sanitize_call(cnd) 0L cnd <- sanitize_call(cnd)45: 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({ else 2L } }, output_handler = knit_handlers(options$render, options))) 44: eng_r(options) watcher$push(cnd) watcher$push(cnd)30: block_exec(params) TRUE45: }, 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 { }eval(call) if (on_warning$silence) { if (options$error && options$include) block_exec(params) switch(on_error, continue = invokeRestart("eval_continue"), for (expr in tle$exprs) { invokeRestart("muffleWarning")46: 31: eval(call) 32: ev <- withVisible(eval(expr, envir)) 0L }call_block(x)}, 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) stop = invokeRestart("eval_stop"), error = NULL) else 2L}) 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) } watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers) 33: doWithOneRestart(return(expr), restart)47: TRUEprocess_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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), function(loc) { setwd(wd)}, 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) {34: withOneRestart(expr, restarts[[1L]]) 35: withRestartList(expr, restarts[-nr]) 36: doWithOneRestart(return(expr), restart) 37: write_utf8(res, output %n% stdout())46: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) }, output_handler = knit_handlers(options$render, options)) 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 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, call_block(x)34: 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } paste0("\nQuitting from ", loc, if (!is.null(error)) with_handlers({ else 2L stop_on_error = if (is.numeric(options$error)) options$error else { 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), for (expr in tle$exprs) {withOneRestart(expr, restarts[[1L]]) rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { 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 rlang::entrace(e) paste0("\n", rule(), error, "\n", rule())) }, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc)35: withRestartList(expr, restarts[-nr]) 36: doWithOneRestart(return(expr), restart) error = function(e) { } }, output_handler = knit_handlers(options$render, options))) }, output_handler = knit_handlers(options$render, options)) 37: if (progress && is.function(pb$interrupt)) } ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output()withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) pb$interrupt()55: if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd)doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)) { watcher$print_value(ev$value, ev$visible, envir) }), function(loc) { texi2pdf(file = output, clean = FALSE, quiet = quiet) } setwd(wd) write_utf8(res, output %n% stdout()) output <- find_vignette_product(name, by = "texi2pdf", 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 else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) } 54: engine$weave(file, quiet = quiet, encoding = enc) paste0("\nQuitting from ", loc, if (!is.null(error)) engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", TRUE}, handlers) 55: 44: file, conditionMessage(e)))doTryCatch(return(expr), name, parentenv, handler)33: eng_r(options) }, output_handler = knit_handlers(options$render, options)))38: paste0("\n", rule(), error, "\n", rule()))withRestartList(expr, restarts) 39: withRestarts(with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir))56: doWithOneRestart(return(expr), restart) }, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) watcher$capture_plot_and_output()tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: 44: })eng_r(options)34: 45: block_exec(params) 46: call_block(x) 47: process_group(group)withOneRestart(expr, restarts[[1L]]) 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 { 59: 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/Rtmp2hXezs/file35ce1a08b9b.rds") 45: An irrecoverable exception occurred. R is aborting now ... block_exec(params)48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) 52: pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd)35: if (options$error && options$include) 0LwithRestartList(expr, restarts[-nr]) 36: doWithOneRestart(return(expr), restart) 37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) 38: withRestartList(expr, restarts) 39: withRestarts(with_handlers({ }rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) output_dir = getwd(), ...) 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 { 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {doTryCatch(return(expr), name, parentenv, handler)tryCatchList(expr, classes, parentenv, handlers) if (options$error && options$include) if (progress && is.function(pb$interrupt)) 0L 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) else 2L46: 58: pb$interrupt() }, output_handler = knit_handlers(options$render, options)))call_block(x) 58: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc)tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) 44: eng_r(options) 45: block_exec(params) 46: 47: call_block(x) 47: process_group(group) 48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), process_group(group) setwd(startdir) 48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { TRUE cnd = tryCatch(rlang::entrace(e), error = identity) if (xfun::pkg_available("rlang", "1.0.0")) { error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), output <- find_vignette_product(name, by = "weave", engine = engine) error = function(e) { output <- find_vignette_product(name, by = "weave", engine = engine)}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE) error = function(e) { 40: if (is_R_CMD_build() || is_R_CMD_check()) { if (!have.makefile && vignette_is_tex(output)) { if (progress && is.function(pb$interrupt)) 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)))}) 59: 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/Rtmp2hXezs/file35ce1a08b9b.rds") An irrecoverable exception occurred. R is aborting now ... evaluate::evaluate(...) 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)))}) 59: if (progress && is.function(pb$interrupt)) 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))) cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) pb$interrupt() 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), pb$interrupt() error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } }tools:::.buildOneVignette("basic_usage.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", else { if (xfun::pkg_available("rlang", "1.0.0")) { if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) rlang::entrace(e) error <<- format(cnd) } else { if (is_R_CMD_build() || is_R_CMD_check()) { TRUE, FALSE, "basic_usage", "UTF-8", "/Volumes/Temp/tmp/Rtmp2hXezs/file35ce1a08b9b.rds") } }) } rlang::entrace(e) }An irrecoverable exception occurred. R is aborting now ... cnd = tryCatch(rlang::entrace(e), error = identity) }), function(loc) { } setwd(wd)49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error <<- format(cnd) } } write_utf8(res, output %n% stdout()) }), function(loc) { else { paste0("\nQuitting from ", loc, if (!is.null(error)) setwd(wd) error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) paste0("\n", rule(), error, "\n", rule())) rlang::entrace(e) } } }) 49: }, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) error <<- format(cnd)xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 50: } paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) 50: else { error = function(e) {process_file(text, output) rlang::entrace(e) if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) process_file(text, output) } }51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) else { rlang::entrace(e) } } }), function(loc) { setwd(wd) write_utf8(res, output %n% stdout())52: }rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), 51: output_dir = getwd(), ...)knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)53: paste0("\nQuitting from ", loc, if (!is.null(error)) 52: vweave_rmarkdown(...) paste0("\n", rule(), error, "\n", rule())) }, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), 54: 50: process_file(text, output) 51: output_dir = getwd(), ...)engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), 53: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) output_dir = getwd(), ...) 52: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 57: tryCatchList(expr, classes, parentenv, handlers)55: 58: 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)))}) 59: tools:::.buildOneVignette("basic_usage.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", doTryCatch(return(expr), name, parentenv, handler) TRUE, FALSE, "basic_usage", "UTF-8", "/Volumes/Temp/tmp/Rtmp2hXezs/file35ce1a08b9b.rds")53: vweave_rmarkdown(...) rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), 54: 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: output_dir = getwd(), ...)tryCatch({engine$weave(file, quiet = quiet, encoding = enc) 53: vweave_rmarkdown(...) An irrecoverable exception occurred. R is aborting now ... 54: engine$weave(file, quiet = quiet, encoding = enc) 55: engine$weave(file, quiet = quiet, encoding = enc)doTryCatch(return(expr), name, parentenv, handler) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) 55: if (!have.makefile && vignette_is_tex(output)) {doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)56: 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", texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", file, conditionMessage(e))) engine = engine)tryCatchOne(expr, names, parentenv, handlers[[1L]]) } 57: tryCatchList(expr, classes, parentenv, handlers) }) 59: }, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))}) 59: 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/Rtmp2hXezs/file35ce1a08b9b.rds") An irrecoverable exception occurred. R is aborting now ... 58: tools:::.buildOneVignette("basic_usage.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", 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) } TRUE, FALSE, "basic_usage", "UTF-8", "/Volumes/Temp/tmp/Rtmp2hXezs/file35ce1a08b9b.rds") An irrecoverable exception occurred. R is aborting now ... }, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))}) 59: 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/Rtmp2hXezs/file35ce1a08b9b.rds") An irrecoverable exception occurred. R is aborting now ... Quitting from basic_usage.Rmd:82-91 [unnamed-chunk-7] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ <error/rlang_error> Error in `names(x) <- value`: ! 'names' attribute [3] must be the same length as the vector [0] --- Backtrace: ▆ 1. └─logitr::logitr(...) 2. └─logitr:::getMultistartSummary(allModels) 3. └─base::`colnames<-`(...) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Error: processing vignette 'basic_usage.Rmd' failed with diagnostics: 'names' attribute [3] must be the same length as the vector [0] --- failed re-building ‘basic_usage.Rmd’ --- re-building ‘benchmark.Rmd’ using rmarkdown --- finished re-building ‘benchmark.Rmd’ --- re-building ‘convergence.Rmd’ using rmarkdown --- finished re-building ‘convergence.Rmd’ --- re-building ‘data_formatting.Rmd’ using rmarkdown --- finished re-building ‘data_formatting.Rmd’ --- re-building ‘interactions.Rmd’ using rmarkdown --- finished re-building ‘interactions.Rmd’ --- re-building ‘mnl_models.Rmd’ using rmarkdown *** caught segfault *** address 0x110, cause 'invalid permissions' *** caught segfault *** address 0x110, cause 'invalid permissions' *** caught segfault *** address 0x110, cause 'invalid permissions' *** 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) Traceback: 1: 5: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)tryCatchOne(expr, names, parentenv, handlers[[1L]]) 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, 2: eval_f(x0, ...) 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 6: tryCatchList(expr, classes, parentenv, handlers) 7: tryCatch({ mi = mi, opts = mi$options) mi = mi, opts = mi$options) 4: 4: doTryCatch(return(expr), name, parentenv, handler) 5: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 6: tryCatchList(expr, classes, parentenv, handlers) doTryCatch(return(expr), name, parentenv, handler) 7: tryCatch({ 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) 7: result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {})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: 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) mi = mi, opts = mi$options)}, error = function(e) {}) 8: tryCatchList(expr, classes, parentenv, handlers)system.time({ model <- mi$model *** caught segfault *** address 0x110, cause 'invalid permissions' model$iterations <- result$iterations result <- NULL *** caught segfault *** Traceback: address 0x110, cause 'invalid permissions' model$status <- result$status model$message <- result$message 1: }mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}) 9: FUN(X[[i]], ...) 2: 10: lapply(X = S, FUN = FUN, ...) 11: eval_f(x0, ...)doTryCatch(return(expr), name, parentenv, handler) }, error = function(e) { *** caught segfault *** 14: 12: address 0x110, cause 'invalid permissions' 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, tryCatch(expr, error = function(e) { call <- conditionCall(e) mi = mi, opts = mi$options) 4: doTryCatch(return(expr), name, parentenv, handler) 5: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 6: tryCatchList(expr, classes, parentenv, handlers) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) tryCatchOne(expr, names, parentenv, handlers[[1L]]) *** caught segfault *** address 0x110, cause 'invalid permissions' }) if (!is.null(result)) { call <- sys.call(-4L) 7: tryCatch({ model$fail <- FALSE13: dcall <- deparse(call, nlines = 1L) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, tryCatchList(expr, classes, parentenv, handlers) 14: prefix <- paste("Error in", dcall, ": ")tryCatch(expr, error = function(e) { mi = mi, opts = mi$options) call <- conditionCall(e) model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations}, error = function(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], Traceback: type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L])) if (!is.null(call)) { model$status <- result$status model$message <- result$message }}) if (identical(call[[1L]], quote(doTryCatch))) }) *** caught segfault *** if (!silent && isTRUE(getOption("show.error.messages"))) { 1: address 0x110, cause 'invalid permissions' cat(msg, file = outFile) call <- sys.call(-4L) 9: 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")mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) if (is.na(w)) FUN(X[[i]], ...) 10: lapply(X = S, FUN = FUN, ...) 11: .Internal(printDeferredWarnings()) 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)) } 8: invisible(structure(msg, class = "try-error", condition = e))})system.time({doTryCatch(return(expr), name, parentenv, handler) model <- mi$model Traceback: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 2: eval_f(x0, ...) 3: result <- NULL 2: eval_f(x0, ...) tryCatch({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]]) 3: 15: result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) 6: tryCatchList(expr, classes, parentenv, handlers) }, error = function(e) { }) if (!is.null(result)) { 7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, }) model$fail <- FALSE mi = mi, opts = mi$options)nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, model$coefficients <- result$solution Traceback: }, error = function(e) {15: 12: mi = mi, opts = mi$options) 1: model$logLik <- as.numeric(-1 * result$objective) 4: doTryCatch(return(expr), name, parentenv, handler) 5: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)}) Traceback: tryCatchOne(expr, names, parentenv, handlers[[1L]])16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) 8: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)system.time({try(lapply(X = S, FUN = FUN, ...), silent = TRUE)tryCatchOne(expr, names, parentenv, handlers[[1L]]) 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) 17: FUN(X[[i]], ...) 18: 17: model <- mi$modelFUN(X[[i]], ...) 1: 13: tryCatchList(expr, classes, parentenv, handlers) 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: 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: Traceback: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 2: eval_f(x0, ...) result <- NULLlapply(seq_len(cores), inner.do) 6: tryCatchList(expr, classes, parentenv, handlers) 7: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 3: 18: model$iterations <- result$iterationsnloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, tryCatch({ tryCatch({14: lapply(seq_len(cores), inner.do) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)tryCatch(expr, error = function(e) { mi = mi, opts = mi$options) 6: doTryCatch(return(expr), name, parentenv, handler) model$status <- result$status model$message <- result$message call <- conditionCall(e) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, tryCatchList(expr, classes, parentenv, handlers) 19: }, error = function(e) {parallel::mclapply(miList, runModel, mc.cores = numCores) }) mi = mi, opts = mi$options) 5: 19: }}, error = function(e) { 7: 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]]) if (!is.null(result)) { 20: })withCallingHandlers(expr, warning = function(w) if (inherits(w, }) classes)) tryInvokeRestart("muffleWarning")) if (!is.null(call)) { }) 9: FUN(X[[i]], ...)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))) 8: model$fail <- FALSE *** caught segfault *** address 0x110, cause 'invalid permissions' 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) model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations16: 4: if (identical(call[[1L]], quote(doTryCatch))) 21: 6: model$status <- result$status 8: system.time({ model <- mi$modeldoTryCatch(return(expr), name, parentenv, handler)sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) model$message <- result$message 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, message = function (cnd) {24: result <- NULL call <- sys.call(-4L)tryCatchList(expr, classes, parentenv, handlers) 17: runMultistart(modelInputs) 5: } 7: dcall <- deparse(call, nlines = 1L) Traceback: tryCatchOne(expr, names, parentenv, handlers[[1L]])FUN(X[[i]], ...) watcher$capture_plot_and_output() prefix <- paste("Error in", dcall, ": ")})25: system.time({ 9: tryCatch({ logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", LONG <- 75L 1: if (on_message$capture) { 6: tryCatch({tryCatchList(expr, classes, parentenv, handlers) 7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)18: FUN(X[[i]], ...) sm <- strsplit(conditionMessage(e), "\n")[[1L]] watcher$push(cnd) model <- mi$modelmi$logitFuncs$getMnlV(pars, d$X, d$scalePar) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, }, error = function(e) { 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) { "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate) } 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)) {}) w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (on_message$silence) { result <- NULL 2: })eval_f(x0, ...) if (!is.null(result)) { invokeRestart("muffleMessage") result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, tryCatch({lapply(seq_len(cores), inner.do) 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 ") } if (is.na(w)) 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)) { w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], type = "b") if (w > LONG) } mi = mi, opts = mi$options)}, 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) }, error = function(e) { else prefix <- "Error : " prefix <- paste0(prefix, "\n ") result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, model$fail <- FALSE }) msg <- paste0(prefix, conditionMessage(e), "\n") } model$fail <- FALSE mi = mi, opts = mi$options) model$coefficients <- result$solution } .Internal(seterrmessage(msg[1L])) else prefix <- "Error : " model$coefficients <- result$solution if (!is.null(result)) { model$logLik <- as.numeric(-1 * result$objective) if (on_warning$silence) { msg <- paste0(prefix, conditionMessage(e), "\n") }, error = function(e) { model$fail <- FALSE19: 3: model$logLik <- as.numeric(-1 * result$objective) .Internal(seterrmessage(msg[1L])) }) invokeRestart("muffleWarning")26: model$iterations <- result$iterationsnloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, model$coefficients <- result$solution if (!is.null(result)) { model$iterations <- result$iterationseval(expr, envir) if (!silent && isTRUE(getOption("show.error.messages"))) { mi = mi, opts = mi$options) model$logLik <- as.numeric(-1 * result$objective) model$fail <- FALSE model$iterations <- result$iterationsparallel::mclapply(miList, runModel, mc.cores = numCores) 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", } 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()) if (!silent && isTRUE(getOption("show.error.messages"))) { model$status <- result$status model$message <- result$message }}) model$coefficients <- result$solution27: model$status <- result$statuseval(expr, envir)}, error = function (cnd) cat(msg, file = outFile) 9: FUN(X[[i]], ...) 10: lapply(X = S, FUN = FUN, ...) 11: doTryCatch(return(expr), name, parentenv, handler) 12: model$message <- result$message } 4: invisible(structure(msg, class = "try-error", condition = e)) model$logLik <- as.numeric(-1 * result$objective)tryCatchOne(expr, names, parentenv, handlers[[1L]]) .Internal(printDeferredWarnings()) {}) "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate)20: doTryCatch(return(expr), name, parentenv, handler) } watcher$capture_plot_and_output() model$iterations <- result$iterations invisible(structure(msg, class = "try-error", condition = e)) model$status <- result$status model$message <- result$message cnd <- sanitize_call(cnd)28: withVisible(eval(expr, envir))withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) 21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) 22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage")) 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))) 24: runMultistart(modelInputs) 25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate) 26: eval(expr, envir) 27: eval(expr, envir) 15: })26: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) }13: tryCatchList(expr, classes, parentenv, handlers) }15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 28: 5: watcher$push(cnd)16: }) 9: FUN(X[[i]], ...) 10: lapply(X = S, FUN = FUN, ...) 11: doTryCatch(return(expr), name, parentenv, handler) switch(on_error, continue = invokeRestart("eval_continue"), sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) 17: FUN(X[[i]], ...) 18: lapply(seq_len(cores), inner.do)eval(expr, envir) 27: eval(expr, envir) 28: withVisible(eval(expr, envir)) 29: withCallingHandlers(code, message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage")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, 29: 14: 16: withVisible(eval(expr, envir)) } 29: withCallingHandlers(code, 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) {}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { withCallingHandlers(code, message = function (cnd) 19: parallel::mclapply(miList, runModel, mc.cores = numCores) 20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) 21: cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { mi = mi, opts = mi$options) 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, 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)})12: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 13: tryCatchList(expr, classes, parentenv, handlers) 14: cnd <- sanitize_call(cnd)}, error = function(e) { watcher$push(cnd)}) 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) {tryCatch(expr, error = function(e) {{ switch(on_error, continue = invokeRestart("eval_continue"), }) if (!is.null(result)) { model$fail <- FALSE watcher$capture_plot_and_output() call <- conditionCall(e) 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: model$coefficients <- result$solution stop = invokeRestart("eval_stop"), error = NULL)})sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) evaluate::evaluate(...) watcher$push(cnd) } 41: if (on_warning$silence) { invokeRestart("muffleWarning") if (!is.null(call)) { }}, 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: 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) 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: model$logLik <- as.numeric(-1 * result$objective) 9: model$iterations <- result$iterations model$status <- result$status model$message <- result$message }}) 9: 17: 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, ": ") if (on_message$capture) { 0Leval(call) if (identical(call[[1L]], quote(doTryCatch))) 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: FUN(X[[i]], ...)FUN(X[[i]], ...) watcher$push(cnd) } if (on_message$silence) {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) LONG <- 75L else 2L10: lapply(X = S, FUN = FUN, ...)18: lapply(seq_len(cores), inner.do) 33: }, output_handler = knit_handlers(options$render, options))) doWithOneRestart(return(expr), restart) 34: 11: doWithOneRestart(return(expr), restart) invokeRestart("muffleMessage")tryCatch(expr, error = function(e) {19: 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 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)) call <- sys.call(-4L) }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 { dcall <- deparse(call, nlines = 1L)withOneRestart(expr, restarts[[1L]]) sm <- strsplit(conditionMessage(e), "\n")[[1L]]}, warning = function (cnd) 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) if (options$error && options$include) 44: eng_r(options) 45: block_exec(params) 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"))) { 0L else 2L }, output_handler = knit_handlers(options$render, options)) sm <- strsplit(conditionMessage(e), "\n")[[1L]]34: doTryCatch(return(expr), name, parentenv, handler) 12: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 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], cat(msg, file = outFile)42: .Internal(printDeferredWarnings()) 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: } 35: {in_dir(input_dir(), expr)29: withCallingHandlers(code, message = function (cnd) {withOneRestart(expr, restarts[[1L]])46: tryCatchList(expr, classes, parentenv, handlers) if (getOption("warn") >= 2 || getOption("warn") < 0) {withRestartList(expr, restarts[-nr]) type = "b")parallel::mclapply(miList, runModel, mc.cores = numCores)call_block(x)43: 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: return() in_input_dir(evaluate(code, envir = env, new_device = FALSE, 20: 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 (xfun::pkg_available("rlang", "1.0.0")) {withCallingHandlers(expr, warning = function(w) if (inherits(w, if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { 36: watcher$capture_plot_and_output()35: rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd)doWithOneRestart(return(expr), restart) 47: }eval(expr, envir) 27: eval(expr, envir) 28: withVisible(eval(expr, envir)) 29: withCallingHandlers(code, message = function (cnd) { watcher$capture_plot_and_output() classes)) tryInvokeRestart("muffleWarning"))withRestartList(expr, restarts[-nr])55: doTryCatch(return(expr), name, parentenv, handler) 14: invisible(structure(msg, class = "try-error", condition = e)) 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) if (on_warning$silence) { invokeRestart("muffleWarning") if (on_message$capture) {}) watcher$push(cnd) } if (on_message$silence) { }56: tryCatch(expr, error = function(e) { 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: else { invokeRestart("muffleMessage") rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: if (on_message$capture) { }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() }tryCatchOne(expr, names, parentenv, handlers[[1L]])21: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, call <- conditionCall(e) watcher$push(cnd) 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 ") }suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) } keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)) else prefix <- "Error : "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 { msg <- paste0(prefix, conditionMessage(e), "\n") 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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) } .Internal(seterrmessage(msg[1L])) }}, error = function (cnd) { watcher$capture_plot_and_output()process_group(group)15: if (options$error && options$include) }, error = function(e) { cnd <- sanitize_call(cnd) try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 57: tryCatchList(expr, classes, parentenv, handlers) if (!silent && isTRUE(getOption("show.error.messages"))) {58: watcher$push(cnd) error = function(e) { 0L else 2L 16: if (progress && is.function(pb$interrupt)) cat(msg, file = outFile) OK <<- FALSEtryCatch({ .Internal(printDeferredWarnings()) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL) }}) }, output_handler = knit_handlers(options$render, options))) engine$weave(file, quiet = quiet, encoding = enc) invisible(structure(msg, class = "try-error", condition = e)) 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity)22: pb$interrupt()sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", withCallingHandlers(expr, message = function(c) if (inherits(c, setwd(startdir) watcher$capture_plot_and_output() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { if (on_warning$capture) {30: eval(call) cnd = tryCatch(rlang::entrace(e), error = identity)}) 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")) if (on_message$silence) {17: classes)) tryInvokeRestart("muffleMessage")) error <<- format(cnd) 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))) 24: runMultistart(modelInputs) 25: 31: error <<- format(cnd) invokeRestart("muffleMessage") } else { rlang::entrace(e) } } }), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) paste0("\nQuitting from ", loc, if (!is.null(error)) }logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", cnd <- sanitize_call(cnd) paste0("\n", rule(), error, "\n", rule())) file, conditionMessage(e)))21: else { output <- find_vignette_product(name, by = "weave", engine = engine) }}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)eval(call) "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate) watcher$push(cnd) if (!have.makefile && vignette_is_tex(output)) {}, warning = function (cnd) rlang::entrace(e) }) suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)){ } }FUN(X[[i]], ...) 59: 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/Rtmp2hXezs/file35ce78213e4a.rds") An irrecoverable exception occurred. R is aborting now ... 32: with_handlers({ 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")) for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE if (getOption("warn") >= 2 || getOption("warn") < 0) {50: } 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: texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) {process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 21: 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) })doWithOneRestart(return(expr), restart) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), function(loc) { 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) setwd(wd) write_utf8(res, output %n% stdout()) OK <<- FALSE52: }, handlers)26: paste0("\nQuitting from ", loc, if (!is.null(error)) suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) if (on_warning$silence) {40: message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), paste0("\n", rule(), error, "\n", rule()))26: invokeRestart("muffleWarning")evaluate::evaluate(...) output_dir = getwd(), ...)eval(expr, envir) file, conditionMessage(e)))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) 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) }33: doWithOneRestart(return(expr), restart)22: eval(expr, envir)53: 0L}) 59: 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/Rtmp2hXezs/file35ce78213e4a.rds") An irrecoverable exception occurred. R is aborting now ... 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 34: withOneRestart(expr, restarts[[1L]]) 35: withRestartList(expr, restarts[-nr]) 36: doWithOneRestart(return(expr), restart) 37: withCallingHandlers(expr, message = function(c) if (inherits(c, 27: else 2L vweave_rmarkdown(...)eval(expr, envir)withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])}, error = function (cnd) { watcher$capture_plot_and_output()27: 56: }, output_handler = knit_handlers(options$render, options)) classes)) tryInvokeRestart("muffleMessage"))tryCatchOne(expr, names, parentenv, handlers[[1L]]) eval(expr, envir) 42: 54: cnd <- sanitize_call(cnd) watcher$push(cnd) engine$weave(file, quiet = quiet, encoding = enc) 28: withVisible(eval(expr, envir)) 29: withCallingHandlers(code, message = function (cnd) 57: 23: switch(on_error, continue = invokeRestart("eval_continue"), 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else {tryCatchList(expr, classes, parentenv, handlers)suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))) stop = invokeRestart("eval_stop"), error = NULL) 24: runMultistart(modelInputs) rlang::entrace(e)in_dir(input_dir(), expr){ } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: 28: }) 55: doTryCatch(return(expr), name, parentenv, handler) doTryCatch(return(expr), name, parentenv, handler)withVisible(eval(expr, envir))58: 30: 56: 43: watcher$capture_plot_and_output() 29: withCallingHandlers(code, 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) {eval(call) if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) 25: tryCatch({tryCatchOne(expr, names, parentenv, handlers[[1L]]) 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) }in_input_dir(evaluate(code, envir = env, new_device = FALSE, engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) if (getOption("warn") >= 2 || getOption("warn") < 0) { keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, 56: 57: TRUElogitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", output <- find_vignette_product(name, by = "weave", engine = engine) 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 tryCatchList(expr, classes, parentenv, handlers) "brand"), scalePar = "price", numMultiStarts = 10, startVals = wtp_mnl_pref$Estimate) 58: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine)31: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: tryCatch({}, handlers) if (!have.makefile && vignette_is_tex(output)) { 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)}) else 2Leval(call) 26: engine$weave(file, quiet = quiet, encoding = enc) texi2pdf(file = output, clean = FALSE, quiet = quiet) if (!have.makefile && vignette_is_tex(output)) { eval(expr, envir) }, output_handler = knit_handlers(options$render, options))) 30: 33: 27: setwd(startdir)eval(expr, envir) 28: output <- find_vignette_product(name, by = "weave", engine = engine)eval(call) 32: 44: eng_r(options) 45: block_exec(params) 46: with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers) 33: call_block(x)withVisible(eval(expr, envir))31: output <- find_vignette_product(name, by = "texi2pdf", engine = engine) } texi2pdf(file = output, clean = FALSE, quiet = quiet)doWithOneRestart(return(expr), restart) 34: withOneRestart(expr, restarts[[1L]]) if (!have.makefile && vignette_is_tex(output)) {}, error = function(e) { texi2pdf(file = output, clean = FALSE, quiet = quiet)eval(call)doWithOneRestart(return(expr), restart) 34: OK <<- FALSE output <- find_vignette_product(name, by = "texi2pdf", 29: 35: withRestartList(expr, restarts[-nr]) 36: doWithOneRestart(return(expr), restart) 37: message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", 47: engine = engine)withCallingHandlers(code, message = function (cnd) withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])32: withOneRestart(expr, restarts[[1L]])process_group(group) } 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)))}) { file, conditionMessage(e)))}, error = function(e) {}) 59: 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/Rtmp2hXezs/file35ce78213e4a.rds") An irrecoverable exception occurred. R is aborting now ... OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))})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]]) 59: 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/Rtmp2hXezs/file35ce78213e4a.rds") An irrecoverable exception occurred. R is aborting now ... 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({59: 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, watcher$capture_plot_and_output()35: 48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { for (expr in tle$exprs) {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: ev <- withVisible(eval(expr, envir))tools:::.buildOneVignette("mnl_models.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", keep_message = if (is.numeric(options$message)) TRUE else options$message, 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)) if (is_R_CMD_build() || is_R_CMD_check()) { if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE) TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/Rtmp2hXezs/file35ce78213e4a.rds") stop_on_error = if (is.numeric(options$error)) options$error else { cnd = tryCatch(rlang::entrace(e), error = identity) if (options$error && options$include) 40: error <<- format(cnd){An irrecoverable exception occurred. R is aborting now ... evaluate::evaluate(...) 0L42: else 2L 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) in_dir(input_dir(), expr) }, output_handler = knit_handlers(options$render, options)) if (getOption("warn") >= 2 || getOption("warn") < 0) { 43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, 42: in_dir(input_dir(), expr) return() } keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, 43: keep_message = if (is.numeric(options$message)) TRUE else options$message, else {in_input_dir(evaluate(code, envir = env, new_device = FALSE, } stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L else 2L watcher$capture_plot_and_output() }, output_handler = knit_handlers(options$render, options))) if (on_warning$capture) { 0L keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, else 2L }, output_handler = knit_handlers(options$render, options)) cnd <- sanitize_call(cnd)44: watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") } keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { rlang::entrace(e)}, error = function (cnd) {42: if (options$error && options$include) 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) 0L}) else 2L }, output_handler = knit_handlers(options$render, options))) 44: }in_dir(input_dir(), expr) } }) eng_r(options) 30: 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 2Leval(call) }, output_handler = knit_handlers(options$render, options))) 44: eng_r(options) 45: block_exec(params)49: 45: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) block_exec(params)31: pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) {eval(call) if (is_R_CMD_build() || is_R_CMD_check()) { 32: 46: 46: cnd = tryCatch(rlang::entrace(e), error = identity)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) call_block(x)call_block(x)eng_r(options)34: withOneRestart(expr, restarts[[1L]]) 47: 47: process_group(group) 48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), process_group(group)45: 35: error = function(e) {block_exec(params) 46: error <<- format(cnd) withRestartList(expr, restarts[-nr])call_block(x)48: } else { rlang::entrace(e) } if (progress && is.function(pb$interrupt)) }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 (xfun::pkg_available("rlang", "1.0.0")) { }), function(loc) {withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 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)36: pb$interrupt() error = function(e) { if (progress && is.function(pb$interrupt)) if (xfun::pkg_available("rlang", "1.0.0")) {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 (is_R_CMD_build() || is_R_CMD_check()) { if (is_R_CMD_build() || is_R_CMD_check()) { pb$interrupt() cnd = tryCatch(rlang::entrace(e), error = identity)50: if (xfun::pkg_available("rlang", "1.0.0")) {40: if (is_R_CMD_build() || is_R_CMD_check()) { error <<- format(cnd)process_file(text, output) cnd = tryCatch(rlang::entrace(e), error = identity) cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } error <<- format(cnd) } evaluate::evaluate(...) } else {41: rlang::entrace(e) })evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { } error = function(e) { if (progress && is.function(pb$interrupt)) } } if (options$error && options$include) 51: }) 0L else { rlang::entrace(e) 49: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), function(loc) { setwd(wd) else 2L pb$interrupt() } } }) write_utf8(res, output %n% stdout()) }, output_handler = knit_handlers(options$render, options)) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 42: in_dir(input_dir(), expr) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 53: 43: if (xfun::pkg_available("rlang", "1.0.0")) {vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc)in_input_dir(evaluate(code, envir = env, new_device = FALSE, 55: 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: error = function(e) {doTryCatch(return(expr), name, parentenv, handler) if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) if (progress && is.function(pb$interrupt)) }, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) error <<- format(cnd) } else { rlang::entrace(e) } } }), function(loc) { pb$interrupt()50: process_file(text, output) setwd(wd)eng_r(options)56: write_utf8(res, output %n% stdout()) tryCatchOne(expr, names, parentenv, handlers[[1L]]) if (xfun::pkg_available("rlang", "1.0.0")) { paste0("\nQuitting from ", loc, if (!is.null(error)) 51: 45: paste0("\n", rule(), error, "\n", rule()))57: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)block_exec(params) }, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)tryCatchList(expr, classes, parentenv, handlers) 52: 58: 50: if (is_R_CMD_build() || is_R_CMD_check()) {tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine)process_file(text, output) cnd = tryCatch(rlang::entrace(e), error = identity) if (!have.makefile && vignette_is_tex(output)) { error <<- format(cnd) 46: 51: call_block(x) 47: texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...)knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)process_group(group) } else { }, error = function(e) { rlang::entrace(e)48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) 53: } } }), function(loc) {vweave_rmarkdown(...)52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), pb$interrupt() output_dir = getwd(), ...) OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))}) setwd(wd) if (xfun::pkg_available("rlang", "1.0.0")) { write_utf8(res, output %n% stdout()) if (is_R_CMD_build() || is_R_CMD_check()) {54: 53: engine$weave(file, quiet = quiet, encoding = enc) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) 50: process_file(text, output) cnd = tryCatch(rlang::entrace(e), error = identity) vweave_rmarkdown(...) 59: 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/Rtmp2hXezs/file35ce78213e4a.rds") An irrecoverable exception occurred. R is aborting now ... error <<- format(cnd)51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) }54: engine$weave(file, quiet = quiet, encoding = enc) else { 55: 55: doTryCatch(return(expr), name, parentenv, handler)doTryCatch(return(expr), name, parentenv, handler) 56: rlang::entrace(e)tryCatchOne(expr, names, parentenv, handlers[[1L]]) } 57: tryCatchList(expr, classes, parentenv, handlers) 58: tryCatch({56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: tryCatch({53: }vweave_rmarkdown(...) engine$weave(file, quiet = quiet, encoding = enc) }) setwd(startdir) engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) 49: output <- find_vignette_product(name, by = "weave", engine = engine)xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (!have.makefile && vignette_is_tex(output)) { if (progress && is.function(pb$interrupt)) pb$interrupt() output <- find_vignette_product(name, by = "weave", engine = engine) texi2pdf(file = output, clean = FALSE, quiet = quiet) if (xfun::pkg_available("rlang", "1.0.0")) { output <- find_vignette_product(name, by = "texi2pdf", if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) if (!have.makefile && vignette_is_tex(output)) { engine = engine) }}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))}) 59: 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/Rtmp2hXezs/file35ce78213e4a.rds") } texi2pdf(file = output, clean = FALSE, quiet = quiet)An irrecoverable exception occurred. R is aborting now ... else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) output <- find_vignette_product(name, by = "texi2pdf", engine = engine)vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) }57: tryCatchList(expr, classes, parentenv, handlers) 58: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc)}, error = function(e) { OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))}) 59: setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine)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/Rtmp2hXezs/file35ce78213e4a.rds") An irrecoverable exception occurred. R is aborting now ... 57: tryCatchList(expr, classes, parentenv, handlers) 58: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) if (!have.makefile && vignette_is_tex(output)) { setwd(startdir) texi2pdf(file = output, clean = FALSE, quiet = quiet) 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)))}) 59: tools:::.buildOneVignette("mnl_models.Rmd", "/Volumes/Builds/packages/big-sur-arm64/results/4.5/logitr.Rcheck/vign_test/logitr", 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))) TRUE, FALSE, "mnl_models", "UTF-8", "/Volumes/Temp/tmp/Rtmp2hXezs/file35ce78213e4a.rds")}) 59: 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/Rtmp2hXezs/file35ce78213e4a.rds") An irrecoverable exception occurred. R is aborting now ... An irrecoverable exception occurred. R is aborting now ... Quitting from mnl_models.Rmd:85-98 [unnamed-chunk-9] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ <error/rlang_error> Error in `names(x) <- value`: ! 'names' attribute [3] must be the same length as the vector [0] --- Backtrace: ▆ 1. └─logitr::logitr(...) 2. └─logitr:::getMultistartSummary(allModels) 3. └─base::`colnames<-`(...) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Error: processing vignette 'mnl_models.Rmd' failed with diagnostics: 'names' attribute [3] must be the same length as the vector [0] --- failed re-building ‘mnl_models.Rmd’ --- re-building ‘mnl_models_weighted.Rmd’ using rmarkdown *** caught segfault *** address 0x110, cause 'invalid permissions' Traceback: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 2: eval_f(x0, ...) 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) 4: doTryCatch(return(expr), name, parentenv, handler) 5: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 6: tryCatchList(expr, classes, parentenv, handlers) 7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {}) 8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }}) 9: FUN(X[[i]], ...) 10: lapply(X = S, FUN = FUN, ...) 11: doTryCatch(return(expr), name, parentenv, handler) 12: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 13: tryCatchList(expr, classes, parentenv, handlers) 14: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ") LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (is.na(w)) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))}) 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) 17: FUN(X[[i]], ...) 18: lapply(seq_len(cores), inner.do) 19: parallel::mclapply(miList, runModel, mc.cores = numCores) 20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) 21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) 22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage")) 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))) 24: runMultistart(modelInputs) 25: logitr(data = cars_us, outcome = "choice", obsID = "obsnum", pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", "bev150", "american", "japanese", "chinese", "skorean", "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), scalePar = "price", robust = TRUE, numMultiStarts = 10) 26: eval(expr, envir) 27: eval(expr, envir) 28: withVisible(eval(expr, envir)) 29: withCallingHandlers(code, 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)))}) 59: 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/Rtmp2hXezs/file35ce4bb2d531.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 = 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, 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)))}) 59: 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/Rtmp2hXezs/file35ce4bb2d531.rds") An irrecoverable exception occurred. R is aborting now ... Traceback: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 2: eval_f(x0, ...) 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) 4: doTryCatch(return(expr), name, parentenv, handler) 5: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 6: tryCatchList(expr, classes, parentenv, handlers) 7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {}) 8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }}) 9: FUN(X[[i]], ...) 10: lapply(X = S, FUN = FUN, ...) 11: doTryCatch(return(expr), name, parentenv, handler) 12: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 13: tryCatchList(expr, classes, parentenv, handlers) 14: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ") LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (is.na(w)) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))}) 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) 17: FUN(X[[i]], ...) 18: lapply(seq_len(cores), inner.do) 19: parallel::mclapply(miList, runModel, mc.cores = numCores) 20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) 21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) 22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage")) 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))) 24: runMultistart(modelInputs) 25: logitr(data = cars_us, outcome = "choice", obsID = "obsnum", pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", "bev150", "american", "japanese", "chinese", "skorean", "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), scalePar = "price", robust = TRUE, numMultiStarts = 10) 26: eval(expr, envir) 27: eval(expr, envir) 28: withVisible(eval(expr, envir)) 29: withCallingHandlers(code, 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)))}) 59: 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/Rtmp2hXezs/file35ce4bb2d531.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 = cars_us, outcome = "choice", obsID = "obsnum", pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", 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) "bev150", "american", "japanese", "chinese", "skorean", "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), scalePar = "price", robust = TRUE, numMultiStarts = 10) 26: 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)eval(expr, envir) 27: eval(expr, envir) }, error = function(e) { }) if (!is.null(result)) { 28: withVisible(eval(expr, envir)) model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status 29: withCallingHandlers(code, 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) 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) } 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) 14: tryCatch(expr, error = function(e) { } TRUE}, handlers) 33: doWithOneRestart(return(expr), restart) 34: 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)) withOneRestart(expr, restarts[[1L]]) 35: withRestartList(expr, restarts[-nr]) 36: doWithOneRestart(return(expr), restart) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } *** caught segfault *** 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)) 37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) address 0x110, cause 'invalid permissions' 38: withRestartList(expr, restarts) }) 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 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)16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) } 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)17: FUN(X[[i]], ...) 18: lapply(seq_len(cores), inner.do) 19: parallel::mclapply(miList, runModel, mc.cores = numCores) 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) 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, } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { classes)) tryInvokeRestart("muffleMessage")) 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))) if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) 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: error <<- format(cnd) } else { rlang::entrace(e) } } }), 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)eval(expr, envir) 28: withVisible(eval(expr, envir)) 29: withCallingHandlers(code, message = function (cnd) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)) {{ watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { texi2pdf(file = output, clean = FALSE, quiet = quiet) output <- find_vignette_product(name, by = "texi2pdf", engine = engine) }}, error = function(e) { invokeRestart("muffleMessage") }}, warning = function (cnd) OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))}) 59: { 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")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/Rtmp2hXezs/file35ce4bb2d531.rds") An irrecoverable exception occurred. R is aborting now ... }}, 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)))}) 59: 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/Rtmp2hXezs/file35ce4bb2d531.rds") An irrecoverable exception occurred. R is aborting now ... Traceback: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 2: eval_f(x0, ...) 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) 4: doTryCatch(return(expr), name, parentenv, handler) 5: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 6: tryCatchList(expr, classes, parentenv, handlers) 7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {}) 8: system.time({ model <- mi$model result <- NULL tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) { }) if (!is.null(result)) { model$fail <- FALSE model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }}) 9: FUN(X[[i]], ...) 10: lapply(X = S, FUN = FUN, ...) 11: doTryCatch(return(expr), name, parentenv, handler) 12: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 13: tryCatchList(expr, classes, parentenv, handlers) 14: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ") LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (is.na(w)) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e))}) 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) 17: FUN(X[[i]], ...) 18: lapply(seq_len(cores), inner.do) 19: parallel::mclapply(miList, runModel, mc.cores = numCores) 20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) 21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) 22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage")) 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))) 24: runMultistart(modelInputs) 25: logitr(data = cars_us, outcome = "choice", obsID = "obsnum", pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", "bev150", "american", "japanese", "chinese", "skorean", "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), scalePar = "price", robust = TRUE, numMultiStarts = 10) 26: eval(expr, envir) 27: eval(expr, envir) 28: withVisible(eval(expr, envir)) 29: withCallingHandlers(code, 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)))}) 59: 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/Rtmp2hXezs/file35ce4bb2d531.rds") An irrecoverable exception occurred. R is aborting now ... *** caught segfault *** address 0x110, cause 'invalid permissions' *** caught segfault *** address 0x110, cause 'invalid permissions' *** caught segfault *** address 0x110, cause 'invalid permissions' Traceback: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 2: eval_f(x0, ...) 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) 4: doTryCatch(return(expr), name, parentenv, handler) 5: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 6: tryCatchList(expr, classes, parentenv, handlers) 7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, 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) 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) 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) 4: doTryCatch(return(expr), name, parentenv, handler) 17: FUN(X[[i]], ...) 18: lapply(seq_len(cores), inner.do) 19: parallel::mclapply(miList, runModel, mc.cores = numCores) 20: 5: withCallingHandlers(expr, warning = function(w) if (inherits(w, 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 Traceback: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 2: eval_f(x0, ...) 3: classes)) tryInvokeRestart("muffleWarning")) model$status <- result$status 21: 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)suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) 22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage")) 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]]) 14: 6: tryCatchList(expr, classes, parentenv, handlers) 7: tryCatch({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) 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 } 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))})23: }) 9: FUN(X[[i]], ...) 10: lapply(X = S, FUN = FUN, ...) 11: doTryCatch(return(expr), name, parentenv, handler) suppressMessages(suppressWarnings(parallel::mclapply(miList, 12: 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)) 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))tryCatchOne(expr, names, parentenv, handlers[[1L]]) 13: tryCatchList(expr, classes, parentenv, handlers) 29: withCallingHandlers(code, message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } 14: tryCatch(expr, error = function(e) { call <- conditionCall(e)17: if (!is.null(call)) { *** caught segfault *** FUN(X[[i]], ...) 18: if (identical(call[[1L]], quote(doTryCatch))) address 0x110, cause 'invalid permissions' lapply(seq_len(cores), inner.do) 19: parallel::mclapply(miList, runModel, mc.cores = numCores) call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ") if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] }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))) 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()) }24: watcher$capture_plot_and_output() invisible(structure(msg, class = "try-error", condition = e))})runMultistart(modelInputs) if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) 17: FUN(X[[i]], ...) 18: watcher$capture_plot_and_output() 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: cnd <- sanitize_call(cnd)eval(expr, envir) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)lapply(seq_len(cores), inner.do) 28: withVisible(eval(expr, envir)) 29: 19: parallel::mclapply(miList, runModel, mc.cores = numCores)withCallingHandlers(code, 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) {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) return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd)25: logitr(data = cars_us, outcome = "choice", obsID = "obsnum", pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", "bev150", "american", "japanese", "chinese", "skorean", "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), scalePar = "price", robust = TRUE, numMultiStarts = 10) 26: eval(expr, envir) 27: eval(expr, envir) 28: withVisible(eval(expr, envir)) })29: watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) 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) { watcher$push(cnd) ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)withCallingHandlers(code, message = function (cnd) }) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE) 40: evaluate::evaluate(...){ 41: 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$capture_plot_and_output()evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, Traceback: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 2: eval_f(x0, ...) 3: keep_message = if (is.numeric(options$message)) TRUE else options$message, nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) watcher$print_value(ev$value, ev$visible, envir) 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) { } TRUE}, handlers) 33: doWithOneRestart(return(expr), restart) 34: withOneRestart(expr, restarts[[1L]]) 35: withRestartList(expr, restarts[-nr]) 36: doWithOneRestart(return(expr), restart){ if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) mi = mi, opts = mi$options) 4: doTryCatch(return(expr), name, parentenv, handler) if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } 37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) 38: withRestartList(expr, restarts) watcher$push(cnd) 5: tryCatchOne(expr, names, parentenv, handlers[[1L]]) } 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) 39: else { 6: tryCatchList(expr, classes, parentenv, handlers)withRestarts(with_handlers({ 7: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, rlang::entrace(e) for (expr in tle$exprs) { mi = mi, opts = mi$options) } ev <- withVisible(eval(expr, envir)) }}, error = function(e) {}) 8: system.time({ }) watcher$capture_plot_and_output() } watcher$print_value(ev$value, ev$visible, envir) 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)) { TRUE } TRUE49: }, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE) model$fail <- FALSExfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) model$coefficients <- result$solution 52: model$logLik <- as.numeric(-1 * result$objective)rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), 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) }, handlers) model$iterations <- result$iterations output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) model$status <- result$status model$message <- result$message }}) 43: 9: FUN(X[[i]], ...) 10: lapply(X = S, FUN = FUN, ...)in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, 55: doTryCatch(return(expr), name, parentenv, handler) keep_message = if (is.numeric(options$message)) TRUE else options$message, 11: doTryCatch(return(expr), name, parentenv, handler) 12: stop_on_error = if (is.numeric(options$error)) options$error else {33: doWithOneRestart(return(expr), restart)56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) if (options$error && options$include) tryCatchOne(expr, names, parentenv, handlers[[1L]]) 0L13: else 2L 34: withOneRestart(expr, restarts[[1L]]) 35: tryCatchList(expr, classes, parentenv, handlers) 14: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) 57: withRestartList(expr, restarts[-nr]) call <- sys.call(-4L) 36: doWithOneRestart(return(expr), restart) 37: }, output_handler = knit_handlers(options$render, options))) 44: eng_r(options) 45: block_exec(params) 46: call_block(x) 47: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])tryCatchList(expr, classes, parentenv, handlers)process_group(group) dcall <- deparse(call, nlines = 1L) 58: 38: tryCatch({withRestartList(expr, restarts) engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine)39: withRestarts(with_handlers({ 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)) for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], type = "b") if (w > LONG) 48: 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) {withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), watcher$print_value(ev$value, ev$visible, envir) error = function(e) { prefix <- paste0(prefix, "\n ") } OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))}) 59: 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/Rtmp2hXezs/file35ce4bb2d531.rds") TRUE if (progress && is.function(pb$interrupt)) } else prefix <- "Error : "}, 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: pb$interrupt()in_dir(input_dir(), expr) An irrecoverable exception occurred. R is aborting now ... msg <- paste0(prefix, conditionMessage(e), "\n") if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) .Internal(seterrmessage(msg[1L]))43: 49: in_input_dir(evaluate(code, envir = env, new_device = FALSE, xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), function(loc) { setwd(wd) write_utf8(res, output %n% stdout()) keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) 50: keep_message = if (is.numeric(options$message)) TRUE else options$message, if (!silent && isTRUE(getOption("show.error.messages"))) {process_file(text, output) 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))) cat(msg, file = outFile) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e)) 44: eng_r(options)}) 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 16: 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 45: block_exec(params) 46: call_block(x) 47: process_group(group)55: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {17: FUN(X[[i]], ...) if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) 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")) }58: else {tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) rlang::entrace(e) if (!have.makefile && vignette_is_tex(output)) { texi2pdf(file = output, clean = FALSE, quiet = quiet)21: 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)))}) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e)suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) 22: }withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage")) 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))) 24: runMultistart(modelInputs) 25: logitr(data = cars_us, outcome = "choice", obsID = "obsnum", pars = c("hev", "phev10", "phev20", "phev40", "bev75", "bev100", "bev150", "american", "japanese", "chinese", "skorean", }59: 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/Rtmp2hXezs/file35ce4bb2d531.rds") }), function(loc) { "phevFastcharge", "bevFastcharge", "opCost", "accelTime"), setwd(wd)An irrecoverable exception occurred. R is aborting now ... write_utf8(res, output %n% stdout()) scalePar = "price", robust = TRUE, numMultiStarts = 10) 26: eval(expr, envir) 27: eval(expr, envir) 28: withVisible(eval(expr, envir)) 29: withCallingHandlers(code, message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) } if (on_message$silence) { invokeRestart("muffleMessage") }}, warning = function (cnd) {50: if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } watcher$capture_plot_and_output() if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning") }}, 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: process_file(text, output) 51: 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: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: withRestartList(expr, restarts[-nr]) 36: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: doWithOneRestart(return(expr), restart) 37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) 38: withRestartList(expr, restarts) tryCatchList(expr, classes, parentenv, handlers) 58: 39: withRestarts(with_handlers({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) { 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: OK <<- FALSE message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", file, conditionMessage(e)))}) 59: 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/Rtmp2hXezs/file35ce4bb2d531.rds") 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: 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)))}) 59: 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/Rtmp2hXezs/file35ce4bb2d531.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' *** 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, 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) 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) 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)))}) 59: 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/Rtmp2hXezs/file35ce58fb74af.rds") An irrecoverable exception occurred. R is aborting now ... 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, 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)))}) 59: 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/Rtmp2hXezs/file35ce58fb74af.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) {}) Traceback: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 2: eval_f(x0, ...) 8: system.time({ model <- mi$model result <- NULL tryCatch({ 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) 4: 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: 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 <- NULLlapply(X = S, FUN = FUN, ...) Traceback: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 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 ") 2: Traceback: } 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))eval_f(x0, ...) 3: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) }, error = function(e) {}) 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 4: 1: doTryCatch(return(expr), name, parentenv, handler) })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: if (!is.null(result)) { model$fail <- FALSE tryCatchOne(expr, names, parentenv, handlers[[1L]]) *** caught segfault *** *** caught segfault *** 5: model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective)address 0x110, cause 'invalid permissions' tryCatchOne(expr, names, parentenv, handlers[[1L]]) 6: 6: *** caught segfault *** tryCatchList(expr, classes, parentenv, handlers)tryCatchList(expr, classes, parentenv, handlers) *** caught segfault *** 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) 17: address 0x110, cause 'invalid permissions' address 0x110, cause 'invalid permissions' 7: model$iterations <- result$iterationsaddress 0x110, cause 'invalid permissions' tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) {}) 8: model$status <- result$statusFUN(X[[i]], ...) model$message <- result$message 7: 18: lapply(seq_len(cores), inner.do)tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)}, error = function(e) { 19: 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) {}) 8: system.time({ model <- mi$model result <- NULL })parallel::mclapply(miList, runModel, mc.cores = numCores) 20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) }}) 9: FUN(X[[i]], ...) 10: if (!is.null(result)) {lapply(X = S, FUN = FUN, ...) model$fail <- FALSE model$coefficients <- result$solution 11: doTryCatch(return(expr), name, parentenv, handler) 12: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 13: model$logLik <- as.numeric(-1 * result$objective)tryCatchList(expr, classes, parentenv, handlers) model$iterations <- result$iterations model$status <- result$status model$message <- result$message } 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 <- FALSE14: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L)}) 9: FUN(X[[i]], ...) 10: dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ") LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]]21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) 22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage")) 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") model$coefficients <- result$solution model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message }}) if (w > LONG) 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))) 24: runMultistart(modelInputs) 9: FUN(X[[i]], ...) prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n")lapply(X = S, FUN = FUN, ...) Traceback: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) .Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) 2: eval_f(x0, ...) 3: } Traceback: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) 2: eval_f(x0, ...) invisible(structure(msg, class = "try-error", condition = e))nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, 3: 10: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, lapply(X = S, FUN = FUN, ...) 25: mi = mi, opts = mi$options) Traceback: 1: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar) }) 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 11: mi = mi, opts = mi$options)logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", doTryCatch(return(expr), name, parentenv, handler)16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) 4: "brand"), scalePar = "price", numMultiStarts = 10) Traceback: 11: 12: 2: doTryCatch(return(expr), name, parentenv, handler) 5: eval_f(x0, ...)17: FUN(X[[i]], ...) doTryCatch(return(expr), name, parentenv, handler) tryCatchOne(expr, names, parentenv, handlers[[1L]]) 3: 26: eval(expr, envir) 4: 27: 18: 12: doTryCatch(return(expr), name, parentenv, handler)lapply(seq_len(cores), inner.do) 1: nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, eval(expr, envir)tryCatchOne(expr, names, parentenv, handlers[[1L]]) 19: 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) parallel::mclapply(miList, runModel, mc.cores = numCores) 20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) tryCatchOne(expr, names, parentenv, handlers[[1L]]) mi = mi, opts = mi$options)13: tryCatchList(expr, classes, parentenv, handlers) 21: 13: 28: withVisible(eval(expr, envir)) 4: mi$logitFuncs$getMnlV(pars, d$X, d$scalePar)suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))29: withCallingHandlers(code, message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) {}, error = function(e) {14: }) 8: system.time({ model <- mi$model result <- NULL tryCatch({doTryCatch(return(expr), name, parentenv, handler) 5: watcher$push(cnd) 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) 2: }tryCatchList(expr, classes, parentenv, handlers)22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage"))eval_f(x0, ...) if (on_message$silence) { result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, tryCatchOne(expr, names, parentenv, handlers[[1L]]) invokeRestart("muffleMessage")23: mi = mi, opts = mi$options)}, error = function(e) {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())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, message = function (cnd) } 14: tryCatch(expr, error = function(e) { }, error = function(e) {{ watcher$capture_plot_and_output()}) if (on_message$capture) { } call <- conditionCall(e) watcher$push(cnd) 6: }, warning = function (cnd) { if (getOption("warn") >= 2 || getOption("warn") < 0) { return() } } if (!is.null(call)) { watcher$capture_plot_and_output() 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: if (identical(call[[1L]], quote(doTryCatch))) if (on_message$silence) { }) 8: 3: FUN(X[[i]], ...) if (on_warning$capture) {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()) } cnd <- sanitize_call(cnd) if (!is.null(result)) { invokeRestart("muffleMessage") tryCatchList(expr, classes, parentenv, handlers)nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options) invisible(structure(msg, class = "try-error", condition = e)) }}) 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 7: call <- sys.call(-4L)}, warning = function (cnd) watcher$push(cnd)16: tryCatch({ 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)sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, dcall <- deparse(call, nlines = 1L) 4: 14: 17: {doTryCatch(return(expr), name, parentenv, handler)18: lapply(seq_len(cores), inner.do) if (getOption("warn") >= 2 || getOption("warn") < 0) { return() 5: 19: FUN(X[[i]], ...) tryCatchOne(expr, names, parentenv, handlers[[1L]]) prefix <- paste("Error in", dcall, ": ")18: }parallel::mclapply(miList, runModel, mc.cores = numCores)lapply(seq_len(cores), inner.do) }tryCatch(expr, error = function(e) {19: watcher$capture_plot_and_output() 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: if (on_warning$capture) { cnd <- sanitize_call(cnd) watcher$push(cnd) } if (on_warning$silence) { invokeRestart("muffleWarning")try(lapply(X = S, FUN = FUN, ...), silent = TRUE)parallel::mclapply(miList, runModel, mc.cores = numCores) } LONG <- 75L 16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) if (on_warning$silence) {}, error = function (cnd) mi = mi, opts = mi$options)20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) sm <- strsplit(conditionMessage(e), "\n")[[1L]] invokeRestart("muffleWarning") 6: }17: 21: 20: withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning"))}, error = function(e) { w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "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) if (is.na(w)) { w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], FUN(X[[i]], ...)suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))}, error = function(e) {21: type = "b") }, error = function (cnd) watcher$capture_plot_and_output() cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), if (w > LONG) {22: withCallingHandlers(expr, message = function(c) if (inherits(c, classes)) tryInvokeRestart("muffleMessage")) stop = invokeRestart("eval_stop"), error = NULL)suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) watcher$capture_plot_and_output()})18: cnd <- sanitize_call(cnd) 22: })withCallingHandlers(expr, message = function(c) if (inherits(c, watcher$push(cnd) 8: switch(on_error, continue = invokeRestart("eval_continue"), prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") stop = invokeRestart("eval_stop"), error = NULL)})lapply(seq_len(cores), inner.do)}) .Internal(seterrmessage(msg[1L]))30: 23: if (!silent && isTRUE(getOption("show.error.messages"))) { 8: 30: eval(call) cat(msg, file = outFile)system.time({eval(call) classes)) tryInvokeRestart("muffleMessage")) model <- mi$model19: suppressMessages(suppressWarnings(parallel::mclapply(miList, 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) result <- NULL runModel, mc.cores = numCores)))31: .Internal(printDeferredWarnings()) 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 system.time({eval(call) } TRUEparallel::mclapply(miList, runModel, mc.cores = numCores) 24: }, handlers)23: suppressMessages(suppressWarnings(parallel::mclapply(miList, model <- mi$modelrunMultistart(modelInputs) 25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10) 26: } model$logLik <- as.numeric(-1 * result$objective) model$iterations <- result$iterations model$status <- result$status model$message <- result$message33: invisible(structure(msg, class = "try-error", condition = e)) }})}) runModel, mc.cores = numCores))) eval(expr, envir) 27: doWithOneRestart(return(expr), restart) result <- NULLeval(expr, envir)24: 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 20: withCallingHandlers(expr, warning = function(w) if (inherits(w, 28: withVisible(eval(expr, envir)) 32: tryCatch({ result <- nloptr::nloptr(x0 = mi$model$startVals, eval_f = mi$evalFuncs$objective, mi = mi, opts = mi$options)16: 29: withCallingHandlers(code, message = function (cnd) { watcher$capture_plot_and_output()34: }, error = function(e) { }) if (!is.null(result)) { if (on_message$capture) { watcher$push(cnd)withOneRestart(expr, restarts[[1L]]) classes)) tryInvokeRestart("muffleWarning"))runMultistart(modelInputs) 25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10) 26: eval(expr, envir) 27: model$fail <- FALSE 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: model$coefficients <- result$solutionsendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))with_handlers({ tryCatch(expr, error = function(e) { } 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)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: for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output()eval(expr, envir) model$logLik <- as.numeric(-1 * result$objective)logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10) watcher$print_value(ev$value, ev$visible, envir) model$iterations <- result$iterations 26: 17: 35: model$status <- result$status call <- conditionCall(e)eval(expr, envir) } model$message <- result$message } if (!is.null(call)) { if (on_warning$silence) {FUN(X[[i]], ...) if (identical(call[[1L]], quote(doTryCatch))) 18: 28: } call <- sys.call(-4L) invokeRestart("muffleWarning") }}, error = function (cnd) { watcher$capture_plot_and_output() withVisible(eval(expr, envir)) dcall <- deparse(call, nlines = 1L)withRestartList(expr, restarts[-nr]) prefix <- paste("Error in", dcall, ": ") TRUE }, handlers)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"))}) 33: doWithOneRestart(return(expr), restart)36: LONG <- 75LdoWithOneRestart(return(expr), restart) 34: cnd <- sanitize_call(cnd) 27: sm <- strsplit(conditionMessage(e), "\n")[[1L]] 29: withOneRestart(expr, restarts[[1L]])23: w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") 9: withCallingHandlers(code, message = function (cnd) eval(expr, envir)suppressMessages(suppressWarnings(parallel::mclapply(miList, 37: if (is.na(w)) watcher$push(cnd) runModel, mc.cores = numCores)))FUN(X[[i]], ...) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], 35: switch(on_error, continue = invokeRestart("eval_continue"), withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]){ 28: 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) } withVisible(eval(expr, envir)) 29: withCallingHandlers(code, message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } stop = invokeRestart("eval_stop"), error = NULL) type = "b")10: TRUE 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 (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())}) 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)withRestartList(expr, restarts[-nr]) } if (on_warning$capture) {}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE) cnd <- sanitize_call(cnd) invisible(structure(msg, class = "try-error", condition = e))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 ") } watcher$push(cnd)}) 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)36: 34: } withOneRestart(expr, restarts[[1L]]) 40: if (on_message$silence) {doWithOneRestart(return(expr), restart) 37: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) 38: withRestartList(expr, restarts) invokeRestart("muffleMessage") }}, warning = function (cnd) 24: 16: 35: withRestartList(expr, restarts[-nr]) else prefix <- "Error : " 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)36: 39: 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))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(...) sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE)) msg <- paste0(prefix, conditionMessage(e), "\n")evaluate::evaluate(...){41: 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) runMultistart(modelInputs)}) .Internal(seterrmessage(msg[1L])) if (getOption("warn") >= 2 || getOption("warn") < 0) { 25: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", "brand"), scalePar = "price", numMultiStarts = 10) 26: eval(expr, envir) 27: eval(expr, envir) 46: return() if (!silent && isTRUE(getOption("show.error.messages"))) {17: FUN(X[[i]], ...) 28: } 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) {18: call_block(x)lapply(seq_len(cores), inner.do) 19: parallel::mclapply(miList, runModel, mc.cores = numCores)41: withVisible(eval(expr, envir))30: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, watcher$capture_plot_and_output() 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) keep_message = if (is.numeric(options$message)) TRUE else options$message, 20: 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 2LwithCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) 21: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) 22: 47: 0L cat(msg, file = outFile) else 2L }, output_handler = knit_handlers(options$render, options))) cnd <- sanitize_call(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), stop = invokeRestart("eval_stop"), error = NULL)}) 30: process_group(group) }, 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) 29: withCallingHandlers(code, 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()eval(call) eval(call) .Internal(printDeferredWarnings()) 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) 48: } invisible(structure(msg, class = "try-error", condition = e))}) 15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE) 16: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error <<- format(cnd)withCallingHandlers(expr, message = function(c) if (inherits(c, 34: } error = function(e) { 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) sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))27: eval(expr, envir) 28: withVisible(eval(expr, envir)) 29: withCallingHandlers(code, message = function (cnd) { watcher$capture_plot_and_output() if (on_message$capture) { watcher$push(cnd) } if (on_message$silence) { invokeRestart("muffleMessage") withOneRestart(expr, restarts[[1L]]) if (progress && is.function(pb$interrupt)) } watcher$capture_plot_and_output() 44: 31: else {eval(call)17: pb$interrupt() } if (on_warning$capture) { rlang::entrace(e) 32: }, warning = function (cnd) eng_r(options) if (xfun::pkg_available("rlang", "1.0.0")) { cnd <- sanitize_call(cnd) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {{with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) 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") } watcher$capture_plot_and_output() if (progress && is.function(pb$interrupt)) pb$interrupt() watcher$push(cnd)35: } if (on_warning$silence) { invokeRestart("muffleWarning") }}, error = function (cnd) withRestartList(expr, restarts[-nr])FUN(X[[i]], ...) if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) {}, error = function (cnd) 36: watcher$print_value(ev$value, ev$visible, envir)doWithOneRestart(return(expr), restart) 45: cnd = tryCatch(rlang::entrace(e), error = identity){18: { watcher$capture_plot_and_output() error <<- format(cnd) watcher$capture_plot_and_output() } else { rlang::entrace(e)37: }lapply(seq_len(cores), inner.do) cnd <- sanitize_call(cnd) } TRUE}, handlers) 33: cnd <- sanitize_call(cnd)block_exec(params) } 46: call_block(x) watcher$push(cnd) }) 49: doWithOneRestart(return(expr), restart)xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 47: process_group(group) if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) watcher$push(cnd) switch(on_error, continue = invokeRestart("eval_continue"), withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) 38: withRestartList(expr, restarts) 19: error <<- format(cnd) } else { rlang::entrace(e) } }34: }withOneRestart(expr, restarts[[1L]]) 35: switch(on_error, continue = invokeRestart("eval_continue"), 48: 39: withRestartList(expr, restarts[-nr]) 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]]) withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 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(...) stop = invokeRestart("eval_stop"), error = NULL)parallel::mclapply(miList, runModel, mc.cores = numCores)35: error = function(e) { withRestarts(with_handlers({}) for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) }), function(loc) { else { if (progress && is.function(pb$interrupt)) } TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE) 40: evaluate::evaluate(...) rlang::entrace(e) setwd(wd)41: withRestartList(expr, restarts[-nr])41: }30: write_utf8(res, output %n% stdout())evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, } }), function(loc) {36: 20: paste0("\nQuitting from ", loc, if (!is.null(error)) keep_message = if (is.numeric(options$message)) TRUE else options$message, paste0("\n", rule(), error, "\n", rule())) pb$interrupt()eval(call)doWithOneRestart(return(expr), restart) setwd(wd)}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) keep_message = if (is.numeric(options$message)) TRUE else options$message, 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) stop_on_error = if (is.numeric(options$error)) options$error else {withCallingHandlers(expr, warning = function(w) if (inherits(w, classes)) tryInvokeRestart("muffleWarning")) write_utf8(res, output %n% stdout()) stop_on_error = if (is.numeric(options$error)) options$error else {21: if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options)) 42: in_dir(input_dir(), expr) 43: in_input_dir(evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, keep_message = if (is.numeric(options$message)) TRUE else options$message, stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) if (options$error && options$include) 50: 0L paste0("\nQuitting from ", loc, if (!is.null(error)) 37: suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores)) if (xfun::pkg_available("rlang", "1.0.0")) { 0Lprocess_file(text, output) 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: } paste0("\n", rule(), error, "\n", rule()))withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) if (is_R_CMD_build() || is_R_CMD_check()) { else 2L TRUE}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) cnd = tryCatch(rlang::entrace(e), error = identity) }, output_handler = knit_handlers(options$render, options))51: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 38: error <<- format(cnd) knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) error = function(e) {22: }42: }, handlers)withCallingHandlers(expr, message = function(c) if (inherits(c, 33: doWithOneRestart(return(expr), restart) 34: withOneRestart(expr, restarts[[1L]]) 35: withRestartList(expr, restarts[-nr]) 36: doWithOneRestart(return(expr), restart) 37: else {withRestartList(expr, restarts) rlang::entrace(e)withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]]) classes)) tryInvokeRestart("muffleMessage")) if (progress && is.function(pb$interrupt)) 23: suppressMessages(suppressWarnings(parallel::mclapply(miList, runModel, mc.cores = numCores))) 24: runMultistart(modelInputs) } in_dir(input_dir(), expr)38: withRestartList(expr, restarts) 39: withRestarts(with_handlers({ for (expr in tle$exprs) { 52: pb$interrupt()25: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), if (xfun::pkg_available("rlang", "1.0.0")) { output_dir = getwd(), ...)43: logitr(data = yogurt, outcome = "choice", obsID = "obsID", pars = c("feat", 50: 39: if (is_R_CMD_build() || is_R_CMD_check()) { "brand"), scalePar = "price", numMultiStarts = 10) 26: eval(expr, envir) 27: eval(expr, envir) 28: withVisible(eval(expr, envir)) 29: } in_input_dir(evaluate(code, envir = env, new_device = FALSE, withRestarts(with_handlers({ ev <- withVisible(eval(expr, envir)) })process_file(text, output) for (expr in tle$exprs) {53: watcher$capture_plot_and_output()withCallingHandlers(code, 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)}) ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() watcher$print_value(ev$value, ev$visible, envir) } TRUE watcher$print_value(ev$value, ev$visible, envir) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, }, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE) vweave_rmarkdown(...) cnd = tryCatch(rlang::entrace(e), error = identity) }40: TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE) 40: evaluate::evaluate(...) keep_message = if (is.numeric(options$message)) TRUE else options$message, 41: 54: if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), function(loc) {evaluate::evaluate(...) stop_on_error = if (is.numeric(options$error)) options$error else {evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, engine$weave(file, quiet = quiet, encoding = enc) error <<- format(cnd) if (options$error && options$include) 30: 51: }41: 0Leval(call) keep_message = if (is.numeric(options$message)) TRUE else options$message, setwd(wd)55: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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 <<- FALSEevaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning, 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)))}) 59: 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/Rtmp2hXezs/file35ce58fb74af.rds") An irrecoverable exception occurred. R is aborting now ... else { keep_message = if (is.numeric(options$message)) TRUE else options$message, 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) 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, 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: keep_message = if (is.numeric(options$message)) TRUE else options$message, else 2L }, output_handler = knit_handlers(options$render, options))) 44: eng_r(options) 45: block_exec(params) 46: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) stop_on_error = if (is.numeric(options$error)) options$error else { if (options$error && options$include) 0L 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: 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, call_block(x) rlang::entrace(e) message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", stop_on_error = if (is.numeric(options$error)) options$error else {31: }47: process_group(group) 48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) if (options$error && options$include) pb$interrupt() file, conditionMessage(e)))57: if (options$error && options$include) 0L else 2L }, output_handler = knit_handlers(options$render, options))) 44: tryCatchList(expr, classes, parentenv, handlers) 58: tryCatch({ engine$weave(file, quiet = quiet, encoding = enc) setwd(startdir) output <- find_vignette_product(name, by = "weave", engine = engine) } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) {eng_r(options) if (xfun::pkg_available("rlang", "1.0.0")) {}) 0L 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)))}) else 2L 59: 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/Rtmp2hXezs/file35ce58fb74af.rds") An irrecoverable exception occurred. R is aborting now ... eval(call) if (is_R_CMD_build() || is_R_CMD_check()) { }, output_handler = knit_handlers(options$render, options))) 44: eng_r(options) 45: block_exec(params) 46: call_block(x) 47: process_group(group) cnd = tryCatch(rlang::entrace(e), error = identity)48: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) error <<- format(cnd) } else { rlang::entrace(e) } } }) if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: 59: 32: 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/Rtmp2hXezs/file35ce58fb74af.rds") An irrecoverable exception occurred. R is aborting now ... with_handlers({ for (expr in tle$exprs) { ev <- withVisible(eval(expr, envir)) watcher$capture_plot_and_output() 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } watcher$print_value(ev$value, ev$visible, envir) error <<- format(cnd)process_file(text, output)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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { }), function(loc) { setwd(wd) write_utf8(res, output %n% stdout())51: } else { rlang::entrace(e) } } }), 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) 50: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) cnd = tryCatch(rlang::entrace(e), error = identity)process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: } 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)) { TRUE paste0("\nQuitting from ", loc, if (!is.null(error)) paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), 57: 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)))}) 59: 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/Rtmp2hXezs/file35ce58fb74af.rds") An irrecoverable exception occurred. R is aborting now ... }, handlers)tryCatchList(expr, classes, parentenv, handlers) if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)))}) 59: 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/Rtmp2hXezs/file35ce58fb74af.rds") An irrecoverable exception occurred. R is aborting now ... 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 { output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)))}) 59: 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/Rtmp2hXezs/file35ce58fb74af.rds") An irrecoverable exception occurred. R is aborting now ... 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 (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }) 49: xfun:::handle_error(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), error = function(e) { if (progress && is.function(pb$interrupt)) pb$interrupt() if (xfun::pkg_available("rlang", "1.0.0")) { if (is_R_CMD_build() || is_R_CMD_check()) { cnd = tryCatch(rlang::entrace(e), error = identity) error <<- format(cnd) } else { rlang::entrace(e) } } }), 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) 50: process_file(text, output) 51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) 52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), output_dir = getwd(), ...) 53: vweave_rmarkdown(...) 54: engine$weave(file, quiet = quiet, encoding = enc) 55: doTryCatch(return(expr), name, parentenv, handler) 56: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 57: tryCatchList(expr, classes, parentenv, handlers) 58: 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)))}) 59: 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/Rtmp2hXezs/file35ce58fb74af.rds") An irrecoverable exception occurred. R is aborting now ... 58: 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)))}) 59: 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/Rtmp2hXezs/file35ce58fb74af.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