Re: convert time to UTC seconds since epoch

2010-07-21 Thread Steve Allen
On Jul 20, 6:57 pm, Chris Rebert wrote: [regarding trust of POSIX vis a vis leap seconds] > I'm not saying they necessarily should, but they're standardized and > the `time` module is based on POSIX/Unix-ish assumptions; not > following POSIX would be inconsistent and problematic. > Breaking stand

Re: convert time to UTC seconds since epoch

2010-07-20 Thread Chris Rebert
On Tue, Jul 20, 2010 at 6:48 PM, Greg Hennessy wrote: > On 2010-07-21, Chris Rebert wrote: >> On Tue, Jul 20, 2010 at 6:31 PM, Greg Hennessy wrote: >>> Given the documentation talks about "double leap seconds" which don't >>> exist, why should this code be trusted? >> >> Because they exist(ed) i

Re: convert time to UTC seconds since epoch

2010-07-20 Thread Greg Hennessy
On 2010-07-21, Chris Rebert wrote: > On Tue, Jul 20, 2010 at 6:31 PM, Greg Hennessy wrote: >> Given the documentation talks about "double leap seconds" which don't >> exist, why should this code be trusted? > > Because they exist(ed) in POSIX. Why should POSIX time calculations involving leap se

Re: convert time to UTC seconds since epoch

2010-07-20 Thread Chris Rebert
On Tue, Jul 20, 2010 at 6:31 PM, Greg Hennessy wrote: > On 2010-07-20, Rami Chowdhury wrote: >> If you have a sufficiently recent version of Python, have you >>considered time.strptime: >>http://docs.python.org/library/time.html#time.strptime ? > > Given the documentation talks about "double leap

Re: convert time to UTC seconds since epoch

2010-07-20 Thread Greg Hennessy
On 2010-07-20, Rami Chowdhury wrote: > If you have a sufficiently recent version of Python, have you >considered time.strptime: >http://docs.python.org/library/time.html#time.strptime ? Given the documentation talks about "double leap seconds" which don't exist, why should this code be trusted?

Re: convert time to UTC seconds since epoch

2010-07-20 Thread Ian Kelly
On Tue, Jul 20, 2010 at 4:51 PM, Alexander wrote: >  On 21.07.2010 00:46, Rami Chowdhury wrote: >> On Jul 20, 2010, at 12:26 , Alexander wrote: >> >>> Hi, list >>> >>> How with python standard library to convert string like '-MM-DD >>> mm:HH:SS ZONE' to seconds since epoch in UTC? ZONE may be

Re: convert time to UTC seconds since epoch

2010-07-20 Thread Alexander
On 21.07.2010 00:46, Rami Chowdhury wrote: > On Jul 20, 2010, at 12:26 , Alexander wrote: > >> Hi, list >> >> How with python standard library to convert string like '-MM-DD >> mm:HH:SS ZONE' to seconds since epoch in UTC? ZONE may be literal time >> zone or given in explicit way like +0100. >

Re: convert time to UTC seconds since epoch

2010-07-20 Thread Rami Chowdhury
On Jul 20, 2010, at 12:26 , Alexander wrote: > Hi, list > > How with python standard library to convert string like '-MM-DD > mm:HH:SS ZONE' to seconds since epoch in UTC? ZONE may be literal time > zone or given in explicit way like +0100. If you have a sufficiently recent version of Pytho