[Tickets #13947] Re: Calendar breaks on DST start date

noreply at bugs.horde.org noreply at bugs.horde.org
Mon Apr 13 17:09:30 UTC 2015


DO NOT REPLY TO THIS MESSAGE. THIS EMAIL ADDRESS IS NOT MONITORED.

Ticket URL: https://bugs.horde.org/ticket/13947
------------------------------------------------------------------------------
  Ticket             | 13947
  Updated By         | jsveiga at it.eng.br
  Summary            | Calendar breaks on DST start date
  Queue              | Kronolith
  Version            | 4.2.2
  Type               | Bug
  State              | Feedback
  Priority           | 2. Medium
  Milestone          |
  Patch              |
  Owners             |
------------------------------------------------------------------------------


jsveiga at it.eng.br (2015-04-13 17:09) wrote:

> The problem is that calculations like Date.next().day() don't jump  
> to the next day, but add 24 hours. I guess.

Exactly, and it seems that adding a week adds 7*24h. Then as the DST  
switch days do not have 24h, the resulting "day" is not what is  
expected (as it happens when building the week rows). This is why  
setting the hour for something away from 00:00 solves it as in the  
patch I sent: Although it may shift +-1h, it is still within the  
expected day.

It seems that JS date arithmetic for DST is not really consistent  
across browsers around 00:00 (I've found this detailing differences  
even between IE9 and IE10; maybe related to the same issue:  
https://msdn.microsoft.com/en-us/library/ie/jj863688%28v=vs.85%29.aspx).

So would be interesting to make Kronilith "immune" to that, so the  
results are consistent across different browsers/platforms.





More information about the bugs mailing list