[postgis-tickets] [PostGIS] #4077: st_removerepeatedpoints regression
PostGIS
trac at osgeo.org
Tue May 1 06:16:00 PDT 2018
#4077: st_removerepeatedpoints regression
---------------------+---------------------------
Reporter: nicklas | Owner: pramsey
Type: defect | Status: new
Priority: medium | Milestone: PostGIS 2.5.0
Component: postgis | Version: trunk
Keywords: |
---------------------+---------------------------
Actually I am not sure it is ST_RemoveRepeatedPoints that is the problem,
but something has happened since PostGIS 2.4.
I have problems vatching what is actually happening.
I am running r16554
This query returns as expected a "MULTIPOLYGON EMPTY":
{{{
# select st_snaptogrid('multipolygon(((1 1, 1 2, 2 2,1 1)))'::geometry,
10);
st_snaptogrid
--------------------
010600000000000000
(1 row)
}}}
And if I feed ST_RemoveRepeadedPoints with Multipolygon Empty I get, as
expected a Multipolygon Empty back:
{{{
# select st_removerepeatedpoints('010600000000000000'::geometry);
st_removerepeatedpoints
-------------------------
010600000000000000
(1 row)
}}}
But if I feed ST_RemoveRepeatedPoints with the result from query 1
directly it reads the geometry type from the right place:
{{{
# select st_removerepeatedpoints(st_snaptogrid('multipolygon(((1 1, 1 2, 2
2,1 1)))'::geometry, 10));
ERROR: Unknown geometry type: 1983230296 - Invalid type
}}}
In Postgis 2.4.4 r16526 I get the expected Multipolygon empty back
instead.
Also if I change to polygon instead of multipolygon it works as expected
also in latest trunk version:
{{{
# select st_removerepeatedpoints(st_snaptogrid('polygon((1 1, 1 2, 2 2,1
1))'::geometry, 10));
st_removerepeatedpoints
-------------------------
010300000000000000
(1 row)
}}}
--
Ticket URL: <https://trac.osgeo.org/postgis/ticket/4077>
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