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

Trouble using virtualenv_create #1509

Closed
Jsalas424 opened this issue Dec 4, 2023 · 2 comments
Closed

Trouble using virtualenv_create #1509

Jsalas424 opened this issue Dec 4, 2023 · 2 comments

Comments

@Jsalas424
Copy link

I'm trying to create a virtual environment, but get the following error

> virtualenv_create()
Error: Tools for managing Python virtual environments are not installed.

Install venv with:
$ sudo apt-get install python3-venv

Traceback:
4. stop(message, call. = FALSE)
 
3. virtualenv_module(python)
 
2. module %||% virtualenv_module(python)
 
1. virtualenv_create("r-reticulate")

So I installed python3-venv and tried again, got the same error. I proceeded reboot the system and attempted again, no luck. It looks like I do have it installed:

jon@rstudio:~$ sudo apt install python3-venv
[sudo] password for jon: 
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
python3-venv is already the newest version (3.10.6-1~22.04).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
jon@rstudio:~$ 

Reticulate Config:

> reticulate::py_config() 
python:         /usr/bin/python3
libpython:      /usr/lib/python3.10/config-3.10-x86_64-linux-gnu/libpython3.10.so
pythonhome:     //usr://usr
version:        3.10.12 (main, Nov 20 2023, 15:14:05) [GCC 11.4.0]
numpy:           [NOT FOUND]

NOTE: Python version was forced by RETICULATE_PYTHON_FALLBACK

How do I change the RETICULATE_PYTHON_FALLBACK?

This is in a Ubuntu Jammy Jellyfish VM dedicated to running RStudio Server.

@Jsalas424
Copy link
Author

Resolved by running python3 -m pip install virtualenv from bash.

@madsurgeon
Copy link

I had the same problem and could solve it the same way.
However, I think this should not be necessary and it should work also with the deb package.

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

2 participants