Cache renv dependencies earlier in docs workflows#714
Merged
Conversation
Agent-Logs-Url: https://github.com/d-morrison/rme/sessions/64351220-7227-44c8-8c06-3e65e0c80e13 Co-authored-by: d-morrison <2474437+d-morrison@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Update docs workflow to cache dependencies immediately after installation
Cache renv dependencies earlier in docs workflows
May 13, 2026
Contributor
2026-05-13 03:26 UTC |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the documentation-rendering GitHub Actions workflows to configure r-lib/actions/setup-renv@v2 with an explicit cache setting, aiming to ensure the renv dependency cache is persisted even when long render stages fail or are cancelled.
Changes:
- Add
with: bypass-cache: neverto thesetup-renv@v2step in the publish workflow. - Add
with: bypass-cache: neverto thesetup-renv@v2step in the preview workflow.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| .github/workflows/publish.yml | Adds bypass-cache: never to the setup-renv@v2 step used before render/deploy. |
| .github/workflows/preview.yml | Adds bypass-cache: never to the setup-renv@v2 step used before PR preview rendering. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Docs workflows were only persisting dependency cache in post-job behavior, so runs that failed/cancelled during render could miss cache saves. This updates the workflow cache mode so dependency cache is written immediately after restore/install, before long render stages.
Workflow cache timing
setup-renv:.github/workflows/preview.yml.github/workflows/publish.ymlBehavioral impact
Configuration change
see https://github.com/r-lib/actions/tree/v2-branch/setup-renv#usage for details