[Pythonmac-SIG] MacPython on jaguar

Jack Jansen Jack.Jansen@oratrix.com
Thu, 10 Oct 2002 23:55:06 +0200


On donderdag, oktober 10, 2002, at 10:47 , Neil Mayhew wrote:

> on 10/10/2002 2:16 PM, Jack Jansen wrote:
>
>> The loop to create argv uses GetNextEvent() (not=20
>> WaitNextEvent) , and it
>> simply calls it 100 times... So, it is conceivable that that=20
>> loop finishes
>> before the finder has been scheduled and had a chance to send=20
>> its AppleEvent.
>
> Based on what I am seeing, I=92d say it=92s highly likely this is=20
> the cause of
> the problem.
>
>> I'll change the loop to use WNE()
>
> Rather than looping a fixed number of times, wouldn't it be=20
> better to wait
> until an event does arrive?

It's been *very* long, but I remember that the loop was needed,=20
although I don't remember why. Maybe the CodeWarrior debugger=20
doesn't send the OAPP event if you run a program? I'm sorry, I=20
simply don't remember. But, in the upcoming 222b1 (due in a few=20
minutes) I've changed the loop to use 100 WaitNextEvent calls=20
with a 1-tick timeout. Let's see whether that fixes the problem.

And thanks for trying to up the loop count, that makes me more=20
hopeful that the solution I tried will work...
> --
- Jack Jansen        <Jack.Jansen@oratrix.com>       =20
http://www.cwi.nl/~jack -
- If I can't dance I don't want to be part of your revolution --=20
Emma Goldman -