@@ -26,10 +26,10 @@ Daylight savings time challenges
2626Daylight savings time creates discontinuities in a time series
2727
2828.. image :: /_static/dst_sf_graph.png 
29-    :height:  400 px 
29+    :height:  250 px 
3030
3131.. image :: /_static/dst_fb_graph.png 
32-    :height:  400 px 
32+    :height:  250 px 
3333
3434On representing a point in time
3535------------------------------- 
@@ -59,8 +59,11 @@ the letter Z, e.g. 12:59Z
5959It is similar to, but not the same as, Greenwich Mean Time (GMT). UTC is
6060more precisely defined
6161
62+ .. nextslide ::
63+    
6264.. image :: /_static/Greenwich_clock.jpg 
63- 
65+    :height:  500px  
66+ 	   
6467`UNIX time  <http://en.wikipedia.org/wiki/Unix_time >`__
6568------------------------------------------------------ 
6669
@@ -127,10 +130,8 @@ precision is limited to microseconds and time range is limited:
127130
128131       In [3]: datetime.MINYEAR 
129132       Out[3]: 1 
130- 
131133       In [4]: datetime.MAXYEAR 
132134       Out[4]: 9999 
133- 
134135       In [5]: datetime.datetime(37337,1,1) 
135136       --------------------------------------------------------------------------- 
136137       ValueError                                Traceback (most recent call last) 
@@ -295,6 +296,8 @@ datetimes in the calculations must be all naive or all aware
295296
296297
297298Storing datetimes
299+ ----------------- 
300+ 
298301Try to deal in UTC as much as possible.  Do not depend on the machine's interpretation of local time.
299302For instance, datetime.now() on my Mac will return a naive datetime containing the local time.  Alternatively:
300303
@@ -344,11 +347,18 @@ are supplied for date and datetime objects
344347unfortunately, the default implementation does not handle timezone aware
345348datetimes, but they are simply implementable
346349
347- let's look at examples/datetime\_ naive\_ to\_ sqlite.py and
348- examples/datetime\_ aware\_ to\_ sqlite.py
349350
351+ Python Date and Time Useful links
352+ --------------------------------- 
350353
351- .. nextslide ::
354+ http://agiliq.com/blog/2009/02/understanding-datetime-tzinfo-timedelta-amp-timezo/
355+ 
356+ https://pymotw.com/3/calendar/index.html
357+ 
358+ https://pymotw.com/3/datetime/index.html
359+ 
360+ Dealing with DST and the same time twice in one day
361+ https://www.python.org/dev/peps/pep-0495/
352362
353363Questions?
354364---------- 
0 commit comments