Bugs item #1730389, was opened at 2007-06-03 14:27
Message generated for change (Comment added) made by nnorwitz
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1730389&group_id=5470
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Extension Modules
>Group: Python 2.5
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Emma (embirath)
>Assigned to: Brett Cannon (bcannon)
Summary: strptime bug in time module
Initial Comment:
The strptime function takes 2 arguments:
(1) a time string (like "2007 Jan 17, 10:00"), and
(2) a time format string (like "%Y %b %d, %H:%M")
Normally, a ValueError will be raised when the time string does not match the
format string. The bug I have found is that NO ValueError is raised in the case
below. Instead, and incorrect date is returned (Jan 18th is returned, when
really June 29th should be returned).
> from time import *
> print strptime('2007-180', '%Y-%j %H')
----------------------------------------------------------------------
>Comment By: Neal Norwitz (nnorwitz)
Date: 2007-06-03 14:33
Message:
Logged In: YES
user_id=33168
Originator: NO
Brett, could you take a look? I think this is your code. I verified this
on head, but assume 2.5 has the problem.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1730389&group_id=5470
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com