CRAN Package Check Results for Maintainer ‘Jens Oehlschlägel <Jens.Oehlschlaegel at truecluster.com>’

Last updated on 2024-12-18 19:49:39 CET.

Package ERROR OK
bit 13
bit64 13
ff 3 10

Package bit

Current CRAN status: OK: 13

Package bit64

Current CRAN status: OK: 13

Package ff

Current CRAN status: ERROR: 3, OK: 10

Additional issues

0len gcc-UBSAN

Version: 4.5.0
Check: tests
Result: ERROR Running ‘testthat.R’ [4s/5s] Running the tests in ‘tests/testthat.R’ failed. Complete output: > library(testthat) > test_check("ff") Loading required package: ff Loading required package: bit Attaching package: 'bit' The following object is masked from 'package:base': xor Attaching package ff - getOption("fftempdir")=="/tmp/RtmpDRMupI/ff" - getOption("ffextension")=="ff" - getOption("ffdrop")==TRUE - getOption("fffinonexit")==TRUE - getOption("ffpagesize")==65536 - getOption("ffcaching")=="mmnoflush" -- consider "ffeachflush" if your system stalls on large writes - getOption("ffbatchbytes")==16777216 -- consider a different value for tuning your system - getOption("ffmaxbytes")==536870912 -- consider a different value for tuning your system Attaching package: 'ff' The following objects are masked from 'package:utils': write.csv, write.csv2 The following objects are masked from 'package:base': is.factor, is.ordered *** caught segfault *** address 0x1, cause 'memory not mapped' Traceback: 1: `[<-.ff_array`(`*tmp*`, , value = c(0L, 0L, 0L, 0L, 0L, 0L, 0L, 0L, 0L)) 2: `[<-`(`*tmp*`, , value = c(0L, 0L, 0L, 0L, 0L, 0L, 0L, 0L, 0L)) 3: update.ff(ret, from = initdata, delete = FALSE, bydim = bydim, BATCHSIZE = BATCHSIZE, BATCHBYTES = BATCHBYTES, VERBOSE = VERBOSE) 4: ff(initdata = initdata, length = length, levels = levels, ordered = ordered, dim = dim, dimorder = dimorder, bydim = bydim, symmetric = symmetric, fixdiag = fixdiag, names = names, dimnames = dimnames, ramclass = ramclass, ramattribs = ramattribs, vmode = vmode, update = update, pattern = pattern, filename = filename, readonly = FALSE, overwrite = overwrite, pagesize = pagesize, caching = caching, finalizer = finalizer, finonexit = finonexit, FF_RETURN = FF_RETURN, BATCHSIZE = BATCHSIZE, BATCHBYTES = BATCHBYTES, VERBOSE = VERBOSE) 5: assign("ret", ff(initdata = initdata, length = length, levels = levels, ordered = ordered, dim = dim, dimorder = dimorder, bydim = bydim, symmetric = symmetric, fixdiag = fixdiag, names = names, dimnames = dimnames, ramclass = ramclass, ramattribs = ramattribs, vmode = vmode, update = update, pattern = pattern, filename = filename, readonly = FALSE, overwrite = overwrite, pagesize = pagesize, caching = caching, finalizer = finalizer, finonexit = finonexit, FF_RETURN = FF_RETURN, BATCHSIZE = BATCHSIZE, BATCHBYTES = BATCHBYTES, VERBOSE = VERBOSE)) 6: clone.ff(x, FF_RETURN = TRUE, filename = filename(x), overwrite = overwrite) 7: as.ff.default(r19) 8: as.ff(r19) 9: eval_bare(quo_get_expr(.quo), quo_get_env(.quo)) 10: withVisible(code) 11: withCallingHandlers(withVisible(code), warning = handle_warning, message = handle_message) 12: force(code) 13: withr::with_output_sink(path, withCallingHandlers(withVisible(code), warning = handle_warning, message = handle_message)) 14: .capture(act$val <- eval_bare(quo_get_expr(.quo), quo_get_env(.quo)), ...) 15: quasi_capture(enquo(object), NULL, evaluate_promise) 16: expect_silent(a19 <- as.ff(r19)) 17: eval(code, test_env) 18: eval(code, test_env) 19: withCallingHandlers({ eval(code, test_env) if (!handled && !is.null(test)) { skip_empty() }}, expectation = handle_expectation, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error) 20: doTryCatch(return(expr), name, parentenv, handler) 21: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 22: tryCatchList(expr, names[-nh], parentenv, handlers[-nh]) 23: doTryCatch(return(expr), name, parentenv, handler) 24: tryCatchOne(tryCatchList(expr, names[-nh], parentenv, handlers[-nh]), names[nh], parentenv, handlers[[nh]]) 25: tryCatchList(expr, classes, parentenv, handlers) 26: tryCatch(withCallingHandlers({ eval(code, test_env) if (!handled && !is.null(test)) { skip_empty() }}, expectation = handle_expectation, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error), error = handle_fatal, skip = function(e) { }) 27: test_code(desc, code, env = parent.frame(), reporter = reporter) 28: test_that("lots of stuff related to dims work", { vm <- "quad" expect_silent(r <- as.vmode(integer(), vmode = vm)) expect_silent(r0 <- as.vmode(integer(0), vmode = vm)) expect_silent(r1 <- as.vmode(integer(1), vmode = vm)) expect_silent(r00 <- as.vmode(integer(0), vmode = vm)) expect_silent(r01 <- as.vmode(integer(0), vmode = vm)) expect_silent(r10 <- as.vmode(integer(0), vmode = vm)) expect_silent(r11 <- as.vmode(integer(1), vmode = vm)) expect_silent(r09 <- as.vmode(integer(0), vmode = vm)) expect_silent(r19 <- as.vmode(integer(9), vmode = vm)) expect_silent(r90 <- as.vmode(integer(0), vmode = vm)) expect_silent(r91 <- as.vmode(integer(9), vmode = vm)) expect_silent(r99 <- as.vmode(integer(81), vmode = vm)) expect_error(dim(r) <- integer()) expect_silent(dim(r) <- NULL) expect_silent(dim(r0) <- 0L) expect_silent(dim(r1) <- 1L) expect_silent(dim(r00) <- c(0L, 0L)) expect_silent(dim(r01) <- c(0L, 1L)) expect_silent(dim(r10) <- c(1L, 0L)) expect_silent(dim(r11) <- c(1L, 1L)) expect_silent(dim(r09) <- c(0L, 9L)) expect_silent(dim(r19) <- c(1L, 9L)) expect_silent(dim(r90) <- c(9L, 0L)) expect_silent(dim(r91) <- c(9L, 1L)) expect_silent(dim(r99) <- c(9L, 9L)) expect_silent(d <- NULL) expect_silent(d0 <- list(character())) expect_silent(d1 <- list(LETTERS[1])) expect_silent(d00 <- list(character(), character())) expect_silent(d01 <- list(character(), letters[1])) expect_silent(d10 <- list(LETTERS[1], character())) expect_silent(d11 <- list(LETTERS[1], letters[1])) expect_silent(d09 <- list(character(), letters[1:9])) expect_silent(d19 <- list(LETTERS[1], letters[1:9])) expect_silent(d90 <- list(LETTERS[1:9], character())) expect_silent(d91 <- list(LETTERS[1:9], letters[1])) expect_silent(d99 <- list(LETTERS[1:9], letters[1:9])) expect_silent(dimnames(r) <- d) expect_silent(dimnames(r0) <- d0) expect_silent(dimnames(r1) <- d1) expect_silent(dimnames(r00) <- d00) expect_silent(dimnames(r01) <- d01) expect_silent(dimnames(r10) <- d10) expect_silent(dimnames(r11) <- d11) expect_silent(dimnames(r09) <- d09) expect_silent(dimnames(r19) <- d19) expect_silent(dimnames(r90) <- d90) expect_silent(dimnames(r91) <- d91) expect_silent(dimnames(r99) <- d99) expect_silent(a <- as.ff(r)) expect_silent(a0 <- as.ff(r0)) expect_silent(a1 <- as.ff(r1)) expect_silent(a00 <- as.ff(r00)) expect_silent(a01 <- as.ff(r01)) expect_silent(a10 <- as.ff(r10)) expect_silent(a11 <- as.ff(r11)) expect_silent(a09 <- as.ff(r09)) expect_silent(a19 <- as.ff(r19)) expect_silent(a90 <- as.ff(r90)) expect_silent(a91 <- as.ff(r91)) expect_silent(a99 <- as.ff(r99)) expect_equal(a[], r[]) expect_equal(a0[], r0[]) expect_equal(a1[], r1[]) expect_equal(a00[], r00[]) expect_equal(a01[], r01[]) expect_equal(a10[], r10[]) expect_equal(a11[], r11[]) expect_equal(a09[], r09[]) expect_equal(a19[], r19[]) expect_equal(a90[], r90[]) expect_equal(a91[], r91[]) expect_equal(a99[], r99[]) expect_silent(c <- clone(a)) expect_silent(c0 <- clone(a0)) expect_silent(c1 <- clone(a1)) expect_silent(c00 <- clone(a00)) expect_silent(c01 <- clone(a01)) expect_silent(c10 <- clone(a10)) expect_silent(c11 <- clone(a11)) expect_silent(c09 <- clone(a09)) expect_silent(c19 <- clone(a19)) expect_silent(c90 <- clone(a90)) expect_silent(c91 <- clone(a91)) expect_silent(c99 <- clone(a99)) expect_equal(a[], c[]) expect_equal(a0[], c0[]) expect_equal(a1[], c1[]) expect_equal(a00[], c00[]) expect_equal(a01[], c01[]) expect_equal(a10[], c10[]) expect_equal(a11[], c11[]) expect_equal(a09[], c09[]) expect_equal(a19[], c19[]) expect_equal(a90[], c90[]) expect_equal(a91[], c91[]) expect_equal(a99[], c99[]) expect_error(f <- ff(0, vmode = vm, dim = integer()), "'dims' cannot be of length 0") expect_silent(f <- ff(0, vmode = vm)) expect_silent(f0 <- ff(0, vmode = vm, dim = 0L)) expect_silent(f1 <- ff(0, vmode = vm, dim = 1L)) expect_silent(f00 <- ff(0, vmode = vm, dim = c(0L, 0L))) expect_silent(f01 <- ff(0, vmode = vm, dim = c(0L, 1L))) expect_silent(f10 <- ff(0, vmode = vm, dim = c(1L, 0L))) expect_silent(f11 <- ff(0, vmode = vm, dim = c(1L, 1L))) expect_silent(f09 <- ff(0, vmode = vm, dim = c(0L, 9L))) expect_silent(f19 <- ff(0, vmode = vm, dim = c(1L, 9L))) expect_silent(f90 <- ff(0, vmode = vm, dim = c(9L, 0L))) expect_silent(f91 <- ff(0, vmode = vm, dim = c(9L, 1L))) expect_silent(f99 <- ff(0, vmode = vm, dim = c(9L, 9L))) expect_silent(dimnames(f) <- d) expect_silent(dimnames(f0) <- d0) expect_silent(dimnames(f1) <- d1) expect_silent(dimnames(f00) <- d00) expect_silent(dimnames(f01) <- d01) expect_silent(dimnames(f10) <- d10) expect_silent(dimnames(f11) <- d11) expect_silent(dimnames(f09) <- d09) expect_silent(dimnames(f19) <- d19) expect_silent(dimnames(f90) <- d90) expect_silent(dimnames(f91) <- d91) expect_silent(dimnames(f99) <- d99) expect_equal(dimnames(r), dimnames(f)) expect_equal(dimnames(r1), dimnames(f1)) expect_equal(dimnames(r11), dimnames(f11)) expect_equal(dimnames(r19), dimnames(f19)) expect_equal(dimnames(r91), dimnames(f91)) expect_equal(dimnames(r99), dimnames(f99)) expect_equal(a0[], f0[]) expect_equal(a1[], f1[]) expect_equal(a00[], f00[]) expect_equal(a01[], f01[]) expect_equal(a10[], f10[]) expect_equal(a11[], f11[]) expect_equal(a09[], f09[]) expect_equal(a19[], f19[]) expect_equal(a90[], f90[]) expect_equal(a91[], f91[]) expect_equal(a99[], f99[]) for (frc in list(f00, f01, f10, f11, f09, f19, f90, f91, f99)) { d <- dim(frc) i <- seq_len(d[[1]]) j <- seq_len(d[[2]]) k <- seq_len(prod(d)) ftmp <- clone(frc) rtmp <- ftmp[] rtmp[] <- rtmp[] + 1L ftmp[] <- rtmp[] expect_equal(ftmp[], rtmp[]) rtmp[, ] <- rtmp[, ] + 1L ftmp[, ] <- rtmp[, ] expect_equal(ftmp[], rtmp[]) rtmp[k] <- rtmp[k] + 1L ftmp[k] <- rtmp[k] expect_equal(ftmp[], rtmp[]) rtmp[i, ] <- rtmp[i, ] - 1L ftmp[i, ] <- rtmp[i, ] expect_equal(ftmp[], rtmp[]) rtmp[, j] <- rtmp[, j] - 1L ftmp[, j] <- rtmp[, j] expect_equal(ftmp[], rtmp[]) rtmp[i, j] <- rtmp[i, j] - 1L ftmp[i, j] <- rtmp[i, j] expect_equal(ftmp[], rtmp[]) close(ftmp) delete(ftmp) } for (frc in list(f00, f01, f10, f11, f09, f19, f90, f91, f99)) { d <- dim(frc) i <- seq_len(d[[1]]) j <- seq_len(d[[2]]) k <- seq_len(prod(d)) ftmp <- clone(frc) rtmp <- ftmp[] expect_equal(swap(ftmp, 1L), { ret <- swap(rtmp, 1L) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) expect_equal(swap(ftmp, 1L, , ), { ret <- swap(rtmp, 1L, , ) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) expect_equal(swap(ftmp, 1L, k), { ret <- swap(rtmp, 1L, k) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) expect_equal(swap(ftmp, 1L, i, ), { ret <- swap(rtmp, 1L, i, ) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) expect_equal(swap(ftmp, 1L, , j), { ret <- swap(rtmp, 1L, , j) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) expect_equal(swap(ftmp, 1L, i, j), { ret <- swap(rtmp, 1L, i, j) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) close(ftmp) delete(ftmp) } for (frc in list(f00, f01, f10, f11, f09, f19, f90, f91, f99)) { d <- dim(frc) i <- seq_len(d[[1]]) j <- seq_len(d[[2]]) k <- seq_len(prod(d)) ftmp <- clone(frc) rtmp <- ftmp[] expect_silent(rtmp[] <- 1L) expect_silent(ftmp[] <- 1L) expect_equal(ftmp[], rtmp[]) expect_silent(rtmp[, ] <- 2L) expect_silent(ftmp[, ] <- 2L) expect_equal(ftmp[], rtmp[]) expect_silent(rtmp[k] <- 3L) expect_silent(ftmp[k] <- 3L) expect_equal(ftmp[], rtmp[]) expect_silent(rtmp[i, ] <- 0L) expect_silent(ftmp[i, ] <- 0L) expect_equal(ftmp[], rtmp[]) expect_silent(rtmp[, j] <- 1L) expect_silent(ftmp[, j] <- 1L) expect_equal(ftmp[], rtmp[]) expect_silent(rtmp[i, j] <- 2L) expect_silent(ftmp[i, j] <- 2L) expect_equal(ftmp[], rtmp[]) close(ftmp) delete(ftmp) } dims <- list(f00, f01, f10, f11, f09, f19, f90, f91, f99) nams <- sapply(dims, function(x) paste(dim(x), sep = "", collapse = "")) dres <- array(list(NULL), dim = c(length(nams), length(nams)), dimnames = list(obj = nams, dim = nams)) fres <- array(list(NULL), dim = c(length(nams), length(nams)), dimnames = list(obj = nams, dim = nams)) for (frc in dims) { for (drc in dims) { dtmp <- dim(drc) dnam <- paste(dim(drc), sep = "", collapse = "") fnam <- paste(dim(frc), sep = "", collapse = "") ftmp <- clone(frc) rtmp <- ftmp[] etmp <- try(dim(rtmp) <- dtmp, silent = TRUE) if (inherits(etmp, "try-error")) { dres[[fnam, dnam]] <- as.character(etmp) } etmp <- try(dim(ftmp) <- dtmp, silent = TRUE) if (inherits(etmp, "try-error")) { fres[[fnam, dnam]] <- as.character(etmp) } close(ftmp) delete(ftmp) } } dok <- apply(dres, 1:2, function(x) { is.null(x[[1]]) }) fok <- apply(fres, 1:2, function(x) { is.null(x[[1]]) }) expect_equal(dok, structure(c(TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE), .Dim = c(9L, 9L), .Dimnames = list(obj = c("00", "01", "10", "11", "09", "19", "90", "91", "99"), dim = c("00", "01", "10", "11", "09", "19", "90", "91", "99")))) expect_equal(fok, structure(c(TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE), .Dim = c(9L, 9L), .Dimnames = list(obj = c("00", "01", "10", "11", "09", "19", "90", "91", "99"), dim = c("00", "01", "10", "11", "09", "19", "90", "91", "99")))) rm(rtmp, ftmp, dtmp, etmp, dnam, fnam, dims, nams, dres, fres, dok, fok) gc() rm(i, j, k, vm, ret) rm(frc, drc) rm(d, d0, d1, d00, d01, d10, d11, d09, d19, d90, d91, d99) rm(r, r0, r1, r00, r01, r10, r11, r09, r19, r90, r91, r99) rm(a, a0, a1, a00, a01, a10, a11, a09, a19, a90, a91, a99) rm(c, c0, c1, c00, c01, c10, c11, c09, c19, c90, c91, c99) rm(f, f0, f1, f00, f01, f10, f11, f09, f19, f90, f91, f99)}) 29: eval(code, test_env) 30: eval(code, test_env) 31: withCallingHandlers({ eval(code, test_env) if (!handled && !is.null(test)) { skip_empty() }}, expectation = handle_expectation, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error) 32: doTryCatch(return(expr), name, parentenv, handler) 33: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 34: tryCatchList(expr, names[-nh], parentenv, handlers[-nh]) 35: doTryCatch(return(expr), name, parentenv, handler) 36: tryCatchOne(tryCatchList(expr, names[-nh], parentenv, handlers[-nh]), names[nh], parentenv, handlers[[nh]]) 37: tryCatchList(expr, classes, parentenv, handlers) 38: tryCatch(withCallingHandlers({ eval(code, test_env) if (!handled && !is.null(test)) { skip_empty() }}, expectation = handle_expectation, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error), error = handle_fatal, skip = function(e) { }) 39: test_code(test = NULL, code = exprs, env = env, reporter = get_reporter() %||% StopReporter$new()) 40: source_file(path, env = env(env), desc = desc, error_call = error_call) 41: FUN(X[[i]], ...) 42: lapply(test_paths, test_one_file, env = env, desc = desc, error_call = error_call) 43: doTryCatch(return(expr), name, parentenv, handler) 44: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 45: tryCatchList(expr, classes, parentenv, handlers) 46: tryCatch(code, testthat_abort_reporter = function(cnd) { cat(conditionMessage(cnd), "\n") NULL}) 47: with_reporter(reporters$multi, lapply(test_paths, test_one_file, env = env, desc = desc, error_call = error_call)) 48: test_files_serial(test_dir = test_dir, test_package = test_package, test_paths = test_paths, load_helpers = load_helpers, reporter = reporter, env = env, stop_on_failure = stop_on_failure, stop_on_warning = stop_on_warning, desc = desc, load_package = load_package, error_call = error_call) 49: test_files(test_dir = path, test_paths = test_paths, test_package = package, reporter = reporter, load_helpers = load_helpers, env = env, stop_on_failure = stop_on_failure, stop_on_warning = stop_on_warning, load_package = load_package, parallel = parallel) 50: test_dir("testthat", package = package, reporter = reporter, ..., load_package = "installed") 51: test_check("ff") An irrecoverable exception occurred. R is aborting now ... Segmentation fault Flavor: r-devel-linux-x86_64-debian-gcc

Version: 4.5.0
Check: tests
Result: ERROR Running ‘testthat.R’ [8s/15s] Running the tests in ‘tests/testthat.R’ failed. Complete output: > library(testthat) > test_check("ff") Loading required package: ff Loading required package: bit Attaching package: 'bit' The following object is masked from 'package:base': xor Attaching package ff - getOption("fftempdir")=="/tmp/RtmpZdEIHF/working_dir/Rtmp5gFmVN/ff" - getOption("ffextension")=="ff" - getOption("ffdrop")==TRUE - getOption("fffinonexit")==TRUE - getOption("ffpagesize")==65536 - getOption("ffcaching")=="mmnoflush" -- consider "ffeachflush" if your system stalls on large writes - getOption("ffbatchbytes")==16777216 -- consider a different value for tuning your system - getOption("ffmaxbytes")==536870912 -- consider a different value for tuning your system Attaching package: 'ff' The following objects are masked from 'package:utils': write.csv, write.csv2 The following objects are masked from 'package:base': is.factor, is.ordered *** caught segfault *** address 0x1, cause 'memory not mapped' Traceback: 1: `[<-.ff_array`(`*tmp*`, , value = c(0L, 0L, 0L, 0L, 0L, 0L, 0L, 0L, 0L)) 2: `[<-`(`*tmp*`, , value = c(0L, 0L, 0L, 0L, 0L, 0L, 0L, 0L, 0L)) 3: update.ff(ret, from = initdata, delete = FALSE, bydim = bydim, BATCHSIZE = BATCHSIZE, BATCHBYTES = BATCHBYTES, VERBOSE = VERBOSE) 4: ff(initdata = initdata, length = length, levels = levels, ordered = ordered, dim = dim, dimorder = dimorder, bydim = bydim, symmetric = symmetric, fixdiag = fixdiag, names = names, dimnames = dimnames, ramclass = ramclass, ramattribs = ramattribs, vmode = vmode, update = update, pattern = pattern, filename = filename, readonly = FALSE, overwrite = overwrite, pagesize = pagesize, caching = caching, finalizer = finalizer, finonexit = finonexit, FF_RETURN = FF_RETURN, BATCHSIZE = BATCHSIZE, BATCHBYTES = BATCHBYTES, VERBOSE = VERBOSE) 5: assign("ret", ff(initdata = initdata, length = length, levels = levels, ordered = ordered, dim = dim, dimorder = dimorder, bydim = bydim, symmetric = symmetric, fixdiag = fixdiag, names = names, dimnames = dimnames, ramclass = ramclass, ramattribs = ramattribs, vmode = vmode, update = update, pattern = pattern, filename = filename, readonly = FALSE, overwrite = overwrite, pagesize = pagesize, caching = caching, finalizer = finalizer, finonexit = finonexit, FF_RETURN = FF_RETURN, BATCHSIZE = BATCHSIZE, BATCHBYTES = BATCHBYTES, VERBOSE = VERBOSE)) 6: clone.ff(x, FF_RETURN = TRUE, filename = filename(x), overwrite = overwrite) 7: as.ff.default(r19) 8: as.ff(r19) 9: eval_bare(quo_get_expr(.quo), quo_get_env(.quo)) 10: withVisible(code) 11: withCallingHandlers(withVisible(code), warning = handle_warning, message = handle_message) 12: force(code) 13: withr::with_output_sink(path, withCallingHandlers(withVisible(code), warning = handle_warning, message = handle_message)) 14: .capture(act$val <- eval_bare(quo_get_expr(.quo), quo_get_env(.quo)), ...) 15: quasi_capture(enquo(object), NULL, evaluate_promise) 16: expect_silent(a19 <- as.ff(r19)) 17: eval(code, test_env) 18: eval(code, test_env) 19: withCallingHandlers({ eval(code, test_env) if (!handled && !is.null(test)) { skip_empty() }}, expectation = handle_expectation, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error) 20: doTryCatch(return(expr), name, parentenv, handler) 21: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 22: tryCatchList(expr, names[-nh], parentenv, handlers[-nh]) 23: doTryCatch(return(expr), name, parentenv, handler) 24: tryCatchOne(tryCatchList(expr, names[-nh], parentenv, handlers[-nh]), names[nh], parentenv, handlers[[nh]]) 25: tryCatchList(expr, classes, parentenv, handlers) 26: tryCatch(withCallingHandlers({ eval(code, test_env) if (!handled && !is.null(test)) { skip_empty() }}, expectation = handle_expectation, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error), error = handle_fatal, skip = function(e) { }) 27: test_code(desc, code, env = parent.frame(), reporter = reporter) 28: test_that("lots of stuff related to dims work", { vm <- "quad" expect_silent(r <- as.vmode(integer(), vmode = vm)) expect_silent(r0 <- as.vmode(integer(0), vmode = vm)) expect_silent(r1 <- as.vmode(integer(1), vmode = vm)) expect_silent(r00 <- as.vmode(integer(0), vmode = vm)) expect_silent(r01 <- as.vmode(integer(0), vmode = vm)) expect_silent(r10 <- as.vmode(integer(0), vmode = vm)) expect_silent(r11 <- as.vmode(integer(1), vmode = vm)) expect_silent(r09 <- as.vmode(integer(0), vmode = vm)) expect_silent(r19 <- as.vmode(integer(9), vmode = vm)) expect_silent(r90 <- as.vmode(integer(0), vmode = vm)) expect_silent(r91 <- as.vmode(integer(9), vmode = vm)) expect_silent(r99 <- as.vmode(integer(81), vmode = vm)) expect_error(dim(r) <- integer()) expect_silent(dim(r) <- NULL) expect_silent(dim(r0) <- 0L) expect_silent(dim(r1) <- 1L) expect_silent(dim(r00) <- c(0L, 0L)) expect_silent(dim(r01) <- c(0L, 1L)) expect_silent(dim(r10) <- c(1L, 0L)) expect_silent(dim(r11) <- c(1L, 1L)) expect_silent(dim(r09) <- c(0L, 9L)) expect_silent(dim(r19) <- c(1L, 9L)) expect_silent(dim(r90) <- c(9L, 0L)) expect_silent(dim(r91) <- c(9L, 1L)) expect_silent(dim(r99) <- c(9L, 9L)) expect_silent(d <- NULL) expect_silent(d0 <- list(character())) expect_silent(d1 <- list(LETTERS[1])) expect_silent(d00 <- list(character(), character())) expect_silent(d01 <- list(character(), letters[1])) expect_silent(d10 <- list(LETTERS[1], character())) expect_silent(d11 <- list(LETTERS[1], letters[1])) expect_silent(d09 <- list(character(), letters[1:9])) expect_silent(d19 <- list(LETTERS[1], letters[1:9])) expect_silent(d90 <- list(LETTERS[1:9], character())) expect_silent(d91 <- list(LETTERS[1:9], letters[1])) expect_silent(d99 <- list(LETTERS[1:9], letters[1:9])) expect_silent(dimnames(r) <- d) expect_silent(dimnames(r0) <- d0) expect_silent(dimnames(r1) <- d1) expect_silent(dimnames(r00) <- d00) expect_silent(dimnames(r01) <- d01) expect_silent(dimnames(r10) <- d10) expect_silent(dimnames(r11) <- d11) expect_silent(dimnames(r09) <- d09) expect_silent(dimnames(r19) <- d19) expect_silent(dimnames(r90) <- d90) expect_silent(dimnames(r91) <- d91) expect_silent(dimnames(r99) <- d99) expect_silent(a <- as.ff(r)) expect_silent(a0 <- as.ff(r0)) expect_silent(a1 <- as.ff(r1)) expect_silent(a00 <- as.ff(r00)) expect_silent(a01 <- as.ff(r01)) expect_silent(a10 <- as.ff(r10)) expect_silent(a11 <- as.ff(r11)) expect_silent(a09 <- as.ff(r09)) expect_silent(a19 <- as.ff(r19)) expect_silent(a90 <- as.ff(r90)) expect_silent(a91 <- as.ff(r91)) expect_silent(a99 <- as.ff(r99)) expect_equal(a[], r[]) expect_equal(a0[], r0[]) expect_equal(a1[], r1[]) expect_equal(a00[], r00[]) expect_equal(a01[], r01[]) expect_equal(a10[], r10[]) expect_equal(a11[], r11[]) expect_equal(a09[], r09[]) expect_equal(a19[], r19[]) expect_equal(a90[], r90[]) expect_equal(a91[], r91[]) expect_equal(a99[], r99[]) expect_silent(c <- clone(a)) expect_silent(c0 <- clone(a0)) expect_silent(c1 <- clone(a1)) expect_silent(c00 <- clone(a00)) expect_silent(c01 <- clone(a01)) expect_silent(c10 <- clone(a10)) expect_silent(c11 <- clone(a11)) expect_silent(c09 <- clone(a09)) expect_silent(c19 <- clone(a19)) expect_silent(c90 <- clone(a90)) expect_silent(c91 <- clone(a91)) expect_silent(c99 <- clone(a99)) expect_equal(a[], c[]) expect_equal(a0[], c0[]) expect_equal(a1[], c1[]) expect_equal(a00[], c00[]) expect_equal(a01[], c01[]) expect_equal(a10[], c10[]) expect_equal(a11[], c11[]) expect_equal(a09[], c09[]) expect_equal(a19[], c19[]) expect_equal(a90[], c90[]) expect_equal(a91[], c91[]) expect_equal(a99[], c99[]) expect_error(f <- ff(0, vmode = vm, dim = integer()), "'dims' cannot be of length 0") expect_silent(f <- ff(0, vmode = vm)) expect_silent(f0 <- ff(0, vmode = vm, dim = 0L)) expect_silent(f1 <- ff(0, vmode = vm, dim = 1L)) expect_silent(f00 <- ff(0, vmode = vm, dim = c(0L, 0L))) expect_silent(f01 <- ff(0, vmode = vm, dim = c(0L, 1L))) expect_silent(f10 <- ff(0, vmode = vm, dim = c(1L, 0L))) expect_silent(f11 <- ff(0, vmode = vm, dim = c(1L, 1L))) expect_silent(f09 <- ff(0, vmode = vm, dim = c(0L, 9L))) expect_silent(f19 <- ff(0, vmode = vm, dim = c(1L, 9L))) expect_silent(f90 <- ff(0, vmode = vm, dim = c(9L, 0L))) expect_silent(f91 <- ff(0, vmode = vm, dim = c(9L, 1L))) expect_silent(f99 <- ff(0, vmode = vm, dim = c(9L, 9L))) expect_silent(dimnames(f) <- d) expect_silent(dimnames(f0) <- d0) expect_silent(dimnames(f1) <- d1) expect_silent(dimnames(f00) <- d00) expect_silent(dimnames(f01) <- d01) expect_silent(dimnames(f10) <- d10) expect_silent(dimnames(f11) <- d11) expect_silent(dimnames(f09) <- d09) expect_silent(dimnames(f19) <- d19) expect_silent(dimnames(f90) <- d90) expect_silent(dimnames(f91) <- d91) expect_silent(dimnames(f99) <- d99) expect_equal(dimnames(r), dimnames(f)) expect_equal(dimnames(r1), dimnames(f1)) expect_equal(dimnames(r11), dimnames(f11)) expect_equal(dimnames(r19), dimnames(f19)) expect_equal(dimnames(r91), dimnames(f91)) expect_equal(dimnames(r99), dimnames(f99)) expect_equal(a0[], f0[]) expect_equal(a1[], f1[]) expect_equal(a00[], f00[]) expect_equal(a01[], f01[]) expect_equal(a10[], f10[]) expect_equal(a11[], f11[]) expect_equal(a09[], f09[]) expect_equal(a19[], f19[]) expect_equal(a90[], f90[]) expect_equal(a91[], f91[]) expect_equal(a99[], f99[]) for (frc in list(f00, f01, f10, f11, f09, f19, f90, f91, f99)) { d <- dim(frc) i <- seq_len(d[[1]]) j <- seq_len(d[[2]]) k <- seq_len(prod(d)) ftmp <- clone(frc) rtmp <- ftmp[] rtmp[] <- rtmp[] + 1L ftmp[] <- rtmp[] expect_equal(ftmp[], rtmp[]) rtmp[, ] <- rtmp[, ] + 1L ftmp[, ] <- rtmp[, ] expect_equal(ftmp[], rtmp[]) rtmp[k] <- rtmp[k] + 1L ftmp[k] <- rtmp[k] expect_equal(ftmp[], rtmp[]) rtmp[i, ] <- rtmp[i, ] - 1L ftmp[i, ] <- rtmp[i, ] expect_equal(ftmp[], rtmp[]) rtmp[, j] <- rtmp[, j] - 1L ftmp[, j] <- rtmp[, j] expect_equal(ftmp[], rtmp[]) rtmp[i, j] <- rtmp[i, j] - 1L ftmp[i, j] <- rtmp[i, j] expect_equal(ftmp[], rtmp[]) close(ftmp) delete(ftmp) } for (frc in list(f00, f01, f10, f11, f09, f19, f90, f91, f99)) { d <- dim(frc) i <- seq_len(d[[1]]) j <- seq_len(d[[2]]) k <- seq_len(prod(d)) ftmp <- clone(frc) rtmp <- ftmp[] expect_equal(swap(ftmp, 1L), { ret <- swap(rtmp, 1L) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) expect_equal(swap(ftmp, 1L, , ), { ret <- swap(rtmp, 1L, , ) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) expect_equal(swap(ftmp, 1L, k), { ret <- swap(rtmp, 1L, k) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) expect_equal(swap(ftmp, 1L, i, ), { ret <- swap(rtmp, 1L, i, ) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) expect_equal(swap(ftmp, 1L, , j), { ret <- swap(rtmp, 1L, , j) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) expect_equal(swap(ftmp, 1L, i, j), { ret <- swap(rtmp, 1L, i, j) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) close(ftmp) delete(ftmp) } for (frc in list(f00, f01, f10, f11, f09, f19, f90, f91, f99)) { d <- dim(frc) i <- seq_len(d[[1]]) j <- seq_len(d[[2]]) k <- seq_len(prod(d)) ftmp <- clone(frc) rtmp <- ftmp[] expect_silent(rtmp[] <- 1L) expect_silent(ftmp[] <- 1L) expect_equal(ftmp[], rtmp[]) expect_silent(rtmp[, ] <- 2L) expect_silent(ftmp[, ] <- 2L) expect_equal(ftmp[], rtmp[]) expect_silent(rtmp[k] <- 3L) expect_silent(ftmp[k] <- 3L) expect_equal(ftmp[], rtmp[]) expect_silent(rtmp[i, ] <- 0L) expect_silent(ftmp[i, ] <- 0L) expect_equal(ftmp[], rtmp[]) expect_silent(rtmp[, j] <- 1L) expect_silent(ftmp[, j] <- 1L) expect_equal(ftmp[], rtmp[]) expect_silent(rtmp[i, j] <- 2L) expect_silent(ftmp[i, j] <- 2L) expect_equal(ftmp[], rtmp[]) close(ftmp) delete(ftmp) } dims <- list(f00, f01, f10, f11, f09, f19, f90, f91, f99) nams <- sapply(dims, function(x) paste(dim(x), sep = "", collapse = "")) dres <- array(list(NULL), dim = c(length(nams), length(nams)), dimnames = list(obj = nams, dim = nams)) fres <- array(list(NULL), dim = c(length(nams), length(nams)), dimnames = list(obj = nams, dim = nams)) for (frc in dims) { for (drc in dims) { dtmp <- dim(drc) dnam <- paste(dim(drc), sep = "", collapse = "") fnam <- paste(dim(frc), sep = "", collapse = "") ftmp <- clone(frc) rtmp <- ftmp[] etmp <- try(dim(rtmp) <- dtmp, silent = TRUE) if (inherits(etmp, "try-error")) { dres[[fnam, dnam]] <- as.character(etmp) } etmp <- try(dim(ftmp) <- dtmp, silent = TRUE) if (inherits(etmp, "try-error")) { fres[[fnam, dnam]] <- as.character(etmp) } close(ftmp) delete(ftmp) } } dok <- apply(dres, 1:2, function(x) { is.null(x[[1]]) }) fok <- apply(fres, 1:2, function(x) { is.null(x[[1]]) }) expect_equal(dok, structure(c(TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE), .Dim = c(9L, 9L), .Dimnames = list(obj = c("00", "01", "10", "11", "09", "19", "90", "91", "99"), dim = c("00", "01", "10", "11", "09", "19", "90", "91", "99")))) expect_equal(fok, structure(c(TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE), .Dim = c(9L, 9L), .Dimnames = list(obj = c("00", "01", "10", "11", "09", "19", "90", "91", "99"), dim = c("00", "01", "10", "11", "09", "19", "90", "91", "99")))) rm(rtmp, ftmp, dtmp, etmp, dnam, fnam, dims, nams, dres, fres, dok, fok) gc() rm(i, j, k, vm, ret) rm(frc, drc) rm(d, d0, d1, d00, d01, d10, d11, d09, d19, d90, d91, d99) rm(r, r0, r1, r00, r01, r10, r11, r09, r19, r90, r91, r99) rm(a, a0, a1, a00, a01, a10, a11, a09, a19, a90, a91, a99) rm(c, c0, c1, c00, c01, c10, c11, c09, c19, c90, c91, c99) rm(f, f0, f1, f00, f01, f10, f11, f09, f19, f90, f91, f99)}) 29: eval(code, test_env) 30: eval(code, test_env) 31: withCallingHandlers({ eval(code, test_env) if (!handled && !is.null(test)) { skip_empty() }}, expectation = handle_expectation, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error) 32: doTryCatch(return(expr), name, parentenv, handler) 33: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 34: tryCatchList(expr, names[-nh], parentenv, handlers[-nh]) 35: doTryCatch(return(expr), name, parentenv, handler) 36: tryCatchOne(tryCatchList(expr, names[-nh], parentenv, handlers[-nh]), names[nh], parentenv, handlers[[nh]]) 37: tryCatchList(expr, classes, parentenv, handlers) 38: tryCatch(withCallingHandlers({ eval(code, test_env) if (!handled && !is.null(test)) { skip_empty() }}, expectation = handle_expectation, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error), error = handle_fatal, skip = function(e) { }) 39: test_code(test = NULL, code = exprs, env = env, reporter = get_reporter() %||% StopReporter$new()) 40: source_file(path, env = env(env), desc = desc, error_call = error_call) 41: FUN(X[[i]], ...) 42: lapply(test_paths, test_one_file, env = env, desc = desc, error_call = error_call) 43: doTryCatch(return(expr), name, parentenv, handler) 44: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 45: tryCatchList(expr, classes, parentenv, handlers) 46: tryCatch(code, testthat_abort_reporter = function(cnd) { cat(conditionMessage(cnd), "\n") NULL}) 47: with_reporter(reporters$multi, lapply(test_paths, test_one_file, env = env, desc = desc, error_call = error_call)) 48: test_files_serial(test_dir = test_dir, test_package = test_package, test_paths = test_paths, load_helpers = load_helpers, reporter = reporter, env = env, stop_on_failure = stop_on_failure, stop_on_warning = stop_on_warning, desc = desc, load_package = load_package, error_call = error_call) 49: test_files(test_dir = path, test_paths = test_paths, test_package = package, reporter = reporter, load_helpers = load_helpers, env = env, stop_on_failure = stop_on_failure, stop_on_warning = stop_on_warning, load_package = load_package, parallel = parallel) 50: test_dir("testthat", package = package, reporter = reporter, ..., load_package = "installed") 51: test_check("ff") An irrecoverable exception occurred. R is aborting now ... Flavor: r-devel-linux-x86_64-fedora-clang

Version: 4.5.0
Check: tests
Result: ERROR Running ‘testthat.R’ [9s/22s] Running the tests in ‘tests/testthat.R’ failed. Complete output: > library(testthat) > test_check("ff") Loading required package: ff Loading required package: bit Attaching package: 'bit' The following object is masked from 'package:base': xor Attaching package ff - getOption("fftempdir")=="/tmp/RtmpHGgfMc/working_dir/RtmptwRVcR/ff" - getOption("ffextension")=="ff" - getOption("ffdrop")==TRUE - getOption("fffinonexit")==TRUE - getOption("ffpagesize")==65536 - getOption("ffcaching")=="mmnoflush" -- consider "ffeachflush" if your system stalls on large writes - getOption("ffbatchbytes")==16777216 -- consider a different value for tuning your system - getOption("ffmaxbytes")==536870912 -- consider a different value for tuning your system Attaching package: 'ff' The following objects are masked from 'package:utils': write.csv, write.csv2 The following objects are masked from 'package:base': is.factor, is.ordered *** caught segfault *** address 0x1, cause 'memory not mapped' Traceback: 1: `[<-.ff_array`(`*tmp*`, , value = c(0L, 0L, 0L, 0L, 0L, 0L, 0L, 0L, 0L)) 2: `[<-`(`*tmp*`, , value = c(0L, 0L, 0L, 0L, 0L, 0L, 0L, 0L, 0L)) 3: update.ff(ret, from = initdata, delete = FALSE, bydim = bydim, BATCHSIZE = BATCHSIZE, BATCHBYTES = BATCHBYTES, VERBOSE = VERBOSE) 4: ff(initdata = initdata, length = length, levels = levels, ordered = ordered, dim = dim, dimorder = dimorder, bydim = bydim, symmetric = symmetric, fixdiag = fixdiag, names = names, dimnames = dimnames, ramclass = ramclass, ramattribs = ramattribs, vmode = vmode, update = update, pattern = pattern, filename = filename, readonly = FALSE, overwrite = overwrite, pagesize = pagesize, caching = caching, finalizer = finalizer, finonexit = finonexit, FF_RETURN = FF_RETURN, BATCHSIZE = BATCHSIZE, BATCHBYTES = BATCHBYTES, VERBOSE = VERBOSE) 5: assign("ret", ff(initdata = initdata, length = length, levels = levels, ordered = ordered, dim = dim, dimorder = dimorder, bydim = bydim, symmetric = symmetric, fixdiag = fixdiag, names = names, dimnames = dimnames, ramclass = ramclass, ramattribs = ramattribs, vmode = vmode, update = update, pattern = pattern, filename = filename, readonly = FALSE, overwrite = overwrite, pagesize = pagesize, caching = caching, finalizer = finalizer, finonexit = finonexit, FF_RETURN = FF_RETURN, BATCHSIZE = BATCHSIZE, BATCHBYTES = BATCHBYTES, VERBOSE = VERBOSE)) 6: clone.ff(x, FF_RETURN = TRUE, filename = filename(x), overwrite = overwrite) 7: as.ff.default(r19) 8: as.ff(r19) 9: eval_bare(quo_get_expr(.quo), quo_get_env(.quo)) 10: withVisible(code) 11: withCallingHandlers(withVisible(code), warning = handle_warning, message = handle_message) 12: force(code) 13: withr::with_output_sink(path, withCallingHandlers(withVisible(code), warning = handle_warning, message = handle_message)) 14: .capture(act$val <- eval_bare(quo_get_expr(.quo), quo_get_env(.quo)), ...) 15: quasi_capture(enquo(object), NULL, evaluate_promise) 16: expect_silent(a19 <- as.ff(r19)) 17: eval(code, test_env) 18: eval(code, test_env) 19: withCallingHandlers({ eval(code, test_env) if (!handled && !is.null(test)) { skip_empty() }}, expectation = handle_expectation, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error) 20: doTryCatch(return(expr), name, parentenv, handler) 21: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 22: tryCatchList(expr, names[-nh], parentenv, handlers[-nh]) 23: doTryCatch(return(expr), name, parentenv, handler) 24: tryCatchOne(tryCatchList(expr, names[-nh], parentenv, handlers[-nh]), names[nh], parentenv, handlers[[nh]]) 25: tryCatchList(expr, classes, parentenv, handlers) 26: tryCatch(withCallingHandlers({ eval(code, test_env) if (!handled && !is.null(test)) { skip_empty() }}, expectation = handle_expectation, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error), error = handle_fatal, skip = function(e) { }) 27: test_code(desc, code, env = parent.frame(), reporter = reporter) 28: test_that("lots of stuff related to dims work", { vm <- "quad" expect_silent(r <- as.vmode(integer(), vmode = vm)) expect_silent(r0 <- as.vmode(integer(0), vmode = vm)) expect_silent(r1 <- as.vmode(integer(1), vmode = vm)) expect_silent(r00 <- as.vmode(integer(0), vmode = vm)) expect_silent(r01 <- as.vmode(integer(0), vmode = vm)) expect_silent(r10 <- as.vmode(integer(0), vmode = vm)) expect_silent(r11 <- as.vmode(integer(1), vmode = vm)) expect_silent(r09 <- as.vmode(integer(0), vmode = vm)) expect_silent(r19 <- as.vmode(integer(9), vmode = vm)) expect_silent(r90 <- as.vmode(integer(0), vmode = vm)) expect_silent(r91 <- as.vmode(integer(9), vmode = vm)) expect_silent(r99 <- as.vmode(integer(81), vmode = vm)) expect_error(dim(r) <- integer()) expect_silent(dim(r) <- NULL) expect_silent(dim(r0) <- 0L) expect_silent(dim(r1) <- 1L) expect_silent(dim(r00) <- c(0L, 0L)) expect_silent(dim(r01) <- c(0L, 1L)) expect_silent(dim(r10) <- c(1L, 0L)) expect_silent(dim(r11) <- c(1L, 1L)) expect_silent(dim(r09) <- c(0L, 9L)) expect_silent(dim(r19) <- c(1L, 9L)) expect_silent(dim(r90) <- c(9L, 0L)) expect_silent(dim(r91) <- c(9L, 1L)) expect_silent(dim(r99) <- c(9L, 9L)) expect_silent(d <- NULL) expect_silent(d0 <- list(character())) expect_silent(d1 <- list(LETTERS[1])) expect_silent(d00 <- list(character(), character())) expect_silent(d01 <- list(character(), letters[1])) expect_silent(d10 <- list(LETTERS[1], character())) expect_silent(d11 <- list(LETTERS[1], letters[1])) expect_silent(d09 <- list(character(), letters[1:9])) expect_silent(d19 <- list(LETTERS[1], letters[1:9])) expect_silent(d90 <- list(LETTERS[1:9], character())) expect_silent(d91 <- list(LETTERS[1:9], letters[1])) expect_silent(d99 <- list(LETTERS[1:9], letters[1:9])) expect_silent(dimnames(r) <- d) expect_silent(dimnames(r0) <- d0) expect_silent(dimnames(r1) <- d1) expect_silent(dimnames(r00) <- d00) expect_silent(dimnames(r01) <- d01) expect_silent(dimnames(r10) <- d10) expect_silent(dimnames(r11) <- d11) expect_silent(dimnames(r09) <- d09) expect_silent(dimnames(r19) <- d19) expect_silent(dimnames(r90) <- d90) expect_silent(dimnames(r91) <- d91) expect_silent(dimnames(r99) <- d99) expect_silent(a <- as.ff(r)) expect_silent(a0 <- as.ff(r0)) expect_silent(a1 <- as.ff(r1)) expect_silent(a00 <- as.ff(r00)) expect_silent(a01 <- as.ff(r01)) expect_silent(a10 <- as.ff(r10)) expect_silent(a11 <- as.ff(r11)) expect_silent(a09 <- as.ff(r09)) expect_silent(a19 <- as.ff(r19)) expect_silent(a90 <- as.ff(r90)) expect_silent(a91 <- as.ff(r91)) expect_silent(a99 <- as.ff(r99)) expect_equal(a[], r[]) expect_equal(a0[], r0[]) expect_equal(a1[], r1[]) expect_equal(a00[], r00[]) expect_equal(a01[], r01[]) expect_equal(a10[], r10[]) expect_equal(a11[], r11[]) expect_equal(a09[], r09[]) expect_equal(a19[], r19[]) expect_equal(a90[], r90[]) expect_equal(a91[], r91[]) expect_equal(a99[], r99[]) expect_silent(c <- clone(a)) expect_silent(c0 <- clone(a0)) expect_silent(c1 <- clone(a1)) expect_silent(c00 <- clone(a00)) expect_silent(c01 <- clone(a01)) expect_silent(c10 <- clone(a10)) expect_silent(c11 <- clone(a11)) expect_silent(c09 <- clone(a09)) expect_silent(c19 <- clone(a19)) expect_silent(c90 <- clone(a90)) expect_silent(c91 <- clone(a91)) expect_silent(c99 <- clone(a99)) expect_equal(a[], c[]) expect_equal(a0[], c0[]) expect_equal(a1[], c1[]) expect_equal(a00[], c00[]) expect_equal(a01[], c01[]) expect_equal(a10[], c10[]) expect_equal(a11[], c11[]) expect_equal(a09[], c09[]) expect_equal(a19[], c19[]) expect_equal(a90[], c90[]) expect_equal(a91[], c91[]) expect_equal(a99[], c99[]) expect_error(f <- ff(0, vmode = vm, dim = integer()), "'dims' cannot be of length 0") expect_silent(f <- ff(0, vmode = vm)) expect_silent(f0 <- ff(0, vmode = vm, dim = 0L)) expect_silent(f1 <- ff(0, vmode = vm, dim = 1L)) expect_silent(f00 <- ff(0, vmode = vm, dim = c(0L, 0L))) expect_silent(f01 <- ff(0, vmode = vm, dim = c(0L, 1L))) expect_silent(f10 <- ff(0, vmode = vm, dim = c(1L, 0L))) expect_silent(f11 <- ff(0, vmode = vm, dim = c(1L, 1L))) expect_silent(f09 <- ff(0, vmode = vm, dim = c(0L, 9L))) expect_silent(f19 <- ff(0, vmode = vm, dim = c(1L, 9L))) expect_silent(f90 <- ff(0, vmode = vm, dim = c(9L, 0L))) expect_silent(f91 <- ff(0, vmode = vm, dim = c(9L, 1L))) expect_silent(f99 <- ff(0, vmode = vm, dim = c(9L, 9L))) expect_silent(dimnames(f) <- d) expect_silent(dimnames(f0) <- d0) expect_silent(dimnames(f1) <- d1) expect_silent(dimnames(f00) <- d00) expect_silent(dimnames(f01) <- d01) expect_silent(dimnames(f10) <- d10) expect_silent(dimnames(f11) <- d11) expect_silent(dimnames(f09) <- d09) expect_silent(dimnames(f19) <- d19) expect_silent(dimnames(f90) <- d90) expect_silent(dimnames(f91) <- d91) expect_silent(dimnames(f99) <- d99) expect_equal(dimnames(r), dimnames(f)) expect_equal(dimnames(r1), dimnames(f1)) expect_equal(dimnames(r11), dimnames(f11)) expect_equal(dimnames(r19), dimnames(f19)) expect_equal(dimnames(r91), dimnames(f91)) expect_equal(dimnames(r99), dimnames(f99)) expect_equal(a0[], f0[]) expect_equal(a1[], f1[]) expect_equal(a00[], f00[]) expect_equal(a01[], f01[]) expect_equal(a10[], f10[]) expect_equal(a11[], f11[]) expect_equal(a09[], f09[]) expect_equal(a19[], f19[]) expect_equal(a90[], f90[]) expect_equal(a91[], f91[]) expect_equal(a99[], f99[]) for (frc in list(f00, f01, f10, f11, f09, f19, f90, f91, f99)) { d <- dim(frc) i <- seq_len(d[[1]]) j <- seq_len(d[[2]]) k <- seq_len(prod(d)) ftmp <- clone(frc) rtmp <- ftmp[] rtmp[] <- rtmp[] + 1L ftmp[] <- rtmp[] expect_equal(ftmp[], rtmp[]) rtmp[, ] <- rtmp[, ] + 1L ftmp[, ] <- rtmp[, ] expect_equal(ftmp[], rtmp[]) rtmp[k] <- rtmp[k] + 1L ftmp[k] <- rtmp[k] expect_equal(ftmp[], rtmp[]) rtmp[i, ] <- rtmp[i, ] - 1L ftmp[i, ] <- rtmp[i, ] expect_equal(ftmp[], rtmp[]) rtmp[, j] <- rtmp[, j] - 1L ftmp[, j] <- rtmp[, j] expect_equal(ftmp[], rtmp[]) rtmp[i, j] <- rtmp[i, j] - 1L ftmp[i, j] <- rtmp[i, j] expect_equal(ftmp[], rtmp[]) close(ftmp) delete(ftmp) } for (frc in list(f00, f01, f10, f11, f09, f19, f90, f91, f99)) { d <- dim(frc) i <- seq_len(d[[1]]) j <- seq_len(d[[2]]) k <- seq_len(prod(d)) ftmp <- clone(frc) rtmp <- ftmp[] expect_equal(swap(ftmp, 1L), { ret <- swap(rtmp, 1L) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) expect_equal(swap(ftmp, 1L, , ), { ret <- swap(rtmp, 1L, , ) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) expect_equal(swap(ftmp, 1L, k), { ret <- swap(rtmp, 1L, k) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) expect_equal(swap(ftmp, 1L, i, ), { ret <- swap(rtmp, 1L, i, ) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) expect_equal(swap(ftmp, 1L, , j), { ret <- swap(rtmp, 1L, , j) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) expect_equal(swap(ftmp, 1L, i, j), { ret <- swap(rtmp, 1L, i, j) vmode(ret) <- vm ret }) expect_equal(ftmp[], rtmp[]) close(ftmp) delete(ftmp) } for (frc in list(f00, f01, f10, f11, f09, f19, f90, f91, f99)) { d <- dim(frc) i <- seq_len(d[[1]]) j <- seq_len(d[[2]]) k <- seq_len(prod(d)) ftmp <- clone(frc) rtmp <- ftmp[] expect_silent(rtmp[] <- 1L) expect_silent(ftmp[] <- 1L) expect_equal(ftmp[], rtmp[]) expect_silent(rtmp[, ] <- 2L) expect_silent(ftmp[, ] <- 2L) expect_equal(ftmp[], rtmp[]) expect_silent(rtmp[k] <- 3L) expect_silent(ftmp[k] <- 3L) expect_equal(ftmp[], rtmp[]) expect_silent(rtmp[i, ] <- 0L) expect_silent(ftmp[i, ] <- 0L) expect_equal(ftmp[], rtmp[]) expect_silent(rtmp[, j] <- 1L) expect_silent(ftmp[, j] <- 1L) expect_equal(ftmp[], rtmp[]) expect_silent(rtmp[i, j] <- 2L) expect_silent(ftmp[i, j] <- 2L) expect_equal(ftmp[], rtmp[]) close(ftmp) delete(ftmp) } dims <- list(f00, f01, f10, f11, f09, f19, f90, f91, f99) nams <- sapply(dims, function(x) paste(dim(x), sep = "", collapse = "")) dres <- array(list(NULL), dim = c(length(nams), length(nams)), dimnames = list(obj = nams, dim = nams)) fres <- array(list(NULL), dim = c(length(nams), length(nams)), dimnames = list(obj = nams, dim = nams)) for (frc in dims) { for (drc in dims) { dtmp <- dim(drc) dnam <- paste(dim(drc), sep = "", collapse = "") fnam <- paste(dim(frc), sep = "", collapse = "") ftmp <- clone(frc) rtmp <- ftmp[] etmp <- try(dim(rtmp) <- dtmp, silent = TRUE) if (inherits(etmp, "try-error")) { dres[[fnam, dnam]] <- as.character(etmp) } etmp <- try(dim(ftmp) <- dtmp, silent = TRUE) if (inherits(etmp, "try-error")) { fres[[fnam, dnam]] <- as.character(etmp) } close(ftmp) delete(ftmp) } } dok <- apply(dres, 1:2, function(x) { is.null(x[[1]]) }) fok <- apply(fres, 1:2, function(x) { is.null(x[[1]]) }) expect_equal(dok, structure(c(TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE), .Dim = c(9L, 9L), .Dimnames = list(obj = c("00", "01", "10", "11", "09", "19", "90", "91", "99"), dim = c("00", "01", "10", "11", "09", "19", "90", "91", "99")))) expect_equal(fok, structure(c(TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE), .Dim = c(9L, 9L), .Dimnames = list(obj = c("00", "01", "10", "11", "09", "19", "90", "91", "99"), dim = c("00", "01", "10", "11", "09", "19", "90", "91", "99")))) rm(rtmp, ftmp, dtmp, etmp, dnam, fnam, dims, nams, dres, fres, dok, fok) gc() rm(i, j, k, vm, ret) rm(frc, drc) rm(d, d0, d1, d00, d01, d10, d11, d09, d19, d90, d91, d99) rm(r, r0, r1, r00, r01, r10, r11, r09, r19, r90, r91, r99) rm(a, a0, a1, a00, a01, a10, a11, a09, a19, a90, a91, a99) rm(c, c0, c1, c00, c01, c10, c11, c09, c19, c90, c91, c99) rm(f, f0, f1, f00, f01, f10, f11, f09, f19, f90, f91, f99)}) 29: eval(code, test_env) 30: eval(code, test_env) 31: withCallingHandlers({ eval(code, test_env) if (!handled && !is.null(test)) { skip_empty() }}, expectation = handle_expectation, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error) 32: doTryCatch(return(expr), name, parentenv, handler) 33: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 34: tryCatchList(expr, names[-nh], parentenv, handlers[-nh]) 35: doTryCatch(return(expr), name, parentenv, handler) 36: tryCatchOne(tryCatchList(expr, names[-nh], parentenv, handlers[-nh]), names[nh], parentenv, handlers[[nh]]) 37: tryCatchList(expr, classes, parentenv, handlers) 38: tryCatch(withCallingHandlers({ eval(code, test_env) if (!handled && !is.null(test)) { skip_empty() }}, expectation = handle_expectation, skip = handle_skip, warning = handle_warning, message = handle_message, error = handle_error), error = handle_fatal, skip = function(e) { }) 39: test_code(test = NULL, code = exprs, env = env, reporter = get_reporter() %||% StopReporter$new()) 40: source_file(path, env = env(env), desc = desc, error_call = error_call) 41: FUN(X[[i]], ...) 42: lapply(test_paths, test_one_file, env = env, desc = desc, error_call = error_call) 43: doTryCatch(return(expr), name, parentenv, handler) 44: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 45: tryCatchList(expr, classes, parentenv, handlers) 46: tryCatch(code, testthat_abort_reporter = function(cnd) { cat(conditionMessage(cnd), "\n") NULL}) 47: with_reporter(reporters$multi, lapply(test_paths, test_one_file, env = env, desc = desc, error_call = error_call)) 48: test_files_serial(test_dir = test_dir, test_package = test_package, test_paths = test_paths, load_helpers = load_helpers, reporter = reporter, env = env, stop_on_failure = stop_on_failure, stop_on_warning = stop_on_warning, desc = desc, load_package = load_package, error_call = error_call) 49: test_files(test_dir = path, test_paths = test_paths, test_package = package, reporter = reporter, load_helpers = load_helpers, env = env, stop_on_failure = stop_on_failure, stop_on_warning = stop_on_warning, load_package = load_package, parallel = parallel) 50: test_dir("testthat", package = package, reporter = reporter, ..., load_package = "installed") 51: test_check("ff") An irrecoverable exception occurred. R is aborting now ... Flavor: r-devel-linux-x86_64-fedora-gcc