I am trying to add a GUI input box and I found out that the way you do that is by using a module called tkinter
. While I was trying to install it on my arch linux machine through the ActivePython
package I got the following error:
Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/lib/python3.6/tkinter/__init__.py", line 36, in <module> import _tkinter # If this fails your Python may not be configured for Tk ImportError: libtk8.6.so: cannot open shared object file: No such file or directory shell returned 1\
All you need to do is to install the tkinter package. Now universal precompiled packages such as ActivePython will not work, well at least it didn't work for me. I don't know if this problem occurs in other OSes but I know the solution for Linux: Install the Tk package from the terminal.
In Arch, Tk is available in the Arch repository. You don't need aur for this, just type on the terminal:
sudo pacman -S tk
If you are on another Linux distro such as Debian or a Debian based distro you will probably have to find a PPA repository online and in Debian based distros just type on the terminal:
sudo apt-get install tk
Which applies to all distros.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With