#7128 closed defect (fixed)
POINT EMPTY in a geometrycollection causes an error.
Reported by: | cdestigter | Owned by: | warmerdam |
---|---|---|---|
Priority: | normal | Milestone: | 2.1.5 |
Component: | default | Version: | 2.1.0 |
Severity: | normal | Keywords: | |
Cc: |
Description
This admittedly strange geometry is causing us grief:
>>> from osgeo import ogr >>> ogr.CreateGeometryFromWkt('GEOMETRYCOLLECTION(POINT(1 2),POINT EMPTY)') Traceback (most recent call last): File "<ipython-input-5-246577802f67>", line 1, in <module> ogr.CreateGeometryFromWkt('GEOMETRYCOLLECTION(POINT(1 2),POINT EMPTY)') File "/usr/lib/python2.7/dist-packages/osgeo/ogr.py", line 5484, in CreateGeometryFromWkt return _ogr.CreateGeometryFromWkt(*args, **kwargs) RuntimeError: OGR Error: Corrupt data
I was thinking this behaviour must be a GEOS thing, but using Django's GEOS bindings I get a different result.
>>> from django.contrib.gis import geos >>> geos.GEOSGeometry('GEOMETRYCOLLECTION(POINT(1 2),POINT EMPTY)') <GeometryCollection object at 0x7fbcf6ca6d90>
GEOS 3.4.2 FWIW, and both are using the same /usr/lib/libgeos-3.4.2.so
Change History (7)
comment:1 by , 6 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:4 by , 6 years ago
Milestone: | → 2.1.5 |
---|---|
Version: | svn-trunk → 2.1.0 |
Pure OGR bug. GEOS is not involved in this
Note:
See TracTickets
for help on using tickets.
In 40621: