|
| 1 | +on: |
| 2 | + workflow_dispatch: # Enables manual triggering |
| 3 | + |
| 4 | +name: deps-devel-checks |
| 5 | + |
| 6 | +jobs: |
| 7 | + deps-devel-checks: |
| 8 | + timeout-minutes: 45 |
| 9 | + |
| 10 | + runs-on: ubuntu-latest |
| 11 | + |
| 12 | + name: ${{ matrix.config.pkg }} (${{ matrix.config.r }}) |
| 13 | + |
| 14 | + strategy: |
| 15 | + fail-fast: false |
| 16 | + matrix: |
| 17 | + config: |
| 18 | + - { r: "release", pkg: "crossmap", url: "rossellhayes/crossmap" } |
| 19 | + - { r: "release", pkg: "doFuture", url: "futureverse/doFuture@develop" } |
| 20 | + - { r: "release", pkg: "foreach", url: "RevolutionAnalytics/foreach" } |
| 21 | + - { r: "release", pkg: "future.apply", url: "futureverse/future.apply@develop" } |
| 22 | + - { r: "release", pkg: "futurize", url: "futureverse/futurize@develop" } |
| 23 | + - { r: "release", pkg: "purrr", url: "tidyverse/purrr" } |
| 24 | + - { r: "release", pkg: "furrr", url: "futureverse/furrr" } |
| 25 | +# - { r: "release", pkg: "partykit", url: "partykit" } |
| 26 | + - { r: "release", pkg: "plyr", url: "hadley/plyr" } |
| 27 | + |
| 28 | + env: |
| 29 | + GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} |
| 30 | + R_KEEP_PKG_SOURCE: yes |
| 31 | + R_REMOTES_NO_ERRORS_FROM_WARNINGS: true |
| 32 | + ## Test in other locale (optional) |
| 33 | + ## R (>= 4.4.0) Note, no trailing underscore (sic!) |
| 34 | + _R_COMPARE_LANG_OBJECTS: eqonly |
| 35 | + ## R CMD check |
| 36 | + _R_CHECK_CRAN_INCOMING_: false |
| 37 | + _R_CHECK_MATRIX_DATA_: true |
| 38 | + _R_CHECK_SUGGESTS_ONLY_: false |
| 39 | + _R_CHECK_FORCE_SUGGESTS_: true |
| 40 | + _R_CHECK_THINGS_IN_TEMP_DIR_: true |
| 41 | + _R_CHECK_TESTS_NLINES_: 300 |
| 42 | + _R_CHECK_TESTS_ELAPSED_THRESHOLD_: 0 |
| 43 | + RCMDCHECK_ERROR_ON: note |
| 44 | + NOT_CRAN: true |
| 45 | + ## Specific to futures |
| 46 | +# R_FUTURE_CONNECTIONS_ONMISUSE: "error[details=TRUE]" |
| 47 | + R_FUTURE_GLOBALENV_ONMISUSE: "error" |
| 48 | + R_FUTURE_GLOBALS_ONREFERENCE: "warning" |
| 49 | + R_FUTURE_RNG_ONMISUSE: error |
| 50 | + R_FUTURE_FUTURE_EARLYSIGNAL: defunct |
| 51 | + R_FUTURE_FUTURE_LOCAL: defunct |
| 52 | + R_FUTURE_FUTURE_GC: defunct |
| 53 | + R_FUTURE_PLAN_EARLYSIGNAL: defunct |
| 54 | + R_FUTURE_RESOLVED_RUN: defunct |
| 55 | + ## Specific to testme |
| 56 | + R_TESTME_FILTER_TAGS: '"pkg-${{ matrix.config.pkg }}" %in% tags' |
| 57 | + |
| 58 | + steps: |
| 59 | + - uses: actions/checkout@v4 |
| 60 | + |
| 61 | + - uses: r-lib/actions/setup-pandoc@v2 |
| 62 | + |
| 63 | + - uses: r-lib/actions/setup-r@v2 |
| 64 | + with: |
| 65 | + r-version: ${{ matrix.config.r }} |
| 66 | + use-public-rspm: true |
| 67 | + |
| 68 | + - uses: r-lib/actions/setup-r-dependencies@v2 |
| 69 | + with: |
| 70 | + extra-packages: | |
| 71 | + any::rcmdcheck |
| 72 | + any::remotes |
| 73 | + needs: check |
| 74 | + |
| 75 | + - name: Install package itself (special case) |
| 76 | + run: | |
| 77 | + install.packages(".", repos = NULL, type = "source") |
| 78 | + shell: Rscript {0} |
| 79 | + |
| 80 | + - name: Install development versions of dependencies |
| 81 | + run: | |
| 82 | + pak::pak("${{ matrix.config.url }}") |
| 83 | + shell: Rscript {0} |
| 84 | + |
| 85 | + - name: Session info |
| 86 | + run: | |
| 87 | + options(width = 100) |
| 88 | + parallelly::availableCores(which = "all") |
| 89 | + sapply(c(physical_cores = FALSE, logical_cores = TRUE), parallel::detectCores) |
| 90 | + if (require(RhpcBLASctl, quietly=TRUE)) c(get_num_procs = get_num_procs(), get_num_cores = get_num_cores(), blas_get_num_procs = blas_get_num_procs(), omp_get_num_procs = omp_get_num_procs(), omp_get_max_threads = omp_get_max_threads()) |
| 91 | + capabilities() |
| 92 | + pkgs <- installed.packages()[, "Package"] |
| 93 | + sessioninfo::session_info(pkgs, include_base = TRUE) |
| 94 | + ## Verify LANGUAGE settings by generating a translatable error |
| 95 | + cat(sprintf("LANGUAGE=%s\n", sQuote(Sys.getenv("LANGUAGE")))) |
| 96 | + cat(sprintf("locales: %s\n", sQuote(Sys.getlocale()))) |
| 97 | + tryCatch(log("a"), error = conditionMessage) |
| 98 | + shell: Rscript {0} |
| 99 | + |
| 100 | + - name: Check |
| 101 | + run: | |
| 102 | + rcmdcheck::rcmdcheck( |
| 103 | + args = c("--no-manual", "--as-cran"), |
| 104 | + check_dir = "check" |
| 105 | + ) |
| 106 | + shell: Rscript {0} |
| 107 | + |
| 108 | + - name: Upload check results |
| 109 | + if: failure() |
| 110 | + uses: actions/upload-artifact@v4 |
| 111 | + with: |
| 112 | + name: ${{ runner.os }}-r${{ matrix.config.r }}-results |
| 113 | + path: check |
0 commit comments