homepage

This issue tracker has been migrated to GitHub , and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author belopolsky
Recipients belopolsky, exarkun, lemburg
Date 2012年01月04日.03:51:30
SpamBayes Score 2.8865165e-07
Marked as misclassified No
Message-id <1325649091.3.0.632765285004.issue13556@psf.upfronthosting.co.za>
In-reply-to
Content
Is 3.3 message better?
>>> datetime.now(tz=X())
Traceback (most recent call last):
 File "<stdin>", line 1, in <module>
ValueError: offset must be a timedelta strictly between -timedelta(hours=24) and timedelta(hours=24).
In 2.7, the message is indeed misleading:
>>> datetime.now(tz=X())
Traceback (most recent call last):
 File "<stdin>", line 1, in <module>
ValueError: tzinfo.utcoffset() returned 1440; must be in -1439 .. 1439
I am not sure fixing this in 2.x is worth the trouble, but I would consider improving the message in 3.x by adding information about the actual offset. I vaguely remember that there was a reason for leaving that info out in 3.x.
History
Date User Action Args
2012年01月04日 03:51:31belopolskysetrecipients: + belopolsky, lemburg, exarkun
2012年01月04日 03:51:31belopolskysetmessageid: <1325649091.3.0.632765285004.issue13556@psf.upfronthosting.co.za>
2012年01月04日 03:51:30belopolskylinkissue13556 messages
2012年01月04日 03:51:30belopolskycreate

AltStyle によって変換されたページ (->オリジナル) /