PookieBuns opened a new pull request, #337: URL: https://github.com/apache/avro-rs/pull/337
There is a bug currently in serialization in which if you are serializing an Option<Enum> for a Union Schema (with null), it will automatically try to use the first not-null schema if you choose a not-null enum. This fix allows the serializer to correctly resolve the proper schema to serialize the Enum variant with. ## Notes - This changes the error message for the Union Long test. Imo its now better because it properly shows the expected type vs the attempted type instead of showing the Union as the error. Because of this, I had to change the test assert message to allow it to pass - Serializing unions containing records are a bit funky right now, since structs in rust should be in Capital case but if the name is not in Capital case, you have to rename the struct itself, instead of calling ex. `camelCase` on the Enum. However, this is pre-existing behavior so its not a regression from pre-existing behavior Please let me know if there are any questions or things to address! -- 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]
