Details
-
Bug
-
Status: Resolved
-
Minor
-
Resolution: Fixed
-
None
Description
Minimal reproducible example:
main.rs: https://gist.github.com/adensur/e9787daa19522caefe1473c7fcd8464f
Cargo.toml: https://gist.github.com/adensur/b9ebf7cd0714ed15938762375ae5e96e
The result is different when building with "snappy" codec and without. Depending on the input, the result can be just wrong, or it can fail with an error similar to this:
`ConvertI64ToUsize(TryFromIntError(()), -1976)'`
From the code, it looks like the reader tries to parse known codecs from writer schema, and just uses default codec if it fails https://github.com/apache/avro/blob/master/lang/rust/avro/src/reader.rs#L202
Attachments
Issue Links
- links to