[GRASS-dev] [Temporal] Access a temporal dataset from another mapset

Laurent C. lrntct at gmail.com
Fri Aug 5 14:38:27 PDT 2016


Hello all,

I have several STRDS of rainfall covering a whole country, in a
specific mapset dedicated to rainfall data.
I'd like to run some hydraulic simulations in different regions of the
country, that output several STRDS as results.
For the sake of organizing the data, every study area has its own mapset.
The hydraulic model calls the STRDS from the other mapset return an error:

```
[...]
  File "/home/jrodriguezri/.local/lib/python2.7/site-packages/itzi/gis.py",
line 138, in name_is_stds
    if tgis.SpaceTimeRasterDataset(name).is_in_db():
  File "/usr/lib/grass70/etc/python/grass/temporal/abstract_dataset.py",
line 370, in is_in_db
    return self.base.is_in_db(dbif)
  File "/usr/lib/grass70/etc/python/grass/temporal/base.py", line 314,
in is_in_db
    dbif.execute(sql, mapset=self.mapset)
  File "/usr/lib/grass70/etc/python/grass/temporal/core.py", line 956,
in execute
    "mapset <%(mapset)s>" % {"mapset": mapset}))
  File "/usr/lib/grass70/etc/python/grass/pygrass/messages/__init__.py",
line 269, in fatal
    raise FatalError(message)
grass.exceptions.FatalError: Unable to execute sql statement. There is
no temporal database connection defined for mapset <Lluvia>
```

I realize that if I try to open a strds from another mapset with
t.rst.list, I get a similar error:

```
ERROR: Unable to execute sql statement. There is no temporal database
connection defined for mapset
```

Searching for an open ticket about it, I encounter #2110 which seems
related, but it's quite old and it seems in the discussion that a
STRDS should behave like a map, which could be open from another
mapset.

Is it a normal behaviour, and if it's the case, what is the workaround?

Cheers,
Laurent


More information about the grass-dev mailing list