Quote:
Originally Posted by kovidgoyal
Perhaps a good solution is to raise an exception in FD.__init__ if the current thread is not the GUI thread.
|
That is a good idea. Clearly the intent is that the FD be instantiated on a thread with an event loop. There is supposed to be only one of those, so checking that invariant seems excellent. It also makes the changes to check for is_gui_thread completely correct, because the only possible signal recipient is that thread.
I assume you will make the change...
EDIT: should Dispatcher make the same check? It clearly is making the same assumption.