[GRASS-dev] [GRASS-user] no more gui after upgrade to buster

Hi,

any chance that you update to the much more modern GRASS GIS 7.8?

Best
Markus

On Thu, Jan 9, 2020 at 6:05 PM Frank David <frank.david@geophom.fr> wrote:

Hello all,

I have no more gui on grass 7.6 after upgrade from debian strech to buster.

Thank you for your help !

Regards

Frank

See below last errors :

Traceback (most recent call last):
  File "/usr/local/grass-7.6.0/gui/wxpython/wxgui.py", line 169, in <module>
    sys.exit(main())
  File "/usr/local/grass-7.6.0/gui/wxpython/wxgui.py", line 156, in main
    app = GMApp(workspaceFile)
  File "/usr/local/grass-7.6.0/gui/wxpython/wxgui.py", line 50, in __init__
    wx.App.__init__(self, False)
  File "/usr/lib/python2.7/dist-packages/wx-3.0-gtk3/wx/_core.py", line 8628, in __init__
    self._BootstrapApp()
  File "/usr/lib/python2.7/dist-packages/wx-3.0-gtk3/wx/_core.py", line 8196, in _BootstrapApp
    return _core_.PyApp__BootstrapApp(*args, **kwargs)
  File "/usr/local/grass-7.6.0/gui/wxpython/wxgui.py", line 103, in OnInit
    workspace=self.workspaceFile)
  File "/usr/local/grass-7.6.0/gui/wxpython/lmgr/frame.py", line 142, in __init__
    self.notebook = self._createNoteBook()
  File "/usr/local/grass-7.6.0/gui/wxpython/lmgr/frame.py", line 337, in _createNoteBook
    gcstyle=GC_PROMPT)
  File "/usr/local/grass-7.6.0/gui/wxpython/gui_core/goutput.py", line 118, in __init__
    self.cmdPrompt = GPromptSTC(parent=self, menuModel=self._menuModel)
  File "/usr/local/grass-7.6.0/gui/wxpython/gui_core/prompt.py", line 139, in __init__
    GPrompt.__init__(self, parent=parent, menuModel=menuModel)
  File "/usr/local/grass-7.6.0/gui/wxpython/gui_core/prompt.py", line 57, in __init__
    self.mapList = self._getListOfMaps()
  File "/usr/local/grass-7.6.0/gui/wxpython/gui_core/prompt.py", line 101, in _getListOfMaps
    result['raster'] = grass.list_strings('raster')
  File "/usr/local/grass-7.6.0/etc/python/grass/script/core.py", line 1252, in list_strings
    mapset=mapset).splitlines():
  File "/usr/local/grass-7.6.0/etc/python/grass/script/core.py", line 478, in read_command
    return handle_errors(returncode, stdout, args, kwargs)
  File "/usr/local/grass-7.6.0/etc/python/grass/script/core.py", line 334, in handle_errors
    returncode=returncode)
grass.exceptions.CalledModuleError: Module run None ['g.list', '--q', '-m', 'type=raster'] ended with error
Process ended with non-zero return code 127. See errors in the (error) output.
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

--
_______________________________________________
grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

--
Markus Neteler, PhD
https://www.mundialis.de - free data with free software
https://grass.osgeo.org
https://courses.neteler.org/blog

On Sat, Jan 11, 2020 at 4:51 PM Frank David <frank.david@geophom.fr> wrote:

Hi,

Yes why not. Is the installation procedure is same than stretch ?

I guess it will be the same/similar (I am more Fedora focused but
others here will know).

Is Python3 support will not make problems with my Python2 scripts ? and what to do to avoid in that case ?

The Python package "python3-dev[el]" contains a `2to3` script to update scripts.
Most welcome esp. for the change of print "bla" to print("bla"). :slight_smile:

Do I follow this ? > https://grasswiki.osgeo.org/wiki/Compile_and_Install#GRASS_7_on_Debian_Stretch

Yes, and pls report if anything fails.

Markus

On Sat, Jan 11, 2020 at 6:03 PM Frank David <frank.david@geophom.fr> wrote:

Markus,

I've installed needed packages for garss 7.8 included python3-wxgtk4. libmaria does not exist but libmaria3

[...]

Compile & install ok

The gui is working.

