Opened 14 years ago
Closed 14 years ago
#2571 closed bug (invalid)
Path to GRASS vector map loses "vector/" in path string
Reported by: | neteler | Owned by: | rugginoso |
---|---|---|---|
Priority: | major: does not work as expected | Milestone: | Version 1.5.0 |
Component: | GRASS | Version: | Trunk |
Keywords: | vector | Cc: | rblazek |
Must Fix for Release: | Yes | Platform: | All |
Platform Version: | Awaiting user input: | no |
Description
To access Quantum GIS environment from this console use qgis.utils.iface object (instance of QgisInterface class). >>> iface=qgis.utils.iface >>> map=iface.mapCanvas() >>> print map.layer(0).source() /home/neteler/grassdata/patUTM32/mymapset/box/1_polygon >>>
the correct path to a GRASS vector layer would be including "vector/" in the string:
/home/neteler/grassdata/patUTM32/mymapset/vector/box/1_polygon
Note: for raster layers it is ok:
>>> print map.layer(1).source() /home/neteler/grassdata/patUTM32/neteler/cellhd/elevation
The omission of "vector/" in the string leads to troubles in ogr2ogr called by QGIS plugins.
Change History (3)
comment:1 by , 14 years ago
Cc: | added |
---|
comment:2 by , 14 years ago
Priority: | critical: causes crash or data corruption → major: does not work as expected |
---|
comment:3 by , 14 years ago
Resolution: | → invalid |
---|---|
Status: | new → closed |
Note:
See TracTickets
for help on using tickets.
layer.source() is internal data provider representation of data location. For GRASS vector provider it is GISBASE/LOCATION/MAPSET/MAP/LAYER_TYPE.
Expecting that layer.source should be a valid OGR DSN is just misunderstanding.
Warning: please don't try to change that format, it would break all old project files.