You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 8df7bc6
Browse filesBrowse the repository at this point in the historyBrowse files
<li>UNIX time is represented as the number of seconds from one point in time known as the Epoch, defined to be 00:00 (TZ?) January 1, 1970 UTC, not counting leap seconds
88
+
<li>UNIX time is represented as the number of seconds from one point in time known as the Epoch, defined to be 00:00 UTC January 1, 1970, not counting leap seconds
89
89
<li>Note that UNIX time is based on another time standard
90
90
<li>On 32 bit OSes which store time as a signed 32-bit integer, the largest value that can be stored is 03:14:07 UTC on Tuesday, 19 January 2038. One second afterwards, time overflows back to zero. This is known as the Y2038 problem.
91
91
<li>On 64 bit machines, the largest time which can be represented is in the year 292 billion, at which time our universe is predicted to not exist
@@ -188,7 +188,7 @@ <h2>two types of datetimes - naive and aware</h2>
188
188
<p>Timezone is specified with the tzinfo attribute, through the constructor: datetimes are immutable
189
189
<p>Change the timezone or another attribute with the replace(*args, **kwargs) method to create a new object with all the same attributes except those specified
190
190
<p>tzinfo is expected to be a subclass of datetime.tzinfo
191
-
<p>However, datetime.tzinfo is an abstract base class, which means you'll need to define your own subclass (fraught with peril) or install the pytz package
191
+
<p>However, datetime.tzinfo is an abstract base class, which means you'll need to define your own subclass (filled with peril) or install the pytz package
192
192
<p>pytz is based on the <atarget="_blank" href="http://en.wikipedia.org/wiki/Tz_database">Olson database</a>, a reference database of the world's timezones.
193
193
</section>
194
194
@@ -242,7 +242,7 @@ <h2>time calculations</h2>
242
242
<sectionclass="slide">
243
243
<h2>Storing datetimes</h2>
244
244
<p>Try to deal in UTC as much as possible. Do not depend on the machine's interpretation of local time.
245
-
<p>For instance, my datetime.now() on my Mac will return a naive datetime containing the local time. Alternatively:
245
+
<p>For instance, datetime.now() on my Mac will return a naive datetime containing the local time. Alternatively:
246
246
<pre><code>
247
247
# return the current time as an aware datetime in UTC:
0 commit comments