Troubleshooting Event Scripts

Use the following suggestions to help you troubleshoot your event scripts if they do not execute as expected.

ClosedVerify the full command line incantation that Templater uses

  1. Open the templater.log file and search the text file for the phrases EVENT SCRIPT ERROR, EXEC SHELL SCRIPT, or the string used in the first parameter of the $D.log.msg() method.
  2. Locate the log line that shows a statement starting with "Full command line...", highlight only the full command line as reported by Templater, and copy it to the clipboard.
  3. Start a new command line session and paste the full command line at the prompt. Press Enter.
  4. Verify that your script executes as expected.

ClosedLog script output to a file

  1. Inside your script file, log output messages to a text file. The code to log to a file differs depending on the language you are writing your script in. For example consider the following code for various scripting languages:
    • Logging to file debug.txt on the user's desktop in a Bash script on macOS:
      printf "Troubleshooting my event script" >> ~/Desktop/debug.txt
    • Logging to file debug.txt on the user's desktop in a Batch Script on Windows:
      echo Troubleshooting my event script >> %USERPROFILE%\Desktop\debug.txt
    • Logging to Templater's own templater.log file in ExtendScript:
      $D.log.msg('EVENT SCRIPT DEBUG', "Troubleshooting my event script");
  2. After Templater finishes its tasks, inspect the log file to see if your script generated expected results.

ClosedVerify permissions of script files

  1. Verify that the script file is executable by the user running After Effects.
  2. If the user does not have permission to execute the script file, a user with administrator privileges should set them for the script file. For example, on OSX, you can enter chmod u+x myPostJob.sh to make it executable for the current user. On Windows, use the Security tab in the script file's Properties dialog.