Skip to content

[release/8.0-staging] Correct time zone name creation when generated lazily. #95364

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

Merged
merged 2 commits into from
Nov 30, 2023

Conversation

github-actions[bot]
Copy link
Contributor

@github-actions github-actions bot commented Nov 28, 2023

Fixes #95213

Backport of #95304 to release/8.0-staging

/cc @tarekgh

Customer Impact

Applications running on Linux/Mac that create TimeZoneInfo objects using Windows zone IDs (e.g., Pacific Standard Time) and subsequently request the time zone's Standard, Daylight, or Display name may receive empty strings instead of the expected descriptive time zone names. This issue is a regression in .NET 8.0 introduced by the optimization change outlined in #88368 that aimed to enhance the creation time of the time zone object by deferring the initialization of zone names until they are specifically requested, as opposed to proactively generating the names during the initial creation. Applications and users rely on accurate time zone names, particularly in UI scenarios where the names are displayed.

Testing

I have included additional test cases to cover the specific scenario of concern, ensuring that the code passes all regression tests. This change has been manually tested on Linux and Windows too.

Risk

The changes made are limited and scoped to the initialization of time zone names, without altering any other logic.

IMPORTANT: If this backport is for a servicing release, please verify that:

  • The PR target branch is release/X.0-staging, not release/X.0.

  • If the change touches code that ships in a NuGet package, you have added the necessary package authoring and gotten it explicitly reviewed.

@ghost ghost added the area-System.DateTime label Nov 28, 2023
@ghost
Copy link

ghost commented Nov 28, 2023

Tagging subscribers to this area: @dotnet/area-system-datetime
See info in area-owners.md if you want to be subscribed.

Issue Details

Backport of #95304 to release/8.0-staging

/cc @tarekgh

Customer Impact

Testing

Risk

IMPORTANT: If this backport is for a servicing release, please verify that:

  • The PR target branch is release/X.0-staging, not release/X.0.

  • If the change touches code that ships in a NuGet package, you have added the necessary package authoring and gotten it explicitly reviewed.

Author: github-actions[bot]
Assignees: -
Labels:

area-System.DateTime

Milestone: -

@tarekgh tarekgh added this to the 8.0.x milestone Nov 28, 2023
@tarekgh tarekgh requested a review from mdh1418 November 28, 2023 22:34
@tarekgh tarekgh self-assigned this Nov 28, 2023
@tarekgh
Copy link
Member

tarekgh commented Nov 28, 2023

@artl93 @ericstj this is a change I want to port to 8.0 servicing. Could you please have a look and let me know if you have any questions before I mark the issue with servicing consider label? Thanks!

@artl93 artl93 added the Servicing-consider Issue for next servicing release review label Nov 28, 2023
@tarekgh tarekgh added Servicing-approved Approved for servicing release and removed Servicing-consider Issue for next servicing release review labels Nov 30, 2023
@tarekgh
Copy link
Member

tarekgh commented Nov 30, 2023

Approved offline.

@tarekgh tarekgh merged commit 25fbafa into release/8.0-staging Nov 30, 2023
@tarekgh tarekgh deleted the backport/pr-95304-to-release/8.0-staging branch November 30, 2023 17:31
@akoeplinger akoeplinger modified the milestones: 8.0.x, 8.0.2 Dec 18, 2023
@github-actions github-actions bot locked and limited conversation to collaborators Jan 18, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-System.DateTime Servicing-approved Approved for servicing release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants