Printrun
Printrun copied to clipboard
Gcode view: 2D mode crashing on fast layer change
Traceback (most recent call last):
File "/home/swiftgeek/tmp/Printrun-upstream/printrun/gviz.py", line 405, in paint
self.repaint_everything()
File "/home/swiftgeek/tmp/Printrun-upstream/printrun/gviz.py", line 331, in repaint_everything
dc.SelectObject(self.blitmap)
wx._core.wxAssertionError: C++ assertion "cr && cairo_status(cr) == 0" failed at /usr/src/debug/wxwidgets/wxWidgets-3.2.1/src/gtk/bitmap.cpp(1399) in CairoCreate():
zsh: terminated python ./pronterface.py
First it stops rendering while displaying traceback above after attempt to change layer, and after a bit more layer change attempts crashes entire pronterface
Easiest to trigger with mouse wheel
OS: Archlinux Python version: 3.10.9 wx-config --version: 3.2.1 wxpython: 4.2.0
Hi @swiftgeek I'm unable to replicate this, does it occur with a specific .gcode file? Could you provide it? Or please be more specific on how to reproduce it
No specific file - I didn't find any file it doesn't occur with, simply changing layer fast with mouse wheel triggers it reliably here. Changing one layer at a time and letting it render before changing again doesn't break anything.
Similar thing happens for changing zoom level, which additionally produces following snippet as well as one above
Traceback (most recent call last):
File "/home/swiftgeek/tmp/Printrun-upstream/printrun/gviz.py", line 405, in paint
self.repaint_everything()
File "/home/swiftgeek/tmp/Printrun-upstream/printrun/gviz.py", line 329, in repaint_everything
self.blitmap = wx.Bitmap(int(width) + 1, int(height) + 1, -1)
wx._core.wxAssertionError: C++ assertion ""width > 0 && height > 0"" failed at /usr/src/debug/wxwidgets/wxWidgets-3.2.2/src/gtk/bitmap.cpp(541) in Create(): in
valid bitmap size
I'm unable to replicate this then. On the "Gcode view" tool, scrolling as fast as my mouse wheel allows and changing zoom level using Ctrl+Mouse Wheel does not produce the above either.
Out of curiosity:
- this happens even with #1314 applied?
- what version of python gobject libraries (
python3-gi
on Debian/Ubuntu) are you using?
-- Debian Sid Python 3.11.1 wxPython 4.2.0
- #1314 has no effect on 2D viewers
- python-gobject 3.42.2