On Sun, 27 Nov 2005 07:40:36 -0800, Philipp von Weitershausen <[EMAIL PROTECTED]> wrote:

Philipp von Weitershausen wrote:
I've recently been seeing weird DateTime test failures on all Zope 2
branches since 2.7 (see below). Any idea what I'm doing wrong? My system
is OSX 10.3 with a self-compiled Python 2.4.1 (through darwinports). My
system timezone, as you can see, is GMT+0800 (Beijing time).


I've figured this one out. The Chinese time zone is known as 'CST', but
so is 'US/Central' as well. In fact, Mac OS X itself doesn't report the
time zones to python consistently. When I set my time zone to Chicago
time, time.tzname is ('CST', 'CST') and when I set my time zone to
Shanghai time, it remains the same, even though it's a completely
different time zone. DateTime.DateTimeZone._zmap can only pick one
timezone to be mapped to the 'CST' name and it happens to choose
'US/Central' (which doesn't surprise me obviously). Running the tests
with the operating system's time zone set to, say, CET works fine.

Welcome to the wonderful US-centric world of the Zope DateTime module. I believe the same problem exists for Australian time zones which happen to share abbreviations with some obscure US time zone. ;)

Posting from the US-ly yours,

--
_____________________________________________________________________

     Alexander Limi · Chief Architect · Plone Solutions · Norway

 Consulting · Training · Development · http://www.plonesolutions.com
_____________________________________________________________________

      Plone Co-Founder · http://plone.org · Connecting Content
  Plone Foundation · http://plone.org/foundation · Protecting Plone

_______________________________________________
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - http://mail.zope.org/mailman/listinfo/zope-announce
http://mail.zope.org/mailman/listinfo/zope )

Reply via email to