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

Fix bug in invalid_range_checker #968

Closed

Conversation

ChristopherLi05
Copy link
Contributor

@ChristopherLi05 ChristopherLi05 commented Oct 4, 2023

Motivation and Context

Addresses #967

Your Changes

Description:

  • In invalid_range_checker.py, I reversed the signs on lines 52 and 53 to fix the bug
  • In invalid_range_checker.py, I added and not isinstance(item, nodes.UnaryOp) because negative numbers wouldn't be caught
  • I created test_invalid_range_checker.py since there was no test written for it

Type of change (select all that apply):

  • Bug fix (non-breaking change which fixes an issue)
  • Test update (change that modifies or updates tests only)

Testing

Created test_invalid_range_checker.py and made sure all the checks would pass

Checklist

  • I have performed a self-review of my own code.
  • I have verified that the CI tests have passed.
  • I have reviewed the test coverage changes reported on Coveralls.
  • I have added tests for my changes.
  • I have updated the CHANGELOG.md file.

@david-yz-liu
Copy link
Contributor

@ChristopherLi05 thank you for making this, but I merged in #969 instead (to spread the opportunities for contribution around).

@ChristopherLi05 ChristopherLi05 deleted the invalid-range branch October 10, 2023 18:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants