Bug: aerender version 22.1.1x74 occasionally hangs
In the latest upgrade to After Effects 22.1.1, I have found there is a bug in aerender that causes occasional hangs on MacOS (Catalina 10.15.7 on Intel, and Big Sur 11.6.3 on M1).
Most renders will complete fine as expected, but approximately 1 in 10 will hang or freeze after the render has completed - the output file will be written, but the aerender process hangs. No error is shown in the terminal. Manually opening After Effects (as in the app GUI) will suddenly fix this - the aerender process will immediately un-hang and complete as normal.
Downgrading AE back to to 22.0.1 fixes this bug, it does not occur with this version as far as I can tell.
To reproduce, run a bash script similar to this one, which repeatedly calls aerender in a for loop. It may take a few tries, it does not seem to be consistently reproducible. A log of what the typical output is here. Note that there is no error or any output suggesting something went wrong, it just hangs at the very end.
Is there any guidance on how to fix this? Or will this need to be fixed in a future version?
