I have create an issue : https://github.com/golang/go/issues/56913Title is "tzdata error/go 1.19: zoneinfo error for America/Tijuana #56913"### How to reproduce the problem
```
step 1. run update.bash update zoneinfo.zip to 2022f
step 2. run test code
loc, _ = time.LoadLocation("America/Tijuana")
time_str := time.Now().In(loc).Format("2006-01-02 15:04:05")
step 3. check result
The result should be "2022-11-22 18:49:05"
But got "2022-11-22 19:49:05"
```Jianyong Guo <coolki...@gmail.com> 于2022年11月23日周三 10:32写道:Hi, IantI am doing some test for timezone, I found that, if no using -R option, the zoneinfo.zip data will be wrong for America/Tijuana (a timezone for Mexcio)The last item in transform vector is 1268560800 which is 2010-03-14 18:00:00, The result will be wrong for code like this:loc, _ = time.LoadLocation("America/Tijuana")time_str := time.Now().In(loc).Format("2006-01-02 15:04:05")Freeman GuoHeschi Kreinick <hes...@google.com> 于2022年11月23日周三 01:12写道:I don't know very much about tzdata. Would you like to send a mail to golan...@googlegroups.com or file an issue at go.dev/issue/new?On Tue, Nov 22, 2022 at 7:32 AM Jianyong Guo <coolki...@gmail.com> wrote:Hi,
I found that the zoneinfo.zip data in latest golang versions is error (such go 1.18, go 1.19)
Because from tzdata 2022b, the zoneinfo generator zic has changed, and -R parameter is add.
-R parameter is using to generate redundant data until to 2038
How to fix:
- tzdata 2022f is released and the golang /lib/time/zoneinfo.zip need to be updated.
- the update.bash script has some error, -R args is need for building zoneinfo data.
make CFLAGS=-DSTD_INSPIRED AWK=awk TOPDIR=output install
shoule be:
make CFLAGS=-DSTD_INSPIRED AWK=awk TOPDIR=output ZFLAGS='-R "@2137586400"' installWithout -R parameter: the zoneinfo data can only cover just NEXT year, e.g [1970, .... 2023]
- -R paramter is using to generate future DST rules.
With -R: Can generate all futher DST time, e.g [1970, .... 2023, 2024, 2025, ... 2038]Freeman Guo--╔═══ ══ ══ ═══ ═══ ══ ══ ═══╗郭建勇╚═══ ══ ══ ═══ ═══ ══ ══ ═══ ═══ ══ ══ ═══╝--╔═══ ══ ══ ═══ ═══ ══ ══ ═══╗郭建勇╚═══ ══ ══ ═══ ═══ ══ ══ ═══ ═══ ══ ══ ═══╝