Add Chatham Islands Time (UTC+1245) support. #9639

Merged
merged 1 commit into from Apr 12, 2013

Projects

None yet

4 participants

@BanzaiMan
Contributor

Also update the documentation on the number of supported time zones.

Contributor

Chatham Islands should be behind Samoa, but on my local machine it's not showing that correctly.

$ TZ=Pacific/Apia date   
Sun Mar 10 15:25:32 WST 2013
$ TZ=Pacific/Chatham date
Sun Mar 10 16:10:35 CHADT 2013

Investigating (so that the list order can be maintained).

Owner

Looks like the tzinfo gem has it right:

>> Time.zone = 'Pacific/Apia'
>> Time.current
=> Sun, 10 Mar 2013 16:30:55 WSDT +14:00
>> Time.zone = 'Pacific/Chatham'
>> Time.current
=> Sun, 10 Mar 2013 16:16:48 CHADT +13:45
Contributor

@pixeltrix I think OS X has outdated tzinfo.

eggert/tz@22406c0

Owner

@BanzaiMan yes - using zdump gives you:

$ zdump -v Pacific/Apia
Pacific/Apia  Fri Dec 13 20:45:52 1901 UTC = Fri Dec 13 09:18:56 1901 LMT isdst=0
Pacific/Apia  Sat Dec 14 20:45:52 1901 UTC = Sat Dec 14 09:18:56 1901 LMT isdst=0
Pacific/Apia  Sun Jan  1 11:26:55 1911 UTC = Sat Dec 31 23:59:59 1910 LMT isdst=0
Pacific/Apia  Sun Jan  1 11:26:56 1911 UTC = Sat Dec 31 23:56:56 1910 SAMT isdst=0
Pacific/Apia  Sun Jan  1 11:29:59 1950 UTC = Sat Dec 31 23:59:59 1949 SAMT isdst=0
Pacific/Apia  Sun Jan  1 11:30:00 1950 UTC = Sun Jan  1 00:30:00 1950 WST isdst=0
Pacific/Apia  Sun Sep 26 10:59:59 2010 UTC = Sat Sep 25 23:59:59 2010 WST isdst=0
Pacific/Apia  Sun Sep 26 11:00:00 2010 UTC = Sun Sep 26 01:00:00 2010 WSDT isdst=1
Pacific/Apia  Sat Apr  2 13:59:59 2011 UTC = Sat Apr  2 03:59:59 2011 WSDT isdst=1
Pacific/Apia  Sat Apr  2 14:00:00 2011 UTC = Sat Apr  2 03:00:00 2011 WST isdst=0
Pacific/Apia  Sat Sep 24 13:59:59 2011 UTC = Sat Sep 24 02:59:59 2011 WST isdst=0
Pacific/Apia  Sat Sep 24 14:00:00 2011 UTC = Sat Sep 24 04:00:00 2011 WSDT isdst=1
Pacific/Apia  Fri Dec 30 09:59:59 2011 UTC = Thu Dec 29 23:59:59 2011 WSDT isdst=1
Pacific/Apia  Fri Dec 30 10:00:00 2011 UTC = Sat Dec 31 00:00:00 2011 WSDT isdst=1
Pacific/Apia  Sat Mar 31 13:59:59 2012 UTC = Sun Apr  1 03:59:59 2012 WSDT isdst=1
Pacific/Apia  Sat Mar 31 14:00:00 2012 UTC = Sun Apr  1 03:00:00 2012 WST isdst=0
Pacific/Apia  Mon Jan 18 03:14:07 2038 UTC = Mon Jan 18 16:14:07 2038 WST isdst=0
Pacific/Apia  Tue Jan 19 03:14:07 2038 UTC = Tue Jan 19 16:14:07 2038 WST isdst=0

Doesn't have the September 2012 transition to WSDT 😢

Contributor

If desired, you can update tz database with zic: https://gist.github.com/BanzaiMan/5129358

Owner

@pixeltrix @BanzaiMan is this ready to merge?

Contributor

@pixeltrix Is there anything else I can do?

Owner

@BanzaiMan can you squash the commits into one and I'll merge it - thanks!

@BanzaiMan BanzaiMan Add Chatham Islands Time (UTC+1245) support.
Also update the documentation on the number of supported time zones.
df3bda2
Contributor

@pixeltrix Squashed. Thanks!

@guilleiguaran guilleiguaran merged commit b36ef40 into rails:master Apr 12, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment