diff --git a/NEWS.md b/NEWS.md index 7c881d83..40c85b30 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,5 +1,8 @@ # reticulate (development version) +- Fixed an issue where `virtualenv_starter()` would not discover a + custom built Python (#1704). + # reticulate 1.40.0 - The S3 classes for some (rarely encountered) Python objects have changed. diff --git a/R/virtualenv.R b/R/virtualenv.R index 2a97a311..53198eb5 100644 --- a/R/virtualenv.R +++ b/R/virtualenv.R @@ -551,6 +551,7 @@ virtualenv_starter <- function(version = NULL, all = FALSE) { length(v) != 1L || !startsWith(v, "Python ")) return(NA_character_) + v <- sub("\\+.*$", "", v) substr(v, 8L, 999L) }, error = function(e) NA_character_), ""), strict = FALSE) df <- data.frame(version = v, path = p,