Skip to content

Commit

Permalink
skip vignettes when engine unavailable (#6145)
Browse files Browse the repository at this point in the history
* skip vignettes when engine unavailable

* set to run again tomorrow

* turn off quiet=TRUE to see if that gives any hint of what's going wrong
  • Loading branch information
MichaelChirico authored May 20, 2024
1 parent 705276f commit 40e2d74
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
9 changes: 6 additions & 3 deletions .github/workflows/R-CMD-check-occasional.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
on:
schedule:
- cron: '17 13 19 * *' # 18th of month at 13:17 UTC
- cron: '17 13 21 * *' # 18th of month at 13:17 UTC

# A more complete suite of checks to run monthly; each PR/merge need not pass all these, but they should pass before CRAN release
name: R-CMD-check-occasional
Expand Down Expand Up @@ -135,12 +135,15 @@ jobs:
Sys.unsetenv("TEST_DATA_TABLE_WITH_OTHER_PACKAGES")
}
args <- c("--no-manual", "--as-cran")
do_vignettes <- requireNamespace("knitr", quietly=TRUE)
vignette_args <- if (!do_vignettes) "--no-build-vignettes"
args <- c("--no-manual", "--as-cran", vignette_args)
if (requireNamespace("rcmdcheck", quietly=TRUE)) {
rcmdcheck::rcmdcheck(args = args, error_on = "warning", check_dir = "check")
} else {
Rbin = if (.Platform$OS.type == "windows") "R.exe" else "R"
system2(Rbin, c("CMD", "build", "."))
system2(Rbin, c("CMD", "build", ".", vignette_args))
dt_tar <- list.files(pattern = "^data[.]table_.*[.]tar[.]gz$")
if (!length(dt_tar)) stop("Built tar.gz not found among: ", toString(list.files()))
res = system2(Rbin, c("CMD", "check", dt_tar[1L], args), stdout=TRUE)
Expand Down
2 changes: 1 addition & 1 deletion inst/tests/other.Rraw
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ INT = data.table:::INT
if (anyDuplicated(pkgs)) stop("Packages defined to be loaded for integration tests in 'inst/tests/other.Rraw' contains duplicates.")

f = function(pkg) suppressWarnings(suppressMessages(isTRUE(
library(pkg, character.only=TRUE, logical.return=TRUE, quietly=TRUE, warn.conflicts=FALSE, pos="package:base") # attach at the end for #5101
library(pkg, character.only=TRUE, logical.return=TRUE, warn.conflicts=FALSE, pos="package:base") # attach at the end for #5101
)))
loaded = sapply(pkgs, f)
if (!all(loaded)) {
Expand Down

0 comments on commit 40e2d74

Please sign in to comment.