Skip to content

[Variant] Add VariantBuilder values check#10016

Open
sdf-jkl wants to merge 7 commits into
apache:mainfrom
sdf-jkl:variantbuilder-count-check
Open

[Variant] Add VariantBuilder values check#10016
sdf-jkl wants to merge 7 commits into
apache:mainfrom
sdf-jkl:variantbuilder-count-check

Conversation

@sdf-jkl
Copy link
Copy Markdown
Contributor

@sdf-jkl sdf-jkl commented May 25, 2026

Which issue does this PR close?

Rationale for this change

  • (Single) VariantBuilder accepts 0/1+ values on finish.

What changes are included in this PR?

  • Add only 1 value validation for VariantBuilder
  • Move try_new_list/try_new_object to VariantBuilder
  • Replaced VariantBuilder with WritableMetadataBuilder in tests that only build metadata.

Are these changes tested?

  • Yes, existing unit tests pass.
  • Ran benchmarks locally and added some [#inline] that sort of improved performance (I'm new at this)

Are there any user-facing changes?

@github-actions github-actions Bot added the parquet-variant parquet-variant* crates label May 25, 2026
@sdf-jkl sdf-jkl marked this pull request as ready for review May 28, 2026 22:09
@sdf-jkl
Copy link
Copy Markdown
Contributor Author

sdf-jkl commented May 28, 2026

@alamb @scovich please take a look

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.

[Variant] VariantBuilder (wrongly?) accepts 0+ variant values

1 participant