I have a problem with timezone “Santiago”. Chile changed to daylight time (GMT -3) from 1st september.
Time.now.in_time_zone(“Santiago”)
=> Tue, 04 Sep 2012 10:57:43 CLT -04:00 <<– wrong, should be 11:57:43 CLT -03:00
Any idea?
Thanks.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Timezone data is provided by the tzdata gem. Rails requires a rather up to date version (iirc at least 0.3.31 for Rails 3.2.8), but as time zone definitions are rather short lived, sometimes you need to update them manually. In your case, you need at least 0.3.32 which includes the changes of the Chile DST. At the time of writing of this answer, the current version of tzdata is 0.3.33.
To force a newer version of tzdata, just add this to your
Gemfile: