Skip to content
This repository has been archived by the owner on Apr 10, 2018. It is now read-only.

timezones are not IANA standard #84

Open
tisdall opened this issue Jul 13, 2016 · 0 comments
Open

timezones are not IANA standard #84

tisdall opened this issue Jul 13, 2016 · 0 comments

Comments

@tisdall
Copy link

tisdall commented Jul 13, 2016

I found that I needed to create a mapping from the timezones returned by pygeoip to the proper ones in pytz so I thought I'd share it here. The keys are what are returned by pygeoip and the values are the proper IANA timezones for each.

{
    'Africa/Asmera': 'Africa/Nairobi',
    'America/Indianapolis': 'America/Indiana/Indianapolis',
    'America/Montreal': 'America/Toronto',
    'Asia/Calcutta': 'Asia/Kolkata',
    'Asia/Chongqing': 'Asia/Shanghai',
    'Asia/Harbin': 'Asia/Shanghai',
    'Asia/Istanbul': 'Europe/Istanbul',
    'Asia/Katmandu': 'Asia/Kathmandu',
    'Asia/Macao': 'Asia/Macau',
    'Atlantic/Faeroe': 'Atlantic/Faroe',
    'Australia/Canberra': 'Australia/Sydney',
    'Australia/NSW': 'Australia/Sydney',
    'Australia/North': 'Australia/Darwin',
    'Australia/Queensland': 'Australia/Brisbane',
    'Australia/South': 'Australia/Adelaide',
    'Australia/Tasmania': 'Australia/Hobart',
    'Australia/Victoria': 'Australia/Melbourne',
    'Australia/West': 'Australia/Perth',
    'Chile/Continental': 'America/Santiago',
    'Pacific/Samoa': 'Pacific/Pago_Pago',
    'US/Samoa': 'Pacific/Pago_Pago',
}
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant