Add reusable workflow for R package reverse-dependency checks - #42
Add reusable workflow for R package reverse-dependency checks#42andrjohns wants to merge 8 commits into
Conversation
|
This is awesome, thanks @andrjohns! One question (might have more later). When I check the summary of the loo results (but same pattern is true for the others) it says there were 71 reverse dependencies. However, if I check |
Ahhh good catch! The current workflow is only testing reverse Imports, whereas |
|
Thanks! |
jgabry
left a comment
There was a problem hiding this comment.
Two more very tiny review comments, otherwise this seems great. We had been trying to get something like this working for the loo package using the revdepcheck package, but that has been very difficult to get working well with GHA. This seems to run smoothly!
| } | ||
|
|
||
| dir.create("testdir") | ||
| download.packages(curr_deps, "testdir", repos = "https://cran.rstudio.com") |
There was a problem hiding this comment.
Maybe capture the return value from download.packages() (the downloaded packages) and compare it to curr_deps? Right now I think if a package fails to download then it's essentially omitted from the revdep checks without being flagged anywhere as not being checked
| default: 'rstan' | ||
| type: string | ||
| batch-size: | ||
| description: 'Number of packages to check in each batch (default is 15)' |
There was a problem hiding this comment.
| description: 'Number of packages to check in each batch (default is 15)' | |
| description: 'Number of packages to check in each batch (default is 20)' |
@jgabry based on your comment on the rstan revdeps PR, I've updated the workflow to be reusable by any of the repos to be able to run the reverse-dependency checks for any of our R packages.
The checks are run in batches of 20, with no more than 5 batches in parallel at a time. The run normally takes ~1-1.5 hours (depending on the number of reverse dependencies), and a summary of the results in generated in the actions page. Downstream repos can also specify multiple packages to be checked in a single workflow, for example, here's the output from a run with all of our R packages: https://github.com/andrjohns/rstan/actions/runs/29706615778#summary-88255992246
The workflow supports specifying any combination of CRAN/github refs for the other Stan R packages when testing, so for testing the
StanHeadersandrstanreverse dependency checks I would use:It's easy for the other R package repos to add their own workflow by calling this one,
bayesplotfor example: