From 739042a8758127a46e8777daa7bd565837882271 Mon Sep 17 00:00:00 2001 From: Fernando da Silva Date: Thu, 14 Sep 2023 13:04:00 +0000 Subject: [PATCH] [ci] Updates rsconnect --- renv.lock | 838 ++++++++++++++++++++++++++++++--------------- renv/.gitignore | 1 + renv/activate.R | 527 ++++++++++++++++++++-------- renv/settings.json | 19 + 4 files changed, 975 insertions(+), 410 deletions(-) create mode 100644 renv/settings.json diff --git a/renv.lock b/renv.lock index 9a49f84..325eb66 100644 --- a/renv.lock +++ b/renv.lock @@ -1,6 +1,6 @@ { "R": { - "Version": "4.2.1", + "Version": "4.3.1", "Repositories": [ { "Name": "CRAN", @@ -14,24 +14,26 @@ "Version": "1.75.0-0", "Source": "Repository", "Repository": "CRAN", - "Hash": "e4c04affc2cac20c8fec18385cd14691", - "Requirements": [] + "Hash": "e4c04affc2cac20c8fec18385cd14691" }, "Formula": { "Package": "Formula", "Version": "1.2-4", "Source": "Repository", "Repository": "CRAN", - "Hash": "cc8c8c4d61346cde1ca60030ff9c241f", - "Requirements": [] + "Requirements": [ + "R", + "stats" + ], + "Hash": "cc8c8c4d61346cde1ca60030ff9c241f" }, "GetBCBData": { "Package": "GetBCBData", "Version": "0.6", "Source": "Repository", "Repository": "CRAN", - "Hash": "da62cb93586851d9393d4ce107a28aad", "Requirements": [ + "R", "RCurl", "curl", "dplyr", @@ -42,15 +44,17 @@ "memoise", "purrr", "readr", - "stringr" - ] + "stats", + "stringr", + "utils" + ], + "Hash": "da62cb93586851d9393d4ce107a28aad" }, "Hmisc": { "Package": "Hmisc", "Version": "4.7-0", "Source": "Repository", "Repository": "CRAN", - "Hash": "d6b38998466629deb0346b1feb594283", "Requirements": [ "Formula", "base64enc", @@ -58,266 +62,332 @@ "data.table", "foreign", "ggplot2", + "grid", "gridExtra", "gtable", "htmlTable", "htmltools", "lattice", "latticeExtra", + "methods", "nnet", "rpart", "survival", "viridis" - ] + ], + "Hash": "d6b38998466629deb0346b1feb594283" }, "MASS": { "Package": "MASS", "Version": "7.3-60", "Source": "Repository", "Repository": "CRAN", - "Hash": "a56a6365b3fa73293ea8d084be0d9bb0", - "Requirements": [] + "Requirements": [ + "R", + "grDevices", + "graphics", + "methods", + "stats", + "utils" + ], + "Hash": "a56a6365b3fa73293ea8d084be0d9bb0" }, "Matrix": { "Package": "Matrix", "Version": "1.5-4.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "38082d362d317745fb932e13956dccbb", "Requirements": [ - "lattice" - ] + "R", + "graphics", + "grid", + "lattice", + "methods", + "stats", + "utils" + ], + "Hash": "38082d362d317745fb932e13956dccbb" }, "R6": { "Package": "R6", "Version": "2.5.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "470851b6d5d0ac559e9d01bb352b4021", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "470851b6d5d0ac559e9d01bb352b4021" }, "RColorBrewer": { "Package": "RColorBrewer", "Version": "1.1-2", "Source": "Repository", "Repository": "CRAN", - "Hash": "e031418365a7f7a766181ab5a41a5716", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "e031418365a7f7a766181ab5a41a5716" }, "RCurl": { "Package": "RCurl", "Version": "1.98-1.4", "Source": "Repository", "Repository": "CRAN", - "Hash": "e43588d9fa3aa87ca9ee96450e810895", "Requirements": [ - "bitops" - ] + "R", + "bitops", + "methods" + ], + "Hash": "e43588d9fa3aa87ca9ee96450e810895" }, "Rcpp": { "Package": "Rcpp", "Version": "1.0.8.3", "Source": "Repository", "Repository": "CRAN", - "Hash": "32e79b908fda56ee57fe518a8d37b864", - "Requirements": [] + "Requirements": [ + "methods", + "utils" + ], + "Hash": "32e79b908fda56ee57fe518a8d37b864" }, "anytime": { "Package": "anytime", "Version": "0.3.9", "Source": "Repository", "Repository": "CRAN", - "Hash": "74a64813f17b492da9c6afda6b128e3d", "Requirements": [ "BH", + "R", "Rcpp" - ] + ], + "Hash": "74a64813f17b492da9c6afda6b128e3d" }, "askpass": { "Package": "askpass", "Version": "1.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "e8a22846fff485f0be3770c2da758713", "Requirements": [ "sys" - ] + ], + "Hash": "e8a22846fff485f0be3770c2da758713" }, "backports": { "Package": "backports", "Version": "1.2.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "644043219fc24e190c2f620c1a380a69", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "644043219fc24e190c2f620c1a380a69" }, "base64enc": { "Package": "base64enc", "Version": "0.1-3", "Source": "Repository", "Repository": "CRAN", - "Hash": "543776ae6848fde2f48ff3816d0628bc", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "543776ae6848fde2f48ff3816d0628bc" }, "bit": { "Package": "bit", "Version": "4.0.4", "Source": "Repository", "Repository": "CRAN", - "Hash": "f36715f14d94678eea9933af927bc15d", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "f36715f14d94678eea9933af927bc15d" }, "bit64": { "Package": "bit64", "Version": "4.0.5", "Source": "Repository", "Repository": "CRAN", - "Hash": "9fe98599ca456d6552421db0d6772d8f", "Requirements": [ - "bit" - ] + "R", + "bit", + "methods", + "stats", + "utils" + ], + "Hash": "9fe98599ca456d6552421db0d6772d8f" }, "bitops": { "Package": "bitops", "Version": "1.0-7", "Source": "Repository", "Repository": "CRAN", - "Hash": "b7d8d8ee39869c18d8846a184dd8a1af", - "Requirements": [] + "Hash": "b7d8d8ee39869c18d8846a184dd8a1af" }, "bslib": { "Package": "bslib", "Version": "0.4.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "89a0cd0c45161e3bd1c1e74a2d65e516", "Requirements": [ + "R", "cachem", + "grDevices", "htmltools", "jquerylib", "jsonlite", "memoise", "rlang", "sass" - ] + ], + "Hash": "89a0cd0c45161e3bd1c1e74a2d65e516" }, "cachem": { "Package": "cachem", "Version": "1.0.6", "Source": "Repository", "Repository": "CRAN", - "Hash": "648c5b3d71e6a37e3043617489a0a0e9", "Requirements": [ "fastmap", "rlang" - ] + ], + "Hash": "648c5b3d71e6a37e3043617489a0a0e9" }, "checkmate": { "Package": "checkmate", "Version": "2.2.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "ca9c113196136f4a9ca9ce6079c2c99e", "Requirements": [ - "backports" - ] + "R", + "backports", + "utils" + ], + "Hash": "ca9c113196136f4a9ca9ce6079c2c99e" }, "cli": { "Package": "cli", "Version": "3.0.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "e3ae5d68dea0c55a12ea12a9fda02e61", "Requirements": [ - "glue" - ] + "R", + "glue", + "utils" + ], + "Hash": "e3ae5d68dea0c55a12ea12a9fda02e61" }, "clipr": { "Package": "clipr", "Version": "0.7.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "ebaa97ac99cc2daf04e77eecc7b781d7", - "Requirements": [] + "Requirements": [ + "utils" + ], + "Hash": "ebaa97ac99cc2daf04e77eecc7b781d7" }, "cluster": { "Package": "cluster", "Version": "2.1.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "db63a44aab5aadcb6bf2f129751d129a", - "Requirements": [] + "Requirements": [ + "R", + "grDevices", + "graphics", + "stats", + "utils" + ], + "Hash": "db63a44aab5aadcb6bf2f129751d129a" }, "codetools": { "Package": "codetools", "Version": "0.2-16", "Source": "Repository", "Repository": "CRAN", - "Hash": "89cf4b8207269ccf82fbeb6473fd662b", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "89cf4b8207269ccf82fbeb6473fd662b" }, "colorspace": { "Package": "colorspace", "Version": "2.0-2", "Source": "Repository", "Repository": "CRAN", - "Hash": "6baccb763ee83c0bd313460fdb8b8a84", - "Requirements": [] + "Requirements": [ + "R", + "grDevices", + "graphics", + "methods", + "stats" + ], + "Hash": "6baccb763ee83c0bd313460fdb8b8a84" }, "commonmark": { "Package": "commonmark", "Version": "1.7", "Source": "Repository", "Repository": "CRAN", - "Hash": "0f22be39ec1d141fd03683c06f3a6e67", - "Requirements": [] + "Hash": "0f22be39ec1d141fd03683c06f3a6e67" }, "cpp11": { "Package": "cpp11", "Version": "0.4.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "70976176dfd7f179f212783aab2547b1", - "Requirements": [] + "Hash": "70976176dfd7f179f212783aab2547b1" }, "crayon": { "Package": "crayon", "Version": "1.4.2", "Source": "Repository", "Repository": "CRAN", - "Hash": "0a6a65d92bd45b47b94b84244b528d17", - "Requirements": [] + "Requirements": [ + "grDevices", + "methods", + "utils" + ], + "Hash": "0a6a65d92bd45b47b94b84244b528d17" }, "curl": { "Package": "curl", "Version": "4.3.2", "Source": "Repository", "Repository": "CRAN", - "Hash": "022c42d49c28e95d69ca60446dbabf88", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "022c42d49c28e95d69ca60446dbabf88" }, "data.table": { "Package": "data.table", "Version": "1.14.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "d1b8b1a821ee564a3515fa6c6d5c52dc", - "Requirements": [] + "Requirements": [ + "R", + "methods" + ], + "Hash": "d1b8b1a821ee564a3515fa6c6d5c52dc" }, "digest": { "Package": "digest", "Version": "0.6.28", "Source": "Repository", "Repository": "CRAN", - "Hash": "49b5c6e230bfec487b8917d5a0c77cca", - "Requirements": [] + "Requirements": [ + "R", + "utils" + ], + "Hash": "49b5c6e230bfec487b8917d5a0c77cca" }, "distributional": { "Package": "distributional", "Version": "0.2.2", "Source": "Repository", "Repository": "CRAN", - "Hash": "046f2e782ce27c4d08b02e101aa5fee3", "Requirements": [ "digest", "ellipsis", @@ -328,54 +398,64 @@ "numDeriv", "rlang", "scales", + "stats", + "utils", "vctrs" - ] + ], + "Hash": "046f2e782ce27c4d08b02e101aa5fee3" }, "dplyr": { "Package": "dplyr", "Version": "1.0.7", "Source": "Repository", "Repository": "CRAN", - "Hash": "36f1ae62f026c8ba9f9b5c9a08c03297", "Requirements": [ + "R", "R6", "ellipsis", "generics", "glue", "lifecycle", "magrittr", + "methods", "pillar", "rlang", "tibble", "tidyselect", + "utils", "vctrs" - ] + ], + "Hash": "36f1ae62f026c8ba9f9b5c9a08c03297" }, "ellipsis": { "Package": "ellipsis", "Version": "0.3.2", "Source": "Repository", "Repository": "CRAN", - "Hash": "bb0eec2fe32e88d9e2836c2f73ea2077", "Requirements": [ + "R", "rlang" - ] + ], + "Hash": "bb0eec2fe32e88d9e2836c2f73ea2077" }, "evaluate": { "Package": "evaluate", "Version": "0.14", "Source": "Repository", "Repository": "CRAN", - "Hash": "ec8ca05cffcc70569eaaad8469d2a3a7", - "Requirements": [] + "Requirements": [ + "R", + "methods" + ], + "Hash": "ec8ca05cffcc70569eaaad8469d2a3a7" }, "fabletools": { "Package": "fabletools", "Version": "0.3.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "4a1f396153db9cefd9e6473916b3f9f4", "Requirements": [ + "R", "R6", "distributional", "dplyr", @@ -384,47 +464,53 @@ "lifecycle", "progressr", "rlang", + "stats", "tibble", "tidyr", "tidyselect", "tsibble", + "utils", "vctrs" - ] + ], + "Hash": "4a1f396153db9cefd9e6473916b3f9f4" }, "fansi": { "Package": "fansi", "Version": "0.5.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "d447b40982c576a72b779f0a3b3da227", - "Requirements": [] + "Requirements": [ + "R", + "grDevices", + "utils" + ], + "Hash": "d447b40982c576a72b779f0a3b3da227" }, "farver": { "Package": "farver", "Version": "2.1.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "c98eb5133d9cb9e1622b8691487f11bb", - "Requirements": [] + "Hash": "c98eb5133d9cb9e1622b8691487f11bb" }, "fastmap": { "Package": "fastmap", "Version": "1.1.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "77bd60a6157420d4ffa93b27cf6a58b8", - "Requirements": [] + "Hash": "77bd60a6157420d4ffa93b27cf6a58b8" }, "feasts": { "Package": "feasts", "Version": "0.2.2", "Source": "Repository", "Repository": "CRAN", - "Hash": "416ecd0cfbc652bc2ab02cb29b3b4cf6", "Requirements": [ + "R", "dplyr", "fabletools", "ggplot2", + "grid", "lifecycle", "lubridate", "rlang", @@ -433,17 +519,20 @@ "tibble", "tidyr", "tsibble", + "utils", "vctrs" - ] + ], + "Hash": "416ecd0cfbc652bc2ab02cb29b3b4cf6" }, "flexdashboard": { "Package": "flexdashboard", "Version": "0.6.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "66aa31fb4b18c053cd20753523073742", "Requirements": [ + "R", "bslib", + "grDevices", "htmltools", "htmlwidgets", "jsonlite", @@ -451,56 +540,69 @@ "rmarkdown", "sass", "scales", - "shiny" - ] + "shiny", + "tools", + "utils" + ], + "Hash": "66aa31fb4b18c053cd20753523073742" }, "fontawesome": { "Package": "fontawesome", "Version": "0.4.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "c5a628c2570aa86a96cc6ef739d8bfda", "Requirements": [ + "R", "htmltools", "rlang" - ] + ], + "Hash": "c5a628c2570aa86a96cc6ef739d8bfda" }, "forcats": { "Package": "forcats", "Version": "0.5.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "81c3244cab67468aac4c60550832655d", "Requirements": [ + "R", "ellipsis", "magrittr", "rlang", "tibble" - ] + ], + "Hash": "81c3244cab67468aac4c60550832655d" }, "foreign": { "Package": "foreign", "Version": "0.8-80", "Source": "Repository", "Repository": "CRAN", - "Hash": "ae1b1e15cc6ccb2bc61c0ac33e86d35f", - "Requirements": [] + "Requirements": [ + "R", + "methods", + "stats", + "utils" + ], + "Hash": "ae1b1e15cc6ccb2bc61c0ac33e86d35f" }, "fs": { "Package": "fs", "Version": "1.5.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "44594a07a42e5f91fac9f93fda6d0109", - "Requirements": [] + "Requirements": [ + "R", + "methods" + ], + "Hash": "44594a07a42e5f91fac9f93fda6d0109" }, "furrr": { "Package": "furrr", "Version": "0.2.3", "Source": "Repository", "Repository": "CRAN", - "Hash": "2aba4ab06e8707ac054c6683cb6fed56", "Requirements": [ + "R", "ellipsis", "future", "globals", @@ -508,88 +610,109 @@ "purrr", "rlang", "vctrs" - ] + ], + "Hash": "2aba4ab06e8707ac054c6683cb6fed56" }, "future": { "Package": "future", "Version": "1.22.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "9c56382c3e53f0b4fc0fc16d88fc3974", "Requirements": [ "digest", "globals", "listenv", - "parallelly" - ] + "parallel", + "parallelly", + "tools", + "utils" + ], + "Hash": "9c56382c3e53f0b4fc0fc16d88fc3974" }, "generics": { "Package": "generics", "Version": "0.1.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "3f6bcfb0ee5d671d9fd1893d2faa79cb", - "Requirements": [] + "Requirements": [ + "R", + "methods" + ], + "Hash": "3f6bcfb0ee5d671d9fd1893d2faa79cb" }, "ggplot2": { "Package": "ggplot2", "Version": "3.3.6", "Source": "Repository", "Repository": "CRAN", - "Hash": "0fb26d0674c82705c6b701d1a61e02ea", "Requirements": [ "MASS", + "R", "digest", "glue", + "grDevices", + "grid", "gtable", "isoband", "mgcv", "rlang", "scales", + "stats", "tibble", "withr" - ] + ], + "Hash": "0fb26d0674c82705c6b701d1a61e02ea" }, "ggtext": { "Package": "ggtext", "Version": "0.1.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "03d8caec959ac70e2d13bad1ac40667c", "Requirements": [ + "R", "ggplot2", + "grid", "gridtext", "rlang", "scales" - ] + ], + "Hash": "03d8caec959ac70e2d13bad1ac40667c" }, "globals": { "Package": "globals", "Version": "0.14.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "eca8023ed5ca6372479ebb9b3207f5ae", "Requirements": [ + "R", "codetools" - ] + ], + "Hash": "eca8023ed5ca6372479ebb9b3207f5ae" }, "glue": { "Package": "glue", "Version": "1.6.2", "Source": "Repository", "Repository": "CRAN", - "Hash": "4f2596dfb05dac67b9dc558e5c6fba2e", - "Requirements": [] + "Requirements": [ + "R", + "methods" + ], + "Hash": "4f2596dfb05dac67b9dc558e5c6fba2e" }, "gridExtra": { "Package": "gridExtra", "Version": "2.3", "Source": "Repository", "Repository": "CRAN", - "Hash": "7d7f283939f563670a697165b2cf5560", "Requirements": [ - "gtable" - ] + "grDevices", + "graphics", + "grid", + "gtable", + "utils" + ], + "Hash": "7d7f283939f563670a697165b2cf5560" }, "gridtext": { "Package": "gridtext", @@ -601,340 +724,415 @@ "RemoteUsername": "wilkelab", "RemoteRef": "HEAD", "RemoteSha": "619217496f20a29500b3a98d1069280d6067b4d2", - "Hash": "f90d3b43a8ac45f7e998b8c719f15315", "Requirements": [ + "R", "Rcpp", "curl", + "grDevices", + "grid", "jpeg", "markdown", "png", "rlang", "stringr", "xml2" - ] + ], + "Hash": "f90d3b43a8ac45f7e998b8c719f15315" }, "gtable": { "Package": "gtable", "Version": "0.3.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "ac5c6baf7822ce8732b343f14c072c4d", - "Requirements": [] + "Requirements": [ + "R", + "grid" + ], + "Hash": "ac5c6baf7822ce8732b343f14c072c4d" }, "highr": { "Package": "highr", "Version": "0.9", "Source": "Repository", "Repository": "CRAN", - "Hash": "8eb36c8125038e648e5d111c0d7b2ed4", "Requirements": [ + "R", "xfun" - ] + ], + "Hash": "8eb36c8125038e648e5d111c0d7b2ed4" }, "hms": { "Package": "hms", "Version": "1.1.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "5b8a2dd0fdbe2ab4f6081e6c7be6dfca", "Requirements": [ "ellipsis", "lifecycle", + "methods", "pkgconfig", "rlang", "vctrs" - ] + ], + "Hash": "5b8a2dd0fdbe2ab4f6081e6c7be6dfca" }, "htmlTable": { "Package": "htmlTable", "Version": "2.1.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "4f2a742fc75dedafe660e3b47a37680e", "Requirements": [ "checkmate", "htmltools", "htmlwidgets", "knitr", "magrittr", + "methods", "rstudioapi", "stringr" - ] + ], + "Hash": "4f2a742fc75dedafe660e3b47a37680e" }, "htmltools": { "Package": "htmltools", "Version": "0.5.2", "Source": "Repository", "Repository": "CRAN", - "Hash": "526c484233f42522278ab06fb185cb26", "Requirements": [ + "R", "base64enc", "digest", "fastmap", - "rlang" - ] + "grDevices", + "rlang", + "utils" + ], + "Hash": "526c484233f42522278ab06fb185cb26" }, "htmlwidgets": { "Package": "htmlwidgets", "Version": "1.5.3", "Source": "Repository", "Repository": "CRAN", - "Hash": "6fdaa86d0700f8b3e92ee3c445a5a10d", "Requirements": [ + "grDevices", "htmltools", "jsonlite", "yaml" - ] + ], + "Hash": "6fdaa86d0700f8b3e92ee3c445a5a10d" }, "httpuv": { "Package": "httpuv", "Version": "1.6.5", "Source": "Repository", "Repository": "CRAN", - "Hash": "97fe71f0a4a1c9890e6c2128afa04bc0", "Requirements": [ + "R", "R6", "Rcpp", "later", - "promises" - ] + "promises", + "utils" + ], + "Hash": "97fe71f0a4a1c9890e6c2128afa04bc0" }, "isoband": { "Package": "isoband", "Version": "0.2.5", "Source": "Repository", "Repository": "CRAN", - "Hash": "7ab57a6de7f48a8dc84910d1eca42883", - "Requirements": [] + "Requirements": [ + "grid", + "utils" + ], + "Hash": "7ab57a6de7f48a8dc84910d1eca42883" }, "jpeg": { "Package": "jpeg", "Version": "0.1-9", "Source": "Repository", "Repository": "CRAN", - "Hash": "441ee36360a57b363f4fa3df0c364630", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "441ee36360a57b363f4fa3df0c364630" }, "jquerylib": { "Package": "jquerylib", "Version": "0.1.4", "Source": "Repository", "Repository": "CRAN", - "Hash": "5aab57a3bd297eee1c1d862735972182", "Requirements": [ "htmltools" - ] + ], + "Hash": "5aab57a3bd297eee1c1d862735972182" }, "jsonlite": { "Package": "jsonlite", "Version": "1.7.2", "Source": "Repository", "Repository": "CRAN", - "Hash": "98138e0994d41508c7a6b84a0600cfcb", - "Requirements": [] + "Requirements": [ + "methods" + ], + "Hash": "98138e0994d41508c7a6b84a0600cfcb" }, "knitr": { "Package": "knitr", "Version": "1.33", "Source": "Repository", "Repository": "CRAN", - "Hash": "0bc1b5da1b0eb07cd4b727e95e9ff0b8", "Requirements": [ + "R", "evaluate", "highr", "markdown", + "methods", "stringr", + "tools", "xfun", "yaml" - ] + ], + "Hash": "0bc1b5da1b0eb07cd4b727e95e9ff0b8" }, "labeling": { "Package": "labeling", "Version": "0.4.2", "Source": "Repository", "Repository": "CRAN", - "Hash": "3d5108641f47470611a32d0bdf357a72", - "Requirements": [] + "Requirements": [ + "graphics", + "stats" + ], + "Hash": "3d5108641f47470611a32d0bdf357a72" }, "later": { "Package": "later", "Version": "1.3.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "7e7b457d7766bc47f2a5f21cc2984f8e", "Requirements": [ "Rcpp", "rlang" - ] + ], + "Hash": "7e7b457d7766bc47f2a5f21cc2984f8e" }, "lattice": { "Package": "lattice", "Version": "0.20-41", "Source": "Repository", "Repository": "CRAN", - "Hash": "fbd9285028b0263d76d18c95ae51a53d", - "Requirements": [] + "Requirements": [ + "R", + "grDevices", + "graphics", + "grid", + "stats", + "utils" + ], + "Hash": "fbd9285028b0263d76d18c95ae51a53d" }, "latticeExtra": { "Package": "latticeExtra", "Version": "0.6-29", "Source": "Repository", "Repository": "CRAN", - "Hash": "590829599d6182cf7461787af34666ee", "Requirements": [ + "R", "RColorBrewer", + "grDevices", + "grid", "jpeg", "lattice", - "png" - ] + "png", + "stats", + "utils" + ], + "Hash": "590829599d6182cf7461787af34666ee" }, "lifecycle": { "Package": "lifecycle", "Version": "1.0.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "a6b6d352e3ed897373ab19d8395c98d0", "Requirements": [ + "R", "glue", "rlang" - ] + ], + "Hash": "a6b6d352e3ed897373ab19d8395c98d0" }, "listenv": { "Package": "listenv", "Version": "0.8.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "0bde42ee282efb18c7c4e63822f5b4f7", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "0bde42ee282efb18c7c4e63822f5b4f7" }, "lubridate": { "Package": "lubridate", "Version": "1.8.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "2ff5eedb6ee38fb1b81205c73be1be5a", "Requirements": [ + "R", "cpp11", - "generics" - ] + "generics", + "methods" + ], + "Hash": "2ff5eedb6ee38fb1b81205c73be1be5a" }, "magrittr": { "Package": "magrittr", "Version": "2.0.3", "Source": "Repository", "Repository": "CRAN", - "Hash": "7ce2733a9826b3aeb1775d56fd305472", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "7ce2733a9826b3aeb1775d56fd305472" }, "markdown": { "Package": "markdown", "Version": "1.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "61e4a10781dd00d7d81dd06ca9b94e95", "Requirements": [ + "R", "mime", + "utils", "xfun" - ] + ], + "Hash": "61e4a10781dd00d7d81dd06ca9b94e95" }, "memoise": { "Package": "memoise", "Version": "2.0.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "e2817ccf4a065c5d9d7f2cfbe7c1d78c", "Requirements": [ "cachem", "rlang" - ] + ], + "Hash": "e2817ccf4a065c5d9d7f2cfbe7c1d78c" }, "mgcv": { "Package": "mgcv", "Version": "1.8-42", "Source": "Repository", "Repository": "CRAN", - "Hash": "3460beba7ccc8946249ba35327ba902a", "Requirements": [ "Matrix", - "nlme" - ] + "R", + "graphics", + "methods", + "nlme", + "splines", + "stats", + "utils" + ], + "Hash": "3460beba7ccc8946249ba35327ba902a" }, "mime": { "Package": "mime", "Version": "0.12", "Source": "Repository", "Repository": "CRAN", - "Hash": "18e9c28c1d3ca1560ce30658b22ce104", - "Requirements": [] + "Requirements": [ + "tools" + ], + "Hash": "18e9c28c1d3ca1560ce30658b22ce104" }, "munsell": { "Package": "munsell", "Version": "0.5.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "6dfe8bf774944bd5595785e3229d8771", "Requirements": [ - "colorspace" - ] + "colorspace", + "methods" + ], + "Hash": "6dfe8bf774944bd5595785e3229d8771" }, "nlme": { "Package": "nlme", "Version": "3.1-162", "Source": "Repository", "Repository": "CRAN", - "Hash": "0984ce8da8da9ead8643c5cbbb60f83e", "Requirements": [ - "lattice" - ] + "R", + "graphics", + "lattice", + "stats", + "utils" + ], + "Hash": "0984ce8da8da9ead8643c5cbbb60f83e" }, "nnet": { "Package": "nnet", "Version": "7.3-19", "Source": "Repository", "Repository": "CRAN", - "Hash": "2c797b46eea7fb58ede195bc0b1f1138", - "Requirements": [] + "Requirements": [ + "R", + "stats", + "utils" + ], + "Hash": "2c797b46eea7fb58ede195bc0b1f1138" }, "numDeriv": { "Package": "numDeriv", "Version": "2016.8-1.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "df58958f293b166e4ab885ebcad90e02", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "df58958f293b166e4ab885ebcad90e02" }, "openssl": { "Package": "openssl", "Version": "2.0.5", "Source": "Repository", "Repository": "CRAN", - "Hash": "b04c27110bf367b4daa93f34f3d58e75", "Requirements": [ "askpass" - ] + ], + "Hash": "b04c27110bf367b4daa93f34f3d58e75" }, "packrat": { "Package": "packrat", "Version": "0.8.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "d84055adcb6bb1f4f0ce8c5f235bc328", - "Requirements": [] + "Requirements": [ + "R", + "tools", + "utils" + ], + "Hash": "d84055adcb6bb1f4f0ce8c5f235bc328" }, "parallelly": { "Package": "parallelly", "Version": "1.28.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "5300c9fc71841550bdca64d39e82af0e", - "Requirements": [] + "Requirements": [ + "parallel", + "tools", + "utils" + ], + "Hash": "5300c9fc71841550bdca64d39e82af0e" }, "pillar": { "Package": "pillar", "Version": "1.6.4", "Source": "Repository", "Repository": "CRAN", - "Hash": "60200b6aa32314ac457d3efbb5ccbd98", "Requirements": [ "cli", "crayon", @@ -943,96 +1141,107 @@ "lifecycle", "rlang", "utf8", + "utils", "vctrs" - ] + ], + "Hash": "60200b6aa32314ac457d3efbb5ccbd98" }, "pkgconfig": { "Package": "pkgconfig", "Version": "2.0.3", "Source": "Repository", "Repository": "CRAN", - "Hash": "01f28d4278f15c76cddbea05899c5d6f", - "Requirements": [] + "Requirements": [ + "utils" + ], + "Hash": "01f28d4278f15c76cddbea05899c5d6f" }, "png": { "Package": "png", "Version": "0.1-7", "Source": "Repository", "Repository": "CRAN", - "Hash": "03b7076c234cb3331288919983326c55", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "03b7076c234cb3331288919983326c55" }, "prettyunits": { "Package": "prettyunits", "Version": "1.1.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "95ef9167b75dde9d2ccc3c7528393e7e", - "Requirements": [] + "Hash": "95ef9167b75dde9d2ccc3c7528393e7e" }, "progress": { "Package": "progress", "Version": "1.2.2", "Source": "Repository", "Repository": "CRAN", - "Hash": "14dc9f7a3c91ebb14ec5bb9208a07061", "Requirements": [ "R6", "crayon", "hms", "prettyunits" - ] + ], + "Hash": "14dc9f7a3c91ebb14ec5bb9208a07061" }, "progressr": { "Package": "progressr", "Version": "0.8.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "a8742f0e454e8a40bc269920535e0afb", "Requirements": [ - "digest" - ] + "R", + "digest", + "utils" + ], + "Hash": "a8742f0e454e8a40bc269920535e0afb" }, "promises": { "Package": "promises", "Version": "1.2.0.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "4ab2c43adb4d4699cf3690acd378d75d", "Requirements": [ "R6", "Rcpp", "later", "magrittr", - "rlang" - ] + "rlang", + "stats" + ], + "Hash": "4ab2c43adb4d4699cf3690acd378d75d" }, "purrr": { "Package": "purrr", "Version": "0.3.4", "Source": "Repository", "Repository": "CRAN", - "Hash": "97def703420c8ab10d8f0e6c72101e02", "Requirements": [ + "R", "magrittr", "rlang" - ] + ], + "Hash": "97def703420c8ab10d8f0e6c72101e02" }, "rappdirs": { "Package": "rappdirs", "Version": "0.3.3", "Source": "Repository", "Repository": "CRAN", - "Hash": "5e3c5dc0b071b21fa128676560dbe94d", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "5e3c5dc0b071b21fa128676560dbe94d" }, "readr": { "Package": "readr", "Version": "2.0.2", "Source": "Repository", "Repository": "CRAN", - "Hash": "7cb2c3ecfbc2c6786221d2c0c1f6ed68", "Requirements": [ + "R", "R6", "cli", "clipr", @@ -1040,98 +1249,120 @@ "crayon", "hms", "lifecycle", + "methods", "rlang", "tibble", "tzdb", + "utils", "vroom" - ] + ], + "Hash": "7cb2c3ecfbc2c6786221d2c0c1f6ed68" }, "renv": { "Package": "renv", - "Version": "0.15.5", + "Version": "1.0.2", "Source": "Repository", "Repository": "CRAN", - "Hash": "6a38294e7d12f5d8e656b08c5bd8ae34", - "Requirements": [] + "Requirements": [ + "utils" + ], + "Hash": "4b22ac016fe54028b88d0c68badbd061" }, "rlang": { "Package": "rlang", "Version": "1.0.2", "Source": "Repository", "Repository": "CRAN", - "Hash": "04884d9a75d778aca22c7154b8333ec9", - "Requirements": [] + "Requirements": [ + "R", + "utils" + ], + "Hash": "04884d9a75d778aca22c7154b8333ec9" }, "rmarkdown": { "Package": "rmarkdown", "Version": "2.10", "Source": "Repository", "Repository": "CRAN", - "Hash": "1fb097f233ee98968f8e5d0bcd42df6d", "Requirements": [ + "R", "evaluate", "htmltools", "jsonlite", "knitr", + "methods", "stringr", "tinytex", + "tools", + "utils", "xfun", "yaml" - ] + ], + "Hash": "1fb097f233ee98968f8e5d0bcd42df6d" }, "rpart": { "Package": "rpart", "Version": "4.1-15", "Source": "Repository", "Repository": "CRAN", - "Hash": "9787c1fcb680e655d062e7611cadf78e", - "Requirements": [] + "Requirements": [ + "R", + "grDevices", + "graphics", + "stats" + ], + "Hash": "9787c1fcb680e655d062e7611cadf78e" }, "rsconnect": { "Package": "rsconnect", - "Version": "0.8.28", + "Version": "1.1.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "737312265e542d243f003b9625482e09", "Requirements": [ + "R", + "cli", "curl", "digest", "jsonlite", + "lifecycle", "openssl", "packrat", + "renv", + "rlang", "rstudioapi", + "tools", "yaml" - ] + ], + "Hash": "ec53d658cf0abbd7cd7ce2d6b9d70337" }, "rstudioapi": { "Package": "rstudioapi", "Version": "0.13", "Source": "Repository", "Repository": "CRAN", - "Hash": "06c85365a03fdaf699966cc1d3cf53ea", - "Requirements": [] + "Hash": "06c85365a03fdaf699966cc1d3cf53ea" }, "sass": { "Package": "sass", "Version": "0.4.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "50cf822feb64bb3977bda0b7091be623", "Requirements": [ "R6", "fs", "htmltools", "rappdirs", "rlang" - ] + ], + "Hash": "50cf822feb64bb3977bda0b7091be623" }, "scales": { "Package": "scales", "Version": "1.1.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "6f76f71042411426ec8df6c54f34e6dd", "Requirements": [ + "R", "R6", "RColorBrewer", "farver", @@ -1139,15 +1370,16 @@ "lifecycle", "munsell", "viridisLite" - ] + ], + "Hash": "6f76f71042411426ec8df6c54f34e6dd" }, "shiny": { "Package": "shiny", "Version": "1.7.3", "Source": "Repository", "Repository": "CRAN", - "Hash": "fe12df67fdb3b1142325cc54f100cc06", "Requirements": [ + "R", "R6", "bslib", "cachem", @@ -1157,103 +1389,125 @@ "fastmap", "fontawesome", "glue", + "grDevices", "htmltools", "httpuv", "jsonlite", "later", "lifecycle", + "methods", "mime", "promises", "rlang", "sourcetools", + "tools", + "utils", "withr", "xtable" - ] + ], + "Hash": "fe12df67fdb3b1142325cc54f100cc06" }, "slider": { "Package": "slider", "Version": "0.2.2", "Source": "Repository", "Repository": "CRAN", - "Hash": "5237bd176dc0c4dd7eb8dcdafe514de3", "Requirements": [ + "R", "ellipsis", "glue", "rlang", "vctrs", "warp" - ] + ], + "Hash": "5237bd176dc0c4dd7eb8dcdafe514de3" }, "sourcetools": { "Package": "sourcetools", "Version": "0.1.7", "Source": "Repository", "Repository": "CRAN", - "Hash": "947e4e02a79effa5d512473e10f41797", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "947e4e02a79effa5d512473e10f41797" }, "stringi": { "Package": "stringi", "Version": "1.7.6", "Source": "Repository", "Repository": "CRAN", - "Hash": "bba431031d30789535745a9627ac9271", - "Requirements": [] + "Requirements": [ + "R", + "stats", + "tools", + "utils" + ], + "Hash": "bba431031d30789535745a9627ac9271" }, "stringr": { "Package": "stringr", "Version": "1.4.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "0759e6b6c0957edb1311028a49a35e76", "Requirements": [ + "R", "glue", "magrittr", "stringi" - ] + ], + "Hash": "0759e6b6c0957edb1311028a49a35e76" }, "survival": { "Package": "survival", "Version": "3.5-5", "Source": "Repository", "Repository": "CRAN", - "Hash": "d683341b1fa2e8d817efde27d6e6d35b", "Requirements": [ - "Matrix" - ] + "Matrix", + "R", + "graphics", + "methods", + "splines", + "stats", + "utils" + ], + "Hash": "d683341b1fa2e8d817efde27d6e6d35b" }, "sys": { "Package": "sys", "Version": "3.4", "Source": "Repository", "Repository": "CRAN", - "Hash": "b227d13e29222b4574486cfcbde077fa", - "Requirements": [] + "Hash": "b227d13e29222b4574486cfcbde077fa" }, "tibble": { "Package": "tibble", "Version": "3.1.6", "Source": "Repository", "Repository": "CRAN", - "Hash": "8a8f02d1934dfd6431c671361510dd0b", "Requirements": [ + "R", "ellipsis", "fansi", "lifecycle", "magrittr", + "methods", "pillar", "pkgconfig", "rlang", + "utils", "vctrs" - ] + ], + "Hash": "8a8f02d1934dfd6431c671361510dd0b" }, "tidyr": { "Package": "tidyr", "Version": "1.1.4", "Source": "Repository", "Repository": "CRAN", - "Hash": "c8fbdbd9fcac223d6c6fe8e406f368e1", "Requirements": [ + "R", "cpp11", "dplyr", "ellipsis", @@ -1264,109 +1518,122 @@ "rlang", "tibble", "tidyselect", + "utils", "vctrs" - ] + ], + "Hash": "c8fbdbd9fcac223d6c6fe8e406f368e1" }, "tidyselect": { "Package": "tidyselect", "Version": "1.1.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "7243004a708d06d4716717fa1ff5b2fe", "Requirements": [ + "R", "ellipsis", "glue", "purrr", "rlang", "vctrs" - ] + ], + "Hash": "7243004a708d06d4716717fa1ff5b2fe" }, "tinytex": { "Package": "tinytex", "Version": "0.33", "Source": "Repository", "Repository": "CRAN", - "Hash": "6e0ad90ac5669e35d5456cb61b295acb", "Requirements": [ "xfun" - ] + ], + "Hash": "6e0ad90ac5669e35d5456cb61b295acb" }, "tsibble": { "Package": "tsibble", "Version": "1.0.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "530bfd4537ab035fdc91448cb8c26efc", "Requirements": [ + "R", "anytime", "dplyr", "ellipsis", "generics", "lifecycle", "lubridate", + "methods", "rlang", "tibble", "tidyselect", "vctrs" - ] + ], + "Hash": "530bfd4537ab035fdc91448cb8c26efc" }, "tzdb": { "Package": "tzdb", "Version": "0.2.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "5e069fb033daf2317bd628d3100b75c5", "Requirements": [ + "R", "cpp11" - ] + ], + "Hash": "5e069fb033daf2317bd628d3100b75c5" }, "utf8": { "Package": "utf8", "Version": "1.2.2", "Source": "Repository", "Repository": "CRAN", - "Hash": "c9c462b759a5cc844ae25b5942654d13", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "c9c462b759a5cc844ae25b5942654d13" }, "vctrs": { "Package": "vctrs", "Version": "0.3.8", "Source": "Repository", "Repository": "CRAN", - "Hash": "ecf749a1b39ea72bd9b51b76292261f1", "Requirements": [ + "R", "ellipsis", "glue", "rlang" - ] + ], + "Hash": "ecf749a1b39ea72bd9b51b76292261f1" }, "viridis": { "Package": "viridis", "Version": "0.6.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "424d1285b7372d39806abb19467e4df4", "Requirements": [ + "R", "ggplot2", "gridExtra", + "stats", "viridisLite" - ] + ], + "Hash": "424d1285b7372d39806abb19467e4df4" }, "viridisLite": { "Package": "viridisLite", "Version": "0.4.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "55e157e2aa88161bdb0754218470d204", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "55e157e2aa88161bdb0754218470d204" }, "vroom": { "Package": "vroom", "Version": "1.5.5", "Source": "Repository", "Repository": "CRAN", - "Hash": "9c3b3a3f947c7936cea7485349247e5b", "Requirements": [ + "R", "bit64", "cli", "cpp11", @@ -1374,62 +1641,81 @@ "glue", "hms", "lifecycle", + "methods", "progress", "rlang", + "stats", "tibble", "tidyselect", "tzdb", "vctrs", "withr" - ] + ], + "Hash": "9c3b3a3f947c7936cea7485349247e5b" }, "warp": { "Package": "warp", "Version": "0.2.0", "Source": "Repository", "Repository": "CRAN", - "Hash": "2982481615756e24e79fee95bdc95daa", - "Requirements": [] + "Requirements": [ + "R" + ], + "Hash": "2982481615756e24e79fee95bdc95daa" }, "withr": { "Package": "withr", "Version": "2.4.2", "Source": "Repository", "Repository": "CRAN", - "Hash": "ad03909b44677f930fa156d47d7a3aeb", - "Requirements": [] + "Requirements": [ + "R", + "grDevices", + "graphics", + "stats" + ], + "Hash": "ad03909b44677f930fa156d47d7a3aeb" }, "xfun": { "Package": "xfun", "Version": "0.31", "Source": "Repository", "Repository": "CRAN", - "Hash": "a318c6f752b8dcfe9fb74d897418ab2b", - "Requirements": [] + "Requirements": [ + "stats", + "tools" + ], + "Hash": "a318c6f752b8dcfe9fb74d897418ab2b" }, "xml2": { "Package": "xml2", "Version": "1.3.3", "Source": "Repository", "Repository": "CRAN", - "Hash": "40682ed6a969ea5abfd351eb67833adc", - "Requirements": [] + "Requirements": [ + "R", + "methods" + ], + "Hash": "40682ed6a969ea5abfd351eb67833adc" }, "xtable": { "Package": "xtable", "Version": "1.8-4", "Source": "Repository", "Repository": "CRAN", - "Hash": "b8acdf8af494d9ec19ccb2481a9b11c2", - "Requirements": [] + "Requirements": [ + "R", + "stats", + "utils" + ], + "Hash": "b8acdf8af494d9ec19ccb2481a9b11c2" }, "yaml": { "Package": "yaml", "Version": "2.2.1", "Source": "Repository", "Repository": "CRAN", - "Hash": "2826c5d9efb0a88f657c7a679c7106db", - "Requirements": [] + "Hash": "2826c5d9efb0a88f657c7a679c7106db" } } } diff --git a/renv/.gitignore b/renv/.gitignore index cb06864..63b9ec4 100644 --- a/renv/.gitignore +++ b/renv/.gitignore @@ -1,3 +1,4 @@ +sandbox/ cellar/ library/ local/ diff --git a/renv/activate.R b/renv/activate.R index 72c0818..2969c73 100644 --- a/renv/activate.R +++ b/renv/activate.R @@ -2,11 +2,27 @@ local({ # the requested version of renv - version <- "0.15.5" + version <- "1.0.2" + attr(version, "sha") <- NULL # the project directory project <- getwd() + # use start-up diagnostics if enabled + diagnostics <- Sys.getenv("RENV_STARTUP_DIAGNOSTICS", unset = "FALSE") + if (diagnostics) { + start <- Sys.time() + profile <- tempfile("renv-startup-", fileext = ".Rprof") + utils::Rprof(profile) + on.exit({ + utils::Rprof(NULL) + elapsed <- signif(difftime(Sys.time(), start, units = "auto"), digits = 2L) + writeLines(sprintf("- renv took %s to run the autoloader.", format(elapsed))) + writeLines(sprintf("- Profile: %s", profile)) + print(utils::summaryRprof(profile)) + }, add = TRUE) + } + # figure out whether the autoloader is enabled enabled <- local({ @@ -60,21 +76,75 @@ local({ # load bootstrap tools `%||%` <- function(x, y) { - if (is.environment(x) || length(x)) x else y + if (is.null(x)) y else x + } + + catf <- function(fmt, ..., appendLF = TRUE) { + + quiet <- getOption("renv.bootstrap.quiet", default = FALSE) + if (quiet) + return(invisible()) + + msg <- sprintf(fmt, ...) + cat(msg, file = stdout(), sep = if (appendLF) "\n" else "") + + invisible(msg) + + } + + header <- function(label, + ..., + prefix = "#", + suffix = "-", + n = min(getOption("width"), 78)) + { + label <- sprintf(label, ...) + n <- max(n - nchar(label) - nchar(prefix) - 2L, 8L) + if (n <= 0) + return(paste(prefix, label)) + + tail <- paste(rep.int(suffix, n), collapse = "") + paste0(prefix, " ", label, " ", tail) + + } + + startswith <- function(string, prefix) { + substring(string, 1, nchar(prefix)) == prefix } bootstrap <- function(version, library) { + friendly <- renv_bootstrap_version_friendly(version) + section <- header(sprintf("Bootstrapping renv %s", friendly)) + catf(section) + # attempt to download renv - tarball <- tryCatch(renv_bootstrap_download(version), error = identity) - if (inherits(tarball, "error")) - stop("failed to download renv ", version) + catf("- Downloading renv ... ", appendLF = FALSE) + withCallingHandlers( + tarball <- renv_bootstrap_download(version), + error = function(err) { + catf("FAILED") + stop("failed to download:\n", conditionMessage(err)) + } + ) + catf("OK") + on.exit(unlink(tarball), add = TRUE) # now attempt to install - status <- tryCatch(renv_bootstrap_install(version, tarball, library), error = identity) - if (inherits(status, "error")) - stop("failed to install renv ", version) + catf("- Installing renv ... ", appendLF = FALSE) + withCallingHandlers( + status <- renv_bootstrap_install(version, tarball, library), + error = function(err) { + catf("FAILED") + stop("failed to install:\n", conditionMessage(err)) + } + ) + catf("OK") + + # add empty line to break up bootstrapping from normal output + catf("") + return(invisible()) } renv_bootstrap_tests_running <- function() { @@ -83,28 +153,32 @@ local({ renv_bootstrap_repos <- function() { + # get CRAN repository + cran <- getOption("renv.repos.cran", "https://cloud.r-project.org") + # check for repos override repos <- Sys.getenv("RENV_CONFIG_REPOS_OVERRIDE", unset = NA) - if (!is.na(repos)) + if (!is.na(repos)) { + + # check for RSPM; if set, use a fallback repository for renv + rspm <- Sys.getenv("RSPM", unset = NA) + if (identical(rspm, repos)) + repos <- c(RSPM = rspm, CRAN = cran) + return(repos) + } + # check for lockfile repositories repos <- tryCatch(renv_bootstrap_repos_lockfile(), error = identity) if (!inherits(repos, "error") && length(repos)) return(repos) - # if we're testing, re-use the test repositories - if (renv_bootstrap_tests_running()) - return(getOption("renv.tests.repos")) - # retrieve current repos repos <- getOption("repos") # ensure @CRAN@ entries are resolved - repos[repos == "@CRAN@"] <- getOption( - "renv.repos.cran", - "https://cloud.r-project.org" - ) + repos[repos == "@CRAN@"] <- cran # add in renv.bootstrap.repos if set default <- c(FALLBACK = "https://cloud.r-project.org") @@ -143,33 +217,34 @@ local({ renv_bootstrap_download <- function(version) { - # if the renv version number has 4 components, assume it must - # be retrieved via github - nv <- numeric_version(version) - components <- unclass(nv)[[1]] - - # if this appears to be a development version of 'renv', we'll - # try to restore from github - dev <- length(components) == 4L - - # begin collecting different methods for finding renv - methods <- c( - renv_bootstrap_download_tarball, - if (dev) - renv_bootstrap_download_github - else c( - renv_bootstrap_download_cran_latest, - renv_bootstrap_download_cran_archive + sha <- attr(version, "sha", exact = TRUE) + + methods <- if (!is.null(sha)) { + + # attempting to bootstrap a development version of renv + c( + function() renv_bootstrap_download_tarball(sha), + function() renv_bootstrap_download_github(sha) ) - ) + + } else { + + # attempting to bootstrap a release version of renv + c( + function() renv_bootstrap_download_tarball(version), + function() renv_bootstrap_download_cran_latest(version), + function() renv_bootstrap_download_cran_archive(version) + ) + + } for (method in methods) { - path <- tryCatch(method(version), error = identity) + path <- tryCatch(method(), error = identity) if (is.character(path) && file.exists(path)) return(path) } - stop("failed to download renv ", version) + stop("All download methods failed") } @@ -185,43 +260,75 @@ local({ if (fixup) mode <- "w+b" - utils::download.file( + args <- list( url = url, destfile = destfile, mode = mode, quiet = TRUE ) + if ("headers" %in% names(formals(utils::download.file))) + args$headers <- renv_bootstrap_download_custom_headers(url) + + do.call(utils::download.file, args) + } - renv_bootstrap_download_cran_latest <- function(version) { + renv_bootstrap_download_custom_headers <- function(url) { - spec <- renv_bootstrap_download_cran_latest_find(version) + headers <- getOption("renv.download.headers") + if (is.null(headers)) + return(character()) + + if (!is.function(headers)) + stopf("'renv.download.headers' is not a function") + + headers <- headers(url) + if (length(headers) == 0L) + return(character()) + + if (is.list(headers)) + headers <- unlist(headers, recursive = FALSE, use.names = TRUE) + + ok <- + is.character(headers) && + is.character(names(headers)) && + all(nzchar(names(headers))) - message("* Downloading renv ", version, " ... ", appendLF = FALSE) + if (!ok) + stop("invocation of 'renv.download.headers' did not return a named character vector") + headers + + } + + renv_bootstrap_download_cran_latest <- function(version) { + + spec <- renv_bootstrap_download_cran_latest_find(version) type <- spec$type repos <- spec$repos - info <- tryCatch( - utils::download.packages( - pkgs = "renv", - destdir = tempdir(), - repos = repos, - type = type, - quiet = TRUE - ), + baseurl <- utils::contrib.url(repos = repos, type = type) + ext <- if (identical(type, "source")) + ".tar.gz" + else if (Sys.info()[["sysname"]] == "Windows") + ".zip" + else + ".tgz" + name <- sprintf("renv_%s%s", version, ext) + url <- paste(baseurl, name, sep = "/") + + destfile <- file.path(tempdir(), name) + status <- tryCatch( + renv_bootstrap_download_impl(url, destfile), condition = identity ) - if (inherits(info, "condition")) { - message("FAILED") + if (inherits(status, "condition")) return(FALSE) - } # report success and return - message("OK (downloaded ", type, ")") - info[1, 2] + destfile } @@ -277,8 +384,6 @@ local({ urls <- file.path(repos, "src/contrib/Archive/renv", name) destfile <- file.path(tempdir(), name) - message("* Downloading renv ", version, " ... ", appendLF = FALSE) - for (url in urls) { status <- tryCatch( @@ -286,14 +391,11 @@ local({ condition = identity ) - if (identical(status, 0L)) { - message("OK") + if (identical(status, 0L)) return(destfile) - } } - message("FAILED") return(FALSE) } @@ -307,8 +409,7 @@ local({ return() # allow directories - info <- file.info(tarball, extra_cols = FALSE) - if (identical(info$isdir, TRUE)) { + if (dir.exists(tarball)) { name <- sprintf("renv_%s.tar.gz", version) tarball <- file.path(tarball, name) } @@ -317,7 +418,7 @@ local({ if (!file.exists(tarball)) { # let the user know we weren't able to honour their request - fmt <- "* RENV_BOOTSTRAP_TARBALL is set (%s) but does not exist." + fmt <- "- RENV_BOOTSTRAP_TARBALL is set (%s) but does not exist." msg <- sprintf(fmt, tarball) warning(msg) @@ -326,10 +427,7 @@ local({ } - fmt <- "* Bootstrapping with tarball at path '%s'." - msg <- sprintf(fmt, tarball) - message(msg) - + catf("- Using local tarball '%s'.", tarball) tarball } @@ -356,8 +454,6 @@ local({ on.exit(do.call(base::options, saved), add = TRUE) } - message("* Downloading renv ", version, " from GitHub ... ", appendLF = FALSE) - url <- file.path("https://api.github.com/repos/rstudio/renv/tarball", version) name <- sprintf("renv_%s.tar.gz", version) destfile <- file.path(tempdir(), name) @@ -367,26 +463,105 @@ local({ condition = identity ) - if (!identical(status, 0L)) { - message("FAILED") + if (!identical(status, 0L)) return(FALSE) - } - message("OK") + renv_bootstrap_download_augment(destfile) + return(destfile) } + # Add Sha to DESCRIPTION. This is stop gap until #890, after which we + # can use renv::install() to fully capture metadata. + renv_bootstrap_download_augment <- function(destfile) { + sha <- renv_bootstrap_git_extract_sha1_tar(destfile) + if (is.null(sha)) { + return() + } + + # Untar + tempdir <- tempfile("renv-github-") + on.exit(unlink(tempdir, recursive = TRUE), add = TRUE) + untar(destfile, exdir = tempdir) + pkgdir <- dir(tempdir, full.names = TRUE)[[1]] + + # Modify description + desc_path <- file.path(pkgdir, "DESCRIPTION") + desc_lines <- readLines(desc_path) + remotes_fields <- c( + "RemoteType: github", + "RemoteHost: api.github.com", + "RemoteRepo: renv", + "RemoteUsername: rstudio", + "RemotePkgRef: rstudio/renv", + paste("RemoteRef: ", sha), + paste("RemoteSha: ", sha) + ) + writeLines(c(desc_lines[desc_lines != ""], remotes_fields), con = desc_path) + + # Re-tar + local({ + old <- setwd(tempdir) + on.exit(setwd(old), add = TRUE) + + tar(destfile, compression = "gzip") + }) + invisible() + } + + # Extract the commit hash from a git archive. Git archives include the SHA1 + # hash as the comment field of the tarball pax extended header + # (see https://www.kernel.org/pub/software/scm/git/docs/git-archive.html) + # For GitHub archives this should be the first header after the default one + # (512 byte) header. + renv_bootstrap_git_extract_sha1_tar <- function(bundle) { + + # open the bundle for reading + # We use gzcon for everything because (from ?gzcon) + # > Reading from a connection which does not supply a 'gzip' magic + # > header is equivalent to reading from the original connection + conn <- gzcon(file(bundle, open = "rb", raw = TRUE)) + on.exit(close(conn)) + + # The default pax header is 512 bytes long and the first pax extended header + # with the comment should be 51 bytes long + # `52 comment=` (11 chars) + 40 byte SHA1 hash + len <- 0x200 + 0x33 + res <- rawToChar(readBin(conn, "raw", n = len)[0x201:len]) + + if (grepl("^52 comment=", res)) { + sub("52 comment=", "", res) + } else { + NULL + } + } + renv_bootstrap_install <- function(version, tarball, library) { # attempt to install it into project library - message("* Installing renv ", version, " ... ", appendLF = FALSE) dir.create(library, showWarnings = FALSE, recursive = TRUE) + output <- renv_bootstrap_install_impl(library, tarball) + + # check for successful install + status <- attr(output, "status") + if (is.null(status) || identical(status, 0L)) + return(status) + + # an error occurred; report it + header <- "installation of renv failed" + lines <- paste(rep.int("=", nchar(header)), collapse = "") + text <- paste(c(header, lines, output), collapse = "\n") + stop(text) + + } + + renv_bootstrap_install_impl <- function(library, tarball) { # invoke using system2 so we can capture and report output bin <- R.home("bin") exe <- if (Sys.info()[["sysname"]] == "Windows") "R.exe" else "R" - r <- file.path(bin, exe) + R <- file.path(bin, exe) args <- c( "--vanilla", "CMD", "INSTALL", "--no-multiarch", @@ -394,19 +569,7 @@ local({ shQuote(path.expand(tarball)) ) - output <- system2(r, args, stdout = TRUE, stderr = TRUE) - message("Done!") - - # check for successful install - status <- attr(output, "status") - if (is.numeric(status) && !identical(status, 0L)) { - header <- "Error installing renv:" - lines <- paste(rep.int("=", nchar(header)), collapse = "") - text <- c(header, lines, output) - writeLines(text, con = stderr()) - } - - status + system2(R, args, stdout = TRUE, stderr = TRUE) } @@ -616,34 +779,62 @@ local({ } - renv_bootstrap_validate_version <- function(version) { + renv_bootstrap_validate_version <- function(version, description = NULL) { - loadedversion <- utils::packageDescription("renv", fields = "Version") - if (version == loadedversion) - return(TRUE) + # resolve description file + # + # avoid passing lib.loc to `packageDescription()` below, since R will + # use the loaded version of the package by default anyhow. note that + # this function should only be called after 'renv' is loaded + # https://github.com/rstudio/renv/issues/1625 + description <- description %||% packageDescription("renv") - # assume four-component versions are from GitHub; three-component - # versions are from CRAN - components <- strsplit(loadedversion, "[.-]")[[1]] - remote <- if (length(components) == 4L) - paste("rstudio/renv", loadedversion, sep = "@") + # check whether requested version 'version' matches loaded version of renv + sha <- attr(version, "sha", exact = TRUE) + valid <- if (!is.null(sha)) + renv_bootstrap_validate_version_dev(sha, description) else - paste("renv", loadedversion, sep = "@") + renv_bootstrap_validate_version_release(version, description) + + if (valid) + return(TRUE) + + # the loaded version of renv doesn't match the requested version; + # give the user instructions on how to proceed + remote <- if (!is.null(description[["RemoteSha"]])) { + paste("rstudio/renv", description[["RemoteSha"]], sep = "@") + } else { + paste("renv", description[["Version"]], sep = "@") + } + + # display both loaded version + sha if available + friendly <- renv_bootstrap_version_friendly( + version = description[["Version"]], + sha = description[["RemoteSha"]] + ) fmt <- paste( "renv %1$s was loaded from project library, but this project is configured to use renv %2$s.", - "Use `renv::record(\"%3$s\")` to record renv %1$s in the lockfile.", - "Use `renv::restore(packages = \"renv\")` to install renv %2$s into the project library.", + "- Use `renv::record(\"%3$s\")` to record renv %1$s in the lockfile.", + "- Use `renv::restore(packages = \"renv\")` to install renv %2$s into the project library.", sep = "\n" ) - - msg <- sprintf(fmt, loadedversion, version, remote) - warning(msg, call. = FALSE) + catf(fmt, friendly, renv_bootstrap_version_friendly(version), remote) FALSE } + renv_bootstrap_validate_version_dev <- function(version, description) { + expected <- description[["RemoteSha"]] + is.character(expected) && startswith(expected, version) + } + + renv_bootstrap_validate_version_release <- function(version, description) { + expected <- description[["Version"]] + is.character(expected) && identical(expected, version) + } + renv_bootstrap_hash_text <- function(text) { hashfile <- tempfile("renv-hash-") @@ -663,6 +854,12 @@ local({ # warn if the version of renv loaded does not match renv_bootstrap_validate_version(version) + # execute renv load hooks, if any + hooks <- getHook("renv::autoload") + for (hook in hooks) + if (is.function(hook)) + tryCatch(hook(), error = warnify) + # load the project renv::load(project) @@ -678,7 +875,7 @@ local({ return(profile) # check for a profile file (nothing to do if it doesn't exist) - path <- renv_bootstrap_paths_renv("profile", profile = FALSE) + path <- renv_bootstrap_paths_renv("profile", profile = FALSE, project = project) if (!file.exists(path)) return(NULL) @@ -802,12 +999,91 @@ local({ } + renv_bootstrap_version_friendly <- function(version, shafmt = NULL, sha = NULL) { + sha <- sha %||% attr(version, "sha", exact = TRUE) + parts <- c(version, sprintf(shafmt %||% " [sha: %s]", substring(sha, 1L, 7L))) + paste(parts, collapse = "") + } + + renv_bootstrap_exec <- function(project, libpath, version) { + if (!renv_bootstrap_load(project, libpath, version)) + renv_bootstrap_run(version, libpath) + } + + renv_bootstrap_run <- function(version, libpath) { + + # perform bootstrap + bootstrap(version, libpath) + + # exit early if we're just testing bootstrap + if (!is.na(Sys.getenv("RENV_BOOTSTRAP_INSTALL_ONLY", unset = NA))) + return(TRUE) + + # try again to load + if (requireNamespace("renv", lib.loc = libpath, quietly = TRUE)) { + return(renv::load(project = getwd())) + } + + # failed to download or load renv; warn the user + msg <- c( + "Failed to find an renv installation: the project will not be loaded.", + "Use `renv::activate()` to re-initialize the project." + ) + + warning(paste(msg, collapse = "\n"), call. = FALSE) + + } + + + renv_bootstrap_in_rstudio <- function() { + commandArgs()[[1]] == "RStudio" + } + + # Used to work around buglet in RStudio if hook uses readline + renv_bootstrap_flush_console <- function() { + tryCatch({ + tools <- as.environment("tools:rstudio") + tools$.rs.api.sendToConsole("", echo = FALSE, focus = FALSE) + }, error = function(cnd) {}) + } renv_json_read <- function(file = NULL, text = NULL) { + jlerr <- NULL + + # if jsonlite is loaded, use that instead + if ("jsonlite" %in% loadedNamespaces()) { + + json <- catch(renv_json_read_jsonlite(file, text)) + if (!inherits(json, "error")) + return(json) + + jlerr <- json + + } + + # otherwise, fall back to the default JSON reader + json <- catch(renv_json_read_default(file, text)) + if (!inherits(json, "error")) + return(json) + + # report an error + if (!is.null(jlerr)) + stop(jlerr) + else + stop(json) + + } + + renv_json_read_jsonlite <- function(file = NULL, text = NULL) { text <- paste(text %||% read(file), collapse = "\n") + jsonlite::fromJSON(txt = text, simplifyVector = FALSE) + } + + renv_json_read_default <- function(file = NULL, text = NULL) { # find strings in the JSON + text <- paste(text %||% read(file), collapse = "\n") pattern <- '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]' locs <- gregexpr(pattern, text, perl = TRUE)[[1]] @@ -838,8 +1114,9 @@ local({ # transform the JSON into something the R parser understands transformed <- replaced - transformed <- gsub("[[{]", "list(", transformed) - transformed <- gsub("[]}]", ")", transformed) + transformed <- gsub("{}", "`names<-`(list(), character())", transformed, fixed = TRUE) + transformed <- gsub("[[{]", "list(", transformed, perl = TRUE) + transformed <- gsub("[]}]", ")", transformed, perl = TRUE) transformed <- gsub(":", "=", transformed, fixed = TRUE) text <- paste(transformed, collapse = "\n") @@ -908,35 +1185,17 @@ local({ # construct full libpath libpath <- file.path(root, prefix) - # attempt to load - if (renv_bootstrap_load(project, libpath, version)) - return(TRUE) - - # load failed; inform user we're about to bootstrap - prefix <- paste("# Bootstrapping renv", version) - postfix <- paste(rep.int("-", 77L - nchar(prefix)), collapse = "") - header <- paste(prefix, postfix) - message(header) - - # perform bootstrap - bootstrap(version, libpath) - - # exit early if we're just testing bootstrap - if (!is.na(Sys.getenv("RENV_BOOTSTRAP_INSTALL_ONLY", unset = NA))) - return(TRUE) - - # try again to load - if (requireNamespace("renv", lib.loc = libpath, quietly = TRUE)) { - message("* Successfully installed and loaded renv ", version, ".") - return(renv::load()) + if (renv_bootstrap_in_rstudio()) { + # RStudio only updates console once .Rprofile is finished, so + # instead run code on sessionInit + setHook("rstudio.sessionInit", function(...) { + renv_bootstrap_exec(project, libpath, version) + renv_bootstrap_flush_console() + }) + } else { + renv_bootstrap_exec(project, libpath, version) } - # failed to download or load renv; warn the user - msg <- c( - "Failed to find an renv installation: the project will not be loaded.", - "Use `renv::activate()` to re-initialize the project." - ) - - warning(paste(msg, collapse = "\n"), call. = FALSE) + invisible() }) diff --git a/renv/settings.json b/renv/settings.json new file mode 100644 index 0000000..f836f3f --- /dev/null +++ b/renv/settings.json @@ -0,0 +1,19 @@ +{ + "bioconductor.version": null, + "external.libraries": [], + "ignored.packages": [], + "package.dependency.fields": [ + "Imports", + "Depends", + "LinkingTo" + ], + "ppm.enabled": null, + "ppm.ignored.urls": [], + "r.version": [], + "snapshot.type": "implicit", + "use.cache": true, + "vcs.ignore.cellar": true, + "vcs.ignore.library": true, + "vcs.ignore.local": true, + "vcs.manage.ignores": true +}