pak
pak copied to clipboard
Failure to use the already installed Matrix package
On this GHA build we get the unfortunate error with no extra context: https://github.com/tidymodels/hardhat/runs/3768720403
2021-10-01T15:08:16.0434995Z ##[error]Error: <callr_remote_error: Cannot install packages:
2021-10-01T15:08:16.0446177Z >
2021-10-01T15:08:16.0446592Z in process 9759
2021-10-01T15:08:16.0447427Z -->
2021-10-01T15:08:16.0447872Z <simpleError: Cannot install packages:
2021-10-01T15:08:16.0449766Z >
2021-10-01T15:08:16.0475755Z
2021-10-01T15:08:16.0476201Z Stack trace:
2021-10-01T15:08:16.0476417Z
2021-10-01T15:08:16.0476762Z 12. (function (...) ...
2021-10-01T15:08:16.0477542Z 13. base:::withCallingHandlers(cli_message = function(msg) { ...
2021-10-01T15:08:16.0479420Z 14. get("pkg_deps_internal", asNamespace("pak"))(...)
2021-10-01T15:08:16.0480093Z 15. pak:::pkg_deps_internal2(pkg, upgrade, dependencies)
2021-10-01T15:08:16.0480669Z 16. deps$stop_for_solution_error()
2021-10-01T15:08:16.0481174Z 17. private$plan$stop_for_solve_error()
2021-10-01T15:08:16.0481803Z 18. pkgdepends:::pkgplan_stop_for_solve_error(self, private)
2021-10-01T15:08:16.0483455Z 19. base:::stop("Cannot install packages:\n", msg, call. = FALSE)
2021-10-01T15:08:16.0484128Z 20. base:::.handleSimpleError(function (e) ...
2021-10-01T15:08:16.0484665Z 21. h(simpleError(msg, call))
2021-10-01T15:08:16.0485370Z 22. base:::stop(e)
2021-10-01T15:08:16.0486781Z 23. (function (e) ...
2021-10-01T15:08:16.0487017Z
2021-10-01T15:08:16.0487395Z x Cannot install packages:
Run locally, we get the following:
> pak::pkg_deps("local::.", dependencies = TRUE)
✔ Updated metadata database: 2.44 MB in 5 files.
✔ Updating metadata database ... done
Error: Cannot install packages:
* local::.: Can't install dependency Matrix
* Matrix: Needs R 3.5.0
* Matrix: Needs R 4.2
Type .Last.error.trace to see where the error occurred
Matrix is a recommended package, which should already be installed, but we currently don't have a way to tell pak to use it and that seems to be related to this issue
I have a failing built which tries to install the foreign package which is also a recommended package (and now requires 4.0.0): https://github.com/tidymodels/censored/pull/82/checks?check_run_id=3806116333
@hfrick Why does the same thing work on Linux? https://github.com/tidymodels/censored/pull/82/checks?check_run_id=3806116558#step:5:234
I was wondering the same thing :sweat_smile:
Seeing this on themis as well cc @EmilHvitfeldt
AFAICT themis needs progressr, which needs R 3.5.0, so even if this issue is solved, you won't be able to install it on R 3.4.x:
❯ pak::pkg_deps_explain("tidymodels/themis", "progressr")
themis -> recipes -> ipred -> prodlim -> lava -> progressr
@DavisVaughan the same is true for hardhat, seemingly:
> pak::pkg_deps_explain("tidymodels/hardhat", "progressr", dependencies = TRUE)
hardhat -> recipes -> ipred -> prodlim -> lava -> progressr
progressr is a hard dependency of recipes (both CRAN and GH versions), so anything that needs recipes needs at least R 3.5.0:
> pak::pkg_deps_explain("recipes", "progressr")
recipes -> ipred -> prodlim -> lava -> progressr
> pak::pkg_deps_explain("tidymodels/recipes", "progressr")
recipes -> ipred -> prodlim -> lava -> progressr
@hfrick as for censored, riskRegression is a hard dependency and it needs R 3.5.0:
❯ pak::pkg_deps_explain("tidymodels/censored", "riskRegression")
censored -> pec -> riskRegression
and glmnet is a dev-dependency, and that need R 3.6.0.
I'm going to add a reminder here (most of the folks on this thread probably remember) that about a month ago, we had to move recipes to R>=4.0.0 because of fastICA. Anything that tries to build recipes will now need to stick to R>=4.0.0.
EDIT: Wait, that can't be right??? Because themis is now building back to oldrel-3
?