Whilst using the Spent Time Report, I have noticed that the Week display is incorrect for the first week of 2009. I set a date range of 2008-12-17 to 2009-01-07 and set the Report to show Weeks. The Weeks that are displayed are:
2008-51
2008-52
2008-1
2009-2
I asssume that the third week ought to show as 2009-1
Also affects calendar. I found that problem in our redmine installation and it turns out it's related to the start of the week. Problem is that week 1 of 2009 starts on december 2008,
If you go to calendar for January 2009, the first week is week 52 of 2008, when it should be week 1 of 2009. This doesn't happen if week starts on Monday.
For any week number calculation you should use Monday as first day of week. I would submit a patch, but I don't see any quick way to fix it, I just hacked it to force monday as first day of week, regardless which language you are using.
the week with the year's first Thursday in it (the ISO 8601 definition)
the week starting with the Monday which is nearest in time to 1 January
the week with the year's first working day in it (if Saturdays, Sundays, and 1 January are not working days)
the week with January 4 in it
the first week with the majority (four or more) of its days in the starting year
the week starting with the Monday in the period 29 December - 4 January
the week with the Thursday in the period 1 - 7 January
If 1 January is on a Monday, Tuesday, Wednesday or Thursday, it is in week 01. If 1 January is on a Friday, Saturday or Sunday, it is in week 52 or 53 of the previous year.
I hope this helps fixing the problem. Also, fixing #2884 would allow a quick workaround