Version: 1.6.19.2-linux
Third-party tools: Nuke 15.1
Third-party modules: Custom panel embedding Gaffer ScriptWindow inside Nuke via QWidget
Description
_GLGraphicsScene.drawBackground in GLWidget.py crashes when a drag initiated inside the Gaffer node graph leaves the embedded Gaffer panel boundary. Exceptions raised during __backgroundDrawFunction()
prevent glPopAttrib/glPopClientAttrib from executing, leaking GL attribute pushes that accumulate until the stack overflows. This subsequently triggers re-entrant selection passes ("Another Selector is
already active"), crashing in native code with SIGSEGV.
The root cause is that drawBackground does not wrap __backgroundDrawFunction() in try/finally, so any exception skips the GL pop calls. A try/finally around the draw function would prevent the GL stack
accumulation. However, the re-entrant Selector issue ("Another Selector is already active") also needs investigation — the drag-leave path appears to trigger selection passes that re-enter native code
unsafely.
Steps to reproduce
- Embed a Gaffer
ScriptWindow inside a host application panel (e.g. Nuke custom QWidget panel)
- Create nodes in the Gaffer node graph
- Start dragging a node in the node graph
- While holding the mouse button, move the cursor outside the Gaffer panel/window boundary
- Crash occurs
Debug log
Click to Expand
Traceback (most recent call last):
File ".../GafferUI/GLWidget.py", line 409, in drawBackground
GL.glPushAttrib( GL.GL_ALL_ATTRIB_BITS )
File ".../OpenGL/3.1.5/OpenGL/error.py", line 230, in glCheckError
raise self._errorClass(
OpenGL.error.GLError: GLError(
err = 1283,
description = b'stack overflow',
baseOperation = glPushAttrib,
cArguments = (GL_ALL_ATTRIB_BITS,)
)
ERROR : Emitting signal : ID shader does not have an ieCoreGLNameOut output
ERROR : Emitting signal : Another Selector is already active
ERROR : EventSignalCombiner : stack overflow
WARNING | signal caught: SIGSEGV -- Invalid memory reference
Segmentation fault
Version: 1.6.19.2-linux
Third-party tools: Nuke 15.1
Third-party modules: Custom panel embedding Gaffer ScriptWindow inside Nuke via QWidget
Description
_GLGraphicsScene.drawBackgroundinGLWidget.pycrashes when a drag initiated inside the Gaffer node graph leaves the embedded Gaffer panel boundary. Exceptions raised during__backgroundDrawFunction()prevent
glPopAttrib/glPopClientAttribfrom executing, leaking GL attribute pushes that accumulate until the stack overflows. This subsequently triggers re-entrant selection passes ("Another Selector isalready active"), crashing in native code with SIGSEGV.
The root cause is that
drawBackgrounddoes not wrap__backgroundDrawFunction()intry/finally, so any exception skips the GL pop calls. Atry/finallyaround the draw function would prevent the GL stackaccumulation. However, the re-entrant Selector issue ("Another Selector is already active") also needs investigation — the drag-leave path appears to trigger selection passes that re-enter native code
unsafely.
Steps to reproduce
ScriptWindowinside a host application panel (e.g. Nuke custom QWidget panel)Debug log
Click to Expand
Traceback (most recent call last):
File ".../GafferUI/GLWidget.py", line 409, in drawBackground
GL.glPushAttrib( GL.GL_ALL_ATTRIB_BITS )
File ".../OpenGL/3.1.5/OpenGL/error.py", line 230, in glCheckError
raise self._errorClass(
OpenGL.error.GLError: GLError(
err = 1283,
description = b'stack overflow',
baseOperation = glPushAttrib,
cArguments = (GL_ALL_ATTRIB_BITS,)
)
ERROR : Emitting signal : ID shader does not have an ieCoreGLNameOut output
ERROR : Emitting signal : Another Selector is already active
ERROR : EventSignalCombiner : stack overflow
WARNING | signal caught: SIGSEGV -- Invalid memory reference
Segmentation fault