Hey folks, while playing around with the DB API last night, we discovered that the ORM layer does not enforce content validation.
Since the blank field option defaults to False, we expected to be
unable to save ORM objects with empty fields, but the DB API will
let us do just that:
class BeersOfTheWorld(models.Model):
beer = models.CharField(max_length=256)
b = BeersOfTheWorld()
b.save()
and the record was created with an empty string title.
Then we found
http://code.djangoproject.com/ticket/497
which is marked invalid with a pointer to form manipulators.
Does this reflect the roadmap of Django? Is content validation
expected from higher layers and the ORM layer won't do it?
--
martin | http://madduck.net/ | http://two.sentenc.es/
"one should never do anything that
one cannot talk about after dinner."
-- oscar wilde
spamtraps: [email protected]
digital_signature_gpg.asc
Description: Digital signature (see http://martin-krafft.net/gpg/)

