qgis-stac-plugin
qgis-stac-plugin copied to clipboard
Asset with GeoJSON media type cannot be added as layer, but it should be allowed
When I have an Item that has an asset of type geojson, the "Add asset as layer" button is disabled for that item.
For example:
{
"type": "Feature",
...
"assets": {
"my_geojson": {
"href": "https://s3.amazonaws.com/my-bucket/my.geojson",
"type": "application/geo+json",
"title": "My Geojson"
}
}
}
assets_dialog.py and asset_widget.py have a list of 4 media types that are allowed to be added as layers from a STAC Item:
layer_types = [
AssetLayerType.COG.value,
AssetLayerType.COPC.value,
AssetLayerType.GEOTIFF.value,
AssetLayerType.NETCDF.value,
]
However, asset AssetLayerType defines others that can be loaded, e.g., GeoJSON, that I think are supposed to be in the layer_types but are missing.
+1. Loading GEOJSON and GEOPACKAGE [1] would be useful