eryk918 / postgis_toolbox

Plugin for QGIS implementing selected PostGIS functions
GNU General Public License v3.0
3 stars 0 forks source link

Crash when importing raster with nonstandard coordinate system (no srid / selection dialog accessing gui off main thread?) #7

Open deliciouslytyped opened 2 weeks ago

deliciouslytyped commented 2 weeks ago

Trying to import raster layers into PostGIS can lead to a crash possibly because:

The srid is passed through the code to the sql invocation https://postgis.net/docs/RT_ST_FromGDALRaster.html , which takes an srid. The docs state If srid is NULL, the function will try to automatically assign the SRID from the GDAL raster. If srid is provided, the value provided will override any automatically assigned SRID..

I don't know if the gdal raster string contains metadata, in which case maybe that could be used implicitly to pass the cgs?

In some cases the selection dialog comes up successfully but crashes later.