I have been following this tutorial (https://tutorial.djangogirls.org/en/django_installation/) to learn some python but I have become stuck at the 'Django installation' step. I have managed to create a virtual environment and the .txt file but trying
(myvenv) (base) PS C:\users\JD\djangogirls> pip install -r requirements.txt
I get the error 'could not find version that satisfies requirement'and'no matching distribution found'. This error occurs when I have entered versions 2.2.4 & 3.0.5 of Django into the .txt file.
Have also just tried 'pip install django' and have come across the same errors.
Have tried in the windows command prompt but i get an error stating pip is not recognized as an internal or external command.
I have python 3.7.6 installed.
Any help is very much appreciated
After enabling your virtualenv follow to following code
pip install django==2.2.2
Add django==2.2.2 in requirements.txt
pip install -r reqirements.txt
Related
I'm new to macos and trying to get a dev environment going...I need pip but getting an error message with just pip.
Getting error pkg_resources.DistributionNotFound: The 'pip==20.0.2' distribution was not found and is required by the application
Python3 was installed with macos and I tried to install 2.x version and made it the global default. I think that's why I'm getting the above error.
I uninstalled the 2.x python using pyenv.
How can I remove pip (i've got pip, pip3 and pip 3.8) and start over.
Thanks.
Can you try removing pip using this in the directory where pip pacakge is installed?
sudo rm -r pip <Version Number>
You can get the directory where pip is installed with this: which pip and then cd into that path and run the above command.
I am trying to get the requirements for my code into a local package following this guide:
https://docs.aws.amazon.com/lambda/latest/dg/python-package.html
In step one when I try to run a similar command pip install --target ./package -r requirements.txt it fails with the following error "ERROR: Can not combine '--user' and '--target'". I have no idea why it is complaining.
I am using PyCharm, with a conda environment, and I am running the commands in the PyCharm Terminal.
I found this question/answer: PIP Install: Cannot combine --user and --target
but I am not using the Microsoft store version of python. My PyCharm project is configured to use the Anaconda python interpreter.
Update: I was able to get the command to succeed by installing pip inside of the conda environment I am using but I am still not sure why it was an issue before. If anyone has any details it would be appreciated.
Let me know what details are needed, thanks.
If you are trying to install them all in the same directory try:
pip install -r requirements.txt -t ./package
I have installed pip and setuptools installed on my Mac with pip. While I am installing Ipython with commands: sudo install ipython,Errors following:Link. I have tried these commands: sudo -H pip install ipython --ignore-installed setuptools-1.1.6
,it also came out errors: Could not find a version that satisfies the requirement setuptools-1.1.6 (from versions: ) No matching distribution found for setuptools-1.1.6.
I have googled similar problems,but haven't solved it. Thanks for help.
I recommend using virtualenv. You can install it and then inside the project folder run virtualenv .. This will create a few new folders. Now you can run ./bin/pip install ipython which will install ipython only on that folder. Can you do that and let us know if it worked? You can run all python apps using ./bin/python app.py or by adding #!bin/python.
I have been trying to install django 1.8 on virtualenv, i performed the following steps:
changed to my project directory
changed to scripts folder of virtual environment which I created
activated the virtual env
typed command: pip install django == 1.8
Nothing worked
also, tried pip install django and easy_install django, however, none worked.
Could you please help me out ?
Can you try this command:
sudo pip install django==1.8
One problem could be that the command line doesn't tokenize the command correctly. Try the following (with the quotes around the requirement specifier):
pip install "django==1.8"
Like you haven't shared the output error, I suggest some actions:
Try to use the absolute path or add the path of your pip installation to your PATH system variable:
Go to CMD change the python instalation directory C:\>cd \Python27\Scripts and type C:\Python27\Scripts>pip -h
If works well you can use the absolute path C:\Python27\Scripts>pip install "django==1.8" or add the path of your pip installation to your PATH variable using the command above:
C:\Python27\Scripts>setx PATH "%PATH%;C:\Python27\Scripts"
SUCCESS: Specified value was saved.
Another attempt is updating pip scripts using easy_install
(FlaskEnv27) E:\Projects\FlaskEnv27\Scripts>easy_install pip
Searching for pip
Best match: pip 1.5.6
Removing pip 1.3.1 from easy-install.pth file
Adding pip 1.5.6 to easy-install.pth file
Installing pip-script.py script to E:\Projects\FlaskEnv27\Scripts
Installing pip.exe script to E:\Projects\FlaskEnv27\Scripts
Installing pip.exe.manifest script to E:\Projects\FlaskEnv27\Scripts
Installing pip3.4-script.py script to E:\Projects\FlaskEnv27\Scripts
Installing pip3.4.exe script to E:\Projects\FlaskEnv27\Scripts
Installing pip3.4.exe.manifest script to E:\Projects\FlaskEnv27\Scripts
Installing pip3-script.py script to E:\Projects\FlaskEnv27\Scripts
Installing pip3.exe script to E:\Projects\FlaskEnv27\Scripts
Installing pip3.exe.manifest script to E:\Projects\FlaskEnv27\Scripts
Using c:\python27\lib\site-packages
Processing dependencies for pip
Finished processing dependencies for pip
Getting the attached error when am trying to install Django.
throws up the following error
"could not find the version that satisfies the requirement install"
cd c:\Users\viku.jain\Downloads
python get-pip.py
pip install django==1.9
or you can install django using Git
Make sure that you have Git installed and that you can run its commands from a shell
git clone git://github.com/django/django.git
pip install -e django/
the you can start your work by django-admin utility command