[postgis-tickets] [PostGIS] #4555: Can't repackage postgis_raster with postgis_extensions_upgrade when postgis not installed in public
PostGIS
trac at osgeo.org
Sun Oct 20 17:14:51 PDT 2019
#4555: Can't repackage postgis_raster with postgis_extensions_upgrade when postgis
not installed in public
-----------------------------------+---------------------------
Reporter: robe | Owner: strk
Type: defect | Status: new
Priority: blocker | Milestone: PostGIS 3.0.1
Component: build/upgrade/install | Version: 3.0.x
Keywords: |
-----------------------------------+---------------------------
{{{
CREATE SCHEMA postgis;
ALTER DATABASE test SET search_path=public, contrib, postgis, tiger,
utility;
}}}
-- reconnect
{{{
CREATE EXTENSION postgis SCHEMA postgis VERSION "2.5.3";
-- disconnect
}}}
-- reconnect
{{{
SELECT postgis_full_version(); --is at 2.5.3
SELECT postgis_extensions_upgrade();
}}}
-- outputs
{{{
POSTGIS="3.0.0 r17983" [EXTENSION] PGSQL="110" GEOS="3.8.0-CAPI-1.13.1 "
PROJ="Rel. 5.2.0, September 15th, 2018" GDAL="GDAL 2.4.2, released
2019/06/28" LIBXML="2.9.9" LIBJSON="0.12" LIBPROTOBUF="1.2.1" WAGYU="0.4.3
(Internal)" RASTER (raster lib from "2.5.3 r17699" need upgrade)
[UNPACKAGED!] (raster procs from "2.5.3 r17699" need upgrade)
}}}
Repeat again
{{{
SELECT postgis_extensions_upgrade();
}}}
Gives error:
{{{
NOTICE: Packaging extension postgis_raster
WARNING: 'postgis.gdal_datapath' is already set and cannot be changed
until you reconnect
WARNING: 'postgis.gdal_enabled_drivers' is already set and cannot be
changed until you reconnect
WARNING: 'postgis.enable_outdb_rasters' is already set and cannot be
changed until you reconnect
ERROR: function public.st_srid(geometry) does not exist
LINE 1: ..._makeemptyraster($1, $2, $3, $4, $5, -($5), 0, 0, public.ST_...
^
HINT: No function matches the given name and argument types. You might
need to add explicit type casts.
QUERY: SELECT public.ST_makeemptyraster($1, $2, $3, $4, $5, -($5), 0,
0, public.ST_SRID('POINT(0 0)'::geometry))
CONTEXT: SQL statement "CREATE EXTENSION postgis_raster FROM unpackaged"
PL/pgSQL function postgis_extensions_upgrade() line 48 at EXECUTE
SQL state: 42883
}}}
To force repackaging I had to do this:
{{{
CREATE EXTENSION postgis_raster FROM unpackaged VERSION "3.0.0" SCHEMA
postgis;
}}}
I thought I had tested this already, but I've always been doing
{{{
ALTER EXTENSION postgis UPDATE;
}}}
So perhaps this only happens if you don't do ALTER EXTENSION postgis
UPDATE because the 2.5.3 is incomplet.
--
Ticket URL: <https://trac.osgeo.org/postgis/ticket/4555>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.
More information about the postgis-tickets
mailing list