Hey! Bug creator here! You should be able to create an account with the Apache jira and create ticket for your Pr with a description like the one you have here. ( I was able to create an account without getting special permissions AFAICR) Once you’ve done that, open the PR, and request review from me and Martin. Thank you for contributing this back!
- Jack On Mon, Oct 17, 2022 at 2:01 PM David Peklak <[email protected]> wrote: > Dear avro developers, > I would like to contribute to the avro project. I have identified a bug in > the Rust implementation of GenericSingleObjectReader::read_value > < > https://docs.rs/apache-avro/0.14.0/apache_avro/struct.GenericSingleObjectReader.html#method.read_value > >, > which is exposed when a call to reader.read reads less than 10 bytes. This > is a valid scenario, as according to the documentation of Read::read > <https://doc.rust-lang.org/std/io/trait.Read.html#tymethod.read>, "It is > not an error if the returned value n is smaller than the buffer size, even > when the reader is not at the end of the stream yet." This is also a > real-life scenario: in my use-case, I am chaining three implementations of > the Read trait to messages that can be deserialized (one for the two magic > bytes, one for the schema fingerprint, and one for the actual message > content). Each call to Read::read only returns the bytes of one chain link, > so the first call to Read::read only returns 2 bytes. > I have forked the repository, and wrote a test that exposes the bug (commit > > https://github.com/davidpeklak/avro/commit/128e2a52e8d22c39aa24ba574523883777a85c76 > ), > and a fix for the bug (commit > > https://github.com/davidpeklak/avro/commit/6f7bc050e0454733a9dbd6835f2cd4bd49f390e1 > ), > by calling Read::read_exact > <https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact> > instead of Read::read > <https://doc.rust-lang.org/std/io/trait.Read.html#tymethod.read>. > > I would need help to understand how to proceed from here please. I have > noticed that all pull-requests refer to tickets in Jira > < > https://issues.apache.org/jira/browse/AVRO-3639?jql=project%20%3D%20AVRO%20AND%20component%20%3D%20rust > >, > but I do not know how to get permission to create a Jira ticket. What > should be my next steps? > > Kind regards, > David Peklak >
