Hi! Stephan Richter has started to re-implement DateTime using mxDateTime a couple of weeks ago. That should fix all the various problems with DateTime. At Zope Corporation, Andreas Jung took care of that. So if you complain loud enough, I guess the fix could go into the 2.5 release. It just might be hard to be backward-compatible with all the errors, but maybe there could be something like a legacy mode you can activate if you need it ... ;-)
Joachim ----- Original Message ----- From: "Steve Alexander" <[EMAIL PROTECTED]> To: "Dieter Maurer" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Sunday, September 30, 2001 11:08 PM Subject: Re: [Zope-dev] [Bug] DateTime(string) uses GMT as timezone > Dieter Maurer wrote: > > > Unfortunately > > > > DateTime(year,month,day) != DateTime("%d-%d-%d" % (year,month,day)) > > > > The former uses the local timezone (which I think is right) > > while the latter uses GMT+0 (which seems not right). > > > > Thinks are quite bad, as the latter is used to convert > > ":date" form values into DateTime objects. > > > See also here: > > http://lists.zope.org/pipermail/zope-dev/2001-August/012974.html > > ---- > > I get different times from a string, depending whether I use '-' or '/' > as a date delimiter. > > >>> from DateTime.DateTime import DateTime > >>> DateTime('2001-08-20').pCommonZ() > 'Aug. 20, 2001 12:00 am GMT+0' > >>> DateTime('2001/08/20').pCommonZ() > 'Aug. 20, 2001 12:00 am GMT+1' > >>> > > I find the difference a tad surprising. > > Is this a bug or a feature? > > If it's a bug, I'll work on a fix. > > I'm guessing this is a feature; perhaps using the '-' delimiter suggests > I'm trying to use ISO formatting. > > I'm running this in a GMT+1 timezone btw. > > Zope latest from CVS, Python 2.1. > ---- > > I never got a reply as to whether it was a bug or a feature, so I didn't > work on a fix. > > -- > Steve Alexander > Software Engineer > Cat-Box limited > > > > _______________________________________________ > Zope-Dev maillist - [EMAIL PROTECTED] > http://lists.zope.org/mailman/listinfo/zope-dev > ** No cross posts or HTML encoding! ** > (Related lists - > http://lists.zope.org/mailman/listinfo/zope-announce > http://lists.zope.org/mailman/listinfo/zope ) > > _______________________________________________ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )