#23803: DateField returns datetime if SQLite field is created as TIMESTAMP
-------------------------------------+-------------------------------------
Reporter: me21 | Owner: nobody
Type: Bug | Status: closed
Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution: wontfix
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by mjtamlyn):
* status: new => closed
* resolution: => wontfix
Comment:
Unfortunately, if django were to inspect every value of every field of
every model it loaded to ensure it is in the correct format there would be
a serious performance problem. Consequently care is taken to only apply
`db_converters` when they are necessary (we are still a little heavy
handed with them in some cases though).
If you wished to create a `DateField` subclass which would handle that,
you can use `from_db_value` in Django 1.8
(https://docs.djangoproject.com/en/1.8/ref/models/fields/#django.db.models.Field.from_db_value)
--
Ticket URL: <https://code.djangoproject.com/ticket/23803#comment:2>
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/062.ba58868fd5807861b76b171512a3b856%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.