Bump rubocop from 1.50.2 to 1.51.0
Bumps rubocop from 1.50.2 to 1.51.0.
Release notes
Sourced from rubocop's releases.
RuboCop 1.51 (The RubyKaigi 2023 Edition)
New features
- #11819: Add autocorrection for
Lint/AmbiguousBlockAssociation
. (@r7kamura
)- #11597: Add autocorrection for
Lint/UselessAssignment
. (@r7kamura
)- #11848: Add autocorrection for
Lint/Void
. (@r7kamura
)- #11851: Add autocorrection for
Naming/MemoizedInstanceVariableName
. (@r7kamura
)- #11856: Add autocorrection for
Style/CombinableLoops
. (@r7kamura
)- #11824: Add autocorrection for
Lint/TopLevelReturnWithArgument
. (@r7kamura
)- #11869: Add new
Style/ExactRegexpMatch
cop. (@koic
)- #11814: Make
Style/CollectionCompact
aware ofdelete_if
. (@koic
)- #11866: Make
Style/Semicolon
aware of redundant semicolons in string interpolation braces. (@koic
)Bug fixes
- #11812: Fix a false negative for
Style/Attr
when usingattr
and method definitions. (@koic
)- #11861: Fix a false positive for
Layout/SpaceAfterSemicolon
when no space between a semicolon and a closing brace of string interpolation. (@koic
)- #11830: Fix a false positive for
Lint/IncompatibleIoSelectWithFiberScheduler
. (@koic
)- #11846: Fix a false positive for
Lint/RedundantStringCoercion
when usingto_s(argument)
inputs
argument. (@koic
)- #11865: Fix an error for
Naming/ConstantName
when assigning a constant from an empty branch ofelse
. (@koic
)- #11844: Fix a false positive for
Style/RedundantLineContinuation
when using line concatenation for assigning a return value and without argument parentheses. (@koic
)- #11808: Fix a false positive for
Style/RegexpLiteral
when using a regexp starts with equal as a method argument. (@koic
)- #11822: Fix an error for
Layout/SpaceInsideBlockBraces
when a method call with a multiline block is used as an argument. (@koic
)- #11849: Fix an error for
Style/ConditionalAssignment
whenEnforcedStyle: assign_inside_condition
and using emptycase
condition. (@koic
)- #11967: Fix error for
Style/IfInsideElse
when a deep nested multilineif...then...elsif...else...end
. (@koic
)- #11842: Fix an error for
Style/IfUnlessModifier
when using multipleif
modifier in the long one line. (@koic
)- #11835: Fix an error for
Style/RequireOrder
when multiplerequire
are not sorted. (@koic
)- #11809: Fix an incorrect autocorrect for
Naming/RescuedExceptionsVariableName
when exception variable is referenced afterrescue
statement. (@koic
)- #11852: Fix an incorrect autocorrect for
Style/EvalWithLocation
when usingeval
without line number and with parenthesized method call. (@koic
)- #11862: Fix an incorrect autocorrect for
Style/GuardClause
when usingraise
inelse
branch in a one-liner withthen
. (@koic
)- #11868: Fix a false positive for
Style/HashExcept
when method's receiver/argument is not the same as block key argument. (@fatkodima
)- #11858: Fix false positives when using source comments in blocks. (
@reitermarkus
)- #11510: Fix
Lint/UselessAssignment
false positive when using numbered block parameters. (@sambostock
)- #11872: Fix
Gemspec/DevelopmentDependencies
not trigger when add_development_dependency has more then one arguments. (@Bhacaz
)- #11820: Fix
Lint/EmptyConditionalBody
false-positives for commented emptyelsif
body. (@r7kamura
)Changes
- #11859: Add rubocop-factory_bot to suggested extensions. (
@ydah
)- #10791: (Breaking) Drop runtime support for Ruby 2.6 and JRuby 9.3 (CRuby 2.6 compatible). (
@koic
)- #11826: Exclude
**/*.jb
fromLint/TopLevelReturnWithArgument
. (@r7kamura
)- #11871: Mark
Style/DataInheritance
as unsafe autocorrect,Style/OpenStructUse
as unsafe, andSecurity/CompoundHash
as unsafe. (@koic
)
Changelog
Sourced from rubocop's changelog.
1.51.0 (2023-05-13)
New features
- #11819: Add autocorrection for
Lint/AmbiguousBlockAssociation
. ([@r7kamura
][])- #11597: Add autocorrection for
Lint/UselessAssignment
. ([@r7kamura
][])- #11848: Add autocorrection for
Lint/Void
. ([@r7kamura
][])- #11851: Add autocorrection for
Naming/MemoizedInstanceVariableName
. ([@r7kamura
][])- #11856: Add autocorrection for
Style/CombinableLoops
. ([@r7kamura
][])- #11824: Add autocorrection for
Lint/TopLevelReturnWithArgument
. ([@r7kamura
][])- #11869: Add new
Style/ExactRegexpMatch
cop. ([@koic
][])- #11814: Make
Style/CollectionCompact
aware ofdelete_if
. ([@koic
][])- #11866: Make
Style/Semicolon
aware of redundant semicolons in string interpolation braces. ([@koic
][])Bug fixes
- #11812: Fix a false negative for
Style/Attr
when usingattr
and method definitions. ([@koic
][])- #11861: Fix a false positive for
Layout/SpaceAfterSemicolon
when no space between a semicolon and a closing brace of string interpolation. ([@koic
][])- #11830: Fix a false positive for
Lint/IncompatibleIoSelectWithFiberScheduler
. ([@koic
][])- #11846: Fix a false positive for
Lint/RedundantStringCoercion
when usingto_s(argument)
inputs
argument. ([@koic
][])- #11865: Fix an error for
Naming/ConstantName
when assigning a constant from an empty branch ofelse
. ([@koic
][])- #11844: Fix a false positive for
Style/RedundantLineContinuation
when using line concatenation for assigning a return value and without argument parentheses. ([@koic
][])- #11808: Fix a false positive for
Style/RegexpLiteral
when using a regexp starts with equal as a method argument. ([@koic
][])- #11822: Fix an error for
Layout/SpaceInsideBlockBraces
when a method call with a multiline block is used as an argument. ([@koic
][])- #11849: Fix an error for
Style/ConditionalAssignment
whenEnforcedStyle: assign_inside_condition
and using emptycase
condition. ([@koic
][])- #11967: Fix error for
Style/IfInsideElse
when a deep nested multilineif...then...elsif...else...end
. ([@koic
][])- #11842: Fix an error for
Style/IfUnlessModifier
when using multipleif
modifier in the long one line. ([@koic
][])- #11835: Fix an error for
Style/RequireOrder
when multiplerequire
are not sorted. ([@koic
][])- #11809: Fix an incorrect autocorrect for
Naming/RescuedExceptionsVariableName
when exception variable is referenced afterrescue
statement. ([@koic
][])- #11852: Fix an incorrect autocorrect for
Style/EvalWithLocation
when usingeval
without line number and with parenthesized method call. ([@koic
][])- #11862: Fix an incorrect autocorrect for
Style/GuardClause
when usingraise
inelse
branch in a one-liner withthen
. ([@koic
][])- #11868: Fix a false positive for
Style/HashExcept
when method's receiver/argument is not the same as block key argument. ([@fatkodima
][])- #11858: Fix false positives when using source comments in blocks. ([
@reitermarkus
][])- #11510: Fix
Lint/UselessAssignment
false positive when using numbered block parameters. ([@sambostock
][])- #11872: Fix
Gemspec/DevelopmentDependencies
not trigger when add_development_dependency has more then one arguments. ([@Bhacaz
][])- #11820: Fix
Lint/EmptyConditionalBody
false-positives for commented emptyelsif
body. ([@r7kamura
][])Changes
- #11859: Add rubocop-factory_bot to suggested extensions. ([
@ydah
][])- #10791: (Breaking) Drop runtime support for Ruby 2.6 and JRuby 9.3 (CRuby 2.6 compatible). ([
@koic
][])- #11826: Exclude
**/*.jb
fromLint/TopLevelReturnWithArgument
. ([@r7kamura
][])- #11871: Mark
Style/DataInheritance
as unsafe autocorrect,Style/OpenStructUse
as unsafe, andSecurity/CompoundHash
as unsafe. ([@koic
][])
Commits
-
a38991d
Cut 1.51 to celebrate RubyKaigi 2023 -
0d04592
Update Changelog -
0970cc1
Fix a false positive forLint/IncompatibleIoSelectWithFiberScheduler
-
922501f
Add newStyle/ExactRegexpMatch
cop -
7cda5ae
Mark some cops as unsafe -
824441b
Merge pull request #11872 from Bhacaz/fix_development_dependencies_cop_with_a... -
e768851
Fix Gemspec/DevelopmentDependencies not trigger when add_development_dependen... -
7ef8629
Merge pull request #11870 from fatkodima/fix-hash_except-incorrect-arguments -
1fdb7d6
Fix a false positive for when method's receiver/argument is not the same as ... -
de330b3
Fix an error forStyle/IfInsideElse
- Additional commits viewable in compare view
Dependabot commands
You can trigger Dependabot actions by commenting on this MR
-
@dependabot-bot rebase
will rebase this MR -
@dependabot-bot recreate
will recreate this MR rewriting all the manual changes and resolving conflicts