Cura 21 exception

hi folks just installed cura 21 to see what it does, previously using 15.04, and i get this:

Exception in thread Thread-4:
Traceback (most recent call last):
  File "/usr/lib/python2.7/threading.py", line 801, in __bootstrap_inner
    self.run()
  File "/usr/lib/python2.7/threading.py", line 754, in run
    self.__target(*self.__args, **self.__kwargs)
  File "/usr/share/cura/Cura/util/sliceEngine.py", line 359, in _runEngine
    pos += (objMin + objMax) / 2.0 * 1000
TypeError: Cannot cast ufunc add output from dtype('float64') to dtype('int64') with casting rule 'same_kind'

love the addition of the same style printer-control “thing” from pronterface.

also is there any particular reason why “Control” and “View Mode” would be greyed-out and inaccessible?

another one - this time on exit

Traceback (most recent call last):
  File "/usr/share/cura/Cura/gui/mainWindow.py", line 83, in <lambda>
    self.Bind(wx.EVT_MENU, lambda e: self.scene.OnPrintButton(1), i)
  File "/usr/share/cura/Cura/gui/sceneView.py", line 335, in OnPrintButton
    self._openPrintWindowForConnection(connection)
  File "/usr/share/cura/Cura/gui/sceneView.py", line 357, in _openPrintWindowForConnection
    if not connection.loadGCodeData(self._engine.getResult().getGCode()):
AttributeError: 'NoneType' object has no attribute 'getGCode'
Traceback (most recent call last):
  File "/usr/share/cura/Cura/gui/mainWindow.py", line 83, in <lambda>
    self.Bind(wx.EVT_MENU, lambda e: self.scene.OnPrintButton(1), i)
  File "/usr/share/cura/Cura/gui/sceneView.py", line 335, in OnPrintButton
    self._openPrintWindowForConnection(connection)
  File "/usr/share/cura/Cura/gui/sceneView.py", line 357, in _openPrintWindowForConnection
    if not connection.loadGCodeData(self._engine.getResult().getGCode()):
AttributeError: 'NoneType' object has no attribute 'getGCode'
Closing down

https://github.com/numpy/numpy/issues/7225

requires the use of “np.sum” instead of "pos += ".

ok so this works:

            if objMin is None:
                return
            numpy.add(pos, (objMin + objMax) / 2.0 * 1000, out=pos,
                      casting="unsafe")
            commandList += ['-s', 'posx=%d' % int(pos[0]), '-s', 'posy=%d' % int(pos[1])]

and that’s at line 739 in Cura/util/sliceEngine.py

which also makes the “View Model” and the “Control” buttons appear, yaaay!