Opened 5 years ago

Closed 4 years ago

#4514 closed defect (fixed)

GEOS master breaks topology tests

Reported by: Algunenano Owned by: pramsey
Priority: medium Milestone: PostGIS GEOS
Component: postgis Version: master
Keywords: Cc:

Description

With current GEOS/master (4676.f7c913f3):

$ /usr/bin/perl ../../regress/run_test.pl --topology  regress/addface2.5d.sql || cat /tmp/pgis_reg/test_1_diff
PATH is /usr/lib/colorgcc/bin/:/usr/lib/ccache/bin/:/usr/bin:/usr/local/bin:/usr/local/sbin:/usr/lib/jvm/default/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl
Checking for shp2pgsql ... found
Checking for pgsql2shp ... found
TMPDIR is /tmp/pgis_reg
Creating database 'postgis_reg' 
Loading unpackaged components from /home/raul/dev/public/postgis/regress/00-regress-install/share/contrib/postgis
Loading PostGIS into 'postgis_reg' 
Loading Topology into 'postgis_reg'
PostgreSQL 12beta4 on x86_64-pc-linux-gnu, compiled by clang version 8.0.1 (tags/RELEASE_801/final), 64-bit
  Postgis 3.0.0alpha5dev - r17822 - 2019-09-20 15:13:04
  scripts 3.0.0alpha5dev r17822
  GEOS: 3.8.0dev-CAPI-1.12.0 
  PROJ: 6.2.0

Running tests

 regress/addface2.5d .. failed (diff expected obtained: /tmp/pgis_reg/test_1_diff)
 uninstall .. ok (4725)

Run tests: 2
Failed: 1
--- regress/addface2.5d_expected        2017-08-25 11:53:10.074352999 +0200
+++ /tmp/pgis_reg/test_1_out    2019-09-27 15:36:28.266923387 +0200
@@ -3,11 +3,10 @@
 e2|2
 e3|3
 e4|4
-f1|1
+ERROR:  Polygon boundary is not fully defined by existing edges at or near point POINT Z (0 10 20)
 0|
-1|POLYGON((0 0,0 10,10 10,10 0,0 0))
-1|1|0
-2|1|0
-3|0|1
-4|0|1
+1|0|0
+2|0|0
+3|0|0
+4|0|0
 Topology 'tt3d' dropped

With older GEOS (4574.326b89e6):

$ /usr/bin/perl ../../regress/run_test.pl --topology  regress/addface2.5d.sql || cat /tmp/pgis_reg/test_1_diff
PATH is /usr/lib/colorgcc/bin/:/usr/lib/ccache/bin/:/usr/bin:/usr/local/bin:/usr/local/sbin:/usr/lib/jvm/default/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl
Checking for shp2pgsql ... found
Checking for pgsql2shp ... found
TMPDIR is /tmp/pgis_reg
Creating database 'postgis_reg' 
Loading unpackaged components from /home/raul/dev/public/postgis/regress/00-regress-install/share/contrib/postgis
Loading PostGIS into 'postgis_reg' 
Loading Topology into 'postgis_reg'
PostgreSQL 12beta4 on x86_64-pc-linux-gnu, compiled by clang version 8.0.1 (tags/RELEASE_801/final), 64-bit
  Postgis 3.0.0alpha5dev - r17822 - 2019-09-20 15:13:04
  scripts 3.0.0alpha5dev r17822
  GEOS: 3.8.0dev-CAPI-1.11.0 
  PROJ: 6.2.0

Running tests

 regress/addface2.5d .. ok 
 uninstall .. ok (4725)

Run tests: 2
Failed: 0

I'll try to bisect the issue between those 2 commits.

Change History (8)

comment:3 by robe, 5 years ago

In 17823:

Revise topology tests so they yield same results in GEOS 3.8 and lower
References #4514 for PostGIS 3.0

comment:4 by robe, 5 years ago

strk if you don't like my solution, feel free to revise. If you are okay with it, then we should probably backport to at least 2.5.

I also changed the check_changes in addpolygon test to have a label like you had in linestring one, as it was hard to tell which was failing otherwise.

comment:5 by robe, 5 years ago

In 17824:

Missed some fixes in last commit. this should work on all.
References #4514 for PostGIS 3.0

comment:6 by strk, 5 years ago