BUT my scripts does not work any more. See belows errors :

Traceback (most recent call last):
  File "/usr/local/grass78/gui/wxpython/gui_core/forms.py",
line 2866, in ParseCommand

[...]

name 'unicode' is not defined

----------------------------

If I add # -*- coding:UTF-8 -*- on first line in /usr/local/grass78/etc/python/grass/lib/gis.py and /usr/local/grass78/etc/python/grass/lib/raster.py my scripts work !

Interesting!

Is-it the good fix ??

It would follow:
https://www.python.org/dev/peps/pep-0263/#defining-the-encoding

The file is generated by ctypesgen.py to wrap C, I am not sure how the
encoding could be added there.
Could you open a ticket here?
https://trac.osgeo.org/grass

with the information (+ the Locale you use, is it US or French or...?).

Best
Markus

PS: I have started a wiki entry here (please update):
https://grasswiki.osgeo.org/wiki/Compile_and_Install#GRASS_7_on_Debian_Buster

Hi,

Yes why not. Is the installation procedure is same than stretch ? Is Python3 support will not make problems with my Python2 scripts ? and what to do to avoid in that case ?

Do I follow this ? > https://grasswiki.osgeo.org/wiki/Compile_and_Install#GRASS_7_on_Debian_Stretch

Thank you

···

Le 10/01/2020 à 21:01, Markus Neteler a écrit :

Hi,

any chance that you update to the much more modern GRASS GIS 7.8?

Best
Markus

On Thu, Jan 9, 2020 at 6:05 PM Frank David [<frank.david@geophom.fr>](mailto:frank.david@geophom.fr) wrote:

Hello all,

I have no more gui on grass 7.6 after upgrade from debian strech to buster.

Thank you for your help !

Regards

Frank

See below last errors :

Traceback (most recent call last):
  File "/usr/local/grass-7.6.0/gui/wxpython/wxgui.py", line 169, in <module>
    sys.exit(main())
  File "/usr/local/grass-7.6.0/gui/wxpython/wxgui.py", line 156, in main
    app = GMApp(workspaceFile)
  File "/usr/local/grass-7.6.0/gui/wxpython/wxgui.py", line 50, in __init__
    wx.App.__init__(self, False)
  File "/usr/lib/python2.7/dist-packages/wx-3.0-gtk3/wx/_core.py", line 8628, in __init__
    self._BootstrapApp()
  File "/usr/lib/python2.7/dist-packages/wx-3.0-gtk3/wx/_core.py", line 8196, in _BootstrapApp
    return _core_.PyApp__BootstrapApp(*args, **kwargs)
  File "/usr/local/grass-7.6.0/gui/wxpython/wxgui.py", line 103, in OnInit
    workspace=self.workspaceFile)
  File "/usr/local/grass-7.6.0/gui/wxpython/lmgr/frame.py", line 142, in __init__
    self.notebook = self._createNoteBook()
  File "/usr/local/grass-7.6.0/gui/wxpython/lmgr/frame.py", line 337, in _createNoteBook
    gcstyle=GC_PROMPT)
  File "/usr/local/grass-7.6.0/gui/wxpython/gui_core/goutput.py", line 118, in __init__
    self.cmdPrompt = GPromptSTC(parent=self, menuModel=self._menuModel)
  File "/usr/local/grass-7.6.0/gui/wxpython/gui_core/prompt.py", line 139, in __init__
    GPrompt.__init__(self, parent=parent, menuModel=menuModel)
  File "/usr/local/grass-7.6.0/gui/wxpython/gui_core/prompt.py", line 57, in __init__
    self.mapList = self._getListOfMaps()
  File "/usr/local/grass-7.6.0/gui/wxpython/gui_core/prompt.py", line 101, in _getListOfMaps
    result['raster'] = grass.list_strings('raster')
  File "/usr/local/grass-7.6.0/etc/python/grass/script/core.py", line 1252, in list_strings
    mapset=mapset).splitlines():
  File "/usr/local/grass-7.6.0/etc/python/grass/script/core.py", line 478, in read_command
    return handle_errors(returncode, stdout, args, kwargs)
  File "/usr/local/grass-7.6.0/etc/python/grass/script/core.py", line 334, in handle_errors
    returncode=returncode)
