Detect when an app is crashed
Detect when an app is crashed
- Subject: Detect when an app is crashed
- From: "Stockly, Ed" <email@hidden>
- Date: Fri, 24 Mar 2017 18:44:57 +0000
- Thread-topic: Detect when an app is crashed
I have a need for an AppleScript dead-man's switch. Something that will
respond if the AppleScript, or the app that it's calling (or both) have
frozen and/or are hanged. (The app is either Safari or Chrome, the
AppleScript is a stay-open droplet with an idle handler).
What usually happens is both show an application not responding message in
the dock and in the force-quit window.
The dead-man's switch script would force quit both and relaunch or, if
that doesn't work, force restart the mac.
The commands for force quitting and restarting are pretty simple.
It's detecting when an app is frozen that I don't know about.
Is this possible? The thread on detecting sleep state made me think there
might be a solution (I asked the question years ago)
(Tried having the dead-man's script monitor the modification date of a
file, and have the appleScript update the modification date everytime it
does its thing, then, if the DMS script noticed it hasn't updated, it
would relaunch or restart, but with my first attempt at doing this I just
wound up with one more application not responding message and had to
manually reboot anyway.)
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden