Re: [Pythonmac-SIG] newbie: threads in PyObjC

2007-06-27 Thread Nehemiah Dacres
is this a question or an answer? is this a cocoa question or a PyObjC question? On 6/6/07, Tom Elliott <[EMAIL PROTECTED]> wrote: The kill() method is just a stub, written back when I thought the way to do this is for the main thread to terminate the worker thread. Now, after more reading, I r

[Pythonmac-SIG] newbie: threads in PyObjC

2007-06-06 Thread Tom Elliott
The kill() method is just a stub, written back when I thought the way to do this is for the main thread to terminate the worker thread. Now, after more reading, I realize it's better to have the worker test a condition periodically and exit (gracefully) if necessary. The withObject_ parame

Re: [Pythonmac-SIG] newbie: threads in PyObjC

2007-06-05 Thread Nehemiah Dacres
why does your Kill() method just have a pass statement? On 6/4/07, Ian Baird <[EMAIL PROTECTED]> wrote: > Tom, > > One problem you have here is that you need to create an instance of > the Threaded class to point to as your selector's target object. This > error is causing the message: > > 2007-06

Re: [Pythonmac-SIG] newbie: threads in PyObjC

2007-06-04 Thread Ian Baird
Tom, One problem you have here is that you need to create an instance of the Threaded class to point to as your selector's target object. This error is causing the message: 2007-06-04 20:53:11.415 PyThread[555] *** +[Threaded newThread:]: selector not recognized Plus, you have an unneeded NSAuto

[Pythonmac-SIG] newbie: threads in PyObjC

2007-06-04 Thread Tom Elliott
I'm using the PyObjC bridge. I have a computation that will be triggered by a user. It takes about 2 minutes depending on the database we're using. I'd like the user to be able to kill it if he decides it's taking too long. It seems like threading should be the solution. My simple demo