﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
13256	OGRGeometry equals throws exception when compared to None	ninowalker	nobody	"The following generates an exception: 

{{{
>>> from django.contrib.gis.gdal import OGRGeometry
>>> geom = OGRGeometry(""POINT(0 0)"")
>>> if geom == None:
...    print 1
... 
Traceback (most recent call last):
  File ""<stdin>"", line 1, in <module>
  File ""/usr/local/lib/python2.6/site-packages/Django-1.1.1-py2.6.egg/django/contrib/gis/gdal/geometries.py"", line 166, in __eq__
    return self.equals(other)
  File ""/usr/local/lib/python2.6/site-packages/Django-1.1.1-py2.6.egg/django/contrib/gis/gdal/geometries.py"", line 397, in equals
    return self._topology(capi.ogr_equals, other)
  File ""/usr/local/lib/python2.6/site-packages/Django-1.1.1-py2.6.egg/django/contrib/gis/gdal/geometries.py"", line 385, in _topology
    raise TypeError('Must use another OGRGeometry object for topology operations!')
TypeError: Must use another OGRGeometry object for topology operations!
}}}

Equals (and other predicate methods), should probably test for None before dispatching to the C bindings.  No?"		closed	GIS	1.1		fixed	GDAL		Accepted	0	0	0	0	0	0
