Opened 20 months ago

Closed 20 months ago

Last modified 20 months ago

#5251 closed defect (fixed)

GEOS 3.12 regression on tickets #4011 ST_LineMerge

Reported by: robe Owned by: robe
Priority: blocker Milestone: PostGIS 3.4.0
Component: QA/buildbots Version: master
Keywords: Cc:

Description

I'm not sure how long this one has been going on since we had the other GEOS issue too. Regression on test #4011

PostgreSQL 14.5, compiled by Visual C++ build 1914, 64-bit
  Postgis 3.4.0dev - (3.3.0rc2-128-g1bd0a8410) - 2022-09-26 20:52:35
  scripts 3.4.0dev 3.3.0rc2-128-g1bd0a8410
  raster scripts 3.4.0dev 3.3.0rc2-128-g1bd0a8410
  GEOS: 3.12.0dev-CAPI-1.18.0
  PROJ: 7.2.1
  SFCGAL: 1.4.1
  GDAL: GDAL 3.4.3, released 2022/04/22

 ./regress/core/tickets .. failed (diff expected obtained: /projects/postgis/tmp/3.4.0dev_pg14_geos3.12_gdal3.4.3w64/test_84_diff)
-----------------------------------------------------------------------------
--- ./regress/core/tickets_expected	2022-08-27 01:03:01.977034900 -0400
+++ /projects/postgis/tmp/3.4.0dev_pg14_geos3.12_gdal3.4.3w64/test_84_out	2022-09-26 17:11:56.173769200 -0400
@@ -320,7 +320,7 @@
 #4011|ST_LineString|MULTILINESTRING((0 0,1 1),EMPTY)|f|t
 #4011|ST_MultiLineString|MULTILINESTRING(EMPTY,EMPTY)|t|t
 #4011||||
-#4011|ST_GeometryCollection|POLYGON((0 0,1 0,1 1,0 0))|f|t
+#4011|ST_LineString|POLYGON((0 0,1 0,1 1,0 0))|f|t
 #4011|ST_LineString|GEOMETRYCOLLECTION(LINESTRING(0 0,1 1))|f|t
 #4011|ST_MultiLineString|MULTILINESTRING EMPTY|t|t
 #4011|ST_GeometryCollection|MULTILINESTRING((0 0,0 0))|f|f
-----------------------------------------------------------------------------

winnie might be the only bot testing GEOS 3.12dev, so could be a GEOS issue.

I'll flip debbie to test GEOS main to see if she runs into the same issue

The query is

SELECT '#4011',
ST_GeometryType(ST_LineMerge(geom)) AS linemerge,
ST_AsText(geom) AS geom,
ST_IsEmpty(geom) AS empty,
ST_IsValid(geom) AS valid
FROM (VALUES
('LINESTRING(0 0, 1 1)'),
('MULTILINESTRING((0 0, 1 1), (1 1, 2 2))'),
('MULTILINESTRING((0 0, 1 1), EMPTY)'),
('MULTILINESTRING(EMPTY, EMPTY)'),
(NULL),
('POLYGON((0 0, 1 0, 1 1, 0 0))'),
('GEOMETRYCOLLECTION(LINESTRING(0 0, 1 1))'),
('MULTILINESTRING EMPTY'),
('MULTILINESTRING((0 0, 0 0))')
) as f(geom);

The one in particular that is giving different answer is

SELECT ST_LineMerge('POLYGON((0 0, 1 0, 1 1, 0 0))'::geometry);

In past, this would give false GEOMETRYCOLLECTION EMPTY now it's giving LINESTRING(0 0,1 0,1 1,0 0)

I think it's a geos change, cause my geos 3.12dev dates 9/14 gave the old answer. I copied winnie's geos build from today and now get this new answer.

Change History (3)

comment:1 by robe, 20 months ago

Summary: winnie regression on tickets #4011 ST_LineMergeGEOS 3.12 regression on tickets #4011 ST_LineMerge

I'm going to take out just the polygon part of this so all regress.

I'm not sure it's worthwhile to put in a conditional for GEOS 3.12 vs GEOS < 3.12

comment:2 by Regina Obe <lr@…>, 20 months ago

Resolution: fixed
Status: newclosed

In 60129dc/git:

Take out POLYGON test of tickets.sql #4011 to fix regression for GEOS ≥ 3.12. Closes #5251 for PostGIS 3.4.0dev

comment:3 by Regina Obe <lr@…>, 20 months ago

In 22601a1/git:

Take out POLYGON test of tickets.sql #4011 to fix regression for GEOS ≥ 3.12. Closes #5251 for PostGIS 3.4.0dev

Note: See TracTickets for help on using tickets.