Calendar in clock applet makes mistake on week number in GNOME3

Solution Unverified - Updated -

Issue

  • Computation used to calculate week numbers in gnome calendar is getting wrong when the daylight saving time is applied.
  • Everyone using gnome 3.x living in a timezone that uses daylight saving time is affected by this bug. The bug is consisting of showing the week 13 two times and hence every week afterwords is wrong.
  • The problem is that not all days are MSECS_IN_DAY long. During daylight saving time there's one hour missing, so for example the 2nd of April of 2015 is 91 days after January the 1st, but the result of our operation is 90.9583. Since we are rounding downwards, one day is lost. The problem remains until autumn, when there's one day that's one hour longer, that's why there's w43 missing in 2015."

Environment

  • Red Hat Enterprise Linux 7
  • gnome-shell-3.8.4-45.el7.x86_64

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.