Author belopolsky
Recipients Esben.Agerbæk.Black, belopolsky, lemburg, pitrou
Date 2012-04-10.13:32:30
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <CAP7h-xbKmyEGYW-pkDzZh-oyDWyCFR_naCm0THrQnFESVXaYCA@mail.gmail.com>
In-reply-to <1334054351.3389.8.camel@localhost.localdomain>
Content
On Tue, Apr 10, 2012 at 6:44 AM, Antoine Pitrou <report@bugs.python.org> wrote:
> It's so easy that the patch isn't a one-liner and it seems to still have
> bugs wrt. intended behaviour.

Unless I miss something, the inverse to isocalendar() is simply

from datetime import *

def fromiso(year, week, day):
    d = date(year, 1, 4)
    return d + timedelta((week - 1) * 7 + day - d.isoweekday())

At least it works in my testing:

(2012, 15, 2)
History
Date User Action Args
2012-04-10 13:32:30belopolskysetrecipients: + belopolsky, lemburg, pitrou, Esben.Agerbæk.Black
2012-04-10 13:32:30belopolskylinkissue14423 messages
2012-04-10 13:32:30belopolskycreate