Path: csiph.com!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!newsfeed.xs4all.nl!newsfeed2.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.021 X-Spam-Evidence: '*H*': 0.96; '*S*': 0.00; '(so': 0.07; 'suppose': 0.07; '(it': 0.09; 'eat': 0.09; 'timestamp': 0.09; 'assume': 0.11; 'essential': 0.15; 'file,': 0.15; '7pm.': 0.16; 'roy': 0.16; 'seconds,': 0.16; 'subject: \n ': 0.16; 'utc': 0.16; 'wrote:': 0.17; 'differ': 0.17; 'thu,': 0.17; 'widget': 0.17; 'jan': 0.18; 'sort': 0.21; 'supposed': 0.21; 'clock': 0.22; 'tells': 0.22; 'second': 0.24; 'header:In-Reply-To:1': 0.25; 'header:User- Agent:1': 0.26; 'am,': 0.27; 'opposed': 0.27; "doesn't": 0.28; 'chris': 0.28; 'run': 0.28; '>>>>': 0.29; '"the': 0.29; "i'm": 0.29; 'figure': 0.30; 'resolution': 0.30; 'quickly': 0.32; 'to:addr:python-list': 0.33; 'server': 0.35; 'pm,': 0.35; 'subject:?': 0.35; 'really': 0.36; 'but': 0.36; 'display': 0.36; 'york': 0.37; 'subject:: ': 0.38; 'mean': 0.38; 'some': 0.38; 'sure': 0.38; 'to:addr:python.org': 0.39; 'received:192': 0.39; 'notice': 0.39; 'received:192.168': 0.40; 'help': 0.40; 'your': 0.60; 'easy': 0.60; 'between': 0.63; 'to,': 0.65; 'date,': 0.65; 'hours': 0.66; 'header:Reply-To:1': 0.68; 'received:74.208': 0.71; 'smith': 0.71; 'reply-to:no real name:2**0': 0.72; 'day': 0.73; 'article': 0.78; '2013': 0.84; 'received:74.208.4.194': 0.84; 'subject:Using': 0.84 Date: Wed, 02 Jan 2013 12:44:57 -0500 From: Dave Angel User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:16.0) Gecko/20121011 Thunderbird/16.0.1 MIME-Version: 1.0 To: python-list@python.org Subject: Re: Using mktime to convert date to seconds since epoch - omitting elements from the tuple? References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Provags-ID: V02:K0:Zq6QC8pKUP2yptp5IW9KAxZ4gMo5mvvdMlqu2CsxNg1 oCqlUqV0EjMvf/Z+1M+suqOktNDKnONAzKk8AIIIeN5rjCf9Gq z1cvhC8FjxG3qawve8i03goUGspUwlowMR7v+Fp9270O8+9FZs iroappCB60ZA9WFK6NakAJBFlJr8osBf/hjlEWLaKuMCPL2TU1 WBaiFGosFp3N2yjeTbPISIE6tltvNjToZfki/mktk89X+NNs1k advvyn9JIykr2MtVU0RD0VwBJAd1FaVB0e5TFaOf6D+lep6XcS tYOhNOJm6zrg0xnRJfttmAZzotJtPUxvXjGHqQPxvhRArPM+w= = X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list Reply-To: d@davea.name List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 38 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1357148722 news.xs4all.nl 6971 [2001:888:2000:d::a6]:34444 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:36000 On 01/02/2013 12:34 PM, Chris Angelico wrote: > On Thu, Jan 3, 2013 at 4:27 AM, Roy Smith wrote: >> In article , >> Chris Angelico wrote: >> >>>> I assume you mean timestamps. A date doesn't need to worry about UTC >>>> the way a timestamp does. >> I'm not sure how a date and a timestamp differ in any significant >> way. A date is just a very low-precision time. >> >> I suppose what's really essential is a way to quickly see the current >> UTC time. That way, when you're looking at some event in a log file, >> it's easy to figure out, "that was 20 minutes ago", as opposed to, >> "that was 5 hours and 20 minutes ago". I run my desktop in New York >> time (so I know when I'm supposed to eat lunch), but I also have a >> second clock widget displaying UTC time just below it. Right now, >> it's 17:22. > The difference between "20 minutes ago" and "5 hours and 20 minutes > ago" doesn't really come up when your resolution is 86400 seconds, as > is the case with a date :) Only 20.83 % of the time for that timezone. You might not notice it if you always log off by 7pm. > > I have the same sort of thing. My desktop's clock is on local time > (4:33AM), but my server tells me, when I type 'who', that "The current > UTC (GMT) time is: Wed 17:33:35" (it doesn't bother with the date, > only the day of week, as the main purpose of that time display is to > help people synchronize on weekly events). > > ChrisA -- DaveA