[GRASS-dev] [GRASS-SVN] r63475 - grass/trunk/gui/wxpython/mapdisp

Vaclav Petras wenzeslaus at gmail.com
Thu Dec 11 06:48:08 PST 2014


On Wed, Dec 10, 2014 at 4:41 PM, <svn_grass at osgeo.org> wrote:

> Author: martinl
> Date: 2014-12-10 13:41:10 -0800 (Wed, 10 Dec 2014)
> New Revision: 63475
>
> Modified:
>    grass/trunk/gui/wxpython/mapdisp/main.py
> Log:
> d.mon wx0: don't call g.gisenv in the watcher (it's too much invasive) -
> TODO: find better solution
>
> Modified: grass/trunk/gui/wxpython/mapdisp/main.py
> ===================================================================
> --- grass/trunk/gui/wxpython/mapdisp/main.py    2014-12-10 21:17:38 UTC
> (rev 63474)
> +++ grass/trunk/gui/wxpython/mapdisp/main.py    2014-12-10 21:41:10 UTC
> (rev 63475)
> @@ -412,14 +412,19 @@
>          """Redraw, if new layer appears (check's timestamp of
>          cmdfile)
>          """
> -        try:
> -            # GISBASE and other sytem enviromental variables can not be
> used
> +        ###
> +        ### TODO: fint better solution
> +        ###
> +        ### the check bellow disabled, it's invasive to call g.gisenv
> +        ### in the watcher...
> +        # try:
> +            # GISBASE and other system enviromental variables can not be
> used
>              # since the process inherited them from GRASS
>              # raises exception when vaiable does not exists
> -            grass.gisenv()['GISDBASE']
> -        except KeyError:
> -            self.timer.Stop()
> -            return
> +            ### grass.gisenv()['GISDBASE']
> +        # except KeyError:
> +        #    self.timer.Stop()
> +        #    return
>
>          # todo: events
>          try:
>
> Just to clarify, the purpose of the code was just to check if GRASS is
still running and stop redrawing if it is not? I'm not sure what is the
behavior now, perhaps some errors somewhere. But the main GUI also does not
check if GRASS is running and just throws some errors, so maybe the need
for a better solution is not so big and/or it applies to all GUI
applications (d.mon wx*, g.gui, g.gui.*).

http://trac.osgeo.org/grass/changeset/63475
http://trac.osgeo.org/grass/changeset/63476


> _______________________________________________
> grass-commit mailing list
> grass-commit at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/grass-commit
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/grass-dev/attachments/20141211/b312a317/attachment.html>


More information about the grass-dev mailing list