Skip to main content
Stefan Rakete
Inspiring
Jul 3, 2024 9:34 AM UTC
Question

Batch script breaking after 100 documents

Hi,
a batch script that I created for Illustrator will break after about 100 documents that have been processed. I am closing every document after processing and everything works fine if I process less than 100 documents at a time. What can cause this Illustrator behaviour and how can I avoid this? I am on an Mac M1 using OS Ventura and Illustrator version 28.5

This topic is closed to new replies. Start a new post to keep the conversation going.

3 replies

Inspiring
Jul 5, 2024 6:51 AM UTC

AI crashes after opening and closing >100 docs? I remember dealing with that bug from more than a decade ago. (Using the AppleScript API, but the JSX API shares a lot of the plumbing.) Quitting and restarting AI after every 100 docs was the workaround; you can easily do that using AppleScript. (If your script is JSX, write an AppleScript helper app that performs the relaunch, then have your JSX run it via `File.execute`.)

Translate
Stefan Rakete
Inspiring
Jul 5, 2024 8:19 AM UTC

Yes, AI is crashing. Thanks for the workaround. Anything I can do about memory management within the script itself to avoid the crash?  Thanks

Translate
Inspiring
Jul 5, 2024 9:23 AM UTC

It seems to be the number of files opened and closed that triggers it. Nothing you can do about that. Implement the workaround, file a bug report if you want, and move along.

Translate