Opened 17 years ago
Closed 17 years ago
#5438 closed (fixed)
GeometryProxy: evaluate empty string to None
Reported by: | Robert Coup | Owned by: | jbronn |
---|---|---|---|
Component: | GIS | Version: | gis |
Severity: | Keywords: | sprint | |
Cc: | Triage Stage: | Unreviewed | |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
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.
Attachments (1)
Change History (5)
by , 17 years ago
Attachment: | proxy_newmodel_none.patch added |
---|
comment:1 by , 17 years ago
Version: | SVN → gis |
---|
comment:2 by , 17 years ago
Owner: | changed from | to
---|---|
Status: | new → assigned |
comment:3 by , 17 years ago
Status: | assigned → new |
---|
comment:4 by , 17 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Note:
See TracTickets
for help on using tickets.
(In [6243]) gis: Fixed #5438 with patches from rcoup.