feat: add 13 commonly-used timezone abbreviations#130
Draft
Koan-Bot wants to merge 1 commit intocpan-authors:mainfrom
Draft
feat: add 13 commonly-used timezone abbreviations#130Koan-Bot wants to merge 1 commit intocpan-authors:mainfrom
Koan-Bot wants to merge 1 commit intocpan-authors:mainfrom
Conversation
Add timezone abbreviations that are widely used in real-world date strings but were missing from Time::Zone, causing str2time() to return undef: Standard zones: - ACST (Australian Central Standard, UTC+9:30) - AWST (Australian Western Standard, UTC+8, alias for WST) - SAST (South African Standard, UTC+2) - EAT (East Africa, UTC+3) - TRT (Turkey, UTC+3) - IRST (Iran Standard, UTC+3:30) - AFT (Afghanistan, UTC+4:30) - PKT (Pakistan Standard, UTC+5) - NPT (Nepal, UTC+5:45) Daylight zones: - ACDT (Australian Central Daylight, UTC+10:30) - AWDT (Australian Western Daylight, UTC+9) - WEST (Western European Summer, UTC+1) - IRDT (Iran Daylight, UTC+4:30) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds 13 timezone abbreviations to Time::Zone that are commonly used in real-world date strings.
Why
Dates using these timezone abbreviations (e.g., "Thu Apr 24 10:30:00 ACST 2025") caused
str2time()to returnundefbecause the abbreviations weren't in Time::Zone's lookup tables. These timezones cover Australia (Central/Western), Africa (South African, East Africa), Middle East (Turkey, Iran, Afghanistan), and South Asia (Pakistan, Nepal) — regions with significant populations whose date formats were unsupported.How
Added entries to
@Zone(9 standard) and@dstZone(4 daylight) inTime::Zone.pm, maintaining offset order. Each abbreviation maps to its IANA-standard UTC offset. Also uncommented/replaced the oldCAST/CADTcommented entries with their modernACST/ACDTforms.Testing
t/zone.tverify each abbreviation resolves to the correct offsetstr2time()now successfully parses dates with all 13 new timezone abbreviations🤖 Generated with Claude Code
Quality Report
Changes: 2 files changed, 36 insertions(+), 3 deletions(-)
Code scan: clean
Tests: skipped
Branch hygiene: clean
Generated by Kōan post-mission quality pipeline