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
Reticulate not detecting python3-venv even though it is installed so cant create virtualenvs #1495
Comments
What is the output of |
The output of that is pretty large. I slimmed it down by searching for anything matching venv:
|
Tentative fix in fix/ubuntu22-venv, can you please confirm it works for you? remotes::install_github("rstudio/reticulate@fix/ubuntu22-venv") |
That works for me. Output below:
Thanks! |
When I install reticulate (in RStudio 2023.09.1) and try to create a virtualenv I see the following error message:
Install venv with:
$ sudo apt-get install python3-venv
When I try to install the above package Ubuntu (Ubuntu 22.04.3 LTS) tells me it is already installed. Digging into the reticulate code it looks like the issue might be this line here:
reticulate/R/virtualenv.R
Line 432 in 99f14f2
The regex uses start and end line characters (^ $) that seem to cause it to fail when detecting the installed package.
My session description is attached below
R version 4.1.2 (2021-11-01)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 22.04.3 LTS
Matrix products: default
BLAS: /usr/lib/x86_64-linux-gnu/blas/libblas.so.3.10.0
LAPACK: /usr/lib/x86_64-linux-gnu/lapack/liblapack.so.3.10.0
locale:
[1] LC_CTYPE=en_GB.UTF-8 LC_NUMERIC=C LC_TIME=en_GB.UTF-8 LC_COLLATE=en_GB.UTF-8 LC_MONETARY=en_GB.UTF-8
[6] LC_MESSAGES=en_GB.UTF-8 LC_PAPER=en_GB.UTF-8 LC_NAME=C LC_ADDRESS=C LC_TELEPHONE=C
[11] LC_MEASUREMENT=en_GB.UTF-8 LC_IDENTIFICATION=C
attached base packages:
[1] stats graphics grDevices utils datasets methods base
loaded via a namespace (and not attached):
[1] compiler_4.1.2 here_1.0.1 Matrix_1.4-0 rprojroot_2.0.3 tools_4.1.2 rappdirs_0.3.3 Rcpp_1.0.11
[8] reticulate_1.34.0 grid_4.1.2 jsonlite_1.8.7 rlang_1.1.1 png_0.1-8 lattice_0.20-45
The text was updated successfully, but these errors were encountered: