[PostGIS] #6121: Adding a node below distance of multiple edge segments snaps only one of them
PostGIS
trac at osgeo.org
Wed Sep 2 09:46:49 PDT 2026
#6121: Adding a node below distance of multiple edge segments snaps only one of
them
------------------------+---------------------------
Reporter: strk | Owner: strk
Type: defect | Status: new
Priority: medium | Milestone: PostGIS 3.5.7
Component: topology | Version: 3.5.x
Keywords: robustness |
------------------------+---------------------------
Starting in PostGIS-3.5.0 we added experimental code to snap more than one
existing edges to incoming nodes when those edges are below tolerance.
Previously, only the closest edge was snapped, to avoid having to deal
with edge merging.
This code is still experimental as of current master branch
(3.7.0rc1-20-g655fc78a1) and has a known bug: if the SAME edge has
MULTIPLE segments within tolerance distance from the incoming node only
one of them will snap, instead of both of them.
This limitation results in the best case in producing a resulting topology
with unwanted proximities. In the worst case the unwanted proximities
result in a later (possibly within same transaction) exception being
thrown.
A simple test to reproduce this would be:
1. Add a V-shaped 2 segments edge, with a narrow angle
2. Add a Point far from any of the 3 vertices of the edge but within
tolerance from the two segments
The correct result should be to have an Y-shaped 3 edges resulting
topology. At the moment you are likely to get a 2 edges topology instead.
--
Ticket URL: <https://trac.osgeo.org/postgis/ticket/6121>
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