-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Improve invalid-slice-index
and add invalid-slice-step
#7762
Conversation
Pull Request Test Coverage Report for Build 3457177074
💛 - Coveralls |
This comment has been minimized.
This comment has been minimized.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, the error level check are always a pleasure to review :) (Line not covered is due to inference it's hard to test in the current state of the testutil)
It's actually a bit more complicated. I wouldn't want to remove the uncovered line in |
🤖 According to the primer, this change has no effect on the checked open source code. 🤖🎉 This comment was generated for commit f0638f8 |
Description
Followup to pylint-dev/astroid#1844 (comment) by @nelfin.
This PR
invalid-slice-index
check to detect invalid indices on string and byte sequences.invalid-slice-step
when0
is passed as step value for common builtin sequences.