Skip to content

Commit 6592fa7

Browse files
authored
Merge pull request #1667 from rstudio/fix/virtualenv_create
Fix error in `virtualenv_create()`
2 parents 74627cd + 5c768b2 commit 6592fa7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

R/virtualenv.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -450,7 +450,7 @@ virtualenv_module <- function(python) {
450450
if (python_has_module(python, "easy_install")) {
451451
commands$push(paste("$", python, "-m easy_install --upgrade --user pip"))
452452
} else if (is_ubuntu() && dirname(python) == "/usr/bin") {
453-
package <- if (py_version < 3) "python-pip" else "python3-pip"
453+
package <- if (py_version < "3") "python-pip" else "python3-pip"
454454
commands$push(paste("$ sudo apt-get install", package))
455455
} else {
456456
commands$push("$ curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py")
@@ -462,7 +462,7 @@ virtualenv_module <- function(python) {
462462
# then, recommend installation of virtualenv or venv with pip
463463
commands$push(paste("Install", modules[[1]], "with:"))
464464
if (is_ubuntu() && dirname(python) == "/usr/bin") {
465-
package <- if (py_version < 3) "python-virtualenv" else "python3-venv"
465+
package <- if (py_version < "3") "python-virtualenv" else "python3-venv"
466466
commands$push(paste("$ sudo apt-get install", package))
467467
} else {
468468
commands$push(paste("$", python, "-m pip install --upgrade --user", module))

0 commit comments

Comments
 (0)