Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AVRO-3263: Fix warning in Perl encoder when validating a long field #1422

Conversation

mhcuervo
Copy link
Contributor

  • Disable warnings in the limited scope of "long" validation that uses pack and unpack. It is unnecessary as warnings don't affect the validation outcome and in some scenarios this validation is expected to fail.
  • Add test cases to validate the fix

Make sure you have checked all steps below.

Jira

Tests

  • My PR adds the following unit tests:
  • Binary_Encodings.Complex_Types.Unions-record-with-long-field
  • Binary_Encodings.Complex_Types.Unions-record-with-long-field-nowarning

Commits

  • My commits all reference Jira issues in their subject lines. In addition, my commits follow the guidelines from "How to write a good git commit message":
    1. Subject is separated from body by a blank line
    2. Subject is limited to 50 characters (not including Jira issue reference)
    3. Subject does not end with a period
    4. Subject uses the imperative mood ("add", not "adding")
    5. Body wraps at 72 characters
    6. Body explains "what" and "why", not "how"

Documentation

  • In case of new functionality, my PR adds documentation that describes how to use it.
    • All the public functions and the classes in the PR contain Javadoc that explain what it does

@github-actions github-actions bot added the Perl label Dec 12, 2021
- Disable warnings in the limited scope of "long" validation that uses pack and unpack. It is unnecessary as warnings don't affect the validation outcome and in some scenarios this validation is expected to fail.
- Add test cases to validate the fix
@mhcuervo mhcuervo force-pushed the mhcuervo/AVRO-3263_perl_encoder_long_validation branch from 3ae5fc4 to 7e28c4b Compare December 12, 2021 11:59
@RyanSkraba RyanSkraba changed the title AVRO-3258: Fix warning in Perl encoder when validating a long field AVRO-3263: Fix warning in Perl encoder when validating a long field Dec 12, 2021
@RyanSkraba RyanSkraba self-requested a review December 13, 2021 10:15
- Check explicitly and return early if $data is undefined.
@RyanSkraba RyanSkraba merged commit 8a5fc3c into apache:master Dec 15, 2021
RyanSkraba pushed a commit that referenced this pull request Dec 15, 2021
…1422)

* AVRO-3258: Fix warning in Perl encoder when validating a long field

- Disable warnings in the limited scope of "long" validation that uses pack and unpack. It is unnecessary as warnings don't affect the validation outcome and in some scenarios this validation is expected to fail.
- Add test cases to validate the fix

* AVRO-3258: Fix warning in Perl encoder when validating a long field

- Check explicitly and return early if $data is undefined.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
3 participants