ID 605599 - filenameFilter callbacks which change the customOCIOConfigPath do not get applied in Flipbook renders

Follow

Problem summary
filenameFilter callbacks which change the customOCIOConfigPath do not get applied in Flipbook renders.
This does seem to work when using a filenameFilter callback to change file paths on Read nodes.
 
The issue appears to be due to filenameFilter not working in Hiero's OCIO settings.
 
Customer reported version
Nuke 15.1v3 
 
Customer reported platform
Windows 10
 
Steps to reproduce
 
1) First, you will need two seperate OCIO config setups. You can copy the ones that ship with Nuke into a new location. For example:
C:/temp/167635/aces_1.2/config.ocio
C:/temp/167635/nuke-default/config.ocio
 
2) Launch Nuke.
 
3) Read in some footage and connect it to the Viewer.
 
4) Execute the following code in the Script Editor:

import nuke def myFilenameFilter(filename):     filename = filename.replace( 'C:/temp/167635/aces_1.2', 'C:/temp/167635/nuke-default' )     return filename nuke.addFilenameFilter(myFilenameFilter)
 
5) In Project Settings (Edit > Project Settings) and set the following:
  • color management to OCIO
  • OCIO config to custom
  • custom OCIO config to the path of one of your config files (ie. C:/temp/167635/aces_1.2/config.ocio)
 
6) Click Flipbook this viewer and in the dialog that appears, press OK.
 
Expected behaviour
The new OCIO config path, as defined by the filenameFilter callback should get applied in the Flipbook render.
 
Actual behaviour
In this case, the new OCIO config path isn't applied and this leads to an invalid LUT error:
Traceback (most recent call last):  File "C:\Program Files\Nuke16.0v4\pythonextensions\site-packages\hiero\ui\nuke_bridge\nuke_flipbook.py", line 378, in flipbook    p.setLUT( viewerLUT )RuntimeError: invalid LUT specified
 
However, this can also lead to the following crash, if the original OCIO config path isn't valid on this machine:
ID 605403 - Nuke crashes when rendering a flipbook, if you have an invalid OCIO config set in your Project Settings
 
Workaround
Unknown.
 
Reproduced by support
This bug has been reproduced in:
Nuke 16.0v4 - Windows 11 - Linux Rocky 9
Nuke 14.0v1 - Windows 11
Nuke 13.0v1 - Windows 11 - Linux CentOS 7
 
Earliest version tested
Nuke 13.0v1
- This issue appears to be in all tested versions of the product

    We're sorry to hear that

    Please tell us why