Skip to content

Commit

Permalink
Merge pull request #16 from inbo/get_all_s3_objects
Browse files Browse the repository at this point in the history
Get all s3 objects
  • Loading branch information
ThierryO authored Dec 3, 2017
2 parents 7d1f7b0 + d010472 commit de985d1
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 7 deletions.
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Package: n2kanalysis
Title: Generic Functions to Analyse Data from the Natura 2000 Monitoring
Version: 0.2.4.1
Date: 2017-11-29
Version: 0.2.4.2
Date: 2017-12-03
Authors@R: c(person("Thierry", "Onkelinx", email = "[email protected]", role = c("aut", "cre")))
Description: All generic functions for the analysis. The full analysis is
defined in the analysis package of each monitoring scheme.
Expand Down
1 change: 0 additions & 1 deletion R/fit_model_n2kAggregate.R
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
#' @rdname fit_model
#' @importFrom methods setMethod new
#' @importFrom multimput aggregate_impute
#' @importFrom aws.s3 get_bucket s3readRDS
#' @include n2kAggregate_class.R
setMethod(
f = "fit_model",
Expand Down
3 changes: 2 additions & 1 deletion R/fit_model_n2kManifest.R
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,8 @@ setMethod(
if (inherits(dots$base, "s3_bucket")) {
available <- get_bucket(
bucket = dots$base,
prefix = dots$project
prefix = dots$project,
max = Inf
)
manifest <- data.frame(
Filename = sapply(available, "[[", "Key"),
Expand Down
1 change: 0 additions & 1 deletion R/fit_model_n2kModelImputed.R
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
#' @rdname fit_model
#' @importFrom methods setMethod new
#' @importFrom multimput model_impute
#' @importFrom aws.s3 get_bucket s3readRDS
#' @include n2kModelImputed_class.R
setMethod(
f = "fit_model",
Expand Down
4 changes: 2 additions & 2 deletions R/store_manifest_yaml.R
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ setMethod(
)
filename <- gsub("\\.manifest", ".yaml", stored$Contents$Key) %>%
gsub(pattern = "(.*/)manifest(/.*)", replacement = "\\1yaml\\2")
available <- get_bucket(base, prefix = filename)
available <- get_bucket(base, prefix = filename, max = Inf)
if (length(available)) {
return(available)
}
Expand Down Expand Up @@ -73,7 +73,7 @@ setMethod(
if (!bucket_ok) {
stop("Unable to write to S3 bucket")
}
get_bucket(base, prefix = filename)
get_bucket(base, prefix = filename, max = Inf)
}
)

Expand Down

0 comments on commit de985d1

Please sign in to comment.