Problem summary:
Hiero crashes after running
hiero.ui.BinView().selection() in the Script Editor.
This also affects Nuke Studio.
Customer reported version:
Hiero 13.2v6
Customer reported platform:
CentOS 7
Steps to reproduce:
1) Launch Hiero and select the option to
Start a new Project...
2) Navigate to
Window > Script Editor, and run the following code:
hiero.ui.BinView().selection()
3) Observe Hiero's performance.
Expected behavior:
Prior to Nuke 13.1v2, running the code in step 2 would produce the following error and not crash Hiero:
RuntimeError: Internal C++ object (ui.Hiero.Python.BinView) already deleted.
Actual behavior:
Hiero crashes when
hiero.ui.BinView().selection() is called. Using the deprecated
getSelection() method also seems to exhibit the same behavior.
Workaround:
Please see the Python code below for an example of how selected Bin items could be accessed without crashing:
for widget in hiero.ui.windowManager().windows(): if widget.windowTitle() == "Project": widget.setFocus()currentSelection = hiero.ui.activeView().selection()for item in currentSelection: print(item)
Reproduced by Support in:
Nuke Studio/Hiero 14.0v4 - Windows 10, CentOS 7
Nuke Studio/Hiero 14.0v1 - Windows 10
Nuke Studio/Hiero 13.2v7 - Windows 10
Nuke Studio/Hiero 13.2v1 - Windows 10
Nuke Studio/Hiero 13.1v2 - Windows 10, CentOS 7 -
Regression
Unable to reproduce bug in:
Nuke Studio/Hiero 13.1v1 - Windows 10, CentOS 7
Earliest version tested:
Nuke Studio/Hiero 13.1v1 - This issue doesn't appear in this version and has regressed