1
0
mirror of https://github.com/django/django.git synced 2025-10-23 21:59:11 +00:00

Updated UTC uses to datetime.timezone.utc in docs.

This commit is contained in:
Diane DeMers Chen
2022-10-20 15:52:45 -07:00
committed by GitHub
parent 5c2c7277d4
commit a16132a9c4
3 changed files with 4 additions and 4 deletions

View File

@@ -721,8 +721,8 @@ Usage example::
{'date': datetime.date(2014, 6, 15),
'day': datetime.datetime(2014, 6, 16, 0, 0, tzinfo=zoneinfo.ZoneInfo('Australia/Melbourne')),
'hour': datetime.datetime(2014, 6, 16, 0, 0, tzinfo=zoneinfo.ZoneInfo('Australia/Melbourne')),
'minute': 'minute': datetime.datetime(2014, 6, 15, 14, 30, tzinfo=zoneinfo.ZoneInfo('UTC')),
'second': datetime.datetime(2014, 6, 15, 14, 30, 50, tzinfo=zoneinfo.ZoneInfo('UTC'))
'minute': 'minute': datetime.datetime(2014, 6, 15, 14, 30, tzinfo=timezone.utc),
'second': datetime.datetime(2014, 6, 15, 14, 30, 50, tzinfo=timezone.utc)
}
``TimeField`` truncation

View File

@@ -80,7 +80,7 @@ Argument Value
arguments passed to ``__init__()``)
``kwargs`` ``{'question_text': "What's new?",``
``'pub_date': datetime.datetime(2012, 2, 26, 13, 0, 0, 775217, tzinfo=<UTC>)}``
``'pub_date': datetime.datetime(2012, 2, 26, 13, 0, 0, 775217, tzinfo=datetime.timezone.utc)}``
========== ===============================================================
``post_init``