Cannot import tkinter after installing Python 3 with pyenv
For MacOS you can try installing tcl-tk
via homebrew and then activating the env. vars. mentioned in its caveats section, as detailed in this answer.
This problem seems to be solved now using the approach described in this post:
- First uninstall Python 3.4.2 :
pyenv uninstall 3.4.2
, then - Run
sudo apt-get install tk-dev
- And reinstall Python 3.4.2 :
pyenv install 3.4.2