Skip Menu |
 

This queue is for tickets about the TimeDate CPAN distribution.

Report information
The Basics
Id: 52387
Status: open
Priority: 0/
Queue: TimeDate

People
Owner: Nobody in particular
Requestors: thomas.lehrner [...] culturall.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Received: from la.mx.develooper.com (x1.develooper.com [207.171.7.70]) by diesel.bestpractical.com (Postfix) with SMTP id 42D2F19B82E6 for <bug-TimeDate [...] rt.cpan.org>; Thu, 3 Dec 2009 05:04:16 -0500 (EST)
Received: (qmail 20111 invoked by uid 103); 3 Dec 2009 10:04:14 -0000
Received: from x16.dev (10.0.100.26) by x1.dev with QMQP; 3 Dec 2009 10:04:14 -0000
Received: from mail.culturall.com (HELO mail.culturall.com) (195.34.137.2) by 16.mx.develooper.com (qpsmtpd/0.80) with ESMTP; Thu, 03 Dec 2009 02:04:12 -0800
Received: from [192.168.205.76] ([192.168.205.76]) by mail.culturall.com (8.13.8+Sun/8.13.8) with ESMTP id nB3A46cL017653 for <bug-TimeDate [...] rt.cpan.org.>; Thu, 3 Dec 2009 11:04:06 +0100 (CET)
Delivered-To: cpan-bug+TimeDate [...] diesel.bestpractical.com
Subject: seconds since the Epoch, UCT
MIME-Version: 1.0
User-Agent: Thunderbird 2.0.0.23 (Windows/20090812)
X-Spam-Status: No, hits=0.0 required=8.0 tests=
Return-Path: <thomas.lehrner [...] culturall.com>
X-Spam-Check-BY: 16.mx.develooper.com
X-Original-To: bug-TimeDate [...] rt.cpan.org
Date: Thu, 03 Dec 2009 11:04:06 +0100
X-Spam-Level: *
content-type: text/plain; charset="utf-8"; format="flowed"
Message-ID: <4B178D16.5020404 [...] culturall.com>
To: bug-TimeDate [...] rt.cpan.org
Content-Transfer-Encoding: 7bit
From: Thomas Lehrner <thomas.lehrner [...] culturall.com>
X-RT-Original-Encoding: ISO-8859-1
Content-Length: 887
Download (untitled) / with headers
text/plain 887b
Hi, i think i found a bug in the calcultaion in the "seconds since the Epoch, UTC". Should not deliver "strftime("%s", @lt)" and "time2str("%s", time())" the same? perl -e 'use Date::Format; my @lt = localtime(time); print time()."\n"; print strftime("%s", @lt)."\n"; print time2str("%s", time())."\n"; print time2str("%s", time(), "CET");' example with my current time zone (CET): print $Date::Format::VERSION; => 2.23 perl -v => This is perl, v5.10.0 built for i86pc-solaris uname -a => SunOS 5.10 Generic_141415-05 i86pc i386 i86pc time() => 1259832417 strftime("%s", @lt) => 1259836017 correct time2str("%s", time()) => 1259832417 should be the same as strftime("%s", @lt)? time2str("%s", time(), "CET") => 1259832417 should be the same as strftime("%s", @lt)? Thanks in advance Thomas Lehrner
MIME-Version: 1.0
In-Reply-To: <4B178D16.5020404 [...] culturall.com>
X-Mailer: MIME-tools 5.427 (Entity 5.427)
Content-Disposition: inline
Charset: utf8
References: <4B178D16.5020404 [...] culturall.com>
Content-Type: text/plain
Message-ID: <rt-3.6.HEAD-17098-1260621789-1648.52387-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
Content-Length: 96
Fixed in TimeDate-1.20 just uploaded to CPAN. Allow a while for it to propagate to CPAN mirrors
MIME-Version: 1.0
In-Reply-To: <rt-3.6.HEAD-17098-1260621789-1648.52387-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.427 (Entity 5.427)
Content-Disposition: inline
Charset: utf8
References: <4B178D16.5020404 [...] culturall.com> <rt-3.6.HEAD-17098-1260621789-1648.52387-0-0 [...] rt.cpan.org>
Message-ID: <rt-3.6.HEAD-13597-1260791204-1080.52387-0-0 [...] rt.cpan.org>
Content-Type: text/plain
Content-Transfer-Encoding: binary
From: thomas.lehrner [...] culturall.com
X-RT-Original-Encoding: utf-8
Content-Length: 4121
On Sat Dec 12 04:43:09 2009, GBARR wrote: Show quoted text
> Fixed in TimeDate-1.20 just uploaded to CPAN. Allow a while for it to > propagate to CPAN > mirrors
thanks for your quick response :-) but i have to annoy you again, sorry. :-P there are more errors now, or i missunderstand something. example: perl -e 'use Date::Format; my $time = time(); time for a wintertime #my $time = 1276883000; # this is a summertime my @lt = localtime($time); print "time = ".$time."\n"; print "strftime(default time zone) = ".strftime("%s", @lt)."\n"; print "strftime(CET time zone) = ".strftime("%s", @lt, "CET")."\n"; print "strftime(CEST time zone) = ".strftime("%s", @lt, "CEST")."\n"; print "strftime(AWST time zone) = ".strftime("%s", @lt, "AWST")."\n"; print "strftime(UTC time zone) = ".strftime("%s", @lt, "UTC")."\n"; print "strftime(GMT time zone) = ".strftime("%s", @lt, "GMT")."\n"; print "strftime(+0100 time zone) = ".strftime("%s", @lt, "+0100")."\n"; print "strftime(+0200 time zone) = ".strftime("%s", @lt, "+0200")."\n"; print "strftime(abcdef time zone) = ".strftime("%s", @lt, "abcdef")."\n"; print "time2str(default time zone) = ".time2str("%s", $time)."\n"; print "time2str(CET time zone) = ".time2str("%s", $time, "CET")."\n"; print "time2str(CEST time zone) = ".time2str("%s", $time, "CEST")."\n"; print "time2str(AWST time zone) = ".time2str("%s", $time, "AWST")."\n"; print "time2str(UTC time zone) = ".time2str("%s", $time, "UTC")."\n"; print "time2str(GMT time zone) = ".time2str("%s", $time, "GMT")."\n"; print "time2str(+0100 time zone) = ".time2str("%s", $time, "+0100")."\n"; print "time2str(+0200 time zone) = ".time2str("%s", $time, "+0200")."\n"; print "time2str(abcdef time zone) = ".time2str("%s", $time, "abcdef")."\n";' my current time zone is CET result: time = 1260789389 current utc strftime(default time zone) = 1260789389 should be +3600 strftime(CET time zone) = 1260792989 correct strftime(CEST time zone) = 1260792989 shouldn't be +3600 strftime(AWST time zone) = 1260792989 shouldn't be +3600 strftime(UTC time zone) = 1260792989 shouldn't be +3600 strftime(GMT time zone) = 1260792989 shouldn't be +3600 strftime(+0100 time zone) = 1260792989 correct strftime(+0200 time zone) = 1260792989 shouldn't be +3600 strftime(abcdef time zone) = 1260792989 maybe correct, if you use default time zone time2str(default time zone) = 1260789389 should be +3600 time2str(CET time zone) = 1260789389 should be +3600 time2str(CEST time zone) = 1260789389 shouldn't be utc time2str(AWST time zone) = 1260789389 shouldn't be utc time2str(UTC time zone) = 1260789389 correct time2str(GMT time zone) = 1260789389 correct time2str(+0100 time zone) = 1260789389 shouldn't be utc time2str(+0200 time zone) = 1260789389 shouldn't be utc time2str(abcdef time zone) = 1260789389 shouldn't be utc if you use "my $time = 1276883000; # this is a summertime" time = 1278783000 strftime(default time zone) = 1278783000 strftime(CET time zone) = 1278790200 strftime(CEST time zone) = 1278790200 strftime(AWST time zone) = 1278790200 strftime(UTC time zone) = 1278790200 strftime(GMT time zone) = 1278790200 strftime(+0100 time zone) = 1278790200 strftime(+0200 time zone) = 1278790200 strftime(abcdef time zone) = 1278790200 time2str(default time zone) = 1278783000 time2str(CET time zone) = 1278783000 time2str(CEST time zone) = 1278783000 time2str(AWST time zone) = 1278783000 time2str(UTC time zone) = 1278783000 time2str(GMT time zone) = 1278783000 time2str(+0100 time zone) = 1278783000 time2str(+0200 time zone) = 1278783000 time2str(abcdef time zone) = 1278783000 shouldn't be 'strftime("%s", @lt, "CET")', 'strftime("%s", @lt)', 'time2str("%s", $time, "CET")' and 'time2str("%s", $time)' the same if my system time is 'CET'? additionally, shouldn't the time value be +3600 in winter and time value+7200 in summer? shouldn't be the time zone overwritten, when you use other time zones? thanks in advance
X-RT-Interface: REST
MIME-Version: 1.0
X-Mailer: MIME-tools 5.504 (Entity 5.504)
RT-Message-ID: <rt-4.0.18-1337-1579123596-1688.52387-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="utf-8"
Content-Disposition: inline
Content-Transfer-Encoding: binary
Content-Length: 79


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.