Note that I did not manage to reproduce this by running the script command through the debug console, I'm not sure if the paused game state somehow makes this issue not occur.
The following cases that I tested, result in the behavior described above.
1) Running the code via action called by addAction (Repro mission uses this)
2) Running the code via "KeyDown" display event handler
3) Running the code via "MouseZChanged" display event handler
4) From a precompiled postInit function, which spawns a code block where it delays the animate code by 1 second. (Without the delay, the animate worked without problems)
Using Dev build 1.53.132487
Video: https://www.youtube.com/watch?v=kaAGnTW-yFQ