Skip to content

Commit 40e2d74

Browse files
skip vignettes when engine unavailable (#6145)
* 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
1 parent 705276f commit 40e2d74

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

.github/workflows/R-CMD-check-occasional.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
on:
22
schedule:
3-
- cron: '17 13 19 * *' # 18th of month at 13:17 UTC
3+
- cron: '17 13 21 * *' # 18th of month at 13:17 UTC
44

55
# A more complete suite of checks to run monthly; each PR/merge need not pass all these, but they should pass before CRAN release
66
name: R-CMD-check-occasional
@@ -135,12 +135,15 @@ jobs:
135135
Sys.unsetenv("TEST_DATA_TABLE_WITH_OTHER_PACKAGES")
136136
}
137137
138-
args <- c("--no-manual", "--as-cran")
138+
do_vignettes <- requireNamespace("knitr", quietly=TRUE)
139+
140+
vignette_args <- if (!do_vignettes) "--no-build-vignettes"
141+
args <- c("--no-manual", "--as-cran", vignette_args)
139142
if (requireNamespace("rcmdcheck", quietly=TRUE)) {
140143
rcmdcheck::rcmdcheck(args = args, error_on = "warning", check_dir = "check")
141144
} else {
142145
Rbin = if (.Platform$OS.type == "windows") "R.exe" else "R"
143-
system2(Rbin, c("CMD", "build", "."))
146+
system2(Rbin, c("CMD", "build", ".", vignette_args))
144147
dt_tar <- list.files(pattern = "^data[.]table_.*[.]tar[.]gz$")
145148
if (!length(dt_tar)) stop("Built tar.gz not found among: ", toString(list.files()))
146149
res = system2(Rbin, c("CMD", "check", dt_tar[1L], args), stdout=TRUE)

inst/tests/other.Rraw

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ INT = data.table:::INT
2323
if (anyDuplicated(pkgs)) stop("Packages defined to be loaded for integration tests in 'inst/tests/other.Rraw' contains duplicates.")
2424

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

0 commit comments

Comments
 (0)