rstudio / tensorflow.rstudio.com

https://tensorflow.rstudio.com
9 stars 12 forks source link

virtualenv_path not found #61

Closed xvtstephen closed 1 year ago

xvtstephen commented 1 year ago

I have python in /usr/bin/python on linux mint 21.1 (ubuntu 22 jammy) and when I call

virtualenv_create("r-reticulate", python ="/usr/bin/python/") Error in system2(python, args, stdout = TRUE, stderr = FALSE) :

I tried to step through the function and get an error on

virtualenv_path(envname) Error in virtualenv_path(envname) : could not find function "virtualenv_path" listing the reticulate namespace does not show a virtualenv_path function. also: $ which virtualenv /usr/local/bin/virtualenv getOption("reticulate.virtualenv.module") NULL

Please, help. Thanks

t-kalinowski commented 1 year ago

Hmm, I can't reproduce locally. Perhaps something went wrong with the package installation? Can you please reinstall reticulate:

install.packages("reticulate")

Also, why is there a trailing / in /usr/bin/python/? Should that just be /usr/bin/python?

xvtstephen commented 1 year ago

Hello, you are correct about the slash, it should not be there. but where is the function virtualenv_path() called in virtualenv_create()?

also should getOption("reticulate.virtualenv.module") etc find something?

I will try the same on another box. I was able to install everything from within Rstudio. Cheers Stephen

On Fri, 2023-08-11 at 08:59 -0700, Tomasz Kalinowski wrote:

Hmm, I can't reproduce locally. Perhaps something went wrong with the> package installation? Can you please reinstall reticulate:

install.packages("reticulate") Also, why is there a trailing / in /usr/bin/python/? Should that just> be /usr/bin/python?

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.

t-kalinowski commented 1 year ago

Both virtualenv_path and virtualenv_create are from the reticulate package.

Glad you got it working.