Changes between Initial Version and Version 1 of Ticket #20684, comment 29


Ignore:
Timestamp:
09/07/2013 10:26:02 AM (22 months ago)
Author:
jcd
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #20684, comment 29

    initial v1  
    33One option is to name the feature that we are implementing (HTML5 boolean attributes).
    44
    5     "Starting in Django 1.x, widget attributes with boolean values will render according to the rules for HTML5 boolean attributes."
     5    (1) "Starting in Django 1.x, widget attributes with boolean values will render according to the rules for HTML5 boolean attributes."
    66
    77If they don't know what that means, they have the search term for HTML5 boolean attributes.  I admit this is still a little obtuse for users who aren't familiar with all the rules for HTML5, but it's also terse.  Explaining the new feature in the DeprecationWarning will be a bit verbose for a one-line warning, but could be done:
    88
    9     "Starting in Django 1.x, the rendering of attributes with boolean values will change; Attributes marked True will render as the name of the attribute, and attributes marked False will not render at all [in accordance with the rules for HTML5 boolean attributes."
     9    (2) "Starting in Django 1.x, the rendering of attributes with boolean values will change; Attributes marked True will render as the name of the attribute, and attributes marked False will not render at all [in accordance with the rules for HTML5 boolean attributes."
    1010
    1111Alternatively, we could separate out true and false values into separate DeprecationWarnings, so we can be explicit about exactly what will happen and why, while still being terse..
    1212
    13     True: "Starting in Django 1.x, widget attributes set to 'True' will render as the name of the attribute with no value, in accordance with the rules for HTML5 boolean attributes." 
     13    (3) True: "Starting in Django 1.x, widget attributes set to 'True' will render as the name of the attribute with no value, in accordance with the rules for HTML5 boolean attributes." 
    1414    False: "Starting in Django 1.x, widget attributes set to 'False' will not be rendered, in accordance with the rules for HTML5 boolean attributes."
    1515
    1616I think my preference would be for separate True and False DeprecationWarnings.
     17
     18Edit: Added numberings to the various proposals, for ease of reference.
Back to Top