Ticket #1543 (closed defect: fixed)

Opened 16 months ago

Last modified 15 months ago

ST_GetFaceGeometry exception on invalid edge, null on unexistent face

Reported by: strk Owned by: strk
Priority: medium Milestone: PostGIS 2.0.0
Component: topology Version: trunk
Keywords: Cc:

Description

The SQL/MM document says that an exception should be raised IF the face argument references an unknown face. Doesn't say anything about faces bound by no ring (would be due to invalid topology).

The current implementation results in an exception in the latter case (no ring) but not in the former (unknown face).

In turn this doesn't help validating a topology in that the exception on invalid topology makes the whole validateTopology function bail out.

Change History

Changed 16 months ago by strk

This is actually ST_BuildArea's fault, whereas passing 'LINESTRING(0 0, 10 10)' as input returns NULL while 'LINESTRING(0 0)' as input returns an exception (cause the input is invalid...).

Changed 16 months ago by strk

  • summary changed from ST_GetFaceGeometry exception on partial face boundary, null on unexistent face to ST_GetFaceGeometry exception on invalid edge, null on unexistent face

Changed 15 months ago by strk

  • status changed from new to closed
  • resolution set to fixed

r9184 fixes the exception by making even single-point edges convertible to GEOS. The null-on-unexistent face I'll pretend I didnt see (would only make things slower)

Note: See TracTickets for help on using tickets.