#29754: Trunc() doesn't handle NonExistentTimeError/AmbiguousTimeError
-------------------------------------+-------------------------------------
Reporter: Alexander Holmbäck | Owner: nobody
Type: Bug | Status: new
Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution:
Keywords: pytz, Trunc() | Triage Stage:
| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Comment (by Simon Charette):
The `AmbiguousTimeError` case could be worked around by adding a
`Trunc(is_dst=None)` optional argument that would be passed down to
`localize`. That would make the API a bit more usable when tzinfo is
provided and you know what you're after.
I'm afraid there isn't much that can be done for `NonExistentTimeError`
though.
--
Ticket URL: <https://code.djangoproject.com/ticket/29754#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 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/066.bf5f4962af740d27bd6d170272ae5e35%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.