Batch File Creation Problem CS5.5
I am having an issue creating aep files on our farm using aerender in CS5.5. We have a script that uses a template aep to generate a new file for various shots. It works fine in CS4. When I use the same script in CS5.5 it creates a file, but when you try to open it, it gives the following messages:
After Effects warning: Reading past end of file
After Effects error: strange situation [0/2]. (26 :: 84)
At which point AE either crashes or leaves a blank file.
However, if you try to import the same file, it works fine and everything appears as desired.
If I run the same script through the CS5.5 UI (AfterFX.exe as opposed to aerender.exe) the file generated opens without issue.
I also tried stripping out parts of the script to see if removing elements fixed the issue. It did not - in fact I made a new script to try in batch mode that only saves a file. This results in the the same
After Effects warning: Reading past end of file
but no errors, though I imagine that's because it's a blank project to begin with.
Here is the code for that script:
function testBuild() {
var saveMe = new File("//server/job/comp/dev/work/test/shot/file_test.aep");
app.project.save(saveMe);
}
We are using a slightly modified version of commandLineRenderer.jsx that allows extra flags to run pre-render scripts and submit without rendering. I merged our custom edits with the version that ships with CS5.5 to ensure continuity. Again, the script works in CS4 (even w/ the updated custom CS5.5 version of the commandLineRenderer.jsx).
Here's the command that runs on the farm:
aerender -s 1 -e 1 -norender -script //server/job/bin/dev/testBuild.jsx -command "testBuild()" 2>&1
the -norender -script and -command flags were things we added to commandLineRenderer.jsx, -norender indicates not to render the project, -script gives the script to load and -command the command to run.
The issue seems directly related to saving using aerender.exe in CS5.5 since everyting works correctly in CS4 and in the CS5.5 UI
We are running Windows 7 64-bit.
Thanks for any help you can provide!