MacOS – way to kill an unresponsive applescript launched by an application without killing the application

applescripthangmacosquicksilver

I've got an AppleScript that I usually launch out of Quicksilver, but occasionally, the script hangs, never exiting. (I think it's waiting on a non-existent window to appear).

This results in Quicksilver being monopolized, waiting for the script to die off.

If this were a Windows box, there would be a "scripting host" process I could end to fix this, but I'm not sure if OS X has a similar process. Nothing jumps out at me in the process list.

Of course, I could just kill and restart Quicksilver, but I'm wondering if there's an explicit way to just kill a runaway applescript that's running in the context of another application?

Best Answer

It looks like the AppleScript is run within Quicksilver’s process (depending on how you run it). If that’s the case, you’d need to relaunch Quicksilver. If it’s not completely frozen, you can do this quickly with ⌃⌘Q.

It might also be possible to set some kind of timeout in the script to prevent it from hanging indefinitely.