grass.exceptions.CalledModuleError: Module run None ['g.list', '--q', '-m', 'type=raster'] ended with error
Process ended with non-zero return code 127. See errors in the (error) output.
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

--
_______________________________________________
grass-user mailing list
[grass-user@lists.osgeo.org](mailto:grass-user@lists.osgeo.org)
[https://lists.osgeo.org/mailman/listinfo/grass-user](https://lists.osgeo.org/mailman/listinfo/grass-user)


Geophom
327 rue de Vieille Cour 44521 OUDON
Tel +33(0)2 85 52 02 59 - Port +33(0)6 04 47 91 06
www.geophom.fr

Hi

I had (and still have) a similar problem that I began experiencing when I updated to 7.8. I may be mistaken but as far as I understand it is not GRASS but something related to wxPython for python 3 in the platform in question. I am using openSUSE 15.1 and already spent a too much time trying in vain to solve this. For the time being I will use GRASS in command line or via QGIS.

/H.

···

On 2020-01-11 10:52, Frank David wrote:

Hi,

Yes why not. Is the installation procedure is same than stretch ? Is Python3 support will not make problems with my Python2 scripts ? and what to do to avoid in that case ?

Do I follow this ? > https://grasswiki.osgeo.org/wiki/Compile_and_Install#GRASS_7_on_Debian_Stretch

Thank you

Le 10/01/2020 à 21:01, Markus Neteler a écrit :

Hi,

any chance that you update to the much more modern GRASS GIS 7.8?

Best
Markus

On Thu, Jan 9, 2020 at 6:05 PM Frank David [<frank.david@geophom.fr>](mailto:frank.david@geophom.fr) wrote:

Hello all,

I have no more gui on grass 7.6 after upgrade from debian strech to buster.

Thank you for your help !

Regards

Frank

See below last errors :

Traceback (most recent call last):
  File "/usr/local/grass-7.6.0/gui/wxpython/wxgui.py", line 169, in <module>
    sys.exit(main())
  File "/usr/local/grass-7.6.0/gui/wxpython/wxgui.py", line 156, in main
    app = GMApp(workspaceFile)
  File "/usr/local/grass-7.6.0/gui/wxpython/wxgui.py", line 50, in __init__
    wx.App.__init__(self, False)
  File "/usr/lib/python2.7/dist-packages/wx-3.0-gtk3/wx/_core.py", line 8628, in __init__
    self._BootstrapApp()
  File "/usr/lib/python2.7/dist-packages/wx-3.0-gtk3/wx/_core.py", line 8196, in _BootstrapApp
    return _core_.PyApp__BootstrapApp(*args, **kwargs)
  File "/usr/local/grass-7.6.0/gui/wxpython/wxgui.py", line 103, in OnInit
    workspace=self.workspaceFile)
  File "/usr/local/grass-7.6.0/gui/wxpython/lmgr/frame.py", line 142, in __init__
    self.notebook = self._createNoteBook()
  File "/usr/local/grass-7.6.0/gui/wxpython/lmgr/frame.py", line 337, in _createNoteBook
    gcstyle=GC_PROMPT)
  File "/usr/local/grass-7.6.0/gui/wxpython/gui_core/goutput.py", line 118, in __init__
    self.cmdPrompt = GPromptSTC(parent=self, menuModel=self._menuModel)
  File "/usr/local/grass-7.6.0/gui/wxpython/gui_core/prompt.py", line 139, in __init__
    GPrompt.__init__(self, parent=parent, menuModel=menuModel)
  File "/usr/local/grass-7.6.0/gui/wxpython/gui_core/prompt.py", line 57, in __init__
    self.mapList = self._getListOfMaps()
  File "/usr/local/grass-7.6.0/gui/wxpython/gui_core/prompt.py", line 101, in _getListOfMaps
    result['raster'] = grass.list_strings('raster')
  File "/usr/local/grass-7.6.0/etc/python/grass/script/core.py", line 1252, in list_strings
    mapset=mapset).splitlines():
  File "/usr/local/grass-7.6.0/etc/python/grass/script/core.py", line 478, in read_command
    return handle_errors(returncode, stdout, args, kwargs)
  File "/usr/local/grass-7.6.0/etc/python/grass/script/core.py", line 334, in handle_errors
    returncode=returncode)
