Skip to content

Conversation

@jonded94
Copy link
Contributor

@jonded94 jonded94 commented Dec 3, 2025

Which issue does this PR close? / Rationale for this change

Solves an issue discovered during #8790, namely that ArrowArrayStreamReader does not correctly expose schema-level metadata and does not check whether the StructArray constructed from the FFI stream actually in general corresponds to the expected schema.

What changes are included in this PR?

  • Change how RecordBatch is construted inside ArrowArrayStreamReader such that it holds metadata and schema validity checks are done.
  • Augment FFI tests with schema- and column-level metadata.

Are these changes tested?

Yes, both _test_round_trip_export and _test_round_trip_import now test for metadata on schema- and column-level.

Are there any user-facing changes?

Yes, ArrowArrayStreamReader now is able to export RecordBatch with schema-level metadata, and the interface has increased security since it actually checks for schema validity.

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

Labels

arrow Changes to the arrow crate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants