Can't add SD8 to Automation permissions

I’ve just updated from SD7 to SD8 and opened my applet. On running the applet, SD pops an error “Not authorised to send Apple events to System Events” which is fine. But, I can’t find any way of adding SD8 to the Automation permissions. SD is no longer listed under Automation permissions (SD7 was). I tried referring to System Events by ID but encountered the same problem. I have also added SD8 to Accessibility and Full Disk Access permissions and done a restart. This is on a patched up-to-date install of Catalina 10.15.7

I could reset all my automation permissions but, that seems like overkill and would cause quite a lot of work to re-do permissions on all my other apps. Anyway, would that work ? Is there a way to add SD8 to the Automation permissions ?

Thanks.

This thread is about a slightly different issue, but it might give you some ideas:

Shane, thanks. My searches didn’t find that thread.

  • I’ve deleted every skerrick of SD7 that I can find and rebooted.

  • I’ve deleted SD8 preferences and Application Support files and rebooted.

  • I’ve deleted SD8 from all permissions (Full Disk Access, Files and Folders and Accessibility – I had manually added them in case it would help) then rebooted.

  • Tried tccutil in two forms to reset SD permissions – got an error “Failed to reset com.latenightsw.ScriptDebugger8” and another error: “Failed to reset all approval status for com.latenightsw.ScriptDebugger8”.

  • Tried tccutil reset ListenEvent – reset was successful but SD not added to Automation permissions list.

As it happens I can’t reset ANY app permissions using tccutil – I always get “Failed to reset…”. So, I guess there’s something fundamental there which I don’t understand. But, “tccutil reset AppleEvents” worked – it emptied out all my Automation permissions. But, still, I can’t get SD added to those permissions.

UPDATED: Strangely, I don’t have this issue in Script Editor. It’s very weird as Script Editor runs the same code WITHOUT requiring permission to send Apple Events to System Events – and that is after resetting all Automation permissions and rebooting.

Could this be related to SIP ? I have patch Catalina to run on my old iMac. One of the patches turns off SIP.

I can’t think of what else to do. Normally when a script tries to send Apple Events, there is a dialog which advises the action is not authorised. The dialog has an “OK” button and an “Edit” button. Clicking on OK adds the sending app to Automation permissions and script processing continues. But, I don’t get that dialog. I only get this SD8 error message:

Screen Shot 2021-08-17 at 2.07.23 pm

I’ll start Googling again to see if anyone has found a solution – but for now I’m stumped.

Script Editor gets a pass on all this because it’s Apple software.

If I had to guess, I’d say the patching is a strong possibility. But I’m really only guessing.

Now I’ve snookered myself.

I booted into recovery mode to try to enable SIP, in the hope that would enable SD to be added to Automation permissions. But upon entering the command “csrutil enable” I got the response: “csrutil: failed to modify system integrity configuration. This tool needs to be executed from the Recovery OS”. That was a surprise as I really had booted into recovery mode; the recovery utilities said so.

So, I had thought maybe I can install SD7 and get it running as before. So, I copied it across from my backup and gave it a try. I encountered the same problem as with SD8: it bangs an error but there is now no way to give SD7 permission to send AppleEvents either!

So, for the time being I’m stuck with Script Editor.

I’m going to research how to enable SIP on a patched Mac – even if that succeeds, maybe it won’t make any difference.

I was looking forward to SD8 too.

UPDATE: I’ve managed to get SD7 working again. I restored an old copy of the permissions database and found that all the old Automation permissions were back in place.

Now, can anyone help with getting SD8 to work ?