I am a bit at a loss with v.external.out and GPKG:
grass76 ~/grassdata/nc_spm_08_grass7/user1/
outdir=/tmp/rast2vect/
mkdir -p $outdir
v.external.out output=$outdir format=GPKG
g.region raster=landclass96 -p
r.to.vect input=landclass96 output=landclass96 type=area column=landuse
Extracting areas...
100%
Writing areas...
100%
Registering primitives...
Building areas...
100%
Attaching islands...
100%
Attaching centroids...
100%
Warning 1: The '' extension is not allowed by the GPKG specification,
which may cause compatibility problems
ERROR 1: A file system object called '/home/mneteler/rast2vect/' already exists.
WARNING: Unable to create OGR data source '/home/mneteler/rast2vect/'
WARNING: Unable to create vector map <landclass96>
r.to.vect complete.
This Warning 1 likely comes from GDAL/OGR since no file extension is
provided. But how to use that properly?
r.to.vect input=landclass96 output=landclass96.gpkg type=area column=landuse
WARNING: Illegal vector map name <landclass96.gpkg>. Character '.' not
allowed.
ERROR: Unable to create vector map: <landclass96.gpkg> is not SQL compliant
WARNING: Invalid vector map name <>
Maybe v.external.out lacks an extension= parameter? Or any other trick?
čt 13. 9. 2018 v 16:10 odesílatel Markus Neteler <neteler@osgeo.org> napsal:
v.external.out output=$outdir format=GPKG
$outdir should point to GPKG file not to directory, eg.
v.external.out output=/tmp/test.gpkg format=GPKG
Unfortunately r.to.vect still fails:
Copying features...
WARNING: Boundary is not closed. Feature skipped.
WARNING: Unable to write feature in vector map <landclass96>
WARNING: Writing new feature failed
čt 13. 9. 2018 v 16:10 odesílatel Markus Neteler <neteler@osgeo.org> napsal:
v.external.out output=$outdir format=GPKG
$outdir should point to GPKG file not to directory, eg.
v.external.out output=/tmp/test.gpkg format=GPKG
Unfortunately r.to.vect still fails:
Copying features…
WARNING: Boundary is not closed. Feature skipped.
WARNING: Unable to write feature in vector map
WARNING: Writing new feature failed
It would require fix.
this won’t fix because topological areas can only be converted to non-topological polygons after all boundaries and centroids have been written out and after topology has been built.
pá 14. 9. 2018 v 10:18 odesílatel Markus Metz
<markus.metz.giswork@gmail.com> napsal:
this won't fix because topological areas can only be converted to non-topological polygons after all boundaries and centroids have been written out and after topology has been built.
sure, it would require change logic (and core Vlib functions [1])
which would support writing external (simple features) output. But I
wouldn't call it "won't fix".
@MarkusN Please create issue otherwise it will be forgotten.