Hi, and thanks for answering.
Well, it seems that I've been so preoccupied with my current acticity that I missed the real issue which is apparently much wider and weirder. So, indeed, nothing to do with database tables and r.drain. Apparently, deleting any vector layer gives me the error when using g.remove. I tried creating a new location and mapset, but ran into the same problem. When removing a vector layer the hist, sidx and topo files aren't deleted. I figured it could have something to do with user rights and ran the same operation as an admin, but to no avail. No such issue with GRASS 6 though. The GRASS 7 I'm running currently however is a week-old r55595-540 as the later ones have been giving the error regarding pygrass and g.region at startup. Could this be the key to my issue?

Cheers,
Allar

On 09/04/2013 15:01, Markus Metz wrote:
On Tue, Apr 9, 2013 at 3:21 PM, Allar Haav <[email protected]> wrote:
Hi,

Several modules (for example, r.drain) produce vector layers that are to
some extent broken, at least in WinGRASS 7. Most probably something to do
with database connections as these seem to be missing for them.
Database connections are optional for vector maps. Why do you think
the vector map created by r.drain is broken? What do v.info and
v.category op=report say? The vector map created by r.drain does not
have a database connection, thus also no attribute table. You can add
a table with v.db.addtable if you want to upload some attributes.

Anyway, I
still need to use the output files and I've been creating db tables for them
manually. While they are usable after that, it is nevertheless impossible to
get rid of them afterwards. Using g.remove, the sample command output is as
follows:
Removing vector <vectpath@PERMANENT>
WARNING: Unable to delete file
'C:\GIS\GRASS/Kuigatsi/PERMANENT/vector/vectpath/hist'
WARNING: Unable to delete vector map
WARNING: <vectpath> nothing removed
(Tue Apr 09 13:58:29 2013) Command finished (0 sec)
How exactly did you create db tables? The commands you used are needed
to reproduce and fix the problem.

Markus M

So far the only way of removing those layers is just deleting their actual
files, but this isn't a good workaround as I'm trying to use it in a Python
script. Is there any better way to force the removal of those layers?

Regards,
Allar
_______________________________________________
grass-user mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/grass-user

_______________________________________________
grass-user mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/grass-user

Reply via email to