[issue12758] time.time() returns local time instead of UTC

2013-01-16 Thread Craig McQueen
Craig McQueen added the comment: Alexander Belopolsky wrote: No. Seconds since the epoch is neither local nor UTC. It is just an elapsed number of seconds since an agreed upon time called the epoch. This statement just seems wrong. And I have just been confused by the current

[issue12758] time.time() returns local time instead of UTC

2013-01-16 Thread Antoine Pitrou
Antoine Pitrou added the comment: It makes a difference. It seems with the current behaviour, the epoch is _in the local timezone_. No it isn't. Two different machines: $ LANG=C date Wed Jan 16 21:47:03 UTC 2013 $ python -c import time; print(time.time()) 1358372827.5 $ LANG=C date Wed Jan

[issue12758] time.time() returns local time instead of UTC

2013-01-16 Thread R. David Murray
R. David Murray added the comment: On linux/posix, the epoch is *defined* to be 1970, 1, 1 in UTC. Python just uses whatever the OS defines the epoch to be, as far as I know. -- ___ Python tracker rep...@bugs.python.org

[issue12758] time.time() returns local time instead of UTC

2012-03-15 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 1559a82a3529 by R David Murray in branch '2.7': #12758: removing confusing mention of UTC from time.time description http://hg.python.org/cpython/rev/1559a82a3529 New changeset 5615d6b91b53 by R David Murray in

[issue12758] time.time() returns local time instead of UTC

2012-03-15 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Thanks, Dylan. -- nosy: +r.david.murray resolution: - fixed stage: needs patch - committed/rejected status: open - closed type: - behavior ___ Python tracker rep...@bugs.python.org

[issue12758] time.time() returns local time instead of UTC

2012-03-14 Thread Dylan Sarber
Dylan Sarber dwsar...@gmail.com added the comment: I patched this one up quickly. One has been changed using belopolsky's recommendation, which already reads well. -- keywords: +patch nosy: +dwsarber Added file: http://bugs.python.org/file24858/time_doc_fix.patch

[issue12758] time.time() returns local time instead of UTC

2011-08-16 Thread Maxim Koltsov
New submission from Maxim Koltsov kolma...@gmail.com: Python docs (http://docs.python.org/library/time.html#time.time) say that time.time() function should return UTC timestamp, but actually i get local one: time.mktime(time.gmtime()), time.time(), time.mktime(time.localtime()) (1313466499.0,

[issue12758] time.time() returns local time instead of UTC

2011-08-16 Thread Marc-Andre Lemburg
Marc-Andre Lemburg m...@egenix.com added the comment: Maxim Koltsov wrote: New submission from Maxim Koltsov kolma...@gmail.com: Python docs (http://docs.python.org/library/time.html#time.time) say that time.time() function should return UTC timestamp, but actually i get local one:

[issue12758] time.time() returns local time instead of UTC

2011-08-16 Thread Maxim Koltsov
Maxim Koltsov kolma...@gmail.com added the comment: Then docs must be fixed. By the way, help(time.time) correctly says about localtime. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12758

[issue12758] time.time() returns local time instead of UTC

2011-08-16 Thread Marc-Andre Lemburg
Changes by Marc-Andre Lemburg m...@egenix.com: -- assignee: - docs@python components: +Documentation, Library (Lib) nosy: +docs@python ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12758

[issue12758] time.time() returns local time instead of UTC

2011-08-16 Thread Marc-Andre Lemburg
Changes by Marc-Andre Lemburg m...@egenix.com: -- keywords: +easy ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12758 ___ ___ Python-bugs-list

[issue12758] time.time() returns local time instead of UTC

2011-08-16 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: Would dropping 'in UTC' from Return the time as a floating point number expressed in seconds since the epoch, in UTC. be an acceptable solution? AFAIK there are no non-UTC epochs. -- nosy: +ezio.melotti stage: - needs patch

[issue12758] time.time() returns local time instead of UTC

2011-08-16 Thread Maxim Koltsov
Maxim Koltsov kolma...@gmail.com added the comment: Maybe add some words about local timezone? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12758 ___

[issue12758] time.time() returns local time instead of UTC

2011-08-16 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: Return the local time as a floating point number expressed in seconds since the epoch. -- nosy: +belopolsky ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12758

[issue12758] time.time() returns local time instead of UTC

2011-08-16 Thread Maxim Koltsov
Maxim Koltsov kolma...@gmail.com added the comment: Seems OK to me. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12758 ___ ___

[issue12758] time.time() returns local time instead of UTC

2011-08-16 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: Return the local time as a floating point number expressed in seconds since the epoch. No. Seconds since the epoch is neither local nor UTC. It is just an elapsed number of seconds since an agreed upon time called the