You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello! I am using is_installed() and check_installed() in a pkg and they are great, thank you!
I noticed in the case where you want to check multiple packages AND you specify both version and compare arguments AND there is a mix of versions to check and no version to check, you get an unexpected warning. (A bit of an edge edge case.)
Example below! If you'd like, I can investigate and submit a PR. But I know sometimes it's just easier to update as the maintainer 😝
Thank you!
packageVersion("rlang")
#> [1] '1.1.3'# throws a warning unexpectedlyrlang::is_installed(
pkg= c("dplyr", "tidyr"),
version= c("1.0.0", NA_character_),
compare= c(">=", NA_character_)
)
#> Warning in info$cmp[has_version] <- compare: number of items to replace is not#> a multiple of replacement length#> [1] TRUE# similar situation, but no warningrlang::is_installed(pkg="tidyr", version=NA_character_, compare=NA_character_)
#> [1] TRUE# when version/compare fully specified, no warningrlang::is_installed(
pkg= c("dplyr", "tidyr"),
version= c("1.0.0", "1.0.0"),
compare= c(">=", ">=")
)
#> [1] TRUE
Hello! I am using
is_installed()
andcheck_installed()
in a pkg and they are great, thank you!I noticed in the case where you want to check multiple packages AND you specify both
version
andcompare
arguments AND there is a mix of versions to check and no version to check, you get an unexpected warning. (A bit of an edge edge case.)Example below! If you'd like, I can investigate and submit a PR. But I know sometimes it's just easier to update as the maintainer 😝
Thank you!
Created on 2024-03-03 with reprex v2.1.0
The text was updated successfully, but these errors were encountered: