Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

No module named 'virtualenv.activation.xonsh'

Tags:

python

pipenv

I triyed to execute pipenv shell in a new environtment and I got the following error:

Loading .env environment variables…
Creating a virtualenv for this project…
Using /home/user/.pyenv/shims/python3.9 (3.9.7) to create virtualenv…
⠋ModuleNotFoundError: No module named 'virtualenv.activation.xonsh'
Error while trying to remove the /home/user/.local/share/virtualenvs/7t env: 
No such file or directory

Virtualenv location: 
Warning: Your Pipfile requires python_version 3.9, but you are using None (/bin/python).
  $ pipenv check will surely fail.
Spawning environment shell (/usr/bin/zsh). Use 'exit' to leave.

I tried to remove pipenv, install python with pienv create an alias to python, but anything works.

Any idea, I got the same error in existing environment, I tried to remove all environments folder but nothing.

Thanks.

like image 503
Tlaloc-ES Avatar asked Sep 02 '25 05:09

Tlaloc-ES


1 Answers

Removing the virtualenv pip package worked for me (on Ubuntu WSL)

pip uninstall virtualenv
like image 175
Chris Marais Avatar answered Sep 04 '25 19:09

Chris Marais