I'm having trouble getting my render settings set at startup. My setup worked fine in Maya 2016, but it broke in 2017. The issue still persists in 2018.
If you put the code below into a userSetup.py (I just placed this test userSetup in one of the default Maya python path directories) and run Maya, you'll see that the first 2 evals work fine, but they don't run the code when I need it executed (after VRay is initialized). The last one, the script job, executes the code at the right time, but it breaks the render globals window (window is blank). Is this a bug? Thanks!
import maya.cmds as mc
print 'ran script'
mc.scriptJob(runOnce=True, e=["idle", print_text])