Skip to content

Fix Variant time microsecond JSON formatting#10173

Merged
Jefffrey merged 1 commit into
apache:mainfrom
fallintoplace:fix-variant-time-micros-format
Jun 22, 2026
Merged

Fix Variant time microsecond JSON formatting#10173
Jefffrey merged 1 commit into
apache:mainfrom
fallintoplace:fix-variant-time-micros-format

Conversation

@fallintoplace

Copy link
Copy Markdown
Contributor

What changed

This updates Variant Time JSON formatting to trim only trailing zeros from fractional microseconds.

Why

The previous formatter used trim_matches('0'), which removed leading zeros as well as trailing zeros. That could change values like .010010 into .1001 during JSON serialization.

Validation

  • cargo fmt --package parquet-variant-json
  • cargo test -p parquet-variant-json test_time_to_json

@github-actions github-actions Bot added the parquet-variant parquet-variant* crates label Jun 21, 2026
@Jefffrey Jefffrey merged commit 7c6209f into apache:main Jun 22, 2026
17 checks passed
@Jefffrey

Copy link
Copy Markdown
Contributor

thanks @fallintoplace

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

parquet-variant parquet-variant* crates

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants