[GRASS-dev] [GRASS GIS] #239: crash if zooming in too much

On Jul 30, 2008, at 8:05 AM, <grass-dev-request@lists.osgeo.org> wrote:

Date: Wed, 30 Jul 2008 14:50:24 -0000
From: "GRASS GIS" <trac@osgeo.org>
Subject: [GRASS-dev] [GRASS GIS] #239: crash if zooming in too much
To: undisclosed-recipients:;
Message-ID: <042.96bc0dcf53e1293f1163968a93fb5e8d@osgeo.org>
Content-Type: text/plain; charset="utf-8"

#239: crash if zooming in too much
----------------------+-----------------------------------------------------
Reporter: msieczka | Owner: grass-dev@lists.osgeo.org
    Type: defect | Status: new
Priority: major | Milestone: 6.4.0
Component: default | Version: svn-develbranch6
Keywords: | Platform: Linux
     Cpu: x86-64 |
----------------------+-----------------------------------------------------
r32363

1. Add a raster map (raster or vector).

2. Zoom in until an error like this pops up:

{{{
Execution failed: 'd.rast map=N51E016@PERMANENT --q'

Details:
ERROR: region for current mapset line 1run "g.region"
}}}

3. Try to "Zoom to selected map" or any other zoom operation - a crash:

{{{
Traceback (most recent call last):
  File "/usr/local/grass-6.4.svn/etc/wxpython/gui_modules/ma
pdisp.py", line 2076, in OnZoomToMap

self.ZoomToMap()
  File "/usr/local/grass-6.4.svn/etc/wxpython/gui_modules/ma
pdisp.py", line 2129, in ZoomToMap

self.UpdateMap()
  File "/usr/local/grass-6.4.svn/etc/wxpython/gui_modules/ma
pdisp.py", line 579, in UpdateMap

self.mapfile = self.Map.Render(force=True,
mapWindow=self.parent, windres=windres)
  File "/usr/local/grass-6.4.svn/etc/wxpython/gui_modules/re
nder.py", line 762, in Render

if not layer.Render():
  File "/usr/local/grass-6.4.svn/etc/wxpython/gui_modules/re
nder.py", line 135, in Render

os.environ["GRASS_PNGFILE"] = self.mapfile
  File "/usr/lib/python2.5/os.py", line 474, in __setitem__

putenv(key, item)
TypeError
:
putenv() argument 2 must be string, not None
}}}

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

Arrgh. Fixed this in TclTk but seems like we need to fix it in wxPython too. Thanks for spotting it. With new graphic tools in wxpython, Glynn's rewrite of the display drivers, and Martin's work on nD visualization we may be reworking the display rendering engine. At the moment, I'm not sure how much will be back ported to wxpython. We might try a simple patch on this for the moment, however. I'll try to look into it.

Michael