-
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
FBT001: exclude boolean operators #14203
FBT001: exclude boolean operators #14203
Conversation
Should we be ignoring all dunders? |
We have an |
a2411d6
to
f424f00
Compare
|
@charliermarsh I updated using However, I am not sure if this is the best approach. For one, there is no official list of dunder methods from python's side, and what is considered a known dunder method can change from one version to the next. Maybe a simpler approach would be to just exclude dunder methods in general? This would be easier to document/teach as well. |
The |
I think "all dunder methods except init and new" should be easy to maintain and explain. |
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.
Thanks -- this looks reasonable to me.
Fixes #14202
Summary
Exclude rule FBT001 for boolean operators.
Test Plan
Updated existing
FBT.py
test.