New Environment Variables in Maya 2022

Apart from the expected Python 3 upgrade, two little things slipped through Maya 2022 are 3 new environment variables regarding Maya batch mode.

The MAYA_BATCH_STDOUT_LOGGING_LEVEL and MAYA_BATCH_STDERR_LOGGING_LEVEL set the logging level of outputs of stderr and stdout.
The accepted values are all (stderr default), info, result, warning, error, and none (stdout default)
It should only change the behaviour of mayabatch… but when testing it I haven’t seen any differences. Same with mayapy. If anyone has more info let me know!

When Maya is in batch mode, the MAYA_DISABLE_ADP env var disables the analytics sent to Autodesk, along the same lines as the ones described in this article. They should all be set to 1 to improve your Maya experience:

Oh, and the Maya console is hidden by default now, yay!

Some resources on Maya environment variables:

When Maya encounters a fatal error, this variable writes a crash report file (MayaCrashLog[yymmdd.hhmm].log) to the directory specified with the TMP environment variable. This file contains a detailed description of what Maya was doing when the failure occurred.

This variable is used to override where help files are found. Maya pre-appends this value to its help paths to create a string which is passed to the browser. You can use this to point Maya to a central help server, or set it to a http: URL to have Maya get its help files from a web site instead of the Maya help on your hard drive.

Allows you to override the Expression Editor and use your own editor. The editor must be set to run in the foreground.

If you encounter problems with Maya stopping unexpectedly while loading a large scene, try setting this environment variable to 1. However, when this environment variable is set, Maya does not release the memory used when you select File > New; it only does when you quit Maya.

Suppress warnings on scene open. Can also be set when opening a file by script cmds.file(filepath, open=True, force=True, prompt=False)

This will disable all userSetups of the users

Set to the path of a MEL script that define a new UI