PyQt: user interface freezed when using concurrent.futures.ThreadPoolExecutor

Chris Angelico rosuav at gmail.com
Fri Dec 12 02:42:30 EST 2014


On Fri, Dec 12, 2014 at 6:18 PM, Marko Rauhamaa <marko at pacujo.net> wrote:
> GUI developers have been doing event-driven programming for decades.
> That's an excellent preparation for network programming as well.
> Unfortunately, the minds of a generation of programmers were
> contaminated by the thread craze of the 1990's (Java and Windows NT).

Threads predate Java and NT, and with a much MUCH better
implementation, on OS/2. I don't consider my mind to have been
*contaminated* by the OS/2 threading model, which worked superbly.
Like all models, it has its limitations, but it's one worth getting
your head around IMO. Knowing when to use threads, when to use
processes, and when to keep everything in a single thread with some
kind of dispatch loop (and *which* dispatch loop) is a valuable skill.

But yes, the Windows threading model does have a number of annoying
flaws. And I don't remember how Java did things, except that I
struggled to find basic fundamental primitives like semaphores, and
had to use synchronized functions/objects instead.

ChrisA



More information about the Python-list mailing list