#32892: Optimisation for parse_datetime by preferring datetime.fromisoformat for
well-formed values.
-------------------------------------+-------------------------------------
     Reporter:  Keryn Knight         |                    Owner:  Hasan
         Type:                       |  Ramezani
  Cleanup/optimization               |                   Status:  assigned
    Component:  Utilities            |                  Version:  dev
     Severity:  Normal               |               Resolution:
     Keywords:                       |             Triage Stage:  Accepted
    Has patch:  1                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------

Comment (by Keryn Knight):

 Ah, I've just come back to this to set the has patch info and I see
 there's already one :/
 Oh well, here's mine anyway: https://github.com/django/django/pull/14582
 (which, to be fair, looks to have failed cos of flake8, aren't I great?
 :))


 FWIW, across the test suite, the `parse_date` and `parse_time` values
 which weren't handled by the builtin `fromisoformat` for the appropriate
 type are:
 {{{
 2009-7-8
 2009-5-4
 2012-4-9
 2012-04-56
 10:20:30,400
 4:8:16
 09:15:90
 2011-13-10
 2011-10-32
 2011-10-32
 25:50
 }}}
 by the look of it, which at least for the dates is entirely to be expected
 due to the stricter nature of the stdlib handler (must have 2 digit padded
 months/days etc)

-- 
Ticket URL: <https://code.djangoproject.com/ticket/32892#comment:3>
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/067.a9045cfcd789a6d096d6e4c7fc4d8cdd%40djangoproject.com.

Reply via email to