[GRASS-dev] [GRASS GIS] #194: i.fusion.brovey: remove temp region file?

#194: i.fusion.brovey: remove temp region file?
-----------------------------+----------------------------------------------
Reporter: hamish | Owner: grass-dev@lists.osgeo.org
     Type: defect | Status: new
Priority: minor | Milestone: 6.4.0
Component: default | Version: svn-trunk
Keywords: i.fusion.brovey |
-----------------------------+----------------------------------------------
Hi,

just looking through the i.fusion.brovey script I see that the cleanup()
section resets the region to the temporary region file instead removing
it. Which, AFAICT, is a noop and leaves a saved region file behind.

It in not important that the WIND_OVERRIDE variable is not unset there --
that goes away automatically as soon as the script exits.

?

Hamish

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

#194: i.fusion.brovey: remove temp region file?
----------------------+-----------------------------------------------------
  Reporter: hamish | Owner: grass-dev@lists.osgeo.org
      Type: defect | Status: new
  Priority: minor | Milestone: 6.4.0
Component: default | Version: svn-trunk
Resolution: | Keywords: i.fusion.brovey
----------------------+-----------------------------------------------------
Comment (by hamish):

Also, it is unclear to me if the "clone current region" step is really
needed before setting WIND_OVERRIDE and using the new region file. I
notice i.in.spotvgt doesn't bother to do that.

ie can WIND_OVERRIDE legally point to a region wind file which does not
yet exist?

Hamish

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

#194: i.fusion.brovey: remove temp region file?
----------------------+-----------------------------------------------------
  Reporter: hamish | Owner: grass-dev@lists.osgeo.org
      Type: defect | Status: new
  Priority: minor | Milestone: 6.4.0
Component: default | Version: svn-trunk
Resolution: | Keywords: i.fusion.brovey
----------------------+-----------------------------------------------------
Comment (by neteler):

AFAIR WIND_OVERRIDE didn't exist when I was writing i.fusion.brovey. Feel
free to make appropriate fixes.

Markus

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

#194: i.fusion.brovey: remove temp region file?
----------------------+-----------------------------------------------------
  Reporter: hamish | Owner: grass-dev@lists.osgeo.org
      Type: defect | Status: new
  Priority: minor | Milestone: 6.4.0
Component: default | Version: svn-trunk
Resolution: | Keywords: i.fusion.brovey
----------------------+-----------------------------------------------------
Comment (by glynn):

Replying to [comment:1 hamish]:

> ie can WIND_OVERRIDE legally point to a region wind file which does not
yet exist?

It depends upon the situation, but in most cases, no. Anything which tries
to read the window (which lots of functions do implicitly) will fail if
WIND_OVERRIDE references a non-existent region.

In particular, g.region calls G_get_window() unless -d is given (any
command line settings override specific components of the current region),
which will fail if WIND_OVERRIDE is set but the region doesn't exit.

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

#194: i.fusion.brovey: remove temp region file?
----------------------+-----------------------------------------------------
  Reporter: hamish | Owner: grass-dev@lists.osgeo.org
      Type: defect | Status: closed
  Priority: minor | Milestone: 6.4.0
Component: default | Version: svn-trunk
Resolution: fixed | Keywords: i.fusion.brovey
----------------------+-----------------------------------------------------
Changes (by hamish):

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

Comment:

fixed in r31829, r31830, r31832.

Hamish

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