Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

is_installed does not work in R4.4 #443

Closed
egillax opened this issue Apr 25, 2024 · 1 comment
Closed

is_installed does not work in R4.4 #443

egillax opened this issue Apr 25, 2024 · 1 comment

Comments

@egillax
Copy link
Collaborator

egillax commented Apr 25, 2024

is_installed <- function (pkg, version = 0) {
  installed_version <- tryCatch(utils::packageVersion(pkg), 
                                error = function(e) NA)
  !is.na(installed_version) && installed_version >= version
}

In R 4.4.0 packageVersions are enforced to be characters so the comparison in the last line is invalid.

@egillax
Copy link
Collaborator Author

egillax commented Apr 29, 2024

Fixed by #446

@egillax egillax closed this as completed Apr 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant