A plug-in's uninitializePlugin function is not called automatically when Maya exits. Meaning any code which deallocates resources or a similar task will be called when the plug-in is explicitly unloaded but not when Maya exits. In order to work-around this problem and execute the code when ...