[egenix-users] Unsupported ISO format string

David Huard david.huard at gmail.com
Wed Apr 9 19:27:54 CEST 2008

Hi all, 

I just wanted to point out that the Date parser in mx.DateTime does not 
seem to interpret correctly the hour field in the following ISO string:

In [10]: dt.DateFrom('1979-01-01T01')
Out[10]: <mx.DateTime.DateTime object for '1979-01-01 00:00:00.00' at 

The problem is related to the fact that the minute group is not optional. 
Putting it optional doesn't solve the problem since the regular 
expression relies on the presence of : to identify the time string, which 
is absent in this case. 

Unless I'm wrong, this use case is ISO 8601 compliant.

I patched my local copy, but let's say it's a rather ugly hack based on 
adding an isoT regular expression.  


David Huard

Please CC to my personal email.

More information about the egenix-users mailing list