ID 612526 - Hiero/Nuke Studio crashes when version scanning and there is a Timeline incompatible Nuke script with the same name as the files, when the parent directory has a version

Follow

Problem summary
Hiero/Nuke Studio crashes when version scanning and there is a Timeline incompatible Nuke script with the same name as the files, when the parent directory has a version
 
Customer reported version
hiero.15.1v10
 
Customer reported platform
rocky9
 
Steps to reproduce
 
1) Open Nuke

2) Create a CheckerBoard and connect a Write node

3) In the Write node, set it to a path and call the <some/path>/test_v001/test.####.exr
 
4) Render a frame from the Write node then delete the Write node
 
5) Save the Nuke script in the <some/path>/test_v001 directory, as test.nk. This creates a Nuke script incompatible with the Timeline, as id does not have a Write node
 
6) Open Hiero/Nuke Studio
 
7) Import the exr file written out from Nuke
 
8) Try to version up the .exr, by selecting it in the bin then pressing Alt+Up
 
*Hiero specific incompatible Nuke scripts can also be created in Hiero using Keep Nuke Script when Transcoding images. This is logged as ID 612518
 
Expected behaviour
For Hiero/Nuke Studio to find no compatible Nuke scripts, and not add any new versions to the clip
 
Actual behaviour
Hiero/Nuke Studio crash
 
Workaround
Don't allow Hiero to load in any Nuke script as a version. This can be done with the following Python code:

import os.pathfrom hiero.core import VersionScannerif not hasattr(VersionScanner, "default_filterVersion"):  VersionScanner.default_filterVersion = VersionScanner.filterVersiondef filterVersionSameFormat(self, binItem, newVersionFile):  ext = os.path.splitext(newVersionFile)[1]  if ext == ".nk":    return False  return TrueVersionScanner.filterVersion = filterVersionSameFormat
 
Reproduced by support
This bug has been reproduced in:
Hiero/Nuke Studio 16.0v8 - Windows 11, macOS Sonoma
Hiero/Nuke Studio 16.0v4 - Windows 11, macOS Sonoma - 16.0 regression
Hiero/Nuke Studio 15.2v4 - Windows 11 - 15.2 regression
Hiero 15.1v9 - Windows 11 - 15.1 regression
 
Unable to reproduce bug in:
Hiero/Nuke Studio 16.0v3 - Windows 11, macOS Sonoma
Hiero/Nuke Studio 15.2v3 - Windows 11
Hiero/Nuke Studio 15.1v8 - Windows 11
 
Earliest version tested
Hiero/Nuke Studio 15.1v8 - This issue doesn't appear in this version and has regressed
 

    We're sorry to hear that

    Please tell us why