Tiny Core Extensions > TCE Talk
How do I install tkinter?
saladin:
I did try tk. It did successfully install something, but you're supposed to be able to verify a tkinter installation with
--- Code: ---tkinter._test()
--- End code ---
That gives me the error: "NameError: name 'tkinter' is not defined"
When I try
--- Code: ---tk._test()
--- End code ---
That gives me the error: "AttributeError: module 'tk' has no attribute '_test'".
If I run
--- Code: ---dir(tk)
--- End code ---
it's only giving me nine objects, and they don't look like what I should be getting with tkinter. I think this is a completely different module with a similar name.
I'm thinking I'll have to reinstall python from scratch.
Rich:
Hi saladin
The build script for python shows tk-dev.tcz geting loaded:
http://tinycorelinux.net/10.x/x86_64/tcz/src/python3.7/python3.7.tcz.build-dep
The python .list file shows some tkinter files included:
http://tinycorelinux.net/10.x/x86_64/tcz/python3.7.tcz.list
Juanito:
Here’s how python3.6 was compiled: http://www.tinycorelinux.net/12.x/x86_64/tcz/src/python3.6/compile_python3.6
This works:
--- Code: ---tce-load -i python3.6 tk8.6
python3.6m -m tkinter
--- End code ---
..and brings up a gui box saying "click me".
saladin:
Ah yes, that works for me. Thank you!
I guess the problem was that I was using python 3.7.
Navigation
[0] Message Index
[*] Previous page
Go to full version