[Pythonmac-SIG] How to prevent CommandError -609: connectionInvalid

has hengist.podd at virgin.net
Sat Mar 28 13:47:58 CET 2009


Rajanikanth Jammalamadaka wrote:

> Could somebody tell me how to prevent this
> appscript.reference.CommandError: CommandError -609: connectionInvalid
>
> from happening.
>
> Is there a time out variable that I can increase?


Assuming this is a genuine timeout error and not the target  
application unexpectedly quitting while handling an event [1], you can  
modify the timeout delay by adding a 'timeout' keyword argument to  
your command. See Chapter 11 of the appscript manual for details.

HTH

has

[1] AESendMessage() often reports event timeout errors (-1712)  
incorrectly as connection invalid errors (-609).
-- 
Control AppleScriptable applications from Python, Ruby and ObjC:
http://appscript.sourceforge.net



More information about the Pythonmac-SIG mailing list