#9520: date filter should not crash when dealing with non date objects
--------------------------------------+-------------------------------------
          Reporter:  hotani           |         Owner:  andrewbadr              
              
            Status:  new              |     Milestone:  1.1                     
              
         Component:  Template system  |       Version:  SVN                     
              
        Resolution:                   |      Keywords:  date format filter 
template pycamp2009
             Stage:  Accepted         |     Has_patch:  1                       
              
        Needs_docs:  0                |   Needs_tests:  0                       
              
Needs_better_patch:  0                |  
--------------------------------------+-------------------------------------
Changes (by andrewbadr):

  * has_patch:  0 => 1

Comment:

 The attachment implements the behavior described in the ticket, returning
 ''value'' if there is an exception. It patches the ''time'' filter in
 addition to ''date'' since the two cases are directly analogous. Only
 catches AttributeError since that's what you get when you pass a string to
 ''format'' or ''time_format''. I'd prefer to raise an exception if
 ''value'' can't be formatted and is not a basestring.

-- 
Ticket URL: <http://code.djangoproject.com/ticket/9520#comment:5>
Django <http://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 post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to