My error: The Python 2.6.5 documentation says:<br>v v v v<br><blockquote style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;" class="gmail_quote">classmethod datetime.strptime(date_string, format)¶<br>
<br> Return a datetime corresponding to date_string, parsed according to format. This is equivalent to datetime(*(time.strptime(date_string, format)[0:6])). ValueError is raised if the date_string and format can’t be parsed by time.strptime() or if it returns a value which isn’t a time tuple. See section strftime() and strptime() Behavior.<br>
<br> New in version 2.5.<br></blockquote>^ ^ ^ ^<br>I will include this information as a comment on the codeplex 17470 workitem.<br><br>Note that the equivalent code using "time.strptime()" is included in the above definition.<br>
--<br>Vernon Cole<br><br>On Mon, Jun 7, 2010 at 11:27 PM, Tony Meyer <<a href="mailto:tony.meyer@gmail.com">tony.meyer@gmail.com</a>> wrote:<br>> On Tue, Jun 8, 2010 at 4:46 PM, Vernon Cole <<a href="mailto:vernondcole@gmail.com">vernondcole@gmail.com</a>> wrote:<br>
>> The issue tracker for CPython [if I read it correctly] lists<br>>> datetime.strptime as a new feature to be supported in python 2.7 and<br>>> 3.2. It is not documented in the Python 2.6 manual.<br>><br>
> datetime.datetime.strptime is definitely in CPython 2.5 and 2.6:<br>><br>> """<br>> tony-meyers-imac:~ tameyer$ python<br>> Python 2.5.1 (r251:54863, Feb 6 2009, 19:02:12)<br>> [GCC 4.0.1 (Apple Inc. build 5465)] on darwin<br>
> Type "help", "copyright", "credits" or "license" for more information.<br>>>>> import datetime<br>>>>> datetime.datetime.strptime("2010 06 08", "%Y %m %d")<br>
> datetime.datetime(2010, 6, 8, 0, 0)<br>> """<br>><br>> The only IP 2.6 I have handy is <a href="http://trypython.org">trypython.org</a>, and the above code does<br>> fail there (no copy and paste from the site unfortunately).<br>
><br>> This is a known bug (so go vote!):<br>><br>> <a href="http://ironpython.codeplex.com/workitem/17470">http://ironpython.codeplex.com/workitem/17470</a><br>><br>> Cheers,<br>> Tony<br>> _______________________________________________<br>
> Users mailing list<br>> <a href="mailto:Users@lists.ironpython.com">Users@lists.ironpython.com</a><br>> <a href="http://lists.ironpython.com/listinfo.cgi/users-ironpython.com">http://lists.ironpython.com/listinfo.cgi/users-ironpython.com</a><br>
><br><br>