timezones has too many
There are way too many overlapping timezones in pytz's common list. Has anyone pared this down? For example there are 5 or 6 duplicate Canadian timezones and 15 or so duplicate US time zones. China is 1 timezone no DST, but has 5 entries.. By duplicate I mean GMT offset and DST are exactly the same.
Getting rid of the timezones in pytz.country_timezones['us'] gets rid of the duplicate US timezones as it only contains the America/* zones and not the base US/* zones. This doesn't work for other countries.
I don't think that's a good idea. In Australia, Melbourne and Sydney usually share the same timezone, however the choice of when DST starts and ends is controlled by two different bodies.
When Melbourne hosted the Commonwealth Games a few years back, they changed the DST (just for the one year) for convenience. I think Sydney may have changed also to avoid confusion, but they did have to decide that separately from Melbourne.
链接地址: http://www.djcxy.com/p/2090.html上一篇: 找到一个项目是否在JavaScript数组中的最佳方法?
下一篇: 时区有太多