From 4f07c5a1ab795c5cb3a7cd7cfd8b777634677231 Mon Sep 17 00:00:00 2001 From: Just van den Broecke Date: Tue, 26 Mar 2024 02:59:51 +0100 Subject: [PATCH] #378 fix BGT ETL GDAL options for missing SRS dimensions with GML_SRS_DIMENSION_IF_MISSING --- bgt/etl/conf/etl-imgeo-v2.1.1.cfg | 2 +- stetlcomponents/gfspreparationfilter.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bgt/etl/conf/etl-imgeo-v2.1.1.cfg b/bgt/etl/conf/etl-imgeo-v2.1.1.cfg index 0c44b2a6..3258cf10 100644 --- a/bgt/etl/conf/etl-imgeo-v2.1.1.cfg +++ b/bgt/etl/conf/etl-imgeo-v2.1.1.cfg @@ -114,7 +114,7 @@ spatial_extent = {spatial_extent} # gfs template: not needed, since this is being taken care of by the GfsPreparationFilter #gfs_template = {temp_dir}/prepped.gfs # miscellaneous ogr2ogr options -options = -append -gt 65536 {multi_opts} +options = -append -gt 65536 --config GML_SRS_DIMENSION_IF_MISSING 2 {multi_opts} # cleanup input? cleanup_input = True diff --git a/stetlcomponents/gfspreparationfilter.py b/stetlcomponents/gfspreparationfilter.py index bfe10892..f529d77f 100644 --- a/stetlcomponents/gfspreparationfilter.py +++ b/stetlcomponents/gfspreparationfilter.py @@ -156,7 +156,7 @@ def invoke(self, packet): return packet def execute_ogrinfo(self, gml_file): - ogrinfo_cmd = 'ogrinfo -ro -al -so %s' % gml_file + ogrinfo_cmd = 'ogrinfo --config GML_SRS_DIMENSION_IF_MISSING 2 -ro -al -so %s' % gml_file use_shell = True if os.name == 'nt':