ID 526204 - Export Manager stops opening if a Layered Shader is selected as a USD Export Shader

Follow

Problem summary
Export Manager stops opening if a Layered Shader is selected as the USD Export Shader
 
Customer reported version
Mari 5.0v4
 
Customer reported platform
Linux
 
Steps to reproduce
 
1) Create a Layered Shader via the Shaders palette

2) Open the Export Manager and switch to USD Export tab

3) Select the Layered Shader as the USD Export Shader
 
4) Close the Export Manager
 
5) Reopen the Export Manager
 
Expected behaviour
The Export Manager should open.
 
Actual behaviour
The Export Manager does not open, and an error is returned in the Python Console:
 

Traceback (most recent call last):   File "<string>", line 1, in <module>   File "C:/Program Files/Mari5.0v4/Bundle/Media/Scripts\Mari\system\batch_export_dialog.py", line 1701, in showExportDialog     dialog = ExportDialog()   File "C:/Program Files/Mari5.0v4/Bundle/Media/Scripts\Mari\system\batch_export_dialog.py", line 1019, in __init__     self.addTabWidgets()   File "C:/Program Files/Mari5.0v4/Bundle/Media/Scripts\Mari\system\batch_export_dialog.py", line 1042, in addTabWidgets     tab_widget = tab_widget_callback()   File "C:/Program Files/Mari5.0v4/Bundle/Usd\lib\python\mariUsd\usdExportManagerTab.py", line 1298, in generate_usd_export_widget     return USDExportWidget()   File "C:/Program Files/Mari5.0v4/Bundle/Usd\lib\python\mariUsd\usdExportManagerTab.py", line 982, in __init__     self.on_shader_assignment_changed(None)   File "C:/Program Files/Mari5.0v4/Bundle/Usd\lib\python\mariUsd\usdExportManagerTab.py", line 1112, in on_shader_assignment_changed     new_rows = self.export_item_model.update_shader_items(selected_shaders)   File "C:/Program Files/Mari5.0v4/Bundle/Usd\lib\python\mariUsd\usdExportManagerTab.py", line 537, in update_shader_items     self.updateShaderInputs(shader_item)   File "C:/Program Files/Mari5.0v4/Bundle/Usd\lib\python\mariUsd\usdExportManagerTab.py", line 575, in updateShaderInputs     new_shader_input_infos = self._advancedInputList(shader)   File "C:/Program Files/Mari5.0v4/Bundle/Usd\lib\python\mariUsd\usdExportManagerTab.py", line 548, in _advancedInputList     shader_model_input = shader_model.input(input_name) AttributeError: 'NoneType' object has no attribute 'input'
 
Workaround
The easiest way to prevent this issue is to delete any Layered Shader nodes and then recreate them. If you need to maintain your current Layered Shader nodes, you can follow the steps below to prevent the error:

1. Ensure you have at least one non-Layered Shader node in your project (e.g. a Principled BRDF Shader)
2. Locate any Layered Shader nodes in the Node Graph
3. Delete the Layered Shader nodes
4. Open the Export Manager and switch to the USD tab
5. Select a Shader for USD Export - even if a different Shader is shown as selected, you must manually click it and select
6. Close the Export Manager
7. Undo the deletion of the Layered Shader nodes
 
Reproduced by support
This bug has been reproduced in:
Mari 5.0v4 - Windows 10 - CentOS 7.9
Mari 4.8v4 - CentOS 7.9
Mari 5.0v1 - Windows 10 - CentOS 7.9
 
Earliest version tested
Mari 5.0v1 - This feature did not exist before this version
 
 

    We're sorry to hear that

    Please tell us why