Skip to content
Permalink
Browse files
Vector vrt files should be marked as potential containers
Matches behaviour on GDAL <3.4 builds with GDAL >= 3.4 builds
  • Loading branch information
nyalldawson committed Aug 26, 2021
1 parent ff302ca commit 3722b16ebdcaef2076b4e506d92c282372d3fce7
Showing with 2 additions and 1 deletion.
  1. +1 −0 src/core/qgsgdalutils.cpp
  2. +1 −1 tests/src/python/test_provider_ogr.py
@@ -623,6 +623,7 @@ QStringList QgsGdalUtils::multiLayerFileExtensions()
QStringLiteral( "gpx" ),
QStringLiteral( "pdf" ),
QStringLiteral( "pbf" ),
QStringLiteral( "vrt" ),
QStringLiteral( "nc" ),
QStringLiteral( "shp.zip" ) };
return SUPPORTED_DB_LAYERS_EXTENSIONS;
@@ -2218,7 +2218,7 @@ def test_provider_sublayer_details_fast_scan(self):
self.assertEqual(res[0].uri(), os.path.join(TEST_DATA_DIR, "vector_vrt.vrt"))
self.assertEqual(res[0].providerKey(), "ogr")
self.assertEqual(res[0].type(), QgsMapLayerType.VectorLayer)
self.assertFalse(res[0].skippedContainerScan())
self.assertTrue(res[0].skippedContainerScan())

# raster vrt
res = metadata.querySublayers(os.path.join(TEST_DATA_DIR, "/raster/hub13263.vrt"), Qgis.SublayerQueryFlag.FastScan)

0 comments on commit 3722b16

Please sign in to comment.