mIRC Home    About    Download    Register    News    Help

Print Thread
Getting wrong GMT - $asctime($ctime,HH:nn:ss zzz)) #269228 24/07/21 04:33 AM
Joined: Feb 2011
Posts: 382
K
KindOne Offline OP
Pan-dimensional mouse
OP Offline
Pan-dimensional mouse
K
Joined: Feb 2011
Posts: 382
GMT is off by one hour in every version after 7.55, this is wrong. My timezone is currently in Eastern Daylight Time (GMT-4).

[7.55] 00:12:06 -0400 GMT
[7.56] 00:12:06 -0500 GMT


irc.swiftirc.net #msl (mIRC Scripting Language)
Re: Getting wrong GMT - $asctime($ctime,HH:nn:ss zzz)) [Re: KindOne] #269229 24/07/21 12:30 PM
Joined: Feb 2003
Posts: 2,780
Raccoon Offline
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2003
Posts: 2,780
Do you get the same value for $ctime in both versions, or conflicting values?


Well. At least I won lunch.
Good philosophy, see good in bad, I like!
Re: Getting wrong GMT - $asctime($ctime,HH:nn:ss zzz)) [Re: Raccoon] #269230 24/07/21 05:56 PM
Joined: Feb 2011
Posts: 382
K
KindOne Offline OP
Pan-dimensional mouse
OP Offline
Pan-dimensional mouse
K
Joined: Feb 2011
Posts: 382
Same $ctime value in 7.02 - 7.66 in my testing.

$ctime - $asctime($ctime,HH:nn:ss zzz)


[7.55] 1627148519 - 13:41:59 -0400 GMT
[7.56] 1627148519 - 13:41:59 -0500 GMT


irc.swiftirc.net #msl (mIRC Scripting Language)
Re: Getting wrong GMT - $asctime($ctime,HH:nn:ss zzz)) [Re: KindOne] #269233 25/07/21 12:56 PM
Joined: Feb 2003
Posts: 2,780
Raccoon Offline
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2003
Posts: 2,780
Look like another DST daylight savings time bug, then. I bet it goes away in November.


Please tell me the values of $gmt do not match. If they do match it would be a weird DST bug.


Well. At least I won lunch.
Good philosophy, see good in bad, I like!
Re: Getting wrong GMT - $asctime($ctime,HH:nn:ss zzz)) [Re: Raccoon] #269237 27/07/21 02:02 AM
Joined: Feb 2011
Posts: 382
K
KindOne Offline OP
Pan-dimensional mouse
OP Offline
Pan-dimensional mouse
K
Joined: Feb 2011
Posts: 382
Greeting from the future! Looks like a DST bug.


//echo -ag $version $adate $ctime - $asctime($ctime,HH:nn:ss zzz)

7.55 12/31/2021 1641005909 - 21:58:29 -0500 GMT
7.56 12/31/2021 1641005909 - 21:58:29 -0500 GMT
7.66 12/31/2021 1641005909 - 21:58:29 -0500 GMT


irc.swiftirc.net #msl (mIRC Scripting Language)
Re: Getting wrong GMT - $asctime($ctime,HH:nn:ss zzz)) [Re: Raccoon] #269238 27/07/21 06:51 AM
Joined: Oct 2020
Posts: 5
E
ekcdd Offline
Nutrimatic drinks dispenser
Offline
Nutrimatic drinks dispenser
E
Joined: Oct 2020
Posts: 5
I wonder if this is related to the DST bug that occurred for me a few months back for me. Khaled was unable to reproduce it.

Re: Getting wrong GMT - $asctime($ctime,HH:nn:ss zzz)) [Re: KindOne] #269246 28/07/21 05:26 PM
Joined: Dec 2002
Posts: 4,972
Khaled Offline
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2002
Posts: 4,972
Thanks for your bug report. The time features in v7.56 were updated to 1) use the Windows time APIs and 2) fix issues in v7.55 where it was not reporting correct values in some contexts.

That said, these changes were tested at the time, so I am not sure why the DST issue has appeared again. I remember that when v7.56 was being worked on, both I and others on the forums, tested it in different timezones and times of year, and it was returning the correct values.

I am going to make a change in the next beta and will test again in different timezones and times of year.

However, it will need further beta testing to confirm that it is resolved.

Re: Getting wrong GMT - $asctime($ctime,HH:nn:ss zzz)) [Re: Khaled] #269250 29/07/21 12:39 PM
Joined: Jan 2004
Posts: 1,606
maroon Offline
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 1,606
The testing I did back then was done in thread https://forums.mirc.com/ubbthreads.php/topics/265145/gmt-number where I was looking at the time-of-day being correct, and I did not test zzz at all.

That thread included https://forums.mirc.com/ubbthreads.php/topics/265267/re-gmt-number#Post265267 where Khaled mentioned fixing a DST bug related to zzz but didn't describe what that problem had been. Perhaps that fix had gotten reverted later in the thread when the TimeAPI changed.