#35542: BoundField's label and help_text and renderer should be properties not
class members
-------------------------------------+-------------------------------------
     Reporter:  Christophe Henry     |                    Owner:
         Type:                       |  Christophe Henry
  Cleanup/optimization               |                   Status:  closed
    Component:  Forms                |                  Version:  dev
     Severity:  Normal               |               Resolution:
                                     |  worksforme
     Keywords:                       |             Triage Stage:
                                     |  Unreviewed
    Has patch:  1                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Changes (by Natalia Bidart):

 * cc: David Smith (added)
 * resolution:   => worksforme
 * status:  new => closed

Comment:

 Hey Christophe, thank you for the extra details. For what it's worth, I'm
 not saying that your issue is invalid; I fully acknowledge that it caused
 an error in your project and that you've invested time in finding the root
 cause.

 However, there's another aspect to triaging a bug in Django, which
 involves determining whether a report pertains to a niche use case or
 something that would affect the majority of users. Django is a framework
 designed to provide robust and reliable solutions for common scenarios.
 It's built on a mature code base where code changes should be carefully
 evaluated.

 To accept a ticket like this, we need two things:

 1. A Django minimal project showcasing the issue. I added the `assert`
 suggested above and it's not failing for me. My code is exactly the one
 posted above with the adding of `assert self["foo_select"].help_text ==
 self.fields["foo_select"].help_text`.

 2. To fully describe and understand the use case for your code. Even if
 the `assert` would fail (which as I mentioned is not failing for me), it's
 unclear if this is actually a valid Django logic pattern. Could you please
 describe in words what the goal is in accessing `self[<field name>]` as
 you propose? It seems unusual to access a BoundField inside the Form's
 `__init__` (since the form hasn't been fully created yet). See
 [https://docs.djangoproject.com/en/5.0/ref/forms/api/#accessing-the-
 fields-from-the-form the docs] for ''Accessing the fields from the form''.

 I know we've mentioned this in other tickets you've created, but it's
 important to reiterate: Django is a community-driven project. While the
 Fellows oversee maintenance and ensure timely releases, most design
 decisions and feature changes/additions are made through community
 consensus. The forum is the primary place to seek that consensus, as it
 notifies the most interested parties (unlike here). Since I can't
 reproduce the issue with the provided details and this requires broader
 discussion, the best course of action to post in the
 [https://forum.djangoproject.com/ Django Forum] presenting the use case
 for wider feedback.

 Thanks again!
-- 
Ticket URL: <https://code.djangoproject.com/ticket/35542#comment:8>
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/010701909298b4ad-85a54991-2463-4580-8993-a7c85ce912aa-000000%40eu-central-1.amazonses.com.

Reply via email to