Skip to content

[57_maintenance] fix: finish methods in PrimitiveDictionaryBuilder discard type params - #11805

Merged
alamb merged 1 commit into
apache:57_maintenancefrom
Jefffrey:backport_11327_57
Oct 22, 2026
Merged

alamb merged 1 commit into
apache:57_maintenancefrom
Jefffrey:backport_11327_57

Conversation

@Jefffrey

Copy link
Copy Markdown
Contributor

…ms (apache#11327)

# Which issue does this PR close?

- Relates to apache#3972

# Rationale for this change

`PrimitiveDictionaryBuilder::finish_cloned` and `finish_preserve_values`
built the dictionary with `V::DATA_TYPE`, which is the default
`DataType` for the dictionary's value type. This loses type parameters,
like the scale/precision of a decimal value.

A similar bug was fixed for `finish` in apache#3972, but `finish_cloned` and
`finish_preserve_values` was missed.

# What changes are included in this PR?

See above.

# Are these changes tested?

Yes; existing tests pass, test expanded to cover this behavior. Verified
that the updated test fails without the behavior change.

# Are there any user-facing changes?

No.

# AI usage

Bug found and fix developed with Claude Code (Opus 5.5); I have reviewed
and understand the resulting code.
@Jefffrey Jefffrey added the bug Squash those bugs label Oct 22, 2026
@github-actions github-actions Bot added the arrow-core Core crates related to representing arrow data label Oct 22, 2026
@Jefffrey
Jefffrey marked this pull request as ready for review October 22, 2026 12:23
@alamb
alamb merged commit 5b3960a into apache:57_maintenance Oct 22, 2026
26 checks passed
@alamb

alamb commented Oct 22, 2026

Copy link
Copy Markdown
Contributor

Per suggestion, I will merge all these PRs and we'll wait for the CI on the branch to run all the checks

@Jefffrey
Jefffrey deleted the backport_11327_57 branch October 22, 2026 21:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

arrow-core Core crates related to representing arrow data bug Squash those bugs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants