Opened 9 years ago

Closed 9 years ago

Last modified 8 years ago

#2746 closed defect (fixed)

g.gui.vdigit fails to start with "PyAssertionError: C++ assertion "GetEventHandler() == this" failed at ../src/common/wincmn.cpp(478) in ~wxWindowBase(): any pushed event handlers must have been removed"

Reported by: mlennert Owned by: grass-dev@…
Priority: critical Milestone: 7.2.0
Component: wxGUI Version: svn-trunk
Keywords: g.gui.vdigit digitizer Cc:
CPU: Unspecified Platform: Linux

Description

With a freshly checked out grass70_release, I get the following error when trying to launch the wxGUI:

ATTENTION : le chargement de certaines extensions à échoué. Merci de mettre à jour vos extensions en lançant 'g.extension.all -f'.
Traceback (most recent call last):
  File "/data/home/mlennert/SRC/GRASS/grass70_release/dist.x86_64-unknown-linux-gnu/gui/wxpython/wxgui.py", line 142, in <module>
    sys.exit(main())
  File "/data/home/mlennert/SRC/GRASS/grass70_release/dist.x86_64-unknown-linux-gnu/gui/wxpython/wxgui.py", line 134, in main
    app = GMApp(workspaceFile)
  File "/data/home/mlennert/SRC/GRASS/grass70_release/dist.x86_64-unknown-linux-gnu/gui/wxpython/wxgui.py", line 49, in __init__
    wx.App.__init__(self, False)
  File "/usr/lib/python2.7/dist-packages/wx-3.0-gtk2/wx/_core.py", line 8628, in __init__
    self._BootstrapApp()
  File "/usr/lib/python2.7/dist-packages/wx-3.0-gtk2/wx/_core.py", line 8196, in _BootstrapApp
    return _core_.PyApp__BootstrapApp(*args, **kwargs)
  File "/data/home/mlennert/SRC/GRASS/grass70_release/dist.x86_64-unknown-linux-gnu/gui/wxpython/wxgui.py", line 83, in OnInit
    workspace = self.workspaceFile)
  File "/data/home/mlennert/SRC/GRASS/grass70_release/dist.x86_64-unknown-linux-gnu/gui/wxpython/lmgr/frame.py", line 132, in __init__
    self._createMenuBar()
  File "/data/home/mlennert/SRC/GRASS/grass70_release/dist.x86_64-unknown-linux-gnu/gui/wxpython/lmgr/frame.py", line 252, in _createMenuBar
    self.menubar = Menu(parent=self, model=self._menuTreeBuilder.GetModel(separators=True))
  File "/data/home/mlennert/SRC/GRASS/grass70_release/dist.x86_64-unknown-linux-gnu/gui/wxpython/gui_core/menu.py", line 44, in __init__
    self.Append(self._createMenu(child), child.label)
  File "/data/home/mlennert/SRC/GRASS/grass70_release/dist.x86_64-unknown-linux-gnu/gui/wxpython/gui_core/menu.py", line 52, in _createMenu
    subMenu = self._createMenu(child)
  File "/data/home/mlennert/SRC/GRASS/grass70_release/dist.x86_64-unknown-linux-gnu/gui/wxpython/gui_core/menu.py", line 58, in _createMenu
    self._createMenuItem(menu, label=child.label, **data)
  File "/data/home/mlennert/SRC/GRASS/grass70_release/dist.x86_64-unknown-linux-gnu/gui/wxpython/gui_core/menu.py", line 99, in _createMenuItem
    rhandler = eval('self.parent.' + handler)
  File "<string>", line 1, in <module>
AttributeError: 'GMFrame' object has no attribute 'OnTplotTool'
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
  File "/usr/lib/python2.7/atexit.py", line 24, in _run_exitfuncs
    func(*targs, **kargs)
PyAssertionError: C++ assertion "GetEventHandler() == this" failed at ../src/common/wincmn.cpp(478) in ~wxWindowBase(): any pushed event handlers must have been removed
Error in sys.exitfunc:
Traceback (most recent call last):
  File "/usr/lib/python2.7/atexit.py", line 24, in _run_exitfuncs
    func(*targs, **kargs)
wx._core.PyAssertionError: C++ assertion "GetEventHandler() == this" failed at ../src/common/wincmn.cpp(478) in ~wxWindowBase(): any pushed event handlers must have been removed

Build and library info:

 ./configure  --prefix=/usr/lib --sysconfdir=/etc --sharedstatedir=/var --enable-socket --enable-shared --enable-largefile --with-postgres --with-mysql --with-pthread --with-cxx --with-x --with-gdal --with-freetype --with-motif --with-readline --with-nls --with-odbc --with-sqlite --with-freetype-includes=/usr/include/freetype2 --with-tcltk-includes=/usr/include/tcl --with-postgres-includes=/usr/include/postgresql --with-mysql-includes=/usr/include/mysql --with-proj-share=/usr/share/proj --with-python=/usr/bin/python-config --with-cairo --with-geos --with-blas --with-lapack --with-liblas=/usr/bin/liblas-config
