Reputation: 232
i know there have already been many such questions asked on this forum but i couldnt find any that helped my particular case.
i am trying to install tkinter(and some other packages) using pip install on windows 10 cmd. but it gives the error
pip install tkinter
Could not find a version that satisfies the requirement tkinter (from
versions: )
No matching distribution found for tkinter
how do i install it? i get the same error for some other packages too. what is the solution that works for any and all future packages i install?
Upvotes: 8
Views: 18467
Reputation: 898
When installing packages with pip
, it automatically collects any dependencies of these packages, if they aren't already installed. For example, if you install SciPy
and you haven't installed NumPy
, pip will automatically install NumPy
, because it is listed in SciPy
's dependencies.
The error you got happens, when one of the listed requirements of the package you want to install is not availible. This can have a number of causes:
The required package is not availible on PyPi.
The required package or the package you want to install is not compatible with your version of python.
You typed the wrong package name.
When i try pip install tkinter
, i get the same error. The reason for that is that tkinter is already included in the python standard library (at least for python 3.x). You shouldn't have to install it. You can verify that tkinter is working by a simple example like
import tkinter as tk
root = tk.Tk()
root.mainloop()
Upvotes: 5