The GEOS issue seems to be fixed upstream, so why not reverting this change ? See https://trac.osgeo.org/geos/ticket/990

comment:7 by robe, 5 years ago

strk that was just one failure which was fixed upstream. The other ones were jus tdifferent answers which can't be fixed based on what Paul told me.

Here are the other failures for completeness - this is the output before I revised the tests. Note the above one was already passing.

PostgreSQL 12rc1 on x86_64-pc-linux-gnu, compiled by gcc (Debian 9.2.1-8) 9.2.1 20190909, 64-bit
  Postgis 3.0.0alpha5dev - r17822 - 2019-09-27 19:34:14
  scripts 3.0.0alpha5dev r17822
  GEOS: 3.8.0dev-CAPI-1.12.0 
  PROJ: 6.2.0

Running tests

 regress/legacy_validate .. ok 
 regress/legacy_predicate .. ok 
 regress/legacy_invalid .. ok 
 regress/sqlmm .. ok 
 regress/legacy_query .. ok 
 regress/addnode .. ok 
 regress/addedge .. ok 
 regress/addface .. ok 
 regress/addface2.5d .. ok 
 regress/addtopogeometrycolumn .. ok 
 regress/polygonize .. ok 
 regress/st_addisoedge .. ok 
 regress/st_addisonode .. ok 
 regress/st_addedgemodface .. ok 
 regress/st_addedgenewfaces .. ok 
 regress/st_changeedgegeom .. ok 
 regress/st_createtopogeo .. ok 
 regress/st_getfacegeometry .. ok 
 regress/st_getfaceedges .. ok 
 regress/st_modedgeheal .. ok 
 regress/st_modedgesplit .. ok 
 regress/st_newedgeheal .. ok 
 regress/st_newedgessplit .. ok 
 regress/st_remedgenewface .. ok 
 regress/st_remedgemodface .. ok 
 regress/st_simplify .. ok 
 regress/topoelement .. ok 
 regress/topoelementarray_agg .. ok 
 regress/topogeo_addlinestring .. failed (diff expected obtained: /var/lib/jenkins/workspace/postgis/tmp/3_0_pg12w64/test_29_diff)
-----------------------------------------------------------------------------
--- regress/topogeo_addlinestring_expected	2019-04-20 19:31:54.667900703 +0000
+++ /var/lib/jenkins/workspace/postgis/tmp/3_0_pg12w64/test_29_out	2019-09-27 19:44:03.576919878 +0000
@@ -54,36 +54,36 @@
 snap_again|7
 snap_again|36
 snap_again|38
-crossover|40
 crossover|41
+crossover|43
 crossover|44
 crossover|45
-crossover|N|37||POINT(21 10)
-crossover|N|38||POINT(21 7)
-crossover|N|39||POINT(9 18)
-crossover|N|40||POINT(9 20)
-crossover|N|41||POINT(16.2 14)
-crossover|E|9|sn15|en41
-crossover|E|20|sn9|en38
-crossover|E|21|sn15|en39
-crossover|E|39|sn37|en14
-crossover|E|40|sn38|en37
-crossover|E|41|sn39|en40
-crossover|E|42|sn40|en16
-crossover|E|43|sn41|en14
-crossover|E|44|sn41|en37
-crossover|E|45|sn40|en41
-crossover_again|40
+crossover|N|37||POINT(9 20)
+crossover|N|38||POINT(16.2 14)
+crossover|N|39||POINT(21 10)
+crossover|N|40||POINT(9 18)
+crossover|N|41||POINT(21 7)
+crossover|E|9|sn15|en38
+crossover|E|20|sn9|en41
+crossover|E|21|sn15|en40
+crossover|E|39|sn37|en16
+crossover|E|40|sn38|en14
+crossover|E|41|sn37|en38
+crossover|E|42|sn39|en14
+crossover|E|43|sn38|en39
+crossover|E|44|sn40|en37
+crossover|E|45|sn41|en39
 crossover_again|41
+crossover_again|43
 crossover_again|44
 crossover_again|45
 contains|25
 contains|46
 contains|47
-contains|N|42||POINT(7 36)
-contains|N|43||POINT(14 34)
-contains|E|46|sn21|en42
-contains|E|47|sn43|en22
+contains|N|42||POINT(14 34)
+contains|N|43||POINT(7 36)
+contains|E|46|sn42|en22
+contains|E|47|sn21|en43
 nodecross|48
 nodecross|49
 nodecross|N|44||POINT(18 37)
