v4xsh commented on issue #49058: URL: https://github.com/apache/arrow/issues/49058#issuecomment-3847443198
I’d like to work on this issue. From the Arrow spec / `Schema.fbs`, custom metadata keys and values are defined as strings, which implies valid UTF-8. Allowing arbitrary byte sequences in Python can therefore produce schemas that violate the spec and break cross-language interoperability (e.g. Rust, which enforces UTF-8 via `String`). I think it would make sense to validate that metadata keys and values are valid UTF-8 at schema construction time (or at least before serialization), and raise a clear error when invalid bytes are provided. I’m happy to implement this and add tests covering valid UTF-8, invalid byte sequences, and round-trip behavior. If this approach sounds reasonable, I’d be happy to take ownership of the issue. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
