tkinter is not recognized as a library when importing it on a pycharm project using python 3.x ¿Why? tkinter is not recognized as a library when importing it on a pycharm project using python 3.x ¿Why? tkinter tkinter

tkinter is not recognized as a library when importing it on a pycharm project using python 3.x ¿Why?


Install it via apt.

sudo apt-get update && sudo apt install python3-tk

Works for me.


I fixed the issue by uninstalling PyCharm, and reinstalling it from the command line. The previous version I had installed it through the Linux Mint 19.1 Software Manager, and the version installed behaved in very strange ways; for instance it showed a completely different file tree to the one in my machine when trying to setup interpreters.

Here is the command I used, as per JetBrains recommendation:

sudo snap install [pycharm-professional|pycharm-community] --classic

Note: I had to install snap first :)


tkinter is a built in library in python.

install this package :'future' using this command :

pip install future

now import 'tkinter' in your project :

import tkinter