Thanks @mlampert and @sliptonic for assisting in tracking down the error via unit test analysis. FreeCADGui usage has to be behind an 'if FreeCAD.GuiUp:` test