pak
pak copied to clipboard
Error while creating lockfile not thrown properly
Run r-lib/actions/setup-r-dependencies@v2
Run ## Installing pak
Installing pak
Dependency resolution
ℹ Creating lockfile '.github/pkg.lock'
✔ Updated metadata database: 2.88 MB in 7 files.
ℹ Creating lockfile '.github/pkg.lock'
ℹ Updating metadata database
Error: Error: <rlib_error in throw(cond, parent = e): You can only throw conditions>
one of the log with call stack https://github.com/rstudio/rmarkdown/runs/4815089673?check_suite_focus=true
Similar crash at https://github.com/hsbadr/HiClimR/runs/4831022375 (error: R session crashed with exit code -9
):
ℹ Creating lockfile '.github/pkg.lock'
✔ Updated metadata database: 2.87 MB in 7 files.
ℹ Creating lockfile '.github/pkg.lock'
ℹ Updating metadata database
<error: R session crashed with exit code -9>
NULL
NULL
Error: Error: <error: R session crashed with exit code -9>
$calls
$calls[[1]]
pak::lockfile_create(c("deps::.", "any::sessioninfo", extra_deps),
lockfile = ".github/pkg.lock", dependencies = c(needs, ("all")))
$calls[[2]]
remote(function(...) {
get("lockfile_create_internal", asNamespace("pak"))(...)
}, list(pkg = pkg, lockfile = lockfile, lib = lib, upgrade = upgrade,
dependencies = dependencies))
$calls[[3]]
err$throw(res$error)
$parents
[1] 0 1 2
$envs
$envs[[1]]
[1] "0x55ccba4c3188"
$envs[[2]]
[1] "0x55ccba4db590"
$envs[[3]]
[1] "0x55ccba7cbde0"
$topenvs
$topenvs[[1]]
[1] "namespace:pak"
$topenvs[[2]]
[1] "namespace:pak"
$topenvs[[3]]
[1] "0x55ccba8cf980"
$indices
[1] 1 2 3
$nframes
[1] 3
$messages
$messages[[1]]
[1] "R session crashed with exit code -9"
$ignore
NULL
$classes
[1] "error" "condition"
$pids
[1] 14824 14824 14824
attr(,"class")
[1] "rlib_trace"
Execution halted
Error: Process completed with exit code 1.
I pushed some changed to v2
that seem to fix this: https://github.com/r-lib/actions/issues/483#issuecomment-1013918319
I pushed some changed to
v2
that seem to fix this: r-lib/actions#483 (comment)
Thanks! Will test it.
pkgcache now forces HTTP 1.1 as well, so when that is on CRAN it will solve this issue.
Except for the pre-bundled pak binaries of course. For those (and until pkgcache is on CRAN) the workaround is to force HTTP 1.1 with the env var:
PKGCACHE_HTTP_VERSION=2
(Yes, it HTTP 1.1 corresponds to the value 2.)
Hi, I am having what I believe it is the same problem here: https://github.com/NINAnor/oneimpact/actions/runs/4790505912/jobs/8519719745
But I am pretty new to continuous integration and using pak in this context, so I am not sure how to set it up even with these hints above... anyone could help? The file that creates that is this one.
@bniebuhr Can you try using the suggested syntax? I.e. any::pkgdown
and also local::.
if you need to install the local package. See
https://github.com/r-lib/actions/blob/788d7d59f05b5ac5b9cf4630428a2502514e98fb/examples/pkgdown.yaml#L35
It worked, thanks!