-
-
Notifications
You must be signed in to change notification settings - Fork 3.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
Move Lint/Eval to Security/Eval #3820
Conversation
Makes sense, but would probably require a |
I intentionally did not do some of the work, waiting to see if that idea gain consensus. |
I'm fine with the proposed change. I actually planned to do this myself a
while back. :-)
…On Sat, Dec 24, 2016 at 3:13 PM Timothée Peignier ***@***.***> wrote:
I intentionally did not do some of the work, waiting to see if that idea
gain consensus.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#3820 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAGVyjY_FFXFO3ExpYIwKALN4BEQ04TMks5rLRpcgaJpZM4LVNKe>
.
|
@@ -4,6 +4,7 @@ | |||
|
|||
### New features | |||
|
|||
* [#3820](https://github.com/bbatsov/rubocop/pull/3820): Rename `Lint/Eval` to `Security/Eval`. ([@cyberdelia][]) |
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.
This should actually be under "Changes".
You'll also have to rebase this due to the fact your other PR just got merged. |
Rebased and changed. |
This change improves obsolete warnings in three ways. 1. Show all obsoletes -------- Currently, RuboCop displays first obsolete warning only. ```yaml # two obsolete cops Style/SingleSpaceBeforeFirstArg: Enabled: false Style/SpaceBeforeModifierKeyword: Enabled: false ``` ``` Error: The `Style/SingleSpaceBeforeFirstArg` cop has been renamed to `Style/SpaceBeforeFirstArg. (obsolete configuration found in /tmp/tmp.9T2ers7SW8/.rubocop.yml, please update it) ``` This change makes to display all obsolete warnings. ``` Error: The `Style/SingleSpaceBeforeFirstArg` cop has been renamed to `Style/SpaceBeforeFirstArg.` (obsolete configuration found in /tmp/tmp.9T2ers7SW8/.rubocop.yml, please update it) The `Style/SpaceBeforeModifierKeyword` cop has been removed. Please use `Style/SpaceAroundKeyword` instead. (obsolete configuration found in /tmp/tmp.9T2ers7SW8/.rubocop.yml, please update it) ``` 2. Add obsolete cops --------- `Style/MethodCallParentheses` and `Lint/Eval` are renamed. - rubocop#3797 - rubocop#3820 So, I added the cops to `OBSOLATE_COPS`. 3. Add obsolete parameters In rubocop#3765, some cop's parameters are renamed. So, I added the parameters to `OBSOLATE_PARAMETERS`
This change improves obsolete warnings in three ways. 1. Show all obsoletes -------- Currently, RuboCop displays first obsolete warning only. ```yaml # two obsolete cops Style/SingleSpaceBeforeFirstArg: Enabled: false Style/SpaceBeforeModifierKeyword: Enabled: false ``` ``` Error: The `Style/SingleSpaceBeforeFirstArg` cop has been renamed to `Style/SpaceBeforeFirstArg. (obsolete configuration found in /tmp/tmp.9T2ers7SW8/.rubocop.yml, please update it) ``` This change makes to display all obsolete warnings. ``` Error: The `Style/SingleSpaceBeforeFirstArg` cop has been renamed to `Style/SpaceBeforeFirstArg.` (obsolete configuration found in /tmp/tmp.9T2ers7SW8/.rubocop.yml, please update it) The `Style/SpaceBeforeModifierKeyword` cop has been removed. Please use `Style/SpaceAroundKeyword` instead. (obsolete configuration found in /tmp/tmp.9T2ers7SW8/.rubocop.yml, please update it) ``` 2. Add obsolete cops --------- `Style/MethodCallParentheses` and `Lint/Eval` are renamed. - #3797 - #3820 So, I added the cops to `OBSOLATE_COPS`. 3. Add obsolete parameters In #3765, some cop's parameters are renamed. So, I added the parameters to `OBSOLATE_PARAMETERS`
This is a proposal to move the Eval cop to Security/Eval, this is in order to have all the security checks under the same umbrella.
I'm not sure about the transition, I'm open to suggestions.
Before submitting the PR make sure the following are checked:
[Fix #issue-number]
(if the related issue exists).master
(if not - rebase it).and description in grammatically correct, complete sentences.
rake generate_cops_documentation
(required only when you've added a new cop or changed the configuration/documentation of an existing cop).