@@ -97,13 +97,13 @@
 #1613.1|E|50|sn46|en47
 #1613.2|52
 #1613.2|53
-#1613.2|N|48||POINT(556267.6 144887)
-#1613.2|N|49||POINT(556310 144887)
-#1613.2|N|50||POINT(556250 144887)
-#1613.2|E|50|sn46|en48
-#1613.2|E|51|sn48|en47
+#1613.2|N|48||POINT(556250 144887)
+#1613.2|N|49||POINT(556267.6 144887)
+#1613.2|N|50||POINT(556310 144887)
+#1613.2|E|50|sn46|en49
+#1613.2|E|51|sn49|en47
 #1613.2|E|52|sn48|en49
-#1613.2|E|53|sn50|en48
+#1613.2|E|53|sn49|en50
 #1631.1|54
 #1631.1|N|51||POINT(556267.6 144887)
 #1631.1|N|52||POINT(556267.6 144888)
@@ -199,9 +199,9 @@
 t3412.start|t
 t3412.L1|1
 t3412.L2|2
-t3412.L2|3
-t3412.L2|5
 t3412.L2|4
+t3412.L2|5
+t3412.L2|3
 t3412.end|Topology 'bug3412' dropped
 t3371.start|t
 t3371.L1|1
@@ -210,15 +210,15 @@
 t3371.end|Topology 'bug3711' dropped
 t3838.start|t
 t3838.L1|1
-t3838.L2|1
+t3838.L2|2
 t3838.L2|3
 t3838.L2|4
 t3838.L2|5
+t3838.L2|1
 t3838.L2|6
 t3838.L2|7
 t3838.L2|8
 t3838.L2|9
-t3838.L2|2
 t3838.end|Topology 'bug3838' dropped
 t1855_1.start|t
 t1855_1.0|1
-----------------------------------------------------------------------------
 regress/topogeo_addpoint .. ok 
 regress/topogeo_addpolygon .. failed (diff expected obtained: /var/lib/jenkins/workspace/postgis/tmp/3_0_pg12w64/test_31_diff)
-----------------------------------------------------------------------------
--- regress/topogeo_addpolygon_expected	2019-04-20 19:31:54.667900703 +0000
+++ /var/lib/jenkins/workspace/postgis/tmp/3_0_pg12w64/test_31_out	2019-09-27 19:44:04.628910476 +0000
@@ -30,8 +30,8 @@
 N|26||POINT(28 18)
 E|30|sn14|en26
 E|31|sn26|en18
-E|32|sn26|en13
-E|33|sn17|en26
+E|32|sn17|en26
+E|33|sn26|en13
 F|14
 F|15
 ex_hole|3
@@ -58,5 +58,5 @@
 t1946.start|t
 t1946.0|1
 t1946.1|2
-t1946.2|4
+t1946.2|3
 t1946.end|Topology 'bug1946' dropped
-----------------------------------------------------------------------------
 regress/topogeom_edit .. ok 
 regress/topogeometry_type .. ok 
 regress/topojson .. ok 
 regress/topologysummary .. ok 
 regress/topo2.5d .. ok 
 regress/totopogeom .. ok 
 regress/droptopology .. ok 
 regress/droptopogeometrycolumn .. ok 
 regress/copytopology .. ok 
 regress/createtopogeom .. ok 
 regress/createtopology .. ok 
 regress/gml .. ok 
 regress/getnodebypoint .. ok 
 regress/getedgebypoint .. ok 
 regress/getfacebypoint .. ok 
 regress/getringedges .. ok 
 regress/gettopogeomelements .. ok 
 regress/layertrigger .. ok 
 regress/validatetopology .. ok 
 uninstall .  /var/lib/jenkins/workspace/postgis/branches/3.0/regress/00-regress-install/share/contrib/postgis/uninstall_topology.sql
  /var/lib/jenkins/workspace/postgis/branches/3.0/regress/00-regress-install/share/contrib/postgis/uninstall_postgis.sql
. ok (4725)

Run tests: 51
Failed: 2

comment:8 by strk, 4 years ago

Resolution: fixed
Status: newclosed

It looks like we fixed this long ago

Note: See TracTickets for help on using tickets.