fix: supervise check_r install lifecycle#5
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 475c3f6c42
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| }, add = TRUE) | ||
|
|
||
| timeout_ms <- if (is.finite(timeout)) as.integer(min(timeout * 1000, .Machine$integer.max)) else -1L | ||
| process$wait(timeout = timeout_ms) |
There was a problem hiding this comment.
Drain installer pipes while waiting
When pak::pkg_install() emits more than the OS pipe buffer while stdout/stderr are piped above, this waits for the child to exit without reading either pipe until after the wait returns. In verbose source installs, or any install that writes enough output, the child can block on a full pipe while the parent is blocked here; with the default timeout = Inf that becomes an indefinite hang instead of preserving the previous streaming install behavior. Poll/read the pipes during the wait loop, or avoid piping output when it is not being drained.
Useful? React with 👍 / 👎.
| Depends: | ||
| R (>= 4.1.0) | ||
| Imports: | ||
| callr, |
There was a problem hiding this comment.
Require a callr version that supports package
When users already have callr older than 3.5.0 installed, this unversioned import is considered satisfied, but the new installer calls callr::r_bg(..., package = FALSE), and that package argument was only added in callr 3.5.0. In those environments check_r() fails before it can install anything, so the dependency should declare a minimum version such as callr (>= 3.5.0).
Useful? React with 👍 / 👎.
Summary
install = FALSEdiagnostics tocheck_r()Validation
pkgload::load_all(".", quiet = TRUE, compile = FALSE)passesR CMD check --as-cran --no-manual --no-examples --no-tests: 0 errors, 0 warnings; dependencies in R code OK; unstated dependencies in examples OKNotes
The two check notes are environment/repository metadata only: the worktree
.gitmarker and inability to verify remote current time.