#5438: GeometryProxy: evaluate empty string to None
-----------------------+----------------------------------------------------
Reporter: rcoup | Owner: nobody
Status: new | Component: GIS
Version: SVN | Keywords: sprint
Stage: Unreviewed | Has_patch: 1
-----------------------+----------------------------------------------------
The following code:
{{{
from django.contrib.gis.test.geoapp.models import City
c = City()
c.point
}}}
throws an exception from `GeometryProxy.__get__`, because the `geom_value`
is `''`, and so it tries to create a GEOSGeometry from it.
Attached patch and tests evaluates `''` (and `u''`) to `None` instead.
--
Ticket URL: <http://code.djangoproject.com/ticket/5438>
Django Code <http://code.djangoproject.com/>
The web framework for perfectionists with deadlines
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---