ID 534077 - The exportConfiguration function causes Katana to crash if querying for a value in a missing key

Follow

Problem summary
The exportConfiguration() function causes Katana to crash if querying for a value in a missing key. For example, if during the startup sequence an environment variable is cleared in a Startup script, any calls to exportConfiguration() will cause Katana to crash.

 
Customer reported version
Katana 4.5v5
 
Customer reported platform
CentOS 7
 
Steps to reproduce
 
1) In the Startup folder of a Katana Resources directory add the following code to the init.py file:
 
import os os.environ.pop('KATANA_PERSISTENT_IMAGES_PATH') print("Variable Cleared")
 
2) Launch Katana with the relevant Katana Resources directory added to the KATANA_RESOURCES environment variable.
 
3) In the Python tab run: Configuration.exportConfiguration()
 
Just to note: To repeat the above steps you must first reset the Environment variable KATANA_PERSISTENT_IMAGES_PATH to a viable directory.
 
Expected behaviour
Katana exports the Dictionary of Environment variables and prints it to the Python tab.
 
Actual behaviour
Katana crashes.
 
Workaround
Avoid clearing Environment variables during Startup.
 
Reproduced by support
This bug has been reproduced in:
Katana 6.0v1 - CentOS 7, Windows 10
Katana 5.0v1 - CentOS 7, Windows 10
Katana 4.5v5 - CentOS 7, Windows 10
Katana 4.0v1 - CentOS 7, Windows 10
 
Earliest version tested
Katana 4.0v1 - This feature did not exist before this version.

    We're sorry to hear that

    Please tell us why