Permalink
Browse files

Merge remote-tracking branch 'origin/development' into development

  • Loading branch information...
achubaty committed Nov 9, 2018
2 parents d99e4fe + d66894d commit 5ed6a72de3c18e1f2ed94aef966fa30457955555
Showing with 8 additions and 6 deletions.
  1. +2 −2 R/cache-helpers.R
  2. +6 −4 R/cache.R
@@ -1099,9 +1099,9 @@ nextNumericName <- function(string) {
splits <- strsplit(allSimilarFilesInDirSansExt[alreadyHasNumeric], split = "_")
highestNumber <- max(unlist(lapply(splits, function(split) as.numeric(tail(split,1)))),
na.rm = TRUE)
preNumeric <- lapply(splits, function(spl) paste(spl[-length(spl)], collapse = "_"))
preNumeric <- unique(unlist(lapply(splits, function(spl) paste(spl[-length(spl)], collapse = "_"))))
out <- paste0(preNumeric, "_", highestNumber + 1) # keep rndstr in here, so that both streams keep same rnd number state
out <- paste0(dirname(saveFilenameSansExt), preNumeric, "_", highestNumber + 1) # keep rndstr in here, so that both streams keep same rnd number state
} else {
out <- paste0(saveFilenameSansExt, "_1")
}
@@ -503,18 +503,20 @@ setMethod(
# don't digest the dotPipe elements as they are already
# extracted individually into modifiedDots list elements
dotPipe <- startsWith(names(modifiedDots), "._")
preDigestByClass <- lapply(seq_along(modifiedDots[!dotPipe]), function(x) {
.preDigestByClass(modifiedDots[!dotPipe][[x]])
})
if (verbose) {
startHashTime <- Sys.time()
}
# if (!is.null(list(...)$sim))
# browser(expr = current(list(...)$sim)$moduleName == "LBMR")
preDigest <- lapply(modifiedDots[!dotPipe], function(x) {
# remove some of the arguments passed to Cache, which are irrelevant for digest
argsToOmitForDigest <- dotPipe |
(names(modifiedDots) %in%
c("debug", "notOlderThan", "debugCache", "verbose", "useCache", "showSimilar"))
preDigest <- lapply(modifiedDots[!argsToOmitForDigest], function(x) {
# remove the "newCache" attribute, which is irrelevant for digest
if (!is.null(attr(x, ".Cache")$newCache)) attr(x, ".Cache")$newCache <- NULL
.robustDigest(x, objects = objects,

0 comments on commit 5ed6a72

Please sign in to comment.