On 9/13/06, Ivan Sagalaev <[EMAIL PROTECTED]> wrote: > > Joseph Kocherhans wrote: > > Assumptions: form.bind(data) does *not* return a BoundForm. bind does > > the validation and probably populates form.errors or .errors() or > > whatever. bind returns True or False depending on whether validation > > succeeded or not. bind does not short circuit on the first error. > > > > Validation happens only once, in the bind call. It's not entirely > > obvious that a method called bind would return a boolean depending on > > the success of validation, but examples and docs should clear that up > > that I think. > > It shouldn't be called 'bind' then.
Agreed. Your suggestion of 'process_data' makes more sense.... in fact, I like that, but I'd shorten it to just 'process'. It would do both binding and validation. > Binding makes sense for the original > Adrian's proposal with two kinds of forms. Bind still makes sense with only one kind of form, it just works differently. Rob Husdon's recent post is a good example of why. It may be something as simple as this though: def bind(data): self.bound_data = data Joseph --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-developers -~----------~----~----~----~------~----~------~--~---