Running ‘DEPRECATED.R’ [1s/1s]
  Running ‘cluster-missing-doFuture-pkg.R’ [1s/3s]
  Running ‘doRNG,dopar.R’ [2s/9s]
  Running ‘doRNG,dorng.R’ [5s/16s]
  Running ‘foreach,errors.R’ [1s/4s]
  Running ‘foreach,globals.R’ [7s/30s]
  Running ‘foreach,nested.R’ [7s/36s]
  Running ‘foreach,nested_dopar.R’ [15s/66s]
  Running ‘foreach.R’ [2s/10s]
  Running ‘future.BatchJobs.R’ [0s/1s]
  Running ‘future.batchtools.R’ [0s/1s]
  Running ‘options.R’ [2s/8s]
  Running ‘registerDoFuture.R’ [2s/8s]
  Running ‘times.R’ [2s/10s]
  Running ‘zzz_opt-in,NMF.R’ [0s/1s]
  Running ‘zzz_opt-in,TSP.R’ [0s/1s]
  Running ‘zzz_opt-in,caret.R’ [0s/1s]
  Running ‘zzz_opt-in,foreach.R’ [0s/1s]
  Running ‘zzz_opt-in,glmnet.R’ [0s/1s]
  Running ‘zzz_opt-in,plyr.R’ [0s/1s]