grass.exceptions.CalledModuleError: Module run None ['g.list', '--q', '-m', 'type=raster'] ended with error
Process ended with non-zero return code 127. See errors in the (error) output.
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

--
_______________________________________________
grass-user mailing list
[grass-user@lists.osgeo.org](mailto:grass-user@lists.osgeo.org)
[https://lists.osgeo.org/mailman/listinfo/grass-user](https://lists.osgeo.org/mailman/listinfo/grass-user)


Geophom
327 rue de Vieille Cour 44521 OUDON
Tel +33(0)2 85 52 02 59 - Port +33(0)6 04 47 91 06
www.geophom.fr

_______________________________________________
grass-user mailing list
[grass-user@lists.osgeo.org](mailto:grass-user@lists.osgeo.org)
[https://lists.osgeo.org/mailman/listinfo/grass-user](https://lists.osgeo.org/mailman/listinfo/grass-user)

On Sat, Jan 11, 2020 at 12:08 PM Hernán De Angelis
<dhdeangelis@comhem.se> wrote:

I had (and still have) a similar problem that I began experiencing when I updated to 7.8. I may be mistaken but as far as I understand it is not GRASS but something related to wxPython for python 3 in the platform in question. I am using openSUSE 15.1 and already spent a too much time trying in vain to solve this. For the time being I will use GRASS in command line or via QGIS.

Did you report the error? I don't see any related trac bug report or
email (maybe I am overlooking it).

Markus

Markus,

I’ve installed needed packages for garss 7.8 included python3-wxgtk4. libmaria does not exist but libmaria3

Configuration has return :

BLAS support: yes
BZIP2 support: no
C++ support: yes
Cairo support: yes
DWG support: no
FFTW support: yes
FreeType support: yes
GDAL support: yes
GEOS support: yes
LAPACK support: yes
Large File support (LFS): yes
libLAS support: no
MySQL support: yes
NetCDF support: yes
NLS support: yes
ODBC support: yes
OGR support: yes
OpenCL support: no
OpenGL support: yes
OpenMP support: yes
PDAL support: no
PNG support: yes
POSIX thread support: no
PostgreSQL support: yes
Readline support: yes
Regex support: yes
SQLite support: yes
TIFF support: yes
X11 support: no
Zstandard support: yes

using new PROJ 5+ API

···

Le 11/01/2020 à 17:19, Markus Neteler a écrit :

On Sat, Jan 11, 2020 at 4:51 PM Frank David [<frank.david@geophom.fr>](mailto:frank.david@geophom.fr) wrote:

Hi,

Yes why not. Is the installation procedure is same than stretch ?

I guess it will be the same/similar (I am more Fedora focused but
others here will know).

Is Python3 support will not make problems with my Python2 scripts ? and what to do to avoid in that case ?

The Python package "python3-dev[el]" contains a `2to3` script to update scripts.
Most welcome esp. for the change of print "bla" to print("bla").   :-)

Do I follow this ? > [https://grasswiki.osgeo.org/wiki/Compile_and_Install#GRASS_7_on_Debian_Stretch](https://grasswiki.osgeo.org/wiki/Compile_and_Install#GRASS_7_on_Debian_Stretch)

Yes, and pls report if anything fails.

Markus

Done.

Thanks

Frank

Le 11/01/2020 à 18:51, Markus Neteler a écrit :

Could you open a ticket here?
https://trac.osgeo.org/grass

On 2020-01-11 17:22, Markus Neteler wrote:

On Sat, Jan 11, 2020 at 12:08 PM Hernán De Angelis
<dhdeangelis@comhem.se> wrote:

I had (and still have) a similar problem that I began experiencing when I updated to 7.8. I may be mistaken but as far as I understand it is not GRASS but something related to wxPython for python 3 in the platform in question. I am using openSUSE 15.1 and already spent a too much time trying in vain to solve this. For the time being I will use GRASS in command line or via QGIS.

Did you report the error? I don't see any related trac bug report or
email (maybe I am overlooking it).

No, I did not report this to the GRASS list. I probably tweaked too many things, many more that I can remember to make a useful account of what happened. But as I wrote I have reasons to believe the problem is related to the local wxPython implementation, not GRASS.

H.