Opened 13 years ago

Closed 13 years ago

#1543 closed defect (fixed)

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: master
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 (3)

comment:1 by strk, 13 years ago

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...).

comment:2 by strk, 13 years ago

Summary: ST_GetFaceGeometry exception on partial face boundary, null on unexistent faceST_GetFaceGeometry exception on invalid edge, null on unexistent face

comment:3 by strk, 13 years ago

Resolution: fixed
Status: newclosed

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.