Pip installing to the wrong location - windows

I have installed one version of python a while ago, that was version 3.9.6. I recently installed version 3.11.1 as I am once again using python. I am trying to follow a tutorial on a webscraper and when I try to import the package "requests bs4" using the command python -m pip install requests bs4 I am told that the requirement is already satisfied. This is true that I have it installed in version 39, so my question is how do I direct pip to install it in the newest version of python that I currently have installed.
I tried to mess with the path by deleting version 39 off my path leaving only 311 but when I repeat the command above it returns that the same error as above. Ive looked at other problems very similar to mine but none quite the same, so when I try the solutions for others it doesn't quite work for me.
I am using windows 11

Related

Pip could not find a version that satisfies the requirement torch (from versions: none)

I am trying to install PyTorch on my Windows 11. I have Python 3.8.1, and pip 22.2.2. I have tried running the command py -m pip install torch, but it keeps returning the error:
ERROR: Could not find a version that satisfies the requirement torch (from versions: none)
ERROR: No matching distribution found for torch
I have gone through various StackOverflow posts and tried many different strategies. I even uninstalled and re-installed pip on my system using the get-pip.py file. Nothing seems to work.
Suggestions?
Just came across another post that mentioned how it needs to be the 64-bit version of Python to allow installation of PyTorch.
Just installed Python 3.9.13 with the 64-bit installer, and the installation worked. So, if anyone else is running into issues, would recommend first running python in command shell and checking whether it is 64 bit or 32 bit.

No matching distribution found for PySide2

I get this error when trying to install PySide2 from the Mac's Terminal:
ERROR: No matching distribution found for PySide2
I checked to make sure I have only 1 installation of Python on my MacBook. The screen shot shows the commands I used to check where Python is located and the recommended command I've seen online. I also have the latest version of pip and Python installed. I need PySide2 for PySimpleGUIQt. I also tried home brew, but it also couldn't locate PySide2, but found something called PySide#2 which I don't know if that's another name for PySide2.
It's cause you have python newest then pyside2 support. I try to install pyside2 on python 3.10 (3.9 same error) and get this error.
Proof:
But in 3.8 it's worked (but on Pypi https://pypi.org/project/PySide2/ it's must work and on 3.9 and 3.10)

AllenNLP Torch Version Unavailable

I am trying to install allennlp via pip on the latest version of macOS Catalina. The Python version is 3.9.0. The pip version is 20.2.4.
I was just able to install only a couple of weeks ago, but now I receive the following error when I run the command:
pip3 install allennlp allennlp-models
ERROR: No matching distribution found for torch<1.8.0,>=1.6.0 (from allennlp)
This is really bad because a time-sensitive project I am working on right now completely depends on allennlp working. I needed to reinstall due to some git issues, and my virtual env was reset. What can I do to resolve this issue?
Thanks.
EDIT: Somehow I ended up uninstalling 3.9 in homebrew and now I'm stuck at jsonnet. It errors out. I saw some posts about this issue, but none of the recommendations work.
EDIT2: I tried reinstalling brew's python 3.9. jsonnet standalone works again, but then I have the pytorch issue again.
I'm stuck in a loop. Neither the system macOS 3.8 python nor the latest 3.9 home-brew python works. I'd rather get the home-brew python working, but there's no valid version of torch available for that one apparently.
Do NOT accidentally use home-brew to download the latest Python 3.9. That isn't compatible with a lot of the required libraries.
Phew.

pip install fail - WinError 10061

Good Morning,
When attempting to install Python packages using "pip install ", I get the following error:
pip install error 1
The solution posted here works for most packages. Unfortunately, packages like usaddress, which download additional data during the installation process will result in the following error if the whl/tar is installed locally:
pip install error 2
I believe this is due to a firewall issue, so the solution here did not apply in this case, but may be helpful to others.
Any advice would be greatly appreciated.
*edit: I should have also mentioned that I updated my pip version this morning, after the installation failed.
Python version:
Python 3.6.4 | Anaconda, Inc. | (default, Jan 16 2018, 10:22:32) [MSC v.1900 64 bit (AMD64)] on win32
I found a solution. The issued turned out to be that although I downloaded and tried to pip install usaddress, that particular library had a few dependencies that also needed to be installed.
In the "pip install error 2" example from my question, where I tried to install a local copy of usaddress downloaded from pypi.org, you can see a red sentence at the bottom of the screenshot which says, "Could not find a version that satisfies the requirement future>=0.14". It means that I need to also install a package called "future", of version greater than or equal to 0.14. I went on to pypi.org, and was able to download and pip install the future package.
I found that some libraries have many dependencies, so it can take a few minutes to keep downloading and installing dependencies, but it was an effective way to get around the firewall.
I hope this saves somebody else some time!

installing python packages via pip issues

all I want is install pandas comfortably the package pandas via pip.
Inside python I get the following error message:
>>> pip install pandas
c:\python34\python.exe: No module named pip.__main__; 'pip' is a package and cannot be directly executed
Allright then I use the windows powershell
PS C:\Windows\system32> C:\Python34\python.exe -m pip install pandas
C:\Python34\python.exe: No module named pip
I had uninstalled and reinstalled python because I used at first the 32-Bit version but wanted 64-Bit, but had some issues so switched back to the 32-Bit version.
Before the reinstallation process I remember, that I could get pip to work but due to proxy issues didn't get very far. I am not a hundred percent positive but I might have gotten around the proxy issue at least.
Don't know what to do. Can somebody help.
thanks
Gerrit

Resources