What to do when AppleEvents are just blocked?

Did you make the plist entries that Beatrix cited? I’m not sure they’ll work at all without those… debugging or not.

Start with what works and then work through everything until you get to the point where the AppleScripts don’t work anymore.

A couple of weeks ago I saw that in debug mode everything worked fine and as soon as the app was notarised the AppleScripts didn’t work anymore.

I just tried now, using AppWrapper (I filled the “Music” field of the “Personal Data” section, switched “AppleScript” to “on”, filled the “Usage string” of AppleScript and added “Music” to the list of allowed targets), along with notarising the debug app. Not better.

With the instability of MacOS, some things I tried have made things worse (other apps no longer sending AppleEvents, for instance). It’s hard to progress when the OS regresses at the same time.

It looks like it breaks far more than it works.
On my side, I tried notarised and not-notarised versions, debug and built app; nothing worked so far.

I’m also encountering weird symptoms in other OS areas, though (my desktop folder isn’t localised, I can’t change the default app for “.ts” files, some Apple apps like Mail won’t register mouse clicks before I make another click, etc.). Perhaps I should reinstall…

Thanks.

Copy paste the script from the “Scripting” pane into a build step and voila, AW can be used for debugging as well as building.

App Wrapper uses Apple Script, so does some other apps of mine, which work with 12.3.

Oh, nice! More than being a useful function, it also solved my issues. MacOS prompted me whether I’d allow my app to control Music (and another app) and the AppleEvents worked.

Now, I have a working process, which I can examine to find the root cause of the issue.
A big thanks!

1 Like