- Download the package
- unzip it if it is zipped
cdinto the directory containing setup.py- If there are any installation instructions contained in documentation, read and follow the instructions OTHERWISE
- type in
python setup.py install
You may need administrator privileges for step 5. What you do here depends on your operating system. For example in Ubuntu you would say sudo python setup.py install
EDIT- thanks to kwatford (see first comment)
To bypass the need for administrator privileges during step 5 above you may be able to make use of the --user flag. This way you can install the package only for the current user.
The docs say:
Files will be installed into subdirectories of site.USER_BASE (written as userbase hereafter). This scheme installs pure Python modules and extension modules in the same location (also known as site.USER_SITE).
More details can be found here: http://docs.python.org/2.7/install/index.html
Answer from Sheena on Stack Overflow- Download the package
- unzip it if it is zipped
cdinto the directory containing setup.py- If there are any installation instructions contained in documentation, read and follow the instructions OTHERWISE
- type in
python setup.py install
You may need administrator privileges for step 5. What you do here depends on your operating system. For example in Ubuntu you would say sudo python setup.py install
EDIT- thanks to kwatford (see first comment)
To bypass the need for administrator privileges during step 5 above you may be able to make use of the --user flag. This way you can install the package only for the current user.
The docs say:
Files will be installed into subdirectories of site.USER_BASE (written as userbase hereafter). This scheme installs pure Python modules and extension modules in the same location (also known as site.USER_SITE).
More details can be found here: http://docs.python.org/2.7/install/index.html
To further explain Sheena's answer, I needed to have setup-tools installed as a dependency of another tool e.g. more-itertools.
Download
Click the Clone or download button and choose your method. I placed these into a dev/py/libs directory in my user home directory. It does not matter where they are saved, because they will not be installed there.
- setuptools: https://github.com/pypa/setuptools
- more-itertools: https://github.com/erikrose/more-itertools
Installing setup-tools
You will need to run the following inside the setup-tools directory.
python bootstrap.py
python setup.py install
General dependencies installation
Now you can navigate to the more-itertools direcotry and install it as normal.
- Download the package
- Unpackage it if it's an archive
- Navigate (
cd ...) into the directory containingsetup.py - If there are any installation instructions contained in the documentation contained herein, read and follow the instructions OTHERWISE
- Type in:
python setup.py install
For security reasons pip is blocked by my employers proxy.
Is there a feasible way to install packages without pip?
I did some reading and found instructions that said to manually download the package and install it via an included setup.py script. However I can't seem to locate those package archives. I searched for paramiko and found the github page with the repository that has all the files but no downloadable package.
Any ideas?
python - Install a package without pip - Stack Overflow
Install packages without pip
Installing libraries and dependencies without Pip
Install packages without pip
Hi, I'm working with python as a beginner. My employer provided a laptop that has python installed. Since pip is not installed, is there any way to install a package with all its dependencies? (I dont have admin privileges)
EDIT: So I have managed to reinstall python 3.10.6 with pip. But when I try to install a package with pip (using 'pip install pandas'), I'm getting an error mentioning "SSL certificate verification failed". Can this be because of a firewall? because my internet connection is working fine.
I guess this question comes up frequently, but I didn't find anything that fits my situation.
I'm on a windows machine which is pretty much locked down, now I would like to install a few modules. So I thought I could just pip them, but no, I do not have any pip. Okay, no biggie, manually install pip. No, I cannot connect to the source since the installer from the command line tries to directly connect to the source, but I'm behind a proxy. Now I neither know the proxy name or server or port.
How do install anything in that python build?
I tried to install the pandas module via:
python path\to\module setup.py install
Works fine, but it told me it needs Cython. So I repeated the procedure:
python path\to\module setup.py install
But here I get the error:
can't find '__main__' module in 'path\to\module'
How do I rectify that?
I found this as a work around
python -m pip install ....
Python is an environmental variable. The laptop I'm working on is a work laptop that I need to return, but since my personal laptop died (no boot device was found was that last information it reported). I am probably not set up as an administrator on this device. Hope this might help you.
I think you have set it up correctly. For whatever package you are installing you need to very carefully read the full instructions. After you are sure that you have set it up correctly you can check by running a simple python script I found on this question:
Check if Python Package is installed
You would then just change the module name to the module you tried to install. Hopefully, this helps!
*EDIT You might also need to run the command terminal as an administrator depending on how your computer is set up.