[prev in list] [next in list] [prev in thread] [next in thread]
List: qgis-developer
Subject: [QGIS-Developer] Docs Travis, Failed to open /usr/share/qgis/resources/data/world_map.gpkg:
From: Richard Duivenvoorde <rdmailings () duif ! net>
Date: 2020-10-27 19:22:54
Message-ID: a7faa20b-93ed-8b21-7a47-f710a4c6d8cb () duif ! net
[Download RAW message or body]
Hi Devs,
A build of a Docs PR of my [0] in which I try to open the world_map.gpkg is failing \
because:
Warning 4: Failed to open /usr/share/qgis/resources/data/world_map.gpkg: Permission \
denied.
In my local builds
iface.addVectorLayer(os.path.join(QgsApplication.pkgDataPath(),'resources','data','world_map.gpkg|layername=Countries'), \
'', 'ogr')
just works.
But in Travis (and a global install) apparently the resources are not readable by a \
normal user.
What could be the best solution for that:
- add an install step which makes such resources available for users (and their \
plugins?)
- create code so the inbuilt: uri's would work (see [1])
iface.addVectorLayer('inbuilt:/data/world_map.gpkg|layername=countries', 'Countries', \
'ogr')
Any input appreciated, Thanks,
Richard
[0] https://github.com/qgis/QGIS-Documentation/pull/5521
[1] https://github.com/qgis/QGIS/pull/39175
_______________________________________________
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic