#24710: Replace BaseForm.errors property with get_errors method
-----------------------------+--------------------
     Reporter:  artemrizhov  |      Owner:  nobody
         Type:  Bug          |     Status:  new
    Component:  Forms        |    Version:  1.7
     Severity:  Normal       |   Keywords:
 Triage Stage:  Unreviewed   |  Has patch:  0
Easy pickings:  0            |      UI/UX:  0
-----------------------------+--------------------
 This is not a real bug, but this makes some problems. I think property
 getter should not do so much changes into the internal state of the
 object. This getter calls the `full_clean` method, so this is actually not
 a getter, but a real '''worker'''.

 This also produces very annoying side effects on debugging which really
 look and work like a bug. Please see this stackoverflow question for
 example
 http://stackoverflow.com/questions/12142819/debugging-form-validation-in-
 pycharm
 (sorry for the link to third-party resource, please let me know if you
 think this text should be copied here)

 I propose to replace `errors` property with `get_errors` method so that
 * anybody can see it does some work to retrieve the errors
 * debuggers do not try to evaluate it
 * developers do not spend hours for catching non-existent bugs in their
 apps :)

--
Ticket URL: <https://code.djangoproject.com/ticket/24710>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/054.c094c6648b1d04056c360cfe56858c03%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to