Using /Library/Python/2.7/site-packages/pip-9.0.1-py2.7.egg
Processing dependencies for pip
Finished processing dependencies for pip
Admins-MacBook-Pro:Desktop admin$ pip install python-tk
Collecting python-tk
Could not find a version that satisfies the requirement python-tk (from versions: )
No matching distribution found for python-tk
Admins-MacBook-Pro:Desktop admin$
Admins-MacBook-Pro:Desktop admin$ python
Python 2.7.10 (default, Oct 23 2015, 19:19:21)
[GCC 4.2.1 Compatible Apple LLVM 7.0.0 (clang-700.0.59.5)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> exit()
Admins-MacBook-Pro:Desktop admin$ sudo apt-get install python3-tk #python3
Password:
sudo: apt-get: command not found
Admins-MacBook-Pro:Desktop admin$ import Tkinter as tk
-bash: import: command not found
Admins-MacBook-Pro:Desktop admin$ from Tkinter import *
from: can't read /var/mail/Tkinter
Admins-MacBook-Pro:Desktop admin$
Admins-MacBook-Pro:Desktop admin$
Asked
Active
Viewed 1.5k times
-2
Bryan Oakley
- 341,422
- 46
- 489
- 636
E MA
- 57
- 1
- 1
- 2
-
1possible duplicate of https://stackoverflow.com/questions/12221788/how-to-get-tkinter-working-on-mac#12222271, https://stackoverflow.com/questions/7498658/importerror-when-importing-tkinter-in-python, https://stackoverflow.com/questions/25905540/importerror-no-module-named-tkinter – Vasif Aug 22 '17 at 22:31
-
Mind that in python3 the module is all lowercase `tkinter` and if the module is missing, [install it using brew](https://stackoverflow.com/a/67037737/383793) – Chris Wesseling Oct 04 '21 at 14:59
-
Does this answer your question? [How to get Tkinter working on mac](https://stackoverflow.com/questions/12221788/how-to-get-tkinter-working-on-mac) – Chris Wesseling Oct 04 '21 at 14:59