Help with Virtualenv

cmo17

New Member
Joined
Nov 3, 2020
Messages
8
Reaction score
0
Credits
51
Hello, sorry I am new to linux. The issue I am running into is with installing virtualenv. I am using windows (ubuntu) for reference.

  1. First I tried this which does not work for windows or the version I have (im not sure)
    $ virtualenv venv
    Code:
    Command 'virtualenv' not found, but can be installed with: sudo apt install python3-virtualenv
  2. I followed the directions and did this next (cannot locate package)
$ sudo apt install python3-virtualenv
Code:
          [sudo] password for codebind:

          Reading package lists... Done

          Building dependency tree

          Reading state information... Done

          E: Unable to locate package python3-virtualenv

I have tried some other various of step 2 as well and cannot get anything to work. Any help is appreciated. Thanks
 


You'll need Python3 and PIP installed and then:

Code:
pip3 install virtualenv

You can find out which python you have installed with:

Code:
which python
 
You'll need Python3 and PIP installed and then:

Code:
pip3 install virtualenv

You can find out which python you have installed with:

Code:
which python
Thanks for the reply. When I try to install pip this is what I get
1604464363956.png
 
Sometimes it's just called pip. I have seen on a few occasions, it was named specifically
for a specific version of python. i.e. pip 3.7

What is the output of python -V or python3 -V

It's possible you have both.
 
Sometimes it's just called pip. I have seen on a few occasions, it was named specifically
for a specific version of python. i.e. pip 3.7

What is the output of python -V or python3 -V

It's possible you have both.
1604499927555.png
 
Have you tried to install python-pip without the 3?
 
I have to say I would be very surprised if Ubuntu doesn't have pip.

There is another option, you have to download a python script called get-pip.py.
I have used it. The problem is, if Ubuntu does have pip, it can conflict with this version.

 
WSL isn't real linux. All of the OS options and packages are not available in WSL.
It is just a shell with a small subset of tools.
 
WSL isn't real linux. All of the OS options and packages are not available in WSL.
It is just a shell with a small subset of tools.
I see! I will uninstall that. Do you have a recommended option for windows I should I install?
 
If you have enough RAM, hard drive space, and at least 1 multi-thread 2 core system, you can run VirtualBox (it's free) and install a Linux VM.
 
If you have enough RAM, hard drive space, and at least 1 multi-thread 2 core system, you can run VirtualBox (it's free) and install a Linux VM.
Is there a tutorial for this somewhere? Thanks
 
It is a WSL

Ah, that explains it. Not a clue, sadly. I've never touched WSL in my life. In the future, you might want to preface any questions with that information. It'll save a ton of confusion.
 

Members online


Top