Skip to content

[arrow] Normalize timezone strings for arrow-rust compatibility#7705

Merged
JingsongLi merged 3 commits into
apache:masterfrom
0dunay0:fix/arrow-normalize-timezone-string
Apr 29, 2026
Merged

[arrow] Normalize timezone strings for arrow-rust compatibility#7705
JingsongLi merged 3 commits into
apache:masterfrom
0dunay0:fix/arrow-normalize-timezone-string

Conversation

@0dunay0
Copy link
Copy Markdown
Contributor

@0dunay0 0dunay0 commented Apr 27, 2026

Summary

Fixes #7704.

ZoneId.systemDefault().toString() can produce GMT-prefix timezone strings like GMT-10:00 when the JVM timezone is set to a GMT-prefix offset. Arrow-rust doesn't recognize the GMT prefix and rejects these strings.

normalized() converts them to formats arrow-rust accepts:

  • GMT-10:00 becomes -10:00
  • GMT+05:30 becomes +05:30
  • UTC / GMT becomes Z
  • IANA names like America/New_York pass through unchanged

This was discovered while investigating #6648. The CI randomizes -Duser.timezone and hit GMT+5:00, which triggered a crash in the Lance native writer.

0dunay0 added 3 commits April 26, 2026 17:18
…he#7704)

ZoneId.systemDefault().toString() can produce GMT-prefix timezone
strings like GMT-10:00 which arrow-rust cannot parse. Using
normalized() converts these to standard formats that arrow-rust
accepts: GMT-prefix offsets become UTC offsets (-10:00), GMT/UTC
become Z, and IANA names pass through unchanged.
@0dunay0
Copy link
Copy Markdown
Contributor Author

0dunay0 commented Apr 27, 2026

@plusplusjiajia @JingsongLi Please have a look

Copy link
Copy Markdown
Contributor

@JingsongLi JingsongLi left a comment

Choose a reason for hiding this comment

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

+1

@JingsongLi JingsongLi merged commit 904a5f7 into apache:master Apr 29, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] ArrowFieldTypeConversion produces GMT-prefix timezone strings that arrow-rust cannot parse

2 participants