Eric, on 2007-08-26: > To work around this, I've modified the addition so that instead of adding 1 > day, it adds 1.5 days. This extra half a day is removed by the > theDateTime.earliestTime() call but is enough to overcome the DST addition > problem. Ugly hack.
I had the same problem once in the eXtremeManagement Plone product. For a monthly overview I needed to do something for every day of the month. I worked around it with the code below. day = 1 date = DateTime(2007, 10, 1) # 1 October 2007 while True: # skipped some lines irrelevant to the DateTime problem day += 1 try: date = DateTime(self.year, self.month, day) except: break Hm, that should probably be "except DateTime.DateTime.DateError" but there is not really anything else that can go wrong here. -- Maurits van Rees | http://maurits.vanrees.org/ [NL] Work | http://zestsoftware.nl/ "Do not worry about your difficulties in computers, I can assure you mine are still greater." _______________________________________________ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )