-
Notifications
You must be signed in to change notification settings - Fork 837
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Timezone America/Sao_Paulo is wrong DST (now is -2 and correct is -3) #797
Comments
+1 |
Hi, I am got this erro using just moment (without 'moment-timezone') so I install 'moment-timezone' and set ' moment.tz('America/Sao_Paulo')' to fix them. https://momentjs.com/timezone/docs/#/use-it/node-js/ PS.: Is possible to set with default timezone 'moment.tz.setDefault('America/Sao_Paulo');' |
Brazil no longer has DST changes - decree signed today |
You can use 'moment.tz.setDefault('America/Sao_Paulo');' |
+1 |
mine already has this config ;( |
Maybe, have to use the last version. https://github.com/moment/moment-timezone |
A possible workaround is to use Bahia's timezone: |
const moment = require('moment-timezone').tz.setDefault('America/Sao_Paulo'); const moment = require('moment'); |
I got the same problem. But, with Cuiabá's timezone which is using DST. 😕 |
Same problem here. If I use But the |
Good workaround, but in my case, the custumer can set his timezone, now I set -1 hardcode to work in america/sao_paulo. I'm waiting for the fix in momment plugin =D |
I patched it by myself. Search for the string "America/Sao_Paulo|LMT" in the source file of moment-timezone and replace the whole row with the following: "America/Sao_Paulo|LMT -03 -02|36.s 30 20|01212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121|-2glwR.w HdKR.w 1cc0 1e10 1bX0 Ezd0 So0 1vA0 Mn0 1BB0 ML0 1BB0 zX0 pTd0 PX0 2ep0 nz0 1C10 zX0 1C10 LX0 1C10 Mn0 H210 Rb0 1tB0 IL0 1Fd0 FX0 1EN0 FX0 1HB0 Lz0 1EN0 Lz0 1C10 IL0 1HB0 Db0 1HB0 On0 1zd0 On0 1zd0 Lz0 1zd0 Rb0 1wN0 Wn0 1tB0 Rb0 1tB0 WL0 1tB0 Rb0 1zd0 On0 1HB0 FX0 1C10 Lz0 1Ip0 HX0 1zd0 On0 1HB0 IL0 1wp0 On0 1C10 Lz0 1C10 On0 1zd0 On0 1zd0 Rb0 1zd0 Lz0 1C10 Lz0 1C10 On0 1zd0 On0 1zd0 On0 1zd0 On0 1HB0 FX0|20e6", I hope this will help. |
After upgrade to |
Can confirm that this is working in moment-timezone versions 0.5.26 and later. However, the abbreviation for the timezone is now non-functioning. See https://codesandbox.io/s/objective-pasteur-znco2 for a demo of the timezone working but the abbreviation not working. |
Guys, upgrade your chrome/firefox/safari to latest version and it will works nicely 👍. |
I can't ask customers of my product to do this 😢 |
Please don't answer if you did not get the point. In the current official distribution of timezone-moment-with-data.js (0.5.25-2019a, this is the link https://momentjs.com/timezone/), the timezone America/Sao_Paulo has a programmatic change to DST on November, 3th 2019 and so on for all the following years. This is not a bug that you can fix by upgrading the browser. This is a wrong information in the data caused by a missing change after this decree: https://g1.globo.com/politica/noticia/2019/04/25/bolsonaro-assina-decreto-que-acaba-com-o-horario-de-verao.ghtml. The problem can be solved by installing a newer version of moment-timezone-with-data.js (if the developer team includes this upgrade) or by patching it by yourself following these easy steps, as already posted above: Search for the string "America/Sao_Paulo|LMT" in the source file of moment-timezone and replace the whole row with the following: "America/Sao_Paulo|LMT -03 -02|36.s 30 20|01212121212121212121212121212121212121212121212121212121212121212121212121212121212121212121|-2glwR.w HdKR.w 1cc0 1e10 1bX0 Ezd0 So0 1vA0 Mn0 1BB0 ML0 1BB0 zX0 pTd0 PX0 2ep0 nz0 1C10 zX0 1C10 LX0 1C10 Mn0 H210 Rb0 1tB0 IL0 1Fd0 FX0 1EN0 FX0 1HB0 Lz0 1EN0 Lz0 1C10 IL0 1HB0 Db0 1HB0 On0 1zd0 On0 1zd0 Lz0 1zd0 Rb0 1wN0 Wn0 1tB0 Rb0 1tB0 WL0 1tB0 Rb0 1zd0 On0 1HB0 FX0 1C10 Lz0 1Ip0 HX0 1zd0 On0 1HB0 IL0 1wp0 On0 1C10 Lz0 1C10 On0 1zd0 On0 1zd0 Rb0 1zd0 Lz0 1C10 Lz0 1C10 On0 1zd0 On0 1zd0 On0 1zd0 On0 1HB0 FX0|20e6". As you can see what I am doing is using the same data as before but with dates only until last DST change. That's all. |
@MassimilianoCarosi the current Look at releases page: https://github.com/moment/moment-timezone/releases About browsers, @leonardocouy is right too, because the browsers also had the wrong timezone in old versions. For us, the problem has been completely eliminated after updating moment-timezone AND BROWSERS. |
It worked for me! Great! ㊗️ |
In this case the https://momentjs.com/timezone/ not updated with the last realease but in git hub is up to date. Thank you very much guys! |
In this link is possible see the wrong when click in America/Sao_paulo
https://momentjs.com/timezone/
Brazil stop using DST but , moment timezone is using DST.
Can I set the configuration for stop using DST?
The text was updated successfully, but these errors were encountered: