[GRASS-dev] [GRASS GIS] #2746: GUI fails to start: wx3.0 issue ?

#2746: GUI fails to start: wx3.0 issue ?
-------------------------+---------------------------------
Reporter: mlennert | Owner: grass-dev@…
     Type: defect | Status: new
Priority: critical | Milestone: 7.0.2
Component: wxGUI | Version: svn-releasebranch70
Keywords: g.gui wxgui | CPU: Unspecified
Platform: Linux |
-------------------------+---------------------------------
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
}}}

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/2746&gt;
GRASS GIS <https://grass.osgeo.org>

#2746: GUI fails to start: wx3.0 issue ?
--------------------------+---------------------------------
  Reporter: mlennert | Owner: grass-dev@…
      Type: defect | Status: new
  Priority: critical | Milestone: 7.0.2
Component: wxGUI | Version: svn-releasebranch70
Resolution: | Keywords: g.gui wxgui
       CPU: Unspecified | Platform: Linux
--------------------------+---------------------------------

Comment (by mlennert):

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.

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/2746#comment:1&gt;
GRASS GIS <https://grass.osgeo.org>

#2746: GUI fails to start: wx3.0 issue ?
--------------------------+---------------------------------
  Reporter: mlennert | Owner: grass-dev@…
      Type: defect | Status: new
  Priority: critical | Milestone: 7.0.2
Component: wxGUI | Version: svn-releasebranch70
Resolution: | Keywords: g.gui wxgui
       CPU: Unspecified | Platform: Linux
--------------------------+---------------------------------

Comment (by 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.

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/2746#comment:2&gt;
GRASS GIS <https://grass.osgeo.org>

#2746: 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"
--------------------------+------------------------------------
  Reporter: mlennert | Owner: grass-dev@…
      Type: defect | Status: new
  Priority: critical | Milestone: 7.1.0
Component: wxGUI | Version: svn-trunk
Resolution: | Keywords: g.gui.vdigit digitizer
       CPU: Unspecified | Platform: Linux
--------------------------+------------------------------------
Changes (by mlennert):

* keywords: g.gui wxgui => g.gui.vdigit digitizer
* version: svn-releasebranch70 => svn-trunk
* milestone: 7.0.2 => 7.1.0

Comment:

Replying to [comment:2 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.

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/2746#comment:3&gt;
GRASS GIS <https://grass.osgeo.org>

#2746: 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"
--------------------------+------------------------------------
  Reporter: mlennert | Owner: grass-dev@…
      Type: defect | Status: new
  Priority: critical | Milestone: 7.1.0
Component: wxGUI | Version: svn-trunk
Resolution: | Keywords: g.gui.vdigit digitizer
       CPU: Unspecified | Platform: Linux
--------------------------+------------------------------------

Comment (by annakrat):

Replying to [comment:3 mlennert]:
> Replying to [comment:2 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.

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/2746#comment:4&gt;
GRASS GIS <https://grass.osgeo.org>

#2746: 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"
--------------------------+------------------------------------
  Reporter: mlennert | Owner: grass-dev@…
      Type: defect | Status: closed
  Priority: critical | Milestone: 7.1.0
Component: wxGUI | Version: svn-trunk
Resolution: fixed | Keywords: g.gui.vdigit digitizer
       CPU: Unspecified | Platform: Linux
--------------------------+------------------------------------
Changes (by mlennert):

* status: new => closed
* resolution: => fixed

Comment:

Replying to [comment:4 annakrat]:
> Replying to [comment:3 mlennert]:
> > Replying to [comment:2 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.

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/2746#comment:5&gt;
GRASS GIS <https://grass.osgeo.org>