Skip to content

Enhance TimeZoneHelper with offset and validation#24607

Merged
EngincanV merged 8 commits intorel-10.0from
TimeZoneHelper
Jan 12, 2026
Merged

Enhance TimeZoneHelper with offset and validation#24607
EngincanV merged 8 commits intorel-10.0from
TimeZoneHelper

Conversation

@maliming
Copy link
Member

Copilot AI review requested due to automatic review settings January 12, 2026 02:01
@maliming maliming added this to the 10.0-patch-final milestone Jan 12, 2026
@maliming maliming requested a review from EngincanV January 12, 2026 02:01
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR addresses a TimeZoneNotFoundException issue on Linux by adding validation and filtering to the TimeZoneHelper.GetTimezones method. The enhancement introduces a new TryCreateNameValueWithOffset method that safely handles invalid timezone identifiers and filters them out instead of throwing exceptions.

Changes:

  • Added TryCreateNameValueWithOffset method to safely create timezone NameValue objects with offset formatting
  • Refactored GetTimezones to filter out invalid timezone IDs using the new method
  • Upgraded TimeZoneConverter package from 7.0.0 to 7.2.0
  • Added comprehensive unit tests for the new functionality

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 6 comments.

File Description
framework/src/Volo.Abp.Timing/Volo/Abp/Timing/TimeZoneHelper.cs Refactored GetTimezones to filter invalid timezones, added TryCreateNameValueWithOffset method, and enhanced XML documentation
framework/test/Volo.Abp.Timing.Tests/Volo/Abp/Timing/TimeZoneHelper_Tests.cs Added new test file with tests for filtering invalid timezones and null return behavior
Directory.Packages.props Updated TimeZoneConverter package version from 7.0.0 to 7.2.0

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

maliming and others added 3 commits January 12, 2026 10:26
@EngincanV EngincanV merged commit bb5edb9 into rel-10.0 Jan 12, 2026
3 checks passed
@EngincanV EngincanV deleted the TimeZoneHelper branch January 12, 2026 11:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants