Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#23731 closed Bug (fixed)

PointField does not allow setting blank=True and null=False

Reported by: George Tantiras Owned by: Tim Graham
Component: GIS Version: 1.7
Severity: Release blocker Keywords: PointField, gis
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description (last modified by George Tantiras)

The following code worked nicely in Python 3.3 / Django 1.6.x:

from django.contrib.gis.db import models

class Coordinates(models.Model):

    point = models.PointField(blank=True,null=False)
    objects = models.GeoManager()

However, in Python 3.3 / Django 1.7.1:

$ ./manage.py makemigrations
$ ./manage.py migrate
...
ValueError: String or unicode input unrecognized as WKT EWKT, and HEXEWKB.

Change History (6)

comment:1 Changed 6 years ago by George Tantiras

Description: modified (diff)

comment:2 Changed 6 years ago by Tim Graham

Severity: NormalRelease blocker
Triage Stage: UnreviewedAccepted

comment:3 Changed 6 years ago by Tim Graham

Owner: changed from nobody to Tim Graham
Status: newassigned

comment:4 Changed 6 years ago by Tim Graham

Has patch: set

comment:5 Changed 6 years ago by Tim Graham <timograham@…>

Resolution: fixed
Status: assignedclosed

In d6d55368d45ca05c4c08c4981f9dba5c9b2bd72e:

Fixed #23731 -- Fixed migrations crash when adding blank GeometryFields on PostGIS.

Thanks raratiru for the report and Claude Paroz for review.

comment:6 Changed 6 years ago by Tim Graham <timograham@…>

In 17205a98ed0e4fb2a4ce9137508ee65efc448c07:

[1.7.x] Fixed #23731 -- Fixed migrations crash when adding blank GeometryFields on PostGIS.

Thanks raratiru for the report and Claude Paroz for review.

Backport of d6d55368d4 from master

Note: See TracTickets for help on using tickets.
Back to Top