0

I have been searching for hours reading over various suggestions for this topic so please do not downvote me too fast. The closest thing i could find to a solution is here: Tkinter: "Python may not be configured for Tk". But the trouble is that they do not really explain on there how to get it for windows. Or exactly what part of the setup.py file to modify. Or which setup to modify, I have two setups in different locations. I am looking for some solid advice without harsh comments if I doing something ignorant. Please help... gently lol.

>>> import Tkinter
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "C:\csvn\Python25\lib\lib-tk\Tkinter.py", line 39, in <module>
    import _tkinter # If this fails your Python may not be configured for Tk
ImportError: No module named _tkinter

Edit for Johnathan:

>>> import sys
>>> print(sys.executable)
C:\csvn\Python25\python.exe
>>> print(sys.version)
2.7.1 (r271:86832, Jan  5 2016, 01:37:08) [MSC v.1600 64 bit (AMD64)]
>>> print(sys.path)
['', 'C:\\csvn\\Python25\\lib\\site-packages\\setuptools-18.0-py2.7.egg', 'C:\\c
svn\\Python25\\python27.zip', 'C:\\csvn\\Python25\\DLLs', 'C:\\csvn\\Python25\\l
ib', 'C:\\csvn\\Python25\\lib\\plat-win', 'C:\\csvn\\Python25\\lib\\lib-tk', 'C:
\\csvn\\Python25', 'C:\\csvn\\Python25\\lib\\site-packages', 'C:\\csvn\\Python25
\\lib\\site-packages\\win32', 'C:\\csvn\\Python25\\lib\\site-packages\\win32\\li
b', 'C:\\csvn\\Python25\\lib\\site-packages\\Pythonwin']
>>>
Community
  • 1
  • 1
Brodie
  • 11
  • 1
  • 1
  • 7

1 Answers1

0

Your title says python2.7 but your error message says python2.5 ... I'm guessing you are accidentally running the wrong python installation.

Novel
  • 13,406
  • 2
  • 25
  • 41
  • No the folder says 25 but the actually python it is running is 2.7 – Brodie Jun 30 '16 at 19:42
  • That would be very unusual. Show us the output of `import sys; print(sys.executable); print(sys.version); print(sys.path)` – Novel Jun 30 '16 at 19:51
  • @Johnathan I edited the question to include what you wanted – Brodie Jun 30 '16 at 19:54
  • Well, I'm stumped. Tkinter should be installed alongside python 2.7 in windows. I can only suggest that your reinstall python (and I'd recommend to the default C:\Python27). – Novel Jun 30 '16 at 20:06
  • Yeah, i thought to reinstall as well. I need to figure out some computer issues if that is the case because when i try to install the installer quits and says something went wrong... haha. – Brodie Jun 30 '16 at 20:07