Skip to content
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

time: update zoneinfo_abbrs on Windows #58113

Open
qmuntal opened this issue Jan 27, 2023 · 11 comments
Open

time: update zoneinfo_abbrs on Windows #58113

qmuntal opened this issue Jan 27, 2023 · 11 comments
Assignees
Labels
NeedsFix The path to resolution is known, but the work has not been done. OS-Windows
Milestone

Comments

@qmuntal
Copy link
Member

qmuntal commented Jan 27, 2023

time/zoneinfo_abbrs_windows.go has not been updated since go1.14 (in CL 201378).

A few things changed since then, we should generate it again before releasing go 1.21.
We could also do it for go 1.20, but I suppose it is too late.

@alexbrainman @golang/windows

@qmuntal qmuntal added this to the Go1.21 milestone Jan 27, 2023
@qmuntal qmuntal self-assigned this Jan 27, 2023
@bcmills bcmills added the NeedsFix The path to resolution is known, but the work has not been done. label Jan 27, 2023
@bcmills
Copy link
Contributor

bcmills commented Jan 27, 2023

We could also do it for go 1.20, but I suppose it is too late.

If it is important, you can always request a backport. (A backport to add entries to a data table seems pretty low-risk. 🤷‍♂️)

@gopherbot
Copy link
Contributor

Change https://go.dev/cl/463838 mentions this issue: time: update windows zoneinfo_abbrs

@qmuntal
Copy link
Member Author

qmuntal commented Jan 27, 2023

We could also do it for go 1.20, but I suppose it is too late.

If it is important, you can always request a backport. (A backport to add entries to a data table seems pretty low-risk. 🤷‍♂️)

I haven't had any issue with time zones myself, but probably someone in the wild had. Worth backporting if it's doable. How to file the request?

@ianlancetaylor
Copy link
Member

@gopherbot Please open backport issues

The zoneinfo_abbrs data on Windows has not been updated for several years. We should update and backport if appropriate.

@gopherbot
Copy link
Contributor

Backport issue(s) opened: #58117 (for 1.18), #58118 (for 1.19).

Remember to create the cherry-pick CL(s) as soon as the patch is submitted to master, according to https://go.dev/wiki/MinorReleases.

@alexbrainman
Copy link
Member

@qmuntal thank you for opening this issue.

SGTM to update time/zoneinfo_abbrs_windows.go file.

Alex

@heschi
Copy link
Contributor

heschi commented Jan 27, 2023

cc @golang/release

I think it's too late for the first 1.20 release. I don't know exactly what this does, but it certainly doesn't seem to be just adding things, so I'd be leery of putting it in at the last possible moment. If we haven't done this in years, I presume we can wait a little longer.

Can someone explain a little more why this is important enough to backport? What is the concrete effect on users?

@qmuntal
Copy link
Member Author

qmuntal commented Jan 28, 2023

Can someone explain a little more why this is important enough to backport? What is the concrete effect on users?

The abbrs map inside zoneinfo_abbrs.go is used when formatting the abbreviated local time zone retrieved from the operating system. The problem it solves is that you can't get from Windows the system time zones as a standard IANA Time Zone name, it gives instead the time zone using it's particular naming convention. The map inside zoneinfo_abbrs.go relates the Windows time zone name with an IANA name or a particular offset.

If that map is not up to date, the user could see its time zone with an outdated offset or wrong name when using MST in the time format layout.

For example, with the following code snippet executed on August, someone in the Fiji Standard Time time zone will see the following output Mon Aug 28 19:23:36 +13 2023, but that time zone dropped DST last year, so the correct result would be Mon Aug 28 19:23:36 +12 2023.

package main

import "time"

func main() {
  println(time.Now().Format(time.UnixDate)) // layout: "Mon Jan _2 15:04:05 MST 2006"
}

I agree that it is too late for putting this on go1.20, considering that it is released in two days. On the other hand, I think it would be a good backport candidate for go1.19.6 and go1.20.1.

gopherbot pushed a commit that referenced this issue Jan 29, 2023
zoneinfo_abbrs hasn't been updated since go 1.14, it's time to
regenerate it.

Updates #58113

Change-Id: Ic156ae607c46f1f5a9408b1fc0b56de6c14a4ed4
Reviewed-on: https://go-review.googlesource.com/c/go/+/463838
Reviewed-by: Alex Brainman <alex.brainman@gmail.com>
Run-TryBot: Quim Muntal <quimmuntal@gmail.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Bryan Mills <bcmills@google.com>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
johanbrandhorst pushed a commit to Pryz/go that referenced this issue Feb 12, 2023
zoneinfo_abbrs hasn't been updated since go 1.14, it's time to
regenerate it.

Updates golang#58113

Change-Id: Ic156ae607c46f1f5a9408b1fc0b56de6c14a4ed4
Reviewed-on: https://go-review.googlesource.com/c/go/+/463838
Reviewed-by: Alex Brainman <alex.brainman@gmail.com>
Run-TryBot: Quim Muntal <quimmuntal@gmail.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Bryan Mills <bcmills@google.com>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
@gopherbot
Copy link
Contributor

Change https://go.dev/cl/483716 mentions this issue: time: update windows zoneinfo_abbrs

gopherbot pushed a commit that referenced this issue Apr 11, 2023
While running "go generate" I noticed that there has been a change.

For #58113

Change-Id: Icca349d0a100dd4b11d34e4bbcfd1aef57346db7
Reviewed-on: https://go-review.googlesource.com/c/go/+/483716
Run-TryBot: Ian Lance Taylor <iant@google.com>
Auto-Submit: Ian Lance Taylor <iant@google.com>
Reviewed-by: Quim Muntal <quimmuntal@gmail.com>
Reviewed-by: Ian Lance Taylor <iant@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Bryan Mills <bcmills@google.com>
@gopherbot
Copy link
Contributor

Change https://go.dev/cl/493477 mentions this issue: time: update windows zoneinfo_abbrs

gopherbot pushed a commit that referenced this issue May 12, 2023
The primary branch of the github.com/unicode-org/cldr repository
has changed to main instead of master. This changes the branch used
to download the Windows zone file.

Ran:
go generate time

For #58113

Change-Id: Idb3dcaf44fc52d4b6abfed5a3ca6cd6f745dc3f8
Reviewed-on: https://go-review.googlesource.com/c/go/+/493477
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
Reviewed-by: Quim Muntal <quimmuntal@gmail.com>
Auto-Submit: Carlos Amedee <carlos@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
Run-TryBot: Carlos Amedee <carlos@golang.org>
@dmitshur dmitshur modified the milestones: Go1.21, Go1.22 Aug 8, 2023
@gopherbot gopherbot modified the milestones: Go1.22, Go1.23 Feb 6, 2024
@gopherbot gopherbot modified the milestones: Go1.23, Go1.24 Aug 13, 2024
@gopherbot
Copy link
Contributor

Change https://go.dev/cl/626756 mentions this issue: time: regenerate zoneinfo_abbrs_windows.go

gopherbot pushed a commit that referenced this issue Nov 12, 2024
For #58113

Change-Id: I5833a898991d8ac1f564863c1c63eb3e2e86f7c7
Reviewed-on: https://go-review.googlesource.com/c/go/+/626756
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Commit-Queue: Ian Lance Taylor <iant@google.com>
Commit-Queue: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Robert Findley <rfindley@google.com>
Reviewed-by: Ian Lance Taylor <iant@google.com>
Auto-Submit: Ian Lance Taylor <iant@google.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
NeedsFix The path to resolution is known, but the work has not been done. OS-Windows
Projects
None yet
Development

No branches or pull requests

7 participants