TK + cmd.cmdloop() in threads (was Re: howdoI: Exception in thread - terminating the program?
Ville Vainio
vvainio at karhu.tp.spt.fi
Mon Jul 23 01:32:27 EDT 2001
aahz at panix.com (Aahz Maruch) writes:
> I don't know what cmd.cmdloop() does, but if it's a TK thingie, what
No, cmd is a module that provides a line-oriented command interpreter
for console, nothing to do with TK.
http://www.python.org/doc/current/lib/module-cmd.html
> you're suggesting is a Bad Idea. Generally speaking, it's safest to
> have only one thread accessing any external resource (GUI, file handle,
> DB connection, etc).
But one would think it's reasonably safe to access a resource one
thread at a time, via mutexes etc. (and some external resource, such
as sockets, almost *have to* be accessed in multiple threads). Is TK
really such a beast that all the access to TK widgets have to be
called via it's own event loop?
--
Ville Vainio - http://www.tp.spt.fi/~vvainio - ICQ #115524762
Wild geese have no intention to cast a reflection
Water has no mind to assume their form
More information about the Python-list
mailing list