Catalina will probably release this week, and, in preparation, I have been doing a little research on changes to AppleScript. Thus far I’ve found very little.
The Catalina developer release notes contain the following paragraph:
“To enhance security, AppleEvents and AppleScripts that target an app on a remote system must authenticate as the same user on the remote system. An AppleEvent that targets an app running as a different user receives a procNotFound error.”
The only pertinent post in this forum concerning Catalina has to do with mail attachments, although it is uncertain if this is a Catalina issue or not:
Finally, any AppleScript that scripts iTunes will need to be revised.
So, for me, all my Applescripts should work fine.
Edit December 10, 2019. I just discovered that the default shell in Catalina is changed from Bash to ZSH. Seldom an issue in an AppleScript but worth noting.
Command-line tools are also subject to Gatekeeper security.
The first time a script tries to access files in certain places – desktop, downloads, removable drives, network volumes, among others – authorization will be sought.
There are some issues with script libraries that access third-party frameworks.
Thanks Shane. I knew there just had to be some additional issues.
I use a number of command-line tools in my AppleScripts, including a few downloaded from the internet, and the first issue you note will affect me. I’ll get to work on this as soon as Catalina is released.
Well, I was wildly optimistic to think that Catalina would work with all of my existing Applescripts, and, in fact, the opposite is closer to the truth.
The biggest issue is command-line utilities that I downloaded from the internet. For example, when running a script that uses one of these utilities, I receive a dialog with the following:
“[utility name] cannot be opened because the developer cannot be verified”
The dialog options are Move to Trash and Cancel.
I added the command-line utility to Accessibility and Full Disk Access under Security and Privacy in System Preferences but that didn’t help.
I heard back from the developer of the command-line utility which refused to run under Catalina. He provided a workaround, and I thought I would post it here because it might work with other similar utilities.
The developer’s workaround and other comments are:
I can not use remote AppleEvent between 10.15 machines with AppleScript applet.
The compiling phase does not finish (causes AppleEvent timed out after 180 seconds’ wait).
I thought I would add a postscript to this thread.
When I initially upgraded to Catalina, I encountered three significant issues that pretty much forced me to return to Mojave. These were a bug that prevented my 4k monitor from working in 4k mode, a lack of support of Catalina by the SuperDuper backup app, and my inability to get an important command-line utility to run.
Those issues were resolved and I’m now successfully running Catalina (10.15.1). I had to make some minor changes to a few AppleScripts, and the required file-access authorizations can be irritating, but neither of these is a deal-breaker for me. I can’t say I use any of the new features of Catalina, but it’s nice to be up to date.
BTW, beta 4 of 10.15.2 was released two days ago and hopefully we will see that upate before long.
You’re having better luck than me. A couple of kernel panics, spurious permission issues, and problems opening and saving scripts if Full Disk Access is not turned on.
Catalina 10.15.2 is out and works great for me. Shane does a lot of complicated stuff, so it’s not surprising that he would run into issues that don’t impact me.
Under Catalina the boot drive is now divided into two volumes, which for me are:
Macintosh HD
Macintosh HD - Data
I run the following:
tell application "Finder" to set theFile to selection as text
and it returns:
I was just curious why this is, because I would expect it to be:
I assume that the Data volume is mirrored somehow in the Macintosh HD volume, but I wondered how this works.
Also, I was a bit surprised that the following errors:
alias "Macintosh HD - Data:Users:peavine:Working:New Text File.txt"
And, the following does not:
alias "Macintosh HD:Users:peavine:Working:New Text File.txt"
The drives appear as a single drive by the use of firmlinks, which are a bit like symlinks. These merge the contents of the two drives, so everything except some low-level tools still see a single volume, in your case Macintosh HD.
Thanks Shane. I googled firmlinks and found an informative ars Technica article that explains all of this. None of this directly impacts AppleScripting but it’s interesting to know how things works.