[Zope-CMF] Re: [CMF] 60/ 3 Comment "EffectiveDate and co don't keep tz offset"

Jens Vagelpohl jens at dataflake.org
Mon Nov 22 07:09:18 EST 2004


>
>> Before jumping in and changing it, would there be any problem in 
>> modifying all those DublinCore methods that currently call the 
>> ISO-method on the DateTime class to return a correct ISO 
>> 8601-representation instead? Here's an example:
>> October 13th, 2004 at 2:34:54 PM in Fredericksburg/VA (EST)
>> ISO returns: 2004-10-13 14:24:54
>> ISO 8601 should be: 2004-10-13T14:24:54-05:00
>
> I guess the problem is that the '*Date' methods are used in different 
> places: While forms like metadata_edit_form would benefit from the 
> proposed change, there are other places like content_byline, where the 
> current format seems to be more suitable.
>
> The change potentially breaks the layout of some pages, so moving to 
> ISO 8601 on the maintenance branch isn't very nice. On the other hand 
> we can't use the CatalogableDublinCore methods for edit forms because 
> they return __FLOOR_DATE or __CEILING_DATE instead of None.
>
> Don't know what to do.

Looks like the values from EffectiveDate and friends are used in 
different ways. There is the usage in forms (metadata_edit_form) and 
for content presentation (like on view templates).

Looking at the Dublin Core spec itself, the explanations talk about ISO 
8601 but the examples don't have the time zone representation. They 
only talk about using a "YY-MM-DD"-style string. So really, the way it 
works right now is OK because nothing mandates preserving the time zone 
offset.

I don't completely understand the second comment about __FLOOR_DATE and 
__CEILING_DATE, and I'm not sure it's entirely on topic.

I'm going to close the issue as WONTFIX right now because nothing is 
wrong about the way it works right now.

jens



More information about the Zope-CMF mailing list