From: G. U. <go...@ud...> - 2008-07-26 18:10:28
|
Benno Schulenberg writes: > Anyone know a python function that can compare those strings > correctly, or convert them to some standard time format? I believe the dateutil package gets it right: >>> import dateutil.parser >>> dateutil.parser.parse("2008-07-23 09:35-0500") > dateutil.parser.parse("2008-07-23 12:49+0100") True Dateutil is a separate module, which doesn't come bundled with Python (http://labix.org/python-dateutil). In Fedora for example, it's in the package python-dateutil. |