Running the tests in ‘tests/foreach,errors.R’ failed.
Complete output:
  > source("incl/start.R")
  Loading required package: globals
  Loading required package: future
  Loading required package: foreach
  Loading required package: iterators
  Loading required package: parallel
  [20:37:13.036] plan(): Setting new future strategy stack:
  [20:37:13.037] List of future strategies:
  [20:37:13.037] 1. sequential:
  [20:37:13.037]    - args: function (expr, envir = parent.frame(), substitute = TRUE, lazy = FALSE, seed = NULL, globals = TRUE, local = TRUE, earlySignal = FALSE, label = NULL, ...)
  [20:37:13.037]    - tweaked: FALSE
  [20:37:13.037]    - call: future::plan(future::sequential)
  [20:37:13.039] plan(): nbrOfWorkers() = 1
  > 
  > strategies <- future:::supportedStrategies()
  > strategies <- setdiff(strategies, "multiprocess")
  > 
  > message("*** doFuture() - error handling w/ 'stop' ...")
  *** doFuture() - error handling w/ 'stop' ...
  > 
  > for (strategy in strategies) {
  +   message(sprintf("- plan('%s') ...", strategy))
  +   plan(strategy)
  + 
  +   mu <- 1.0
  +   sigma <- 2.0
  + 
  +   res <- tryCatch({
  +     foreach(i = 1:10, .errorhandling = "stop") %dopar% {
  +       if (i %% 2 == 0) stop(sprintf("Index error ('stop'), because i = %d", i))
  +       dnorm(i, mean = mu, sd = sigma)
  +     }
  +   }, error = identity)
  +   print(res)
  +   stopifnot(inherits(res, "error"),
  +             grepl("Index error", conditionMessage(res)))
  + 
  +   message(sprintf("- plan('%s') ... DONE", strategy))
  + } ## for (strategy ...)
  - plan('sequential') ...
  [20:37:13.068] plan(): Setting new future strategy stack:
  [20:37:13.068] List of future strategies:
  [20:37:13.068] 1. sequential:
  [20:37:13.068]    - args: function (expr, envir = parent.frame(), substitute = TRUE, lazy = FALSE, seed = NULL, globals = TRUE, local = TRUE, earlySignal = FALSE, label = NULL, ...)
  [20:37:13.068]    - tweaked: FALSE
  [20:37:13.068]    - call: plan(strategy)
  [20:37:13.089] plan(): nbrOfWorkers() = 1
  [20:37:13.089] doFuture() ...
  [20:37:13.092] - dummy globals (as locals): [1] 'i'
  [20:37:13.093] - R expression:
  [20:37:13.093] {
  [20:37:13.093]     doFuture::registerDoFuture()
  [20:37:13.093]     lapply(seq_along(...future.x_ii), FUN = function(jj) {
  [20:37:13.093]         ...future.x_jj <- ...future.x_ii[[jj]]
  [20:37:13.093]         i <- NULL
  [20:37:13.093]         ...future.env <- environment()
  [20:37:13.093]         local({
  [20:37:13.093]             for (name in names(...future.x_jj)) {
  [20:37:13.093]                 assign(name, ...future.x_jj[[name]], envir = ...future.env, 
  [20:37:13.093]                   inherits = FALSE)
  [20:37:13.093]             }
  [20:37:13.093]         })
  [20:37:13.093]         tryCatch({
  [20:37:13.093]             if (i%%2 == 0) 
  [20:37:13.093]                 stop(sprintf("Index error ('stop'), because i = %d", 
  [20:37:13.093]                   i))
  [20:37:13.093]             dnorm(i, mean = mu, sd = sigma)
  [20:37:13.093]         }, error = identity)
  [20:37:13.093]     })
  [20:37:13.093] }
  [20:37:13.094] - identifying globals and packages ...
  [20:37:13.096] getGlobalsAndPackages() ...
  [20:37:13.096] Searching for globals...
  [20:37:13.119] - globals found: [22] '{', '::', 'lapply', 'seq_along', '...future.x_ii', '<-', '[[', 'environment', 'local', 'for', 'names', 'assign', 'tryCatch', 'if', '==', '%%', 'stop', 'sprintf', 'dnorm', 'mu', 'sigma', 'identity'
  [20:37:13.119] Searching for globals ... DONE
  [20:37:13.120] Resolving globals: FALSE
  [20:37:13.122] The total size of the 3 globals is 112 bytes (112 bytes)
  [20:37:13.127] - globals: [3] '...future.x_ii', 'mu', 'sigma'
  [20:37:13.127] - packages: [1] 'stats'
  [20:37:13.127] getGlobalsAndPackages() ... DONE
  [20:37:13.128] List of 3
  [20:37:13.128]  $ ...future.x_ii: NULL
  [20:37:13.128]  $ mu            : num 1
  [20:37:13.128]  $ sigma         : num 2
  [20:37:13.128]  - attr(*, "where")=List of 3
  [20:37:13.128]   ..$ ...future.x_ii:<environment: 0x559ff7fa4610> 
  [20:37:13.128]   ..$ mu            :<environment: R_GlobalEnv> 
  [20:37:13.128]   ..$ sigma         :<environment: R_GlobalEnv> 
  [20:37:13.128]  - attr(*, "class")= chr [1:3] "FutureGlobals" "Globals" "list"
  [20:37:13.128]  - attr(*, "resolved")= logi FALSE
  [20:37:13.128]  - attr(*, "total_size")= num 112
  [20:37:13.140]   - R expression:
  [20:37:13.140] {
  [20:37:13.140]     doFuture::registerDoFuture()
  [20:37:13.140]     lapply(seq_along(...future.x_ii), FUN = function(jj) {
  [20:37:13.140]         ...future.x_jj <- ...future.x_ii[[jj]]
  [20:37:13.140]         i <- NULL
  [20:37:13.140]         ...future.env <- environment()
  [20:37:13.140]         local({
  [20:37:13.140]             for (name in names(...future.x_jj)) {
  [20:37:13.140]                 assign(name, ...future.x_jj[[name]], envir = ...future.env, 
  [20:37:13.140]                   inherits = FALSE)
  [20:37:13.140]             }
  [20:37:13.140]         })
  [20:37:13.140]         tryCatch({
  [20:37:13.140]             if (i%%2 == 0) 
  [20:37:13.140]                 stop(sprintf("Index error ('stop'), because i = %d", 
  [20:37:13.140]                   i))
  [20:37:13.140]             dnorm(i, mean = mu, sd = sigma)
  [20:37:13.140]         }, error = identity)
  [20:37:13.140]     })
  [20:37:13.140] }
  [20:37:13.141]   - globals: [3] '...future.x_ii', 'mu', 'sigma'
  [20:37:13.141] List of 3
  [20:37:13.141]  $ ...future.x_ii: NULL
  [20:37:13.141]  $ mu            : num 1
  [20:37:13.141]  $ sigma         : num 2
  [20:37:13.141]  - attr(*, "where")=List of 3
  [20:37:13.141]   ..$ ...future.x_ii:<environment: 0x559ff7fa4610> 
  [20:37:13.141]   ..$ mu            :<environment: R_GlobalEnv> 
  [20:37:13.141]   ..$ sigma         :<environment: R_GlobalEnv> 
  [20:37:13.141]  - attr(*, "class")= chr [1:3] "FutureGlobals" "Globals" "list"
  [20:37:13.141]  - attr(*, "resolved")= logi FALSE
  [20:37:13.141]  - attr(*, "total_size")= num 112
  [20:37:13.148]   - packages: [2] 'doFuture', 'stats'
  [20:37:13.149] - identifying globals and packages ... DONE
  [20:37:13.149] Number of chunks: 1
  [20:37:13.150] Number of futures (= number of chunks): 1
  [20:37:13.151] Launching 1 futures (chunks) ...
  [20:37:13.151] Chunk #1 of 1 ...
  [20:37:13.152]  - Finding globals in 'args_list' chunk #1 ...
  [20:37:13.152] getGlobalsAndPackages() ...
  [20:37:13.152] Searching for globals...
  [20:37:13.153] 
  [20:37:13.153] Searching for globals ... DONE
  [20:37:13.154] - globals: [0] <none>
  [20:37:13.154] getGlobalsAndPackages() ... DONE
  [20:37:13.154] 
  [20:37:13.154] 
  [20:37:13.155]  - Finding globals in 'args_list' for chunk #1 ... DONE
  [20:37:13.155] getGlobalsAndPackages() ...
  [20:37:13.156] - globals passed as-is: [3] '...future.x_ii', 'mu', 'sigma'
  [20:37:13.156] Resolving globals: FALSE
  [20:37:13.157] The total size of the 3 globals is 672 bytes (672 bytes)
  [20:37:13.157] - globals: [3] '...future.x_ii', 'mu', 'sigma'
  [20:37:13.157] 
  [20:37:13.158] getGlobalsAndPackages() ... DONE
  [20:37:13.160] Packages needed by the future expression (n = 2): 'doFuture', 'stats'
  [20:37:13.160] Packages needed by future strategies (n = 0): <none>
  [20:37:13.164] {
  [20:37:13.164]     {
  [20:37:13.164]         ...future.startTime <- base::Sys.time()
  [20:37:13.164]         ...future.oldOptions <- base::options(future.startup.script = FALSE, 
  [20:37:13.164]             future.globals.onMissing = "ignore", future.globals.maxSize = NULL, 
  [20:37:13.164]             future.globals.method = NULL, future.globals.onMissing = NULL, 
  [20:37:13.164]             future.globals.onReference = NULL, future.globals.resolve = NULL, 
  [20:37:13.164]             future.resolve.recursive = NULL, width = 80L)
  [20:37:13.164]         {
  [20:37:13.164]             {
  [20:37:13.164]                 {
  [20:37:13.164]                   base::local({
  [20:37:13.164]                     has_future <- base::requireNamespace("future", 
  [20:37:13.164]                       quietly = TRUE)
  [20:37:13.164]                     version <- if (has_future) 
  [20:37:13.164]                       utils::packageVersion("future")
  [20:37:13.164]                     else NULL
  [20:37:13.164]                     if (!has_future || version < "1.8.0") {
  [20:37:13.164]                       info <- base::c(r_version = base::gsub("R version ", 
  [20:37:13.164]                         "", base::R.version$version.string), 
  [20:37:13.164]                         platform = base::sprintf("%s (%s-bit)", 
  [20:37:13.164]                           base::R.version$platform, 8 * base::.Machine$sizeof.pointer), 
  [20:37:13.164]                         os = base::paste(base::Sys.info()[base::c("sysname", 
  [20:37:13.164]                           "release", "version")], collapse = " "), 
  [20:37:13.164]                         hostname = base::Sys.info()[["nodename"]])
  [20:37:13.164]                       info <- base::sprintf("%s: %s", base::names(info), 
  [20:37:13.164]                         info)
  [20:37:13.164]                       info <- base::paste(info, collapse = "; ")
  [20:37:13.164]                       if (!has_future) {
  [20:37:13.164]                         msg <- base::sprintf("Package 'future' is not installed on worker (%s)", 
  [20:37:13.164]                           info)
  [20:37:13.164]                       }
  [20:37:13.164]                       else {
  [20:37:13.164]                         msg <- base::sprintf("Package 'future' on worker (%s) must be of version >= 1.8.0: %s", 
  [20:37:13.164]                           info, version)
  [20:37:13.164]                       }
  [20:37:13.164]                       base::stop(msg)
  [20:37:13.164]                     }
  [20:37:13.164]                   })
  [20:37:13.164]                 }
  [20:37:13.164]                 base::local({
  [20:37:13.164]                   for (pkg in c("doFuture", "stats")) {
  [20:37:13.164]                     base::loadNamespace(pkg)
  [20:37:13.164]                     base::library(pkg, character.only = TRUE)
  [20:37:13.164]                   }
  [20:37:13.164]                 })
  [20:37:13.164]             }
  [20:37:13.164]             future::plan("default", .cleanup = FALSE, .init = FALSE)
  [20:37:13.164]         }
  [20:37:13.164]     }
  [20:37:13.164]     if (base::is.na(TRUE)) {
  [20:37:13.164]     }
  [20:37:13.164]     else {
  [20:37:13.164]         if (TRUE) {
  [20:37:13.164]             ...future.stdout <- base::rawConnection(base::raw(0L), 
  [20:37:13.164]                 open = "w")
  [20:37:13.164]         }
  [20:37:13.164]         else {
  [20:37:13.164]             ...future.stdout <- base::file(base::switch(.Platform$OS.type, 
  [20:37:13.164]                 windows = "NUL", "/dev/null"), open = "w")
  [20:37:13.164]         }
  [20:37:13.164]         base::sink(...future.stdout, type = "output", split = FALSE)
  [20:37:13.164]         base::on.exit(if (!base::is.null(...future.stdout)) {
  [20:37:13.164]             base::sink(type = "output", split = FALSE)
  [20:37:13.164]             base::close(...future.stdout)
  [20:37:13.164]         }, add = TRUE)
  [20:37:13.164]     }
  [20:37:13.164]     ...future.frame <- base::sys.nframe()
  [20:37:13.164]     ...future.conditions <- base::list()
  [20:37:13.164]     ...future.rng <- base::globalenv()$.Random.seed
  [20:37:13.164]     ...future.result <- base::tryCatch({
  [20:37:13.164]         base::withCallingHandlers({
  [20:37:13.164]             ...future.value <- base::withVisible(base::local({
  [20:37:13.164]                 doFuture::registerDoFuture()
  [20:37:13.164]                 lapply(seq_along(...future.x_ii), FUN = function(jj) {
  [20:37:13.164]                   ...future.x_jj <- ...future.x_ii[[jj]]
  [20:37:13.164]                   i <- NULL
  [20:37:13.164]                   ...future.env <- environment()
  [20:37:13.164]                   local({
  [20:37:13.164]                     for (name in names(...future.x_jj)) {
  [20:37:13.164]                       assign(name, ...future.x_jj[[name]], envir = ...future.env, 
  [20:37:13.164]                         inherits = FALSE)
  [20:37:13.164]                     }
  [20:37:13.164]                   })
  [20:37:13.164]                   tryCatch({
  [20:37:13.164]                     if (i%%2 == 0) 
  [20:37:13.164]                       stop(sprintf("Index error ('stop'), because i = %d", 
  [20:37:13.164]                         i))
  [20:37:13.164]                     dnorm(i, mean = mu, sd = sigma)
  [20:37:13.164]                   }, error = identity)
  [20:37:13.164]                 })
  [20:37:13.164]             }))
  [20:37:13.164]             future::FutureResult(value = ...future.value$value, 
  [20:37:13.164]                 visible = ...future.value$visible, rng = !identical(base::globalenv()$.Random.seed, 
  [20:37:13.164]                   ...future.rng), started = ...future.startTime, 
  [20:37:13.164]                 version = "1.8")
  [20:37:13.164]         }, condition = base::local({
  [20:37:13.164]             c <- base::c
  [20:37:13.164]             inherits <- base::inherits
  [20:37:13.164]             invokeRestart <- base::invokeRestart
  [20:37:13.164]             length <- base::length
  [20:37:13.164]             list <- base::list
  [20:37:13.164]             seq.int <- base::seq.int
  [20:37:13.164]             signalCondition <- base::signalCondition
  [20:37:13.164]             sys.calls <- base::sys.calls
  [20:37:13.164]             Sys.time <- base::Sys.time
  [20:37:13.164]             `[[` <- base::`[[`
  [20:37:13.164]             `+` <- base::`+`
  [20:37:13.164]             `<<-` <- base::`<<-`
  [20:37:13.164]             sysCalls <- function(calls = sys.calls(), from = 1L) {
  [20:37:13.164]                 calls[seq.int(from = from + 12L, to = length(calls) - 
  [20:37:13.164]                   3L)]
  [20:37:13.164]             }
  [20:37:13.164]             function(cond) {
  [20:37:13.164]                 if (inherits(cond, "error")) {
  [20:37:13.164]                   sessionInformation <- function() {
  [20:37:13.164]                     list(r = base::R.Version(), locale = base::Sys.getlocale(), 
  [20:37:13.164]                       rngkind = base::RNGkind(), namespaces = base::loadedNamespaces(), 
  [20:37:13.164]                       search = base::search(), system = base::Sys.info())
  [20:37:13.164]                   }
  [20:37:13.164]                   ...future.conditions[[length(...future.conditions) + 
  [20:37:13.164]                     1L]] <<- list(condition = cond, calls = c(sysCalls(from = ...future.frame), 
  [20:37:13.164]                     cond$call), session = sessionInformation(), 
  [20:37:13.164]                     timestamp = Sys.time(), signaled = 0L)
  [20:37:13.164]                   signalCondition(cond)
  [20:37:13.164]                 }
  [20:37:13.164]                 else if (inherits(cond, c("condition", "immediateCondition"
  [20:37:13.164]                 ))) {
  [20:37:13.164]                   signal <- TRUE && inherits(cond, "immediateCondition")
  [20:37:13.164]                   ...future.conditions[[length(...future.conditions) + 
  [20:37:13.164]                     1L]] <<- list(condition = cond, signaled = base::as.integer(signal))
  [20:37:13.164]                   if (!signal) {
  [20:37:13.164]                     muffleCondition <- function (cond) 
  [20:37:13.164]                     {
  [20:37:13.164]                       inherits <- base::inherits
  [20:37:13.164]                       invokeRestart <- base::invokeRestart
  [20:37:13.164]                       muffled <- FALSE
  [20:37:13.164]                       if (inherits(cond, "message")) {
  [20:37:13.164]                         invokeRestart("muffleMessage")
  [20:37:13.164]                         muffled <- TRUE
  [20:37:13.164]                       }
  [20:37:13.164]                       else if (inherits(cond, "warning")) {
  [20:37:13.164]                         invokeRestart("muffleWarning")
  [20:37:13.164]                         muffled <- TRUE
  [20:37:13.164]                       }
  [20:37:13.164]                       else if (inherits(cond, "condition")) {
  [20:37:13.164]                         computeRestarts <- base::computeRestarts
  [20:37:13.164]                         grepl <- base::grepl
  [20:37:13.164]                         is.null <- base::is.null
  [20:37:13.164]                         restarts <- computeRestarts(cond)
  [20:37:13.164]                         for (restart in restarts) {
  [20:37:13.164]                           name <- restart$name
  [20:37:13.164]                           if (is.null(name)) 
  [20:37:13.164]                             next
  [20:37:13.164]                           if (!grepl("^muffle", name)) 
  [20:37:13.164]                             next
  [20:37:13.164]                           invokeRestart(restart)
  [20:37:13.164]                           muffled <- TRUE
  [20:37:13.164]                           break
  [20:37:13.164]                         }
  [20:37:13.164]                       }
  [20:37:13.164]                       invisible(muffled)
  [20:37:13.164]                     }
  [20:37:13.164]                     muffleCondition(cond)
  [20:37:13.164]                   }
  [20:37:13.164]                 }
  [20:37:13.164]             }
  [20:37:13.164]         }))
  [20:37:13.164]     }, error = function(ex) {
  [20:37:13.164]         base::structure(base::list(value = NULL, visible = NULL, 
  [20:37:13.164]             conditions = ...future.conditions, rng = !identical(base::globalenv()$.Random.seed, 
  [20:37:13.164]                 ...future.rng), version = "1.8"), class = "FutureResult")
  [20:37:13.164]     }, finally = {
  [20:37:13.164]         {
  [20:37:13.164]             NULL
  [20:37:13.164]             future::plan(list(function (expr, envir = parent.frame(), 
  [20:37:13.164]                 substitute = TRUE, lazy = FALSE, seed = NULL, 
  [20:37:13.164]                 globals = TRUE, local = TRUE, earlySignal = FALSE, 
  [20:37:13.164]                 label = NULL, ...) 
  [20:37:13.164]             {
  [20:37:13.164]                 if (substitute) 
  [20:37:13.164]                   expr <- substitute(expr)
  [20:37:13.164]                 local <- as.logical(local)
  [20:37:13.164]                 future <- SequentialFuture(expr = expr, envir = envir, 
  [20:37:13.164]                   substitute = FALSE, lazy = lazy, seed = seed, 
  [20:37:13.164]                   globals = globals, local = local, earlySignal = earlySignal, 
  [20:37:13.164]                   label = label, ...)
  [20:37:13.164]                 if (!future$lazy) 
  [20:37:13.164]                   future <- run(future)
  [20:37:13.164]                 invisible(future)
  [20:37:13.164]             }), .cleanup = FALSE, .init = FALSE)
  [20:37:13.164]         }
  [20:37:13.164]         base::options(...future.oldOptions)
  [20:37:13.164]     })
  [20:37:13.164]     Sys.time
  [20:37:13.164]     if (base::is.na(TRUE)) {
  [20:37:13.164]     }
  [20:37:13.164]     else {
  [20:37:13.164]         base::sink(type = "output", split = FALSE)
  [20:37:13.164]         if (TRUE) {
  [20:37:13.164]             ...future.result$stdout <- base::rawToChar(base::rawConnectionValue(...future.stdout))
  [20:37:13.164]         }
  [20:37:13.164]         else {
  [20:37:13.164]             ...future.result["stdout"] <- base::list(NULL)
  [20:37:13.164]         }
  [20:37:13.164]         base::close(...future.stdout)
  [20:37:13.164]         ...future.stdout <- NULL
  [20:37:13.164]     }
  [20:37:13.164]     ...future.result$conditions <- ...future.conditions
  [20:37:13.164]     ...future.result
  [20:37:13.164] }
  [20:37:13.170] plan(): Setting new future strategy stack:
  [20:37:13.170] List of future strategies:
  [20:37:13.170] 1. sequential:
  [20:37:13.170]    - args: function (expr, envir = parent.frame(), substitute = TRUE, lazy = FALSE, seed = NULL, globals = TRUE, local = TRUE, earlySignal = FALSE, label = NULL, ...)
  [20:37:13.170]    - tweaked: FALSE
  [20:37:13.170]    - call: NULL
  [20:37:13.171] plan(): nbrOfWorkers() = 1
  [20:37:13.207] plan(): Setting new future strategy stack:
  [20:37:13.207] List of future strategies:
  [20:37:13.207] 1. sequential:
  [20:37:13.207]    - args: function (expr, envir = parent.frame(), substitute = TRUE, lazy = FALSE, seed = NULL, globals = TRUE, local = TRUE, earlySignal = FALSE, label = NULL, ...)
  [20:37:13.207]    - tweaked: FALSE
  [20:37:13.207]    - call: plan(strategy)
  [20:37:13.208] plan(): nbrOfWorkers() = 1
  [20:37:13.208] SequentialFuture started (and completed)
  [20:37:13.209] Chunk #1 of 1 ... DONE
  [20:37:13.210] Launching 1 futures (chunks) ... DONE
  [20:37:13.226] - resolving futures
  [20:37:13.226]   - gathering results & relaying conditions (except errors)
  [20:37:13.227] resolve() on list ...
  [20:37:13.227]  recursive: 0
  [20:37:13.228]  length: 1
  [20:37:13.228] 
  [20:37:13.228] Future #1
  [20:37:13.229] signalConditionsASAP(SequentialFuture, pos=1) ...
  [20:37:13.229] - nx: 1
  [20:37:13.230] - relay: TRUE
  [20:37:13.230] - stdout: TRUE
  [20:37:13.230] - signal: TRUE
  [20:37:13.230] - resignal: FALSE
  [20:37:13.231] - force: FALSE
  [20:37:13.231] - relayed: [n=1] FALSE
  [20:37:13.231] - queued futures: [n=1] FALSE
  [20:37:13.231]  - until=1
  [20:37:13.231]  - relaying element #1
  [20:37:13.232] - relayed: [n=1] TRUE
  [20:37:13.232] - queued futures: [n=1] TRUE
  [20:37:13.232] signalConditionsASAP(SequentialFuture, pos=1) ... done
  [20:37:13.233]  length: 0 (resolved future 1)
  [20:37:13.233] Relaying remaining futures
  [20:37:13.233] signalConditionsASAP(NULL, pos=0) ...
  [20:37:13.234] - nx: 1
  [20:37:13.234] - relay: TRUE
  [20:37:13.234] - stdout: TRUE
  [20:37:13.234] - signal: TRUE
  [20:37:13.234] - resignal: FALSE
  [20:37:13.235] - force: FALSE
  [20:37:13.235] - relayed: [n=1] TRUE
  [20:37:13.235] - queued futures: [n=1] TRUE
   - flush all
  [20:37:13.235] - relayed: [n=1] TRUE
  [20:37:13.236] - queued futures: [n=1] TRUE
  [20:37:13.236] signalConditionsASAP(NULL, pos=0) ... done
  [20:37:13.236] resolve() on list ... DONE
  [20:37:13.236] - collecting values of futures
  [20:37:13.237] - accumulating results
  [20:37:13.240] - processing errors (handler = 'stop')
  <simpleError in {    doFuture::registerDoFuture()    lapply(seq_along(...future.x_ii), FUN = function(jj) {        ...future.x_jj <- ...future.x_ii[[jj]]        i <- NULL        ...future.env <- environment()        local({            for (name in names(...future.x_jj)) {                assign(name, ...future.x_jj[[name]], envir = ...future.env,                   inherits = FALSE)            }        })        tryCatch({            if (i%%2 == 0)                 stop(sprintf("Index error ('stop'), because i = %d",                   i))            dnorm(i, mean = mu, sd = sigma)        }, error = identity)    })}: task 2 failed - "Index error ('stop'), because i = 2">
  - plan('sequential') ... DONE
  - plan('multicore') ...
  [20:37:13.241] plan(): Setting new future strategy stack:
  [20:37:13.258] List of future strategies:
  [20:37:13.258] 1. multicore:
  [20:37:13.258]    - args: function (expr, envir = parent.frame(), substitute = TRUE, lazy = FALSE, seed = NULL, globals = TRUE, workers = availableCores(constraints = "multicore"), earlySignal = FALSE, label = NULL, ...)
  [20:37:13.258]    - tweaked: FALSE
  [20:37:13.258]    - call: plan(strategy)
  [20:37:13.320] plan(): nbrOfWorkers() = 2
  [20:37:13.320] doFuture() ...
  [20:37:13.322] - dummy globals (as locals): [1] 'i'
  [20:37:13.322] - R expression:
  [20:37:13.323] {
  [20:37:13.323]     doFuture::registerDoFuture()
  [20:37:13.323]     lapply(seq_along(...future.x_ii), FUN = function(jj) {
  [20:37:13.323]         ...future.x_jj <- ...future.x_ii[[jj]]
  [20:37:13.323]         i <- NULL
  [20:37:13.323]         ...future.env <- environment()
  [20:37:13.323]         local({
  [20:37:13.323]             for (name in names(...future.x_jj)) {
  [20:37:13.323]                 assign(name, ...future.x_jj[[name]], envir = ...future.env, 
  [20:37:13.323]                   inherits = FALSE)
  [20:37:13.323]             }
  [20:37:13.323]         })
  [20:37:13.323]         tryCatch({
  [20:37:13.323]             if (i%%2 == 0) 
  [20:37:13.323]                 stop(sprintf("Index error ('stop'), because i = %d", 
  [20:37:13.323]                   i))
  [20:37:13.323]             dnorm(i, mean = mu, sd = sigma)
  [20:37:13.323]         }, error = identity)
  [20:37:13.323]     })
  [20:37:13.323] }
  [20:37:13.323] - identifying globals and packages ...
  [20:37:13.324] getGlobalsAndPackages() ...
  [20:37:13.324] Searching for globals...
  [20:37:13.335] - globals found: [22] '{', '::', 'lapply', 'seq_along', '...future.x_ii', '<-', '[[', 'environment', 'local', 'for', 'names', 'assign', 'tryCatch', 'if', '==', '%%', 'stop', 'sprintf', 'dnorm', 'mu', 'sigma', 'identity'
  [20:37:13.335] Searching for globals ... DONE
  [20:37:13.336] Resolving globals: FALSE
  [20:37:13.337] The total size of the 3 globals is 112 bytes (112 bytes)
  [20:37:13.337] - globals: [3] '...future.x_ii', 'mu', 'sigma'
  [20:37:13.338] - packages: [1] 'stats'
  [20:37:13.338] getGlobalsAndPackages() ... DONE
  [20:37:13.338] List of 3
  [20:37:13.338]  $ ...future.x_ii: NULL
  [20:37:13.338]  $ mu            : num 1
  [20:37:13.338]  $ sigma         : num 2
  [20:37:13.338]  - attr(*, "where")=List of 3
  [20:37:13.338]   ..$ ...future.x_ii:<environment: 0x559ff6003a58> 
  [20:37:13.338]   ..$ mu            :<environment: R_GlobalEnv> 
  [20:37:13.338]   ..$ sigma         :<environment: R_GlobalEnv> 
  [20:37:13.338]  - attr(*, "class")= chr [1:3] "FutureGlobals" "Globals" "list"
  [20:37:13.338]  - attr(*, "resolved")= logi FALSE
  [20:37:13.338]  - attr(*, "total_size")= num 112
  [20:37:13.370]   - R expression:
  [20:37:13.370] {
  [20:37:13.370]     doFuture::registerDoFuture()
  [20:37:13.370]     lapply(seq_along(...future.x_ii), FUN = function(jj) {
  [20:37:13.370]         ...future.x_jj <- ...future.x_ii[[jj]]
  [20:37:13.370]         i <- NULL
  [20:37:13.370]         ...future.env <- environment()
  [20:37:13.370]         local({
  [20:37:13.370]             for (name in names(...future.x_jj)) {
  [20:37:13.370]                 assign(name, ...future.x_jj[[name]], envir = ...future.env, 
  [20:37:13.370]                   inherits = FALSE)
  [20:37:13.370]             }
  [20:37:13.370]         })
  [20:37:13.370]         tryCatch({
  [20:37:13.370]             if (i%%2 == 0) 
  [20:37:13.370]                 stop(sprintf("Index error ('stop'), because i = %d", 
  [20:37:13.370]                   i))
  [20:37:13.370]             dnorm(i, mean = mu, sd = sigma)
  [20:37:13.370]         }, error = identity)
  [20:37:13.370]     })
  [20:37:13.370] }
  [20:37:13.371]   - globals: [3] '...future.x_ii', 'mu', 'sigma'
  [20:37:13.371] List of 3
  [20:37:13.371]  $ ...future.x_ii: NULL
  [20:37:13.371]  $ mu            : num 1
  [20:37:13.371]  $ sigma         : num 2
  [20:37:13.371]  - attr(*, "where")=List of 3
  [20:37:13.371]   ..$ ...future.x_ii:<environment: 0x559ff6003a58> 
  [20:37:13.371]   ..$ mu            :<environment: R_GlobalEnv> 
  [20:37:13.371]   ..$ sigma         :<environment: R_GlobalEnv> 
  [20:37:13.371]  - attr(*, "class")= chr [1:3] "FutureGlobals" "Globals" "list"
  [20:37:13.371]  - attr(*, "resolved")= logi FALSE
  [20:37:13.371]  - attr(*, "total_size")= num 112
  [20:37:13.406]   - packages: [2] 'doFuture', 'stats'
  [20:37:13.407] - identifying globals and packages ... DONE
  [20:37:13.438] Number of chunks: 2
  [20:37:13.439] Number of futures (= number of chunks): 2
  [20:37:13.439] Launching 2 futures (chunks) ...
  [20:37:13.439] Chunk #1 of 2 ...
  [20:37:13.440]  - Finding globals in 'args_list' chunk #1 ...
  [20:37:13.440] getGlobalsAndPackages() ...
  [20:37:13.440] Searching for globals...
  [20:37:13.441] 
  [20:37:13.441] Searching for globals ... DONE
  [20:37:13.441] - globals: [0] <none>
  [20:37:13.442] getGlobalsAndPackages() ... DONE
  [20:37:13.442] 
  [20:37:13.442] 
  [20:37:13.442]  - Finding globals in 'args_list' for chunk #1 ... DONE
  [20:37:13.443] getGlobalsAndPackages() ...
  [20:37:13.444] - globals passed as-is: [3] '...future.x_ii', 'mu', 'sigma'
  [20:37:13.444] Resolving globals: FALSE
  [20:37:13.445] The total size of the 3 globals is 392 bytes (392 bytes)
  [20:37:13.445] - globals: [3] '...future.x_ii', 'mu', 'sigma'
  [20:37:13.445] 
  [20:37:13.445] getGlobalsAndPackages() ... DONE
  [20:37:13.450] Packages needed by the future expression (n = 2): 'doFuture', 'stats'
  [20:37:13.451] Packages needed by future strategies (n = 0): <none>
  [20:37:13.454] {
  [20:37:13.454]     {
  [20:37:13.454]         ...future.startTime <- base::Sys.time()
  [20:37:13.454]         ...future.oldOptions <- base::options(future.startup.script = FALSE, 
  [20:37:13.454]             future.globals.onMissing = "ignore", future.globals.maxSize = NULL, 
  [20:37:13.454]             future.globals.method = NULL, future.globals.onMissing = "ignore", 
  [20:37:13.454]             future.globals.onReference = NULL, future.globals.resolve = NULL, 
  [20:37:13.454]             future.resolve.recursive = NULL, width = 80L)
  [20:37:13.454]         {
  [20:37:13.454]             {
  [20:37:13.454]                 {
  [20:37:13.454]                   {
  [20:37:13.454]                     base::local({
  [20:37:13.454]                       has_future <- base::requireNamespace("future", 
  [20:37:13.454]                         quietly = TRUE)
  [20:37:13.454]                       version <- if (has_future) 
  [20:37:13.454]                         utils::packageVersion("future")
  [20:37:13.454]                       else NULL
  [20:37:13.454]                       if (!has_future || version < "1.8.0") {
  [20:37:13.454]                         info <- base::c(r_version = base::gsub("R version ", 
  [20:37:13.454]                           "", base::R.version$version.string), 
  [20:37:13.454]                           platform = base::sprintf("%s (%s-bit)", 
  [20:37:13.454]                             base::R.version$platform, 8 * base::.Machine$sizeof.pointer), 
  [20:37:13.454]                           os = base::paste(base::Sys.info()[base::c("sysname", 
  [20:37:13.454]                             "release", "version")], collapse = " "), 
  [20:37:13.454]                           hostname = base::Sys.info()[["nodename"]])
  [20:37:13.454]                         info <- base::sprintf("%s: %s", base::names(info), 
  [20:37:13.454]                           info)
  [20:37:13.454]                         info <- base::paste(info, collapse = "; ")
  [20:37:13.454]                         if (!has_future) {
  [20:37:13.454]                           msg <- base::sprintf("Package 'future' is not installed on worker (%s)", 
  [20:37:13.454]                             info)
  [20:37:13.454]                         }
  [20:37:13.454]                         else {
  [20:37:13.454]                           msg <- base::sprintf("Package 'future' on worker (%s) must be of version >= 1.8.0: %s", 
  [20:37:13.454]                             info, version)
  [20:37:13.454]                         }
  [20:37:13.454]                         base::stop(msg)
  [20:37:13.454]                       }
  [20:37:13.454]                     })
  [20:37:13.454]                   }
  [20:37:13.454]                   ...future.mc.cores.old <- base::getOption("mc.cores")
  [20:37:13.454]                   base::options(mc.cores = 1L)
  [20:37:13.454]                 }
  [20:37:13.454]                 base::local({
  [20:37:13.454]                   for (pkg in c("doFuture", "stats")) {
  [20:37:13.454]                     base::loadNamespace(pkg)
  [20:37:13.454]                     base::library(pkg, character.only = TRUE)
  [20:37:13.454]                   }
  [20:37:13.454]                 })
  [20:37:13.454]             }
  [20:37:13.454]             future::plan("default", .cleanup = FALSE, .init = FALSE)
  [20:37:13.454]         }
  [20:37:13.454]     }
  [20:37:13.454]     if (base::is.na(TRUE)) {
  [20:37:13.454]     }
  [20:37:13.454]     else {
  [20:37:13.454]         if (TRUE) {
  [20:37:13.454]             ...future.stdout <- base::rawConnection(base::raw(0L), 
  [20:37:13.454]                 open = "w")
  [20:37:13.454]         }
  [20:37:13.454]         else {
  [20:37:13.454]             ...future.stdout <- base::file(base::switch(.Platform$OS.type, 
  [20:37:13.454]                 windows = "NUL", "/dev/null"), open = "w")
  [20:37:13.454]         }
  [20:37:13.454]         base::sink(...future.stdout, type = "output", split = FALSE)
  [20:37:13.454]         base::on.exit(if (!base::is.null(...future.stdout)) {
  [20:37:13.454]             base::sink(type = "output", split = FALSE)
  [20:37:13.454]             base::close(...future.stdout)
  [20:37:13.454]         }, add = TRUE)
  [20:37:13.454]     }
  [20:37:13.454]     ...future.frame <- base::sys.nframe()
  [20:37:13.454]     ...future.conditions <- base::list()
  [20:37:13.454]     ...future.rng <- base::globalenv()$.Random.seed
  [20:37:13.454]     ...future.result <- base::tryCatch({
  [20:37:13.454]         base::withCallingHandlers({
  [20:37:13.454]             ...future.value <- base::withVisible(base::local({
  [20:37:13.454]                 doFuture::registerDoFuture()
  [20:37:13.454]                 lapply(seq_along(...future.x_ii), FUN = function(jj) {
  [20:37:13.454]                   ...future.x_jj <- ...future.x_ii[[jj]]
  [20:37:13.454]                   i <- NULL
  [20:37:13.454]                   ...future.env <- environment()
  [20:37:13.454]                   local({
  [20:37:13.454]                     for (name in names(...future.x_jj)) {
  [20:37:13.454]                       assign(name, ...future.x_jj[[name]], envir = ...future.env, 
  [20:37:13.454]                         inherits = FALSE)
  [20:37:13.454]                     }
  [20:37:13.454]                   })
  [20:37:13.454]                   tryCatch({
  [20:37:13.454]                     if (i%%2 == 0) 
  [20:37:13.454]                       stop(sprintf("Index error ('stop'), because i = %d", 
  [20:37:13.454]                         i))
  [20:37:13.454]                     dnorm(i, mean = mu, sd = sigma)
  [20:37:13.454]                   }, error = identity)
  [20:37:13.454]                 })
  [20:37:13.454]             }))
  [20:37:13.454]             future::FutureResult(value = ...future.value$value, 
  [20:37:13.454]                 visible = ...future.value$visible, rng = !identical(base::globalenv()$.Random.seed, 
  [20:37:13.454]                   ...future.rng), started = ...future.startTime, 
  [20:37:13.454]                 version = "1.8")
  [20:37:13.454]         }, condition = base::local({
  [20:37:13.454]             c <- base::c
  [20:37:13.454]             inherits <- base::inherits
  [20:37:13.454]             invokeRestart <- base::invokeRestart
  [20:37:13.454]             length <- base::length
  [20:37:13.454]             list <- base::list
  [20:37:13.454]             seq.int <- base::seq.int
  [20:37:13.454]             signalCondition <- base::signalCondition
  [20:37:13.454]             sys.calls <- base::sys.calls
  [20:37:13.454]             Sys.time <- base::Sys.time
  [20:37:13.454]             `[[` <- base::`[[`
  [20:37:13.454]             `+` <- base::`+`
  [20:37:13.454]             `<<-` <- base::`<<-`
  [20:37:13.454]             sysCalls <- function(calls = sys.calls(), from = 1L) {
  [20:37:13.454]                 calls[seq.int(from = from + 12L, to = length(calls) - 
  [20:37:13.454]                   3L)]
  [20:37:13.454]             }
  [20:37:13.454]             function(cond) {
  [20:37:13.454]                 if (inherits(cond, "error")) {
  [20:37:13.454]                   sessionInformation <- function() {
  [20:37:13.454]                     list(r = base::R.Version(), locale = base::Sys.getlocale(), 
  [20:37:13.454]                       rngkind = base::RNGkind(), namespaces = base::loadedNamespaces(), 
  [20:37:13.454]                       search = base::search(), system = base::Sys.info())
  [20:37:13.454]                   }
  [20:37:13.454]                   ...future.conditions[[length(...future.conditions) + 
  [20:37:13.454]                     1L]] <<- list(condition = cond, calls = c(sysCalls(from = ...future.frame), 
  [20:37:13.454]                     cond$call), session = sessionInformation(), 
  [20:37:13.454]                     timestamp = Sys.time(), signaled = 0L)
  [20:37:13.454]                   signalCondition(cond)
  [20:37:13.454]                 }
  [20:37:13.454]                 else if (inherits(cond, "condition")) {
  [20:37:13.454]                   signal <- FALSE && inherits(cond, character(0))
  [20:37:13.454]                   ...future.conditions[[length(...future.conditions) + 
  [20:37:13.454]                     1L]] <<- list(condition = cond, signaled = base::as.integer(signal))
  [20:37:13.454]                   if (!signal) {
  [20:37:13.454]                     muffleCondition <- function (cond) 
  [20:37:13.454]                     {
  [20:37:13.454]                       inherits <- base::inherits
  [20:37:13.454]                       invokeRestart <- base::invokeRestart
  [20:37:13.454]                       muffled <- FALSE
  [20:37:13.454]                       if (inherits(cond, "message")) {
  [20:37:13.454]                         invokeRestart("muffleMessage")
  [20:37:13.454]                         muffled <- TRUE
  [20:37:13.454]                       }
  [20:37:13.454]                       else if (inherits(cond, "warning")) {
  [20:37:13.454]                         invokeRestart("muffleWarning")
  [20:37:13.454]                         muffled <- TRUE
  [20:37:13.454]                       }
  [20:37:13.454]                       else if (inherits(cond, "condition")) {
  [20:37:13.454]                         computeRestarts <- base::computeRestarts
  [20:37:13.454]                         grepl <- base::grepl
  [20:37:13.454]                         is.null <- base::is.null
  [20:37:13.454]                         restarts <- computeRestarts(cond)
  [20:37:13.454]                         for (restart in restarts) {
  [20:37:13.454]                           name <- restart$name
  [20:37:13.454]                           if (is.null(name)) 
  [20:37:13.454]                             next
  [20:37:13.454]                           if (!grepl("^muffle", name)) 
  [20:37:13.454]                             next
  [20:37:13.454]                           invokeRestart(restart)
  [20:37:13.454]                           muffled <- TRUE
  [20:37:13.454]                           break
  [20:37:13.454]                         }
  [20:37:13.454]                       }
  [20:37:13.454]                       invisible(muffled)
  [20:37:13.454]                     }
  [20:37:13.454]                     muffleCondition(cond)
  [20:37:13.454]                   }
  [20:37:13.454]                 }
  [20:37:13.454]             }
  [20:37:13.454]         }))
  [20:37:13.454]     }, error = function(ex) {
  [20:37:13.454]         base::structure(base::list(value = NULL, visible = NULL, 
  [20:37:13.454]             conditions = ...future.conditions, rng = !identical(base::globalenv()$.Random.seed, 
  [20:37:13.454]                 ...future.rng), version = "1.8"), class = "FutureResult")
  [20:37:13.454]     }, finally = {
  [20:37:13.454]         {
  [20:37:13.454]             {
  [20:37:13.454]                 base::options(mc.cores = ...future.mc.cores.old)
  [20:37:13.454]             }
  [20:37:13.454]             future::plan(list(function (expr, envir = parent.frame(), 
  [20:37:13.454]                 substitute = TRUE, lazy = FALSE, seed = NULL, 
  [20:37:13.454]                 globals = TRUE, workers = availableCores(constraints = "multicore"), 
  [20:37:13.454]                 earlySignal = FALSE, label = NULL, ...) 
  [20:37:13.454]             {
  [20:37:13.454]                 if (substitute) 
  [20:37:13.454]                   expr <- substitute(expr)
  [20:37:13.454]                 if (is.function(workers)) 
  [20:37:13.454]                   workers <- workers()
  [20:37:13.454]                 workers <- as.integer(workers)
  [20:37:13.454]                 stop_if_not(is.finite(workers), workers >= 1L)
  [20:37:13.454]                 if (workers == 1L || !supportsMulticore(warn = TRUE)) {
  [20:37:13.454]                   return(sequential(expr, envir = envir, substitute = FALSE, 
  [20:37:13.454]                     lazy = lazy, seed = seed, globals = globals, 
  [20:37:13.454]                     local = TRUE, label = label, ...))
  [20:37:13.454]                 }
  [20:37:13.454]                 oopts <- options(mc.cores = workers)
  [20:37:13.454]                 on.exit(options(oopts))
  [20:37:13.454]                 future <- MulticoreFuture(expr = expr, envir = envir, 
  [20:37:13.454]                   substitute = FALSE, lazy = lazy, seed = seed, 
  [20:37:13.454]                   globals = globals, workers = workers, earlySignal = earlySignal, 
  [20:37:13.454]                   label = label, ...)
  [20:37:13.454]                 if (!future$lazy) 
  [20:37:13.454]                   future <- run(future)
  [20:37:13.454]                 invisible(future)
  [20:37:13.454]             }), .cleanup = FALSE, .init = FALSE)
  [20:37:13.454]         }
  [20:37:13.454]         base::options(...future.oldOptions)
  [20:37:13.454]     })
  [20:37:13.454]     Sys.time
  [20:37:13.454]     if (base::is.na(TRUE)) {
  [20:37:13.454]     }
  [20:37:13.454]     else {
  [20:37:13.454]         base::sink(type = "output", split = FALSE)
  [20:37:13.454]         if (TRUE) {
  [20:37:13.454]             ...future.result$stdout <- base::rawToChar(base::rawConnectionValue(...future.stdout))
  [20:37:13.454]         }
  [20:37:13.454]         else {
  [20:37:13.454]             ...future.result["stdout"] <- base::list(NULL)
  [20:37:13.454]         }
  [20:37:13.454]         base::close(...future.stdout)
  [20:37:13.454]         ...future.stdout <- NULL
  [20:37:13.454]     }
  [20:37:13.454]     ...future.result$conditions <- ...future.conditions
  [20:37:13.454]     ...future.result
  [20:37:13.454] }
  [20:37:13.459] requestCore(): workers = 2
  [20:37:13.464] MulticoreFuture started
  [20:37:13.464] Chunk #1 of 2 ... DONE
  [20:37:13.465] Chunk #2 of 2 ...
  [20:37:13.465]  - Finding globals in 'args_list' chunk #2 ...
  [20:37:13.465] getGlobalsAndPackages() ...
  [20:37:13.466] Searching for globals...
  [20:37:13.467] 
  [20:37:13.467] Searching for globals ... DONE
  [20:37:13.468] - globals: [0] <none>
  [20:37:13.468] getGlobalsAndPackages() ... DONE
  [20:37:13.468] 
  [20:37:13.468] 
  [20:37:13.469]  - Finding globals in 'args_list' for chunk #2 ... DONE
  [20:37:13.470] getGlobalsAndPackages() ...
  [20:37:13.470] - globals passed as-is: [3] '...future.x_ii', 'mu', 'sigma'
  [20:37:13.471] Resolving globals: FALSE
  [20:37:13.472] The total size of the 3 globals is 392 bytes (392 bytes)
  [20:37:13.472] - globals: [3] '...future.x_ii', 'mu', 'sigma'
  [20:37:13.473] 
  [20:37:13.473] getGlobalsAndPackages() ... DONE
  [20:37:13.477] Packages needed by the future expression (n = 2): 'doFuture', 'stats'
  [20:37:13.477] Packages needed by future strategies (n = 0): <none>
  [20:37:13.479] plan(): Setting new future strategy stack:
  [20:37:13.480] List of future strategies:
  [20:37:13.480] 1. sequential:
  [20:37:13.480]    - args: function (expr, envir = parent.frame(), substitute = TRUE, lazy = FALSE, seed = NULL, globals = TRUE, local = TRUE, earlySignal = FALSE, label = NULL, ...)
  [20:37:13.480]    - tweaked: FALSE
  [20:37:13.480]    - call: NULL
  [20:37:13.481] plan(): nbrOfWorkers() = 1
  [20:37:13.484] plan(): Setting new future strategy stack:
  [20:37:13.484] List of future strategies:
  [20:37:13.484] 1. multicore:
  [20:37:13.484]    - args: function (expr, envir = parent.frame(), substitute = TRUE, lazy = FALSE, seed = NULL, globals = TRUE, workers = availableCores(constraints = "multicore"), earlySignal = FALSE, label = NULL, ...)
  [20:37:13.484]    - tweaked: FALSE
  [20:37:13.484]    - call: plan(strategy)
  [20:37:13.482] {
  [20:37:13.482]     {
  [20:37:13.482]         ...future.startTime <- base::Sys.time()
  [20:37:13.482]         ...future.oldOptions <- base::options(future.startup.script = FALSE, 
  [20:37:13.482]             future.globals.onMissing = "ignore", future.globals.maxSize = NULL, 
  [20:37:13.482]             future.globals.method = NULL, future.globals.onMissing = "ignore", 
  [20:37:13.482]             future.globals.onReference = NULL, future.globals.resolve = NULL, 
  [20:37:13.482]             future.resolve.recursive = NULL, width = 80L)
  [20:37:13.482]         {
  [20:37:13.482]             {
  [20:37:13.482]                 {
  [20:37:13.482]                   {
  [20:37:13.482]                     base::local({
  [20:37:13.482]                       has_future <- base::requireNamespace("future", 
  [20:37:13.482]                         quietly = TRUE)
  [20:37:13.482]                       version <- if (has_future) 
  [20:37:13.482]                         utils::packageVersion("future")
  [20:37:13.482]                       else NULL
  [20:37:13.482]                       if (!has_future || version < "1.8.0") {
  [20:37:13.482]                         info <- base::c(r_version = base::gsub("R version ", 
  [20:37:13.482]                           "", base::R.version$version.string), 
  [20:37:13.482]                           platform = base::sprintf("%s (%s-bit)", 
  [20:37:13.482]                             base::R.version$platform, 8 * base::.Machine$sizeof.pointer), 
  [20:37:13.482]                           os = base::paste(base::Sys.info()[base::c("sysname", 
  [20:37:13.482]                             "release", "version")], collapse = " "), 
  [20:37:13.482]                           hostname = base::Sys.info()[["nodename"]])
  [20:37:13.482]                         info <- base::sprintf("%s: %s", base::names(info), 
  [20:37:13.482]                           info)
  [20:37:13.482]                         info <- base::paste(info, collapse = "; ")
  [20:37:13.482]                         if (!has_future) {
  [20:37:13.482]                           msg <- base::sprintf("Package 'future' is not installed on worker (%s)", 
  [20:37:13.482]                             info)
  [20:37:13.482]                         }
  [20:37:13.482]                         else {
  [20:37:13.482]                           msg <- base::sprintf("Package 'future' on worker (%s) must be of version >= 1.8.0: %s", 
  [20:37:13.482]                             info, version)
  [20:37:13.482]                         }
  [20:37:13.482]                         base::stop(msg)
  [20:37:13.482]                       }
  [20:37:13.482]                     })
  [20:37:13.482]                   }
  [20:37:13.482]                   ...future.mc.cores.old <- base::getOption("mc.cores")
  [20:37:13.482]                   base::options(mc.cores = 1L)
  [20:37:13.482]                 }
  [20:37:13.482]                 base::local({
  [20:37:13.482]                   for (pkg in c("doFuture", "stats")) {
  [20:37:13.482]                     base::loadNamespace(pkg)
  [20:37:13.482]                     base::library(pkg, character.only = TRUE)
  [20:37:13.482]                   }
  [20:37:13.482]                 })
  [20:37:13.482]             }
  [20:37:13.482]             future::plan("default", .cleanup = FALSE, .init = FALSE)
  [20:37:13.482]         }
  [20:37:13.482]     }
  [20:37:13.482]     if (base::is.na(TRUE)) {
  [20:37:13.482]     }
  [20:37:13.482]     else {
  [20:37:13.482]         if (TRUE) {
  [20:37:13.482]             ...future.stdout <- base::rawConnection(base::raw(0L), 
  [20:37:13.482]                 open = "w")
  [20:37:13.482]         }
  [20:37:13.482]         else {
  [20:37:13.482]             ...future.stdout <- base::file(base::switch(.Platform$OS.type, 
  [20:37:13.482]                 windows = "NUL", "/dev/null"), open = "w")
  [20:37:13.482]         }
  [20:37:13.482]         base::sink(...future.stdout, type = "output", split = FALSE)
  [20:37:13.482]         base::on.exit(if (!base::is.null(...future.stdout)) {
  [20:37:13.482]             base::sink(type = "output", split = FALSE)
  [20:37:13.482]             base::close(...future.stdout)
  [20:37:13.482]         }, add = TRUE)
  [20:37:13.482]     }
  [20:37:13.482]     ...future.frame <- base::sys.nframe()
  [20:37:13.482]     ...future.conditions <- base::list()
  [20:37:13.482]     ...future.rng <- base::globalenv()$.Random.seed
  [20:37:13.482]     ...future.result <- base::tryCatch({
  [20:37:13.482]         base::withCallingHandlers({
  [20:37:13.482]             ...future.value <- base::withVisible(base::local({
  [20:37:13.482]                 doFuture::registerDoFuture()
  [20:37:13.482]                 lapply(seq_along(...future.x_ii), FUN = function(jj) {
  [20:37:13.482]                   ...future.x_jj <- ...future.x_ii[[jj]]
  [20:37:13.482]                   i <- NULL
  [20:37:13.482]                   ...future.env <- environment()
  [20:37:13.482]                   local({
  [20:37:13.482]                     for (name in names(...future.x_jj)) {
  [20:37:13.482]                       assign(name, ...future.x_jj[[name]], envir = ...future.env, 
  [20:37:13.482]                         inherits = FALSE)
  [20:37:13.482]                     }
  [20:37:13.482]                   })
  [20:37:13.482]                   tryCatch({
  [20:37:13.482]                     if (i%%2 == 0) 
  [20:37:13.482]                       stop(sprintf("Index error ('stop'), because i = %d", 
  [20:37:13.482]                         i))
  [20:37:13.482]                     dnorm(i, mean = mu, sd = sigma)
  [20:37:13.482]                   }, error = identity)
  [20:37:13.482]                 })
  [20:37:13.482]             }))
  [20:37:13.482]             future::FutureResult(value = ...future.value$value, 
  [20:37:13.482]                 visible = ...future.value$visible, rng = !identical(base::globalenv()$.Random.seed, 
  [20:37:13.482]                   ...future.rng), started = ...future.startTime, 
  [20:37:13.482]                 version = "1.8")
  [20:37:13.482]         }, condition = base::local({
  [20:37:13.482]             c <- base::c
  [20:37:13.482]             inherits <- base::inherits
  [20:37:13.482]             invokeRestart <- base::invokeRestart
  [20:37:13.482]             length <- base::length
  [20:37:13.482]             list <- base::list
  [20:37:13.482]             seq.int <- base::seq.int
  [20:37:13.482]             signalCondition <- base::signalCondition
  [20:37:13.482]             sys.calls <- base::sys.calls
  [20:37:13.482]             Sys.time <- base::Sys.time
  [20:37:13.482]             `[[` <- base::`[[`
  [20:37:13.482]             `+` <- base::`+`
  [20:37:13.482]             `<<-` <- base::`<<-`
  [20:37:13.482]             sysCalls <- function(calls = sys.calls(), from = 1L) {
  [20:37:13.482]                 calls[seq.int(from = from + 12L, to = length(calls) - 
  [20:37:13.482]                   3L)]
  [20:37:13.482]             }
  [20:37:13.482]             function(cond) {
  [20:37:13.482]                 if (inherits(cond, "error")) {
  [20:37:13.482]                   sessionInformation <- function() {
  [20:37:13.482]                     list(r = base::R.Version(), locale = base::Sys.getlocale(), 
  [20:37:13.482]                       rngkind = base::RNGkind(), namespaces = base::loadedNamespaces(), 
  [20:37:13.482]                       search = base::search(), system = base::Sys.info())
  [20:37:13.482]                   }
  [20:37:13.482]                   ...future.conditions[[length(...future.conditions) + 
  [20:37:13.482]                     1L]] <<- list(condition = cond, calls = c(sysCalls(from = ...future.frame), 
  [20:37:13.482]                     cond$call), session = sessionInformation(), 
  [20:37:13.482]                     timestamp = Sys.time(), signaled = 0L)
  [20:37:13.482]                   signalCondition(cond)
  [20:37:13.482]                 }
  [20:37:13.482]                 else if (inherits(cond, "condition")) {
  [20:37:13.482]                   signal <- FALSE && inherits(cond, character(0))
  [20:37:13.482]                   ...future.conditions[[length(...future.conditions) + 
  [20:37:13.482]                     1L]] <<- list(condition = cond, signaled = base::as.integer(signal))
  [20:37:13.482]                   if (!signal) {
  [20:37:13.482]                     muffleCondition <- function (cond) 
  [20:37:13.482]                     {
  [20:37:13.482]                       inherits <- base::inherits
  [20:37:13.482]                       invokeRestart <- base::invokeRestart
  [20:37:13.482]                       muffled <- FALSE
  [20:37:13.482]                       if (inherits(cond, "message")) {
  [20:37:13.482]                         invokeRestart("muffleMessage")
  [20:37:13.482]                         muffled <- TRUE
  [20:37:13.482]                       }
  [20:37:13.482]                       else if (inherits(cond, "warning")) {
  [20:37:13.482]                         invokeRestart("muffleWarning")
  [20:37:13.482]                         muffled <- TRUE
  [20:37:13.482]                       }
  [20:37:13.482]                       else if (inherits(cond, "condition")) {
  [20:37:13.482]                         computeRestarts <- base::computeRestarts
  [20:37:13.482]                         grepl <- base::grepl
  [20:37:13.482]                         is.null <- base::is.null
  [20:37:13.482]                         restarts <- computeRestarts(cond)
  [20:37:13.482]                         for (restart in restarts) {
  [20:37:13.482]                           name <- restart$name
  [20:37:13.482]                           if (is.null(name)) 
  [20:37:13.482]                             next
  [20:37:13.482]                           if (!grepl("^muffle", name)) 
  [20:37:13.482]                             next
  [20:37:13.482]                           invokeRestart(restart)
  [20:37:13.482]                           muffled <- TRUE
  [20:37:13.482]                           break
  [20:37:13.482]                         }
  [20:37:13.482]                       }
  [20:37:13.482]                       invisible(muffled)
  [20:37:13.482]                     }
  [20:37:13.482]                     muffleCondition(cond)
  [20:37:13.482]                   }
  [20:37:13.482]                 }
  [20:37:13.482]             }
  [20:37:13.482]         }))
  [20:37:13.482]     }, error = function(ex) {
  [20:37:13.482]         base::structure(base::list(value = NULL, visible = NULL, 
  [20:37:13.482]             conditions = ...future.conditions, rng = !identical(base::globalenv()$.Random.seed, 
  [20:37:13.482]                 ...future.rng), version = "1.8"), class = "FutureResult")
  [20:37:13.482]     }, finally = {
  [20:37:13.482]         {
  [20:37:13.482]             {
  [20:37:13.482]                 base::options(mc.cores = ...future.mc.cores.old)
  [20:37:13.482]             }
  [20:37:13.482]             future::plan(list(function (expr, envir = parent.frame(), 
  [20:37:13.482]                 substitute = TRUE, lazy = FALSE, seed = NULL, 
  [20:37:13.482]                 globals = TRUE, workers = availableCores(constraints = "multicore"), 
  [20:37:13.482]                 earlySignal = FALSE, label = NULL, ...) 
  [20:37:13.482]             {
  [20:37:13.482]                 if (substitute) 
  [20:37:13.482]                   expr <- substitute(expr)
  [20:37:13.482]                 if (is.function(workers)) 
  [20:37:13.482]                   workers <- workers()
  [20:37:13.482]                 workers <- as.integer(workers)
  [20:37:13.482]                 stop_if_not(is.finite(workers), workers >= 1L)
  [20:37:13.482]                 if (workers == 1L || !supportsMulticore(warn = TRUE)) {
  [20:37:13.482]                   return(sequential(expr, envir = envir, substitute = FALSE, 
  [20:37:13.482]                     lazy = lazy, seed = seed, globals = globals, 
  [20:37:13.482]                     local = TRUE, label = label, ...))
  [20:37:13.482]                 }
  [20:37:13.482]                 oopts <- options(mc.cores = workers)
  [20:37:13.482]                 on.exit(options(oopts))
  [20:37:13.482]                 future <- MulticoreFuture(expr = expr, envir = envir, 
  [20:37:13.482]                   substitute = FALSE, lazy = lazy, seed = seed, 
  [20:37:13.482]                   globals = globals, workers = workers, earlySignal = earlySignal, 
  [20:37:13.482]                   label = label, ...)
  [20:37:13.482]                 if (!future$lazy) 
  [20:37:13.482]                   future <- run(future)
  [20:37:13.482]                 invisible(future)
  [20:37:13.482]             }), .cleanup = FALSE, .init = FALSE)
  [20:37:13.482]         }
  [20:37:13.482]         base::options(...future.oldOptions)
  [20:37:13.482]     })
  [20:37:13.482]     Sys.time
  [20:37:13.482]     if (base::is.na(TRUE)) {
  [20:37:13.482]     }
  [20:37:13.482]     else {
  [20:37:13.482]         base::sink(type = "output", split = FALSE)
  [20:37:13.482]         if (TRUE) {
  [20:37:13.482]             ...future.result$stdout <- base::rawToChar(base::rawConnectionValue(...future.stdout))
  [20:37:13.482]         }
  [20:37:13.482]         else {
  [20:37:13.482]             ...future.result["stdout"] <- base::list(NULL)
  [20:37:13.482]         }
  [20:37:13.482]         base::close(...future.stdout)
  [20:37:13.482]         ...future.stdout <- NULL
  [20:37:13.482]     }
  [20:37:13.482]     ...future.result$conditions <- ...future.conditions
  [20:37:13.482]     ...future.result
  [20:37:13.482] }
  [20:37:13.488] requestCore(): workers = 2
  [20:37:13.497] MulticoreFuture started
  [20:37:13.498] Chunk #2 of 2 ... DONE
  [20:37:13.498] Launching 2 futures (chunks) ... DONE
  [20:37:13.498] plan(): nbrOfWorkers() = 2
  [20:37:13.498] - resolving futures
  [20:37:13.499]   - gathering results & relaying conditions (except errors)
  [20:37:13.499] resolve() on list ...
  [20:37:13.499]  recursive: 0
  [20:37:13.500]  length: 2
  [20:37:13.500] 
  [20:37:13.504] Future #1
  [20:37:13.508] signalConditionsASAP(MulticoreFuture, pos=1) ...
  [20:37:13.508] - nx: 2
  [20:37:13.509] - relay: TRUE
  [20:37:13.509] - stdout: TRUE
  [20:37:13.509] - signal: TRUE
  [20:37:13.509] - resignal: FALSE
  [20:37:13.510] - force: FALSE
  [20:37:13.510] - relayed: [n=2] FALSE, FALSE
  [20:37:13.510] - queued futures: [n=2] FALSE, FALSE
  [20:37:13.510]  - until=1
  [20:37:13.511]  - relaying element #1
  [20:37:13.511] - relayed: [n=2] TRUE, FALSE
  [20:37:13.511] - queued futures: [n=2] TRUE, FALSE
  [20:37:13.512] signalConditionsASAP(MulticoreFuture, pos=1) ... done
  [20:37:13.512]  length: 1 (resolved future 1)
  [20:37:13.532] plan(): Setting new future strategy stack:
  [20:37:13.532] List of future strategies:
  [20:37:13.532] 1. sequential:
  [20:37:13.532]    - args: function (expr, envir = parent.frame(), substitute = TRUE, lazy = FALSE, seed = NULL, globals = TRUE, local = TRUE, earlySignal = FALSE, label = NULL, ...)
  [20:37:13.532]    - tweaked: FALSE
  [20:37:13.532]    - call: NULL
  [20:37:13.534] plan(): nbrOfWorkers() = 1
  [20:37:13.536] plan(): Setting new future strategy stack:
  [20:37:13.537] List of future strategies:
  [20:37:13.537] 1. multicore:
  [20:37:13.537]    - args: function (expr, envir = parent.frame(), substitute = TRUE, lazy = FALSE, seed = NULL, globals = TRUE, workers = availableCores(constraints = "multicore"), earlySignal = FALSE, label = NULL, ...)
  [20:37:13.537]    - tweaked: FALSE
  [20:37:13.537]    - call: plan(strategy)
  [20:37:13.539] plan(): nbrOfWorkers() = 2
  [20:37:13.539] Future #2
  [20:37:13.548] signalConditionsASAP(MulticoreFuture, pos=2) ...
  [20:37:13.549] - nx: 2
  [20:37:13.549] - relay: TRUE
  [20:37:13.549] - stdout: TRUE
  [20:37:13.549] - signal: TRUE
  [20:37:13.550] - resignal: FALSE
  [20:37:13.550] - force: FALSE
  [20:37:13.550] - relayed: [n=2] TRUE, FALSE
  [20:37:13.550] - queued futures: [n=2] TRUE, FALSE
  [20:37:13.551]  - until=2
  [20:37:13.551]  - relaying element #2
  [20:37:13.552] - relayed: [n=2] TRUE, TRUE
  [20:37:13.552] - queued futures: [n=2] TRUE, TRUE
  [20:37:13.552] signalConditionsASAP(MulticoreFuture, pos=2) ... done
  [20:37:13.552]  length: 0 (resolved future 2)
  [20:37:13.553] Relaying remaining futures
  [20:37:13.553] signalConditionsASAP(NULL, pos=0) ...
  [20:37:13.553] - nx: 2
  [20:37:13.553] - relay: TRUE
  [20:37:13.561] - stdout: TRUE
  [20:37:13.562] - signal: TRUE
  [20:37:13.562] - resignal: FALSE
  [20:37:13.562] - force: FALSE
  [20:37:13.562] - relayed: [n=2] TRUE, TRUE
  [20:37:13.563] - queued futures: [n=2] TRUE, TRUE
   - flush all
  [20:37:13.563] - relayed: [n=2] TRUE, TRUE
  [20:37:13.564] - queued futures: [n=2] TRUE, TRUE
  [20:37:13.564] signalConditionsASAP(NULL, pos=0) ... done
  [20:37:13.564] resolve() on list ... DONE
  [20:37:13.564] - collecting values of futures
  [20:37:13.565] - accumulating results
  [20:37:13.567] - processing errors (handler = 'stop')
  <simpleError in {    doFuture::registerDoFuture()    lapply(seq_along(...future.x_ii), FUN = function(jj) {        ...future.x_jj <- ...future.x_ii[[jj]]        i <- NULL        ...future.env <- environment()        local({            for (name in names(...future.x_jj)) {                assign(name, ...future.x_jj[[name]], envir = ...future.env,                   inherits = FALSE)            }        })        tryCatch({            if (i%%2 == 0)                 stop(sprintf("Index error ('stop'), because i = %d",                   i))            dnorm(i, mean = mu, sd = sigma)        }, error = identity)    })}: task 2 failed - "Index error ('stop'), because i = 2">
  - plan('multicore') ... DONE
  - plan('multisession') ...
  [20:37:13.569] plan(): Setting new future strategy stack:
  [20:37:13.570] List of future strategies:
  [20:37:13.570] 1. multisession:
  [20:37:13.570]    - args: function (expr, envir = parent.frame(), substitute = TRUE, lazy = FALSE, seed = NULL, globals = TRUE, persistent = FALSE, workers = availableCores(), gc = FALSE, earlySignal = FALSE, label = NULL, ...)
  [20:37:13.570]    - tweaked: FALSE
  [20:37:13.570]    - call: plan(strategy)
  [20:37:13.571] plan(): plan_init() of 'multisession', 'cluster', 'multiprocess', 'future', 'function' ...
  [20:37:13.571] multisession:
  [20:37:13.571] - args: function (expr, envir = parent.frame(), substitute = TRUE, lazy = FALSE, seed = NULL, globals = TRUE, persistent = FALSE, workers = availableCores(), gc = FALSE, earlySignal = FALSE, label = NULL, ...)
  [20:37:13.571] - tweaked: FALSE
  [20:37:13.571] - call: plan(strategy)
  [local output] Workers: [n = 2] 'localhost', 'localhost'
  [local output] Base port: 33711
  [local output] Creating node 1 of 2 ...
  [local output] - setting up node
  Testing if worker's PID can be inferred: ''/home/hornik/tmp/R.check/r-devel-gcc/Work/build/bin/Rscript' -e 'try(suppressWarnings(cat(Sys.getpid(),file="/home/hornik/tmp/scratch/RtmpxomQPY/future.parent=4044.fcc5d1f990f.pid")), silent = TRUE)' -e "file.exists('/home/hornik/tmp/scratch/RtmpxomQPY/future.parent=4044.fcc5d1f990f.pid')"'
  - Possible to infer worker's PID: TRUE
  [local output] Starting worker #1 on 'localhost': '/home/hornik/tmp/R.check/r-devel-gcc/Work/build/bin/Rscript' --default-packages=datasets,utils,grDevices,graphics,stats,methods -e '#label=foreach,errors.R:4044:gimli2:hornik' -e 'try(suppressWarnings(cat(Sys.getpid(),file="/home/hornik/tmp/scratch/RtmpxomQPY/future.parent=4044.fcc5d1f990f.pid")), silent = TRUE)' -e 'parallel:::.slaveRSOCK()' MASTER=localhost PORT=33711 OUT=/dev/null TIMEOUT=120 XDR=TRUE
  [local output] - Exit code of system() call: 0
  [local output] Waiting for worker #1 on 'localhost' to connect back
  [local output] Detected a warning from socketConnection(): 'port 33711 cannot be opened'
  Warning in socketConnection("localhost", port = port, server = TRUE, blocking = TRUE,  :
    port 33711 cannot be opened
  Killing worker process (PID 5499) if still alive
  [20:37:15.848] Attempting to find a working pid_exists_*() function ...
  Call: tools::pskill(4044, signal = 0L)
  [1] TRUE
  Call: tools::pskill(4044, signal = 0L)
  [1] TRUE
  [20:37:15.849] - success
  [20:37:15.849] Attempting to find a working pid_exists_*() function ... done
  Worker (PID 5499) was successfully killed: TRUE
  Error in socketConnection("localhost", port = port, server = TRUE, blocking = TRUE,  : 
    Failed to launch and connect to R worker on local machine 'localhost' from local machine 'gimli2'.
   * The error produced by socketConnection() was: 'cannot open the connection'
   * In addition, socketConnection() produced 1 warning(s):
     - Warning #1: 'port 33711 cannot be opened' (which suggests that this port is either already occupied by another process or blocked by the firewall on your local machine)
   * The localhost socket connection that failed to connect to the R worker used port 33711 using a communication timeout of 120 seconds and a connection timeout of 120 seconds.
   * Worker launch call: '/home/hornik/tmp/R.check/r-devel-gcc/Work/build/bin/Rscript' --default-packages=datasets,utils,grDevices,graphics,stats,methods -e '#label=foreach,errors.R:4044:gimli2:hornik' -e 'try(suppressWarnings(cat(Sys.getpid(),file="/home/hornik/tmp/scratch/RtmpxomQPY/future.parent=4044.fcc5d1f990f.pid")), silent = TRUE)' -e 'parallel:::.slaveRSOCK()' MASTER=localhost PORT=33711 OUT=/dev/null TIMEOUT=120 XDR=TRUE.
   * Worker (PID 5499) was successfully killed: TRUE
   * Troubleshooting suggestions:
     - Suggestion #1: Set 'outfile=NULL' to see output from worker.
  Calls: plan ... tryCatchList -> tryCatchOne -> <Anonymous> -> <Anonymous>
  Execution halted