[Pythonmac-SIG] Python+Automator?

Paul Berkowitz berkowit at silcom.com
Mon Jan 24 17:45:54 CET 2005


On 1/23/05 9:40 PM, "Bob Ippolito" <bob at redivi.com> wrote:

> 
> You're totally wrong here.  Automator actions *entirely separate* from
> applications!  Apple applications will not and can not support
> Automator actions directly, but they may ship with Automator actions.
> Whether these actions communicate with their application via Apple
> Events, Distributed Objects, or simply link with the same code and do
> things directly is beside the point entirely.
> 
> Objective-C actions can perform a superset of what AppleScript actions
> can do, including sending apple events to other applications, so your
> rant makes no sense.  Yes, you could use appscript from a PyObjC
> plugin.  I would expect that the majority of actions that people will
> write in Python will do very little inter-application communication
> anyway and instead will do things that Python is significantly better
> than AppleScript at (doing stuff on a network, mangling files, calling
> into Objective-C frameworks, etc.).
> 

I don't know why you call it a rant - you appear to be a bit deficient in
the politeness department. Is it really necessary to turn a conversation
into trading insults?

I've already made some AppleScript Automator actions, so I know how they
work, thanks. My Objective-C is more limited so I haven't tried one of those
yet. My reading of the docs, and what I was told by some Apple engineers,
implied pretty strongly that you'd have to have access to an application's
Cocoa APIs to be able to write an action controlling that application, which
I was saying was going to be unlikely unless it was your own application.
Also there are two Apple applications which expose their API's: one is
Address Book, and I think the other is iChat, so those are available. Of
course Objective-C and thus PyObjC are perfect for getting into frameworks
and the other stuff you mention. No dispute there. Perhaps we were talking
at cross-purposes. The docs mention that you can write "mixed mode" actions
that use both AppleScript and ObjC to do both. It hadn't occurred to me that
you might want to send raw AppleEvents from ObjC when AppleScript was
available, but OK. I suppose that's because I do a lot of AppleScript and
find it easier. If you'd really rather send AppleEvents between applications
then I'm glad you can do it. I did say that has's appscript would surely be
useful here.

I think getting into any more detail might be breaking NDA - most of this so
far is in the publicly available documents.


-- 
Paul Berkowitz




More information about the Pythonmac-SIG mailing list