Opened 17 years ago

Closed 17 years ago

#6229 closed (duplicate)

loaddata should allow null for BooleanField(null=true)

Reported by: odonian Owned by: nobody
Component: Core (Management commands) Version: dev
Severity: Keywords: loaddata dumpdata BooleanField null
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

If I have a model with a BooleanField(blank=True, null=True), then proceed to run dumpdata, it seems that loaddata will fail with an error.

Problem installing fixture '/foo/bar/datadump.json':
[u'This value must be either True or False.']

I hand-edited the fixture file to change all the "null" values for the said BooleanField field to "false" and the fixture loads fine. But methinks loaddata should allow nulls when the models.py definition allows it.

Change History (1)

comment:1 by Brian Rosner, 17 years ago

Resolution: duplicate
Status: newclosed

Duplicate of #5563.

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