OptiX v3.0 Issue: Callabale program scoping - Validation error Inconsistent scope lookups in PTX cod

I have just come across an issue with the callable programs in v3.0. I want to be able to call my getLights callable-program from inside a material but when we run in hybrid we want to do this in the ray-generation program.

Using the same callable-program in the ray-generation and a material results in the below validation issue:

Invalid context (Details: Function “_rtContextLaunch2D” caught exception: Validation error: Inconsistent scope lookups in PTX code (Program attached to different object types), [5570939])

I would have thought this should be possible as its pretty annoying otherwise. I get the feeling I have to use a different callable-function variable name to work around this issue?

Thanks for any help anybody can give.

This can be solved by using bindless callable programs (via Program IDS). Bound callable programs from a single RT_CALLABLE_PROGRAM function must have consistent calling scopes (ie, can be called from multiple different closest_hits/any_hits but not from a mixture of hit programs and miss programs).