diff options
| author | Alex Gaynor <alex.gaynor@gmail.com> | 2013-11-15 05:05:20 -0800 |
|---|---|---|
| committer | Alex Gaynor <alex.gaynor@gmail.com> | 2013-11-15 05:05:20 -0800 |
| commit | a90ffcac218e6783f931d3a44eca4d830b9315ba (patch) | |
| tree | 1a56fa2452953a11317af2efd3c254690f098e95 | |
| parent | 6e9e6ca0712cf1d2d0874ea5c8b63140804605a5 (diff) | |
| parent | 32e75803be8b3e9c35e6735c265125c4130ffabc (diff) | |
Merge pull request #1921 from loic/ticket21432
Fixed typo and slightly improved error message when db is missing time zone definitions.
| -rw-r--r-- | django/db/models/sql/compiler.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/django/db/models/sql/compiler.py b/django/db/models/sql/compiler.py index 38806e7dc2..98b953937f 100644 --- a/django/db/models/sql/compiler.py +++ b/django/db/models/sql/compiler.py @@ -1083,8 +1083,8 @@ class SQLDateTimeCompiler(SQLCompiler): if settings.USE_TZ: if datetime is None: raise ValueError("Database returned an invalid value " - "in QuerySet.dates(). Are time zone " - "definitions and pytz installed?") + "in QuerySet.datetimes(). Are time zone " + "definitions for your database and pytz installed?") datetime = datetime.replace(tzinfo=None) datetime = timezone.make_aware(datetime, self.query.tzinfo) yield datetime |
