[issue14423] Getting the starting date of iso week from a week number and a year.
Marc-Andre Lemburg
report at bugs.python.org
Tue Apr 10 00:20:25 CEST 2012
Marc-Andre Lemburg <mal at egenix.com> added the comment:
Alexander Belopolsky wrote:
>
> Alexander Belopolsky <alexander.belopolsky at gmail.com> added the comment:
>
> Before you invest in a C version, let's discuss whether this feature is desirable. The proposed function implements a very simple and not very common calculation. Note that even dateutil does not provide direct support for this: you are instructed to use relativedelta to add weeks to January 1st of the given year.
Which is wrong, since the start of the first ISO week of a year
can in fact start in the preceeding year...
http://en.wikipedia.org/wiki/ISO_week_date
and it's not a simple calculation.
ISO weeks are in common use throughout Europe, it's part of the
ISO 8601 standard. mxDateTime has had such constructors for ages:
http://www.egenix.com/products/python/mxBase/mxDateTime/doc/#_Toc293683820
----------
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue14423>
_______________________________________
More information about the Python-bugs-list
mailing list