libgis Revision: 64733 
libgis Date: 2015-02-25 01:56:29 +0100 (mer 25 fév 2015) 
PROJ.4: 4.9.1
GDAL/OGR: 1.11.2
GEOS: 3.5.0
SQLite: 3.8.11.1
wx: 3.0.2

Change History (6)

comment:1 by mlennert, 9 years ago

I'm getting a similar issue in trunk. Interestingly I can start the wxgui, but when I try to launch g.gui.vdigit, I get:

Traceback (most recent call last):
  File "/data/home/mlennert/SRC/GRASS/grass_trunk/dist.x86_64-unknown-linux-gnu/scripts/g.gui.vdigit", line 109, in <module>
    main()
  File "/data/home/mlennert/SRC/GRASS/grass_trunk/dist.x86_64-unknown-linux-gnu/scripts/g.gui.vdigit", line 103, in main
    frame = VDigitMapFrame(options['map'])
  File "/data/home/mlennert/SRC/GRASS/grass_trunk/dist.x86_64-unknown-linux-gnu/scripts/g.gui.vdigit", line 63, in __init__
    title=_("GRASS GIS Vector Digitizer"), size=(850, 600))
  File "/data/home/mlennert/SRC/GRASS/grass_trunk/dist.x86_64-unknown-linux-gnu/gui/wxpython/mapdisp/frame.py", line 126, in __init__
    self.CreateStatusbar()
  File "/data/home/mlennert/SRC/GRASS/grass_trunk/dist.x86_64-unknown-linux-gnu/gui/wxpython/mapdisp/frame.py", line 249, in CreateStatusbar
    self.Map.GetRenderMgr().updateProgress.connect(self.statusbarManager.SetProgress)
AttributeError: 'NoneType' object has no attribute 'GetRenderMgr'
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
  File "/usr/lib/python2.7/atexit.py", line 24, in _run_exitfuncs
    func(*targs, **kargs)
PyAssertionError: C++ assertion "GetEventHandler() == this" failed at ../src/common/wincmn.cpp(478) in ~wxWindowBase(): any pushed event handlers must have been removed
Error in sys.exitfunc:
Traceback (most recent call last):
  File "/usr/lib/python2.7/atexit.py", line 24, in _run_exitfuncs
    func(*targs, **kargs)
wx._core.PyAssertionError: C++ assertion "GetEventHandler() == this" failed at ../src/common/wincmn.cpp(478) in ~wxWindowBase(): any pushed event handlers must have been removed

Again, this is with a completely fresh checkout of trunk.

comment:2 by annakrat, 9 years ago

Do you have anything in ~/.grass7/toolboxes? I suspect you have there menu xml file generated for trunk, which fails because tplot is not in G70.

in reply to:  2 ; comment:3 by mlennert, 9 years ago

Keywords: g.gui.vdigit digitizer added; g.gui wxgui removed
Milestone: 7.0.27.1.0
Summary: GUI fails to start: wx3.0 issue ?g.gui.vdigit fails to start with "PyAssertionError: C++ assertion "GetEventHandler() == this" failed at ../src/common/wincmn.cpp(478) in ~wxWindowBase(): any pushed event handlers must have been removed"
Version: svn-releasebranch70svn-trunk

Replying to annakrat:

Do you have anything in ~/.grass7/toolboxes? I suspect you have there menu xml file generated for trunk, which fails because tplot is not in G70.

That's it for the g.gui issue in g70. Thanks !

However, the error when launching g.gui.vdigit in trunk remains (with fresh check out at r66264). I don't have this problem in g70.

I've changed the title and parameters of this ticket to reflect that.

in reply to:  3 ; comment:4 by annakrat, 9 years ago

Replying to mlennert:

Replying to annakrat:

Do you have anything in ~/.grass7/toolboxes? I suspect you have there menu xml file generated for trunk, which fails because tplot is not in G70.

That's it for the g.gui issue in g70. Thanks !

However, the error when launching g.gui.vdigit in trunk remains (with fresh check out at r66264). I don't have this problem in g70.

I've changed the title and parameters of this ticket to reflect that.

Should be fixed in r66351. BTW, the bottom part of the error is not directly related, it's just a consequence of the error, but I am not sure what's causing it.

in reply to:  4 comment:5 by mlennert, 9 years ago

Resolution: fixed
Status: newclosed

Replying to annakrat:

Replying to mlennert:

Replying to annakrat:

Do you have anything in ~/.grass7/toolboxes? I suspect you have there menu xml file generated for trunk, which fails because tplot is not in G70.

That's it for the g.gui issue in g70. Thanks !

However, the error when launching g.gui.vdigit in trunk remains (with fresh check out at r66264). I don't have this problem in g70.

I've changed the title and parameters of this ticket to reflect that.

Should be fixed in r66351.

Yes, it is, thank you !

IIUC, this does not need to be ported to release70, so I'm closing the ticket.

comment:6 by neteler, 8 years ago

Milestone: 7.1.07.2.0

Milestone renamed

Note: See TracTickets for help on using tickets.