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
Change terminology to Allowlist
and Denylist
#7469
Change terminology to Allowlist
and Denylist
#7469
Conversation
4774503
to
adfeabe
Compare
43e554c
to
c55761f
Compare
I agree with the overall premise and the timing of the change, but I think we can do better with the naming - e.g. instead of naming something |
@rubocop-hq/rubocop-core Please add your feedback here as well, if you have some. My general point is that we should try to do something more than just auto-replacing the existing problematic names. From my perspective the use of generic names like |
I have nothing against replacing |
c55761f
to
b1c7a41
Compare
I brushed up this PR. I would be happy to get suggestions if you have other good names :-) |
b1c7a41
to
5b60700
Compare
5b60700
to
3c3833b
Compare
### Summary Follow up rubocop#6464, rubocop#6466, and rubocop#6467. This PR changes a terminology from `Whitelist` and `Blacklist` to `Allowlist` and `Denylist`. This change is an obvious breaking change to some cop options. So I'd like to introduce it before RuboCop 1.0 if this change is acceptable. ### Other Information This change has also been made in Rails repository and other repos. rails/rails#33681
3c3833b
to
4008aa7
Compare
Thanks! |
I think the few places we use the term "whitelist", we really don't need to. Changing to use "allowed" etc. instead. RuboCop did similar changes in rubocop/rubocop#7469.
@@ -3840,7 +3842,7 @@ Style/TrivialAccessors: | |||
# Commonly used in DSLs | |||
AllowDSLWriters: false | |||
IgnoreClassMethods: false | |||
Whitelist: | |||
AllowedMethod: |
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.
Seems that this is missing the trailing s
.
Should be AllowedMethods
.
PR incoming.
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.
Resolves warning: > Warning: Style/TrivialAccessors does not support AllowedMethod parameter. > > Supported parameters are: > > - Enabled > - ExactNameMatch > - AllowPredicates > - AllowDSLWriters > - IgnoreClassMethods > - AllowedMethods (Issue where bug introduced to Rubocop)[rubocop/rubocop#7469] (Issue describing resolution)[rubocop/rubocop#7530]
I think the few places we use the term "whitelist", we really don't need to. Changing to use "allowed" etc. instead. RuboCop did similar changes in rubocop/rubocop#7469.
I think the few places we use the term "whitelist", we really don't need to. Changing to use "allowed" etc. instead. RuboCop did similar changes in rubocop/rubocop#7469.
Summary
Follow up #6464, #6466, and #6467.
This PR changes a terminology from
Whitelist
andBlacklist
toAllowlist
andDenylist
.This change is an obvious breaking change to some cop options. So I'd like to introduce it before RuboCop 1.0 if this change is acceptable.
Other Information
This change has also been made in Rails repository and other repos.
rails/rails#33681
Before submitting the PR make sure the following are checked:
[Fix #issue-number]
(if the related issue exists).master
(if not - rebase it).bundle exec rake default
. It executes all tests and RuboCop for itself, and generates the documentation.