chore(deps): update dependency rubocop to v1.63.4
This MR contains the following updates:
Package | Update | Change |
---|---|---|
rubocop (source, changelog) | minor |
1.42.0 -> 1.63.4
|
Release Notes
rubocop/rubocop (rubocop)
v1.63.4
Bug fixes
-
#12871: Fix an error for
rubocop -V
when.rubocop.yml
contains ERB. ([@earlopain][]) -
#12862: Fix a false positive for
Style/RedundantLineContinuation
when line continuations involvereturn
with a return value. ([@koic][]) -
#12664: Fix handling of
textDocument/diagnostic
. ([@muxcmux][]) -
#12865: Fix Rails Cops, which weren't reporting any violations unless running with
bundle exec
. ([@amomchilov][])
v1.63.3
Bug fixes
-
#12857: Fix false negatives for
Lint/UnreachableCode
when using pattern matching. ([@koic][]) -
#12852: Fix an error for
Lint/EmptyFile
in formatters when using cache. ([@earlopain][]) -
#12848: Fix an error that occurs in
RuboCop::Lockfile
when the constant Bundler is uninitialized. ([@koic][])
Changes
v1.63.2
Bug fixes
-
#12843: Fix an error for
Lint/MixedCaseRange
when a character betweenZ
anda
is used in the regexp range. ([@koic][]) -
#12846: Fix an error for
RuboCop::Lockfile
when there is no Bundler environment. ([@koic][]) -
#12832: Fix an error for
Style/ArgumentsForwarding
when using block arg in nested method definitions. ([@koic][]) -
#12841: Fix false negatives for
Lint/UnreachableLoop
when using pattern matching. ([@koic][]) - #12835: Allow global offenses to be disabled by directive comments. ([@earlopain][])
Changes
v1.63.1
Bug fixes
-
#12828: Fix a false positive for
Lint/AssignmentInCondition
if assigning inside a method call. ([@earlopain][]) -
#12823: Fixed "uninitialized constant
RuboCop::Lockfile::Bundler
", caused when running RuboCop withoutbundler exec
on codebases that userubocop-rails
. ([@amomchilov][])
v1.63.0
New features
-
#11878: Add new
Style/MapIntoArray
cop. ([@ymap][]) -
#12186: Add new
requires_gem
API for declaring which gems a Cop needs. ([@amomchilov][])
Bug fixes
-
#12769: Fix a false positive for
Lint/RedundantWithIndex
when callingwith_index
with receiver and a block. ([@koic][]) - #12547: Added a comment recommending upgrading to the latest version of Rubocop in the error text when an Infinite loop detected error occurs. ([@Hiroto-Iizuka][])
-
#12782: Fix an error for
Style/Alias
withEnforcedStyle: prefer_alias
when callingalias_method
with fewer than 2 arguments. ([@earlopain][]) -
#12781: Fix an error for
Style/ExactRegexpMatch
when callingmatch
without a receiver. ([@earlopain][]) -
#12780: Fix an error for
Style/RedundantEach
when usingreverse_each.each
without a block. ([@earlopain][]) -
#12731: Treat
&.
the same way as.
for setter methods inLint/AssignmentInCondition
. ([@jonas054][]) -
#12793: Fix false positives for
Style/RedundantLineContinuation
when using line continuation with modifier. ([@koic][]) -
#12807: Fix false positives for
Naming/BlockForwarding
when using explicit block forwarding in block method and others. ([@koic][]) -
#12796: Fix false positives for
Style/EvalWithLocation
when usingeval
with a line number from a method call or a variable. ([@koic][]) -
#12794: Fix false positives for
Style/RedundantArgument
when when single-quoted strings for cntrl character. ([@koic][]) -
#12797: Fix false positives for
Style/RedundantLineContinuation
when using line continuations with&&
or||
operator in assignment. ([@koic][]) -
#12793: Fix false positives for
Style/RedundantLineContinuation
when multi-line continuations with operators. ([@koic][]) -
#12801: Fix incorrect autocorrect for
Style/CollectionCompact
when usingdelete_if
. ([@koic][]) -
#12789: Make
Style/RedundantPercentQ
safe on multiline strings. ([@boardfish][]) -
#12802: Return global offenses for
Naming/FileName
andNaming/InclusiveLanguage
for empty files. ([@earlopain][]) -
#12804: Return global offenses for
Style/Copyright
when the file is empty. ([@earlopain][])
Changes
- #12813: Add rubocop-rspec_rails to suggested extensions and extension doc. ([@ydah][])
-
#12820: Add support more Capybara debugger entry points for
Lint/Debugger
. ([@ydah][]) - #12676: Adjust offending range in LSP. ([@koic][])
-
#12815: Ignore
Rakefile.rb
inNaming/FileName
in the default config. ([@artur-intech][]) - #12800: Handle empty obsoletion config. ([@sambostock][])
-
#12721: Make
Lint/Debugger
aware ofruby/debug
requires. ([@earlopain][]) -
#12817: Make
rubocop -V
display rubocop-rspec_rails version when using it. ([@ydah][]) -
#12180: Replace regex with
Bundler::LockfileParser
. ([@amomchilov][])
v1.62.1
Bug fixes
-
#12761: Fix a false positive for
Style/HashEachMethods
when the key block argument ofEnumerable#each
method is unused afterchunk
. ([@koic][]) -
#12768: Fix a false positive for
Style/NilComparison
without receiver andEnforcedStyle: comparison
. ([@earlopain][]) -
#12752: Fix an error for
Gemspec/RequiredRubyVersion
when the file is empty. ([@earlopain][]) -
#12770: Fix an error for
Lint/RedundantWithIndex
when the method has no receiver. ([@earlopain][]) -
#12775: Fix an error for
Lint/UselessTimes
when no block is present. ([@earlopain][]) -
#12772: Fix an error for
Style/ClassVars
when callingclass_variable_set
without arguments. ([@earlopain][]) -
#12773: Fix an error for
Style/For
withEnforcedStyle: for
when no receiver. ([@earlopain][]) -
#12765: Fix an error for
Layout/MultilineMethodCallIndentation
with safe navigation and assignment method. ([@earlopain][]) -
#12703: Fix an error for
Lint/MixedCaseRange
with invalid byte sequence in UTF-8. ([@earlopain][]) -
#12755: Fix an exception for
RedundantCurrentDirectoryInPath
in case ofrequire_relative
without arguments. ([@viralpraxis][]) -
#12710: Fix a false negative for
Layout/EmptyLineAfterMagicComment
when the file is comments only. ([@earlopain][]) -
#12758: Fix false positives for
Layout/RedundantLineBreak
when using&&
or||
after a backslash newline. ([@koic][]) -
#12763: Fix an infinite loop for
Style/MultilineMethodSignature
when there is a newline directly after the def keyword. ([@earlopain][]) -
#12774: Fix an infinite loop for
Style/RaiseArgs
withEnforcedStyle: compact
when passing more than 2 arguments toraise
. ([@earlopain][]) -
#12663: Fix
Lint/Syntax
getting disabled byrubocop:disable Lint/Syntax
. ([@earlopain][]) - #12756: Only parse target Ruby from gemspec if array elements are strings. ([@davidrunger][])
Changes
-
#12730: Skip
LineLength
phase on--auto-gen-only-exclude
. ([@sambostock][])
v1.62.0
New features
- #12600: Support Prism as a Ruby parser (experimental). ([@koic][])
-
#12725: Support
TargetRubyVersion 3.4
(experimental). ([@koic][])
Bug fixes
-
#12746: Fix a false positive for
Lint/ToEnumArguments
when enumerator is created for another method in no arguments method definition. ([@koic][]) -
#12726: Fix a false positive for
Style/RedundantLineContinuation
when using line concatenation and calling a method with keyword arguments without parentheses. ([@koic][]) -
#12738: Fix an error for
Style/Encoding
when magic encoding with mixed case present. ([@koic][]) -
#12732: Fix error determining target Ruby when gemspec
required_ruby_version
is read from another file. ([@davidrunger][]) -
#12736: Fix invalid autocorrect in
Layout/SpaceInsideHashLiteralBraces
. ([@bquorning][]) - #12667: Don't load excluded configuration. ([@jonas054][])
v1.61.0
New features
-
#12682: Add
--editor-mode
CLI option. ([@koic][]) -
#12657: Support
AutoCorrect: contextual
option for LSP. ([@koic][]) -
#12273: Make
OffenseCountFormatter
display autocorrection information. ([@koic][]) -
#12679: Publish
RuboCop::LSP.enable
API to enable LSP mode. ([@koic][]) -
#12699: Support searching for
.rubocop.yml
andrubocop/config.yml
in compliance with dot-config. ([@koic][])
Bug fixes
-
#12720: Fix a false positive for
Style/ArgumentsForwarding
when using block arg forwarding to within block with Ruby 3.3.0. ([@koic][]) -
#12714: Fix an error for
Gemspec/RequiredRubyVersion
whenrequired_ruby_version
is specified withGem::Requirement.new
and is higher thanTargetRubyVersion
. ([@koic][]) -
#12690: Fix an error for
Style/CaseLikeIf
when using==
with literal and using ternary operator. ([@koic][]) -
#12668: Fix an incorrect autocorrect for
Lint/EmptyConditionalBody
when missingif
body with conditionalelse
body. ([@koic][]) -
#12683: Fix an incorrect autocorrect for
Style/MapCompactWithConditionalBlock
when using guard clause withnext
implicitly nil. ([@koic][]) -
#12693: Fix an incorrect autocorrect for
Style/ObjectThen
when usingyield_self
without receiver. ([@koic][]) -
#12646: Fix
--auto-gen-config
bug forLayout/SpaceBeforeBlockBraces
. ([@jonas054][]) -
#12717: Fix regexp for inline disable comments in
Style/CommentedKeyword
. ([@jonas054][]) -
#12695: Fix bug in
Include
from inherited file in a parent directory. ([@jonas054][]) -
#12656: Fix an error for
Layout/RedundantLineBreak
when using index access call chained on multiline hash literal. ([@koic][]) -
#12691: Fix an error for
Style/MultilineTernaryOperator
when nesting multiline ternary operators. ([@koic][]) -
#12707: Fix false negative for
Style/RedundantAssignment
when using pattern matching. ([@koic][]) -
#12674: Fix false negatives for
Style/RedundantReturn
when using pattern matching. ([@koic][]) -
#12673: Fix false negatives for
Lint/RedundantSafeNavigation
when using safe navigation operator for literal receiver. ([@koic][]) -
#12719: Fix false negatives for
Style/ArgumentsForwarding
when using forwardable block arguments with Ruby 3.2+. ([@koic][]) -
#12687: Fix a false positive for
Lint/Void
wheneach
block with conditional expressions that has multiple statements. ([@koic][]) -
#12649: Fix false positives for
Style/InverseMethods
when using relational comparison operator with safe navigation. ([@koic][]) -
#12711: Handle implicit receivers in
Style/InvertibleUnlessCondition
. ([@sambostock][]) -
#12648: Fix numblock regressions in
omit_parentheses
Style/MethodCallWithArgsParentheses
. ([@gsamokovarov][])
Changes
- #12641: Make error message clearer when the namespace is incorrect. ([@maruth-stripe][])
-
#12637: Mark
Style/RaiseArgs
as unsafe. ([@r7kamura][]) - #12645: Change source order for target ruby to check gemspec after RuboCop configuration. ([@jenshenny][])
v1.60.2
Bug fixes
-
#12627: Fix a false positive for
Layout/RedundantLineBreak
when using index access call chained on multiple lines with backslash. ([@koic][]) -
#12626: Fix a false positive for
Style/ArgumentsForwarding
when naming a block argument&
. ([@koic][]) -
#12635: Fix a false positive for
Style/HashEachMethods
when both arguments are unused. ([@earlopain][]) -
#12636: Fix an error for
Style/HashEachMethods
when a block with both parameters has no body. ([@earlopain][]) -
#12638: Fix an
Errno::ENOENT
error when using server mode. ([@koic][]) -
#12628: Fix a false positive for
Style/ArgumentsForwarding
when using block arg forwarding with positional arguments forwarding to within block. ([@koic][]) -
#12642: Fix false positives for
Style/HashEachMethods
when using array converter method. ([@koic][]) -
#12632: Fix an infinite loop error when
EnforcedStyle: explicit
ofNaming/BlockForwarding
withStyle/ArgumentsForwarding
. ([@koic][])
v1.60.1
Bug fixes
- #12625: Fix an error when server cache dir has read-only file system. ([@Strzesia][])
-
#12618: Fix false positives for
Style/ArgumentsForwarding
when using block argument forwarding with other arguments. ([@koic][]) -
#12614: Fix false positiveis for
Style/RedundantParentheses
when parentheses in control flow keyword with multiline style argument. ([@koic][])
Changes
v1.60.0
Bug fixes
-
#12603: Fix an infinite loop error for
Style/MultilineTernaryOperator
when using a method call as a ternary operator condition with a line break between receiver and method. ([@koic][]) -
#12549: Fix a false positive for
Style/RedundantLineContinuation
when line continuations for multiline leading dot method chain with a blank line. ([@koic][]) -
#12610: Accept parentheses in argument calls with blocks for
Style/MethodCallWithArgsParentheses
omit_parentheses
style. ([@gsamokovarov][]) -
#12580: Fix an infinite loop error for
Layout/EndAlignment
when misaligned in singleton class assignments withEnforcedStyleAlignWith: variable
. ([@koic][]) -
#12548: Fix an infinite loop error for
Layout/FirstArgumentIndentation
when specifyingEnforcedStyle: with_fixed_indentation
ofLayout/ArrayAlignment
. ([@koic][]) -
#12236: Fix an error for
Lint/ShadowedArgument
when self assigning to a block argument infor
. ([@koic][]) -
#12569: Fix an error for
Style/IdenticalConditionalBranches
when usingif
...else
with identical leading lines that assign toself.foo
. ([@koic][]) -
#12437: Fix an infinite loop error for
EnforcedStyle: omit_parentheses
ofStyle/MethodCallWithArgsParentheses
withStyle/SuperWithArgsParentheses
. ([@koic][]) -
#12558: Fix an incorrect autocorrect for
Style/MapToHash
when usingmap.to_h
without receiver. ([@koic][]) -
#12179: Let
--auto-gen-config
generateExclude
whenMax
is overridden. ([@jonas054][]) - #12574: Fix bug for unrecognized style in --auto-gen-config. ([@jonas054][])
-
#12542: Fix false positive for
Lint/MixedRegexpCaptureTypes
when using look-ahead matcher. ([@marocchino][]) -
#12607: Fix a false positive for
Style/RedundantParentheses
when regexp literal attempts to match against a parenthesized condition. ([@koic][]) -
#12539: Fix false positives for
Lint/LiteralAssignmentInCondition
when a collection literal contains non-literal elements. ([@koic][]) -
#12571: Fix false positives for
Naming/BlockForwarding
when using explicit block forwarding in block method. ([@koic][]) -
#12537: Fix false positives for
Style/RedundantParentheses
whenAllowInMultilineConditions: true
ofStyle/ParenthesesAroundCondition
. ([@koic][]) -
#12578: Fix false positives for
Style/ArgumentsForwarding
when rest arguments forwarding to a method in block. ([@koic][]) -
#12540: Fix false positives for
Style/HashEachMethods
when rest block argument ofEnumerable#each
method is used. ([@koic][]) -
#12529: Fix false positives for
Style/ParenthesesAroundCondition
. ([@koic][]) -
#12556: Fix false positives for
Style/RedundantParentheses
when parentheses are used around a semantic operator in expressions within assignments. ([@koic][]) -
#12541: Fix false negative in
Style/ArgumentsForwarding
when a block is forwarded but other args aren't. ([@dvandersluis][]) -
#12581: Handle trailing line continuation in
Layout/LineContinuationLeadingSpace
. ([@eugeneius][]) -
#12601: Make
Style/EachForSimpleLoop
accept block with no parameters. ([@koic][])
Changes
- #12535: Allow --autocorrect with --display-only-fail-level-offenses. ([@naveg][])
-
#12572: Follow a Ruby 3.3 warning for
Security/Open
whenopen
with a literal string starting with a pipe. ([@koic][]) -
#12453: Make
Style/RedundantEach
aware of safe navigation operator. ([@koic][]) -
#12233: Make
Style/SlicingWithRange
aware of redundant and beginless range. ([@koic][]) -
#12388: Reject additional 'expanded'
EnforcedStyle
options when--no-auto-gen-enforced-style
is given. ([@kpost][]) - #12593: Require Parser 3.3.0.2 or higher. ([@koic][])
v1.59.0
New features
Bug fixes
-
#12434: Fix a false positive for
Lint/LiteralAssignmentInCondition
when using interpolated string or xstring literals. ([@koic][]) -
#12435: Fix a false positive for
Lint/SelfAssignment
when using attribute assignment with method call with arguments. ([@koic][]) -
#12444: Fix false positive for
Style/HashEachMethods
when receiver literal is not a hash literal. ([@koic][]) -
#12524: Fix a false positive for
Style/MethodCallWithArgsParentheses
whenEnforcedStyle: omit_parentheses
and parens inwhen
clause is used to pass an argument. ([@koic][]) -
#12505: Fix a false positive for
Style/RedundantParentheses
when using parenthesizedlambda
orproc
withdo
...end
block. ([@koic][]) -
#12442: Fix an incorrect autocorrect for
Style/CombinableLoops
when looping over the same data as previous loop indo
...end
and{
...}
blocks. ([@koic][]) -
#12432: Fix a false positive for
Lint/LiteralAssignmentInCondition
when using parallel assignment with splat operator in block of guard condition. ([@koic][]) -
#12441: Fix false positives for
Style/HashEachMethods
when using destructed block arguments. ([@koic][]) -
#12436: Fix false positives for
Style/RedundantParentheses
when a part of range is a parenthesized condition. ([@koic][]) -
#12429: Fix incorrect autocorrect for
Style/MapToHash
when using dot method calls forto_h
. ([@koic][]) -
#12488: Make
Lint/HashCompareByIdentity
aware of safe navigation operator. ([@koic][]) -
#12489: Make
Lint/NextWithoutAccumulator
aware of safe navigation operator. ([@koic][]) -
#12490: Make
Lint/NumberConversion
aware of safe navigation operator. ([@koic][]) -
#12491: Make
Lint/RedundantWithIndex
aware of safe navigation operator. ([@koic][]) -
#12492: Make
Lint/RedundantWithObject
aware of safe navigation operator. ([@koic][]) -
#12493: Make
Lint/UnmodifiedReduceAccumulator
aware of safe navigation operator. ([@koic][]) -
#12473: Make
Style/ClassCheck
aware of safe navigation operator. ([@koic][]) -
#12445: Make
Style/CollectionCompact
aware of safe navigation operator. ([@koic][]) -
#12474: Make
Style/ConcatArrayLiterals
aware of safe navigation operator. ([@koic][]) -
#12476: Make
Style/DateTime
aware of safe navigation operator. ([@koic][]) -
#12479: Make
Style/EachWithObject
aware of safe navigation operator. ([@koic][]) -
#12446: Make
Style/HashExcept
aware of safe navigation operator. ([@koic][]) -
#12447: Make
Style/MapCompactWithConditionalBlock
aware of safe navigation operator. ([@koic][]) -
#12484: Make
Style/Next
aware of safe navigation operator. ([@koic][]) -
#12486: Make
Style/RedundantArgument
aware of safe navigation operator. ([@koic][]) -
#12454: Make
Style/RedundantFetchBlock
aware of safe navigation operator. ([@koic][]) -
#12495: Make
Layout/RedundantLineBreak
aware of safe navigation operator. ([@koic][]) -
#12455: Make
Style/RedundantSortBy
aware of safe navigation operator. ([@koic][]) -
#12456: Make
Style/RedundantSortBy
aware of safe navigation operator. ([@koic][]) -
#12480: Make
Style/ExactRegexpMatch
aware of safe navigation operator. ([@koic][]) -
#12457: Make
Style/Sample
aware of safe navigation operator. ([@koic][]) -
#12458: Make
Style/SelectByRegexp
cops aware of safe navigation operator. ([@koic][]) -
#12494: Make
Layout/SingleLineBlockChain
aware of safe navigation operator. ([@koic][]) -
#12461: Make
Style/StringChars
aware of safe navigation operator. ([@koic][]) -
#12468: Make
Style/Strip
aware of safe navigation operator. ([@koic][]) -
#12469: Make
Style/UnpackFirst
aware of safe navigation operator. ([@koic][])
Changes
-
#12522: Make
Style/MethodCallWithoutArgsParentheses
allow the parenthesizedit
method in a block. ([@koic][]) -
#12523: Make
Style/RedundantSelf
allow theself.it
method in a block. ([@koic][])
v1.58.0
New features
-
#12420: Add new
Lint/LiteralAssignmentInCondition
cop. ([@koic][]) -
#12353: Add new
Style/SuperWithArgsParentheses
cop. ([@koic][]) -
#12406: Add new
Style/ArrayFirstLast
cop. ([@fatkodima][])
Bug fixes
-
#12372: Fix a false negative for
Lint/Debugger
when used within method arguments abegin
...end
block. ([@koic][]) -
#12378: Fix a false negative for
Style/Semicolon
when a semicolon at the beginning of a lambda block. ([@koic][]) -
#12146: Fix a false positive for
Lint/FloatComparison
when comparing against zero. ([@earlopain][]) -
#12404: Fix a false positive for
Layout/RescueEnsureAlignment
when alignedrescue
indo
-end
numbered block in a method. ([@koic][]) -
#12374: Fix a false positive for
Layout/SpaceBeforeSemicolon
when a space between an opening lambda brace and a semicolon. ([@koic][]) -
#12326: Fix an error for
Style/RedundantDoubleSplatHashBraces
when method call for parenthesized no hash double double splat. ([@koic][]) -
#12361: Fix an incorrect autocorrect for
Naming/BlockForwarding
andStyle/ArgumentsForwarding
when autocorrection conflicts for anonymous arguments. ([@koic][]) -
#12324: Fix an error for
Layout/RescueEnsureAlignment
when usingrescue
indo
...end
block assigned to object attribute. ([@koic][]) -
#12322: Fix an error for
Style/CombinableLoops
when looping over the same data for the third consecutive time or more. ([@koic][]) -
#12366: Fix a false negative for
Layout/ExtraSpacing
when a file has exactly two comments. ([@eugeneius][]) -
#12373: Fix a false negative for
Lint/SymbolConversion
when using string interpolation. ([@earlopain][]) -
#12402: Fix false negatives for
Style/RedundantLineContinuation
when redundant line continuations for a block are used, especially without parentheses around first argument. ([@koic][]) -
#12311: Fix false negatives for
Style/RedundantParentheses
when parentheses around logical operator keywords in method definition. ([@koic][]) -
#12394: Fix false negatives for
Style/RedundantReturn
whenlambda
(->
) ending withreturn
. ([@koic][]) -
#12377: Fix false positives for
Lint/Void
when a collection literal that includes non-literal elements in a method definition. ([@koic][]) -
#12407: Fix an incorrect autocorrect for
Style/MapToHash
withLayout/SingleLineBlockChain
. ([@koic][]) -
#12409: Fix an incorrect autocorrect for
Lint/SafeNavigationChain
when ordinary method chain exists after safe navigation leading dot method call. ([@koic][]) -
#12363: Fix incorrect rendering of HTML character entities in
HTMLFormatter
formatter. ([@koic][]) -
#12424: Make
Style/HashEachMethods
aware of safe navigation operator. ([@koic][]) -
#12413: Make
Style/InverseMethods
aware of safe navigation operator. ([@koic][]) -
#12408: Make
Style/MapToHash
aware of safe navigation operator. ([@koic][])
Changes
-
#12328: Make
Style/AutoResourceCleanup
aware ofTempfile.open
. ([@koic][]) -
#12412: Enhance
Lint/RedundantSafeNavigation
to handle conversion methods with defaults. ([@fatkodima][]) -
#12410: Enhance
Lint/SelfAssignment
to check attribute assignment and key assignment. ([@fatkodima][]) -
#12370: Make
Style/HashEachMethods
aware of unused block value. ([@koic][]) -
#12380: Make
Style/RedundantParentheses
aware of lambda or proc. ([@koic][]) -
#12421: Make
Style/SelfAssignment
aware of%
,^
,<<
, and>>
operators. ([@koic][]) -
#12305: Require
rubocop-ast
version 1.30 or greater. ([@sambostock][]) -
#12337: Supports
EnforcedStyleForRationalLiterals
option forLayout/SpaceAroundOperators
. ([@koic][]) -
#12296: Support
RedundantRestArgumentNames
,RedundantKeywordRestArgumentNames
, andRedundantBlockArgumentNames
options forStyle/ArgumentsForwarding
. ([@koic][])
v1.57.2
Bug fixes
-
#12274: Fix a false positive for
Lint/Void
wheneach
's receiver is an object ofEnumerator
to whichfilter
has been applied. ([@koic][]) -
#12291: Fix a false positive for
Metrics/ClassLength
when a class with a singleton class definition. ([@koic][]) -
#12293: Fix a false positive for
Style/RedundantDoubleSplatHashBraces
when using double splat hash braces withmerge
and method chain. ([@koic][]) -
#12298: Fix a false positive for
Style/RedundantParentheses
when using a parenthesized hash literal as the first argument in a method call without parentheses. ([@koic][]) -
#12283: Fix an error for
Style/SingleLineDoEndBlock
when using single linedo
...end
with no body. ([@koic][]) -
#12312: Fix an incorrect autocorrect for
Style/HashSyntax
when braced hash key and value are the same and it is used inif
...else
. ([@koic][]) -
#12307: Fix an infinite loop error for
Layout/EndAlignment
whenEnforcedStyleAlignWith: variable
and using a conditional statement in a method argument on the same line andend
with method call is not aligned. ([@koic][]) -
#11652: Make
--auto-gen-config
generateinherit_from
correctly inside ERBif
. ([@jonas054][]) -
#12310: Drop
base64
gem from runtime dependency. ([@koic][]) -
#12300: Fix an error for
Style/IdenticalConditionalBranches
whenif
...else
with identical leading lines and using index assign. ([@koic][]) -
#12286: Fix false positives for
Style/RedundantDoubleSplatHashBraces
when using double splat with a hash literal enclosed in parenthesized ternary operator. ([@koic][]) -
#12279: Fix false positives for
Lint/EmptyConditionalBody
when missing 2ndif
body with a comment. ([@koic][]) -
#12275: Fix a false positive for
Style/RedundantDoubleSplatHashBraces
when using double splat within block argument containing a hash literal in an array literal. ([@koic][]) -
#12284: Fix false positives for
Style/SingleArgumentDig
when using some anonymous argument syntax. ([@koic][]) -
#12301: Make
Style/RedundantFilterChain
aware of safe navigation operator. ([@koic][])
v1.57.1
Bug fixes
-
#12271: Fix a false positive for
Lint/RedundantSafeNavigation
when using snake case constant receiver. ([@koic][]) -
#12265: Fix an error for
Layout/MultilineMethodCallIndentation
when usingarithmetic operation with block inside a grouped expression. ([@koic][]) -
#12177: Fix an incorrect autocorrect for
Style/RedundantException
. ([@ydah][]) -
#12261: Fix an infinite loop for
Layout/MultilineMethodCallIndentation
when multiline method chain with a block argument and method chain. ([@ydah][]) -
#12263: Fix false positives for
Style/RedundantDoubleSplatHashBraces
when method call for no hash braced double splat receiver. ([@koic][]) -
#12262: Fix an incorrect autocorrect for
Style/RedundantDoubleSplatHashBraces
when using double splat hash braces withmerge
method call twice. ([@koic][])
v1.57.0
New features
-
#12227: Add new
Style/SingleLineDoEndBlock
cop. ([@koic][]) -
#12246: Make
Lint/RedundantSafeNavigation
aware of constant receiver. ([@koic][]) -
#12257: Make
Style/RedundantDoubleSplatHashBraces
aware ofmerge
methods. ([@koic][])
Bug fixes
-
#12244: Fix a false negative for
Lint/Debugger
when using debugger method inside block. ([@koic][]) -
#12231: Fix a false negative for
Metrics/ModuleLength
when defining a singleton class in a module. ([@koic][]) -
#12249: Fix a false positive
Style/IdenticalConditionalBranches
whenif
..else
with identical leading lines and assign to condition value. ([@koic][]) -
#12253: Fix
Lint/LiteralInInterpolation
to accept an empty string literal interpolated in words literal. ([@knu][]) - #12198: Fix an error for flip-flop with beginless or endless ranges. ([@koic][])
-
#12259: Fix an error for
Lint/MixedCaseRange
when using nested character class in regexp. ([@koic][]) -
#12237: Fix an error for
Style/NestedTernaryOperator
when a ternary operator has a nested ternary operator within anif
. ([@koic][]) -
#12228: Fix false negatives for
Style/MultilineBlockChain
when using multiline block chain with safe navigation operator. ([@koic][]) -
#12247: Fix false negatives for
Style/RedundantParentheses
when using logical or comparison expressions with redundant parentheses. ([@koic][]) -
#12226: Fix false positives for
Layout/MultilineMethodCallIndentation
when aligning methods in multiline block chain. ([@koic][]) - #12076: Fixed an issue where the top-level cache folder was named differently during two consecutive rubocop runs. ([@K-S-A][])
Changes
- #12235: Enable auto parallel inspection when config file is specified. ([@aboutNisblee][])
-
#12234: Enhance
Style/FormatString
's autocorrection when using known conversion methods whose return value is not an array. ([@koic][]) -
#12128: Make
Style/GuardClause
aware ofdefine_method
. ([@koic][]) -
#12126: Make
Style/RedundantFilterChain
aware ofselect.present?
whenActiveSupportExtensionsEnabled
config istrue
. ([@koic][]) -
#12250: Mark
Lint/RedundantRequireStatement
as unsafe autocorrect. ([@koic][]) -
#12097: Mark unsafe autocorrect for
Style/ClassEqualityComparison
. ([@koic][]) -
#12210: Mark
Style/RedundantFilterChain
as unsafe autocorrect. ([@koic][])
v1.56.4
Bug fixes
-
#12221: Fix a false positive for
Layout/EmptyLineAfterGuardClause
when usingreturn
before guard condition with heredoc. ([@koic][]) -
#12213: Fix a false positive for
Lint/OrderedMagicComments
when comment text# encoding: ISO-8859-1
is embedded within example code as source code comment. ([@koic][]) -
#12205: Fix an error for
Style/OperatorMethodCall
when usingfoo bar./ baz
. ([@koic][]) -
#12208: Fix an incorrect autocorrect for the
--disable-uncorrectable
command line option when registering an offense is outside a percent array. ([@koic][]) -
#12203: Fix an incorrect autocorrect for
Lint/SafeNavigationChain
when using safe navigation with comparison operator as an expression of logical operator or comparison operator's operand. ([@koic][]) -
#12206: Fix an incorrect autocorrect for
Style/OperatorMethodCall
when usingfoo./bar
. ([@koic][]) -
#12202: Fix an incorrect autocorrect for
Style/RedundantConditional
when unless/else with boolean results. ([@ydah][]) -
#12199: Fix false negatives for
Layout/MultilineMethodCallIndentation
when using safe navigation operator. ([@koic][])
Changes
v1.56.3
Bug fixes
-
#12151: Make
Layout/EmptyLineAfterGuardClause
allow:nocov:
directive after guard clause. ([@koic][]) -
#12195: Fix a false negative for
Layout/SpaceAfterNot
when a newline is present after!
. ([@ymap][]) -
#12192: Fix a false positive for
Layout/RedundantLineBreak
when using quoted symbols with a single newline. ([@ymap][]) -
#12190: Fix a false positive for
Layout/SpaceAroundOperators
when aligning operators vertically. ([@koic][]) -
#12171: Fix a false positive for
Style/ArrayIntersect
when using block argument forEnumerable#any?
. ([@koic][]) -
#12172: Fix a false positive for
Style/EmptyCaseCondition
when usingreturn
,break
,next
or method call before empty case condition. ([@koic][]) -
#12162: Fix an error for
Bundler/DuplicatedGroup
when there's a duplicate set of groups and thegroup
value contains a splat. ([@koic][]) -
#12182: Fix an error for
Lint/UselessAssignment
when variables are assigned using chained assignment and remain unreferenced. ([@koic][]) -
#12181: Fix an incorrect autocorrect for
Lint/UselessAssignment
when variables are assigned with sequential assignment using the comma operator and unreferenced. ([@koic][]) -
#12187: Fix an incorrect autocorrect for
Style/SoleNestedConditional
when comment is in an empty nestedif
body. ([@ymap][]) -
#12183: Fix an incorrect autocorrect for
Style/MultilineTernaryOperator
when returning a multiline ternary operator expression with safe navigation method call. ([@koic][]) -
#12168: Fix bug in
Style/ArgumentsForwarding
when there are repeated send nodes. ([@owst][]) -
#12185: Set target version for
Layout/HeredocIndentation
. ([@tagliala][])
v1.56.2
Bug fixes
-
#12138: Fix a false positive for
Layout/LineContinuationLeadingSpace
when a backslash is part of a multiline string literal. ([@ymap][]) -
#12155: Fix false positive for
Layout/RedundantLineBreak
when using a modified singleton method definition. ([@koic][]) -
#12143: Fix a false positive for
Lint/ToEnumArguments
when using anonymous keyword arguments forwarding. ([@koic][]) -
#12148: Fix an incorrect autocorrect for
Lint/NonAtomicFileOperation
when usingFileUtils.remove_dir
,FileUtils.remove_entry
, orFileUtils.remove_entry_secure
. ([@koic][]) -
#12141: Fix false positive for
Style/ArgumentsForwarding
when method def includes additional kwargs. ([@owst][]) -
#12154: Fix incorrect
diagnosticProvider
value of LSP. ([@koic][])
v1.56.1
Bug fixes
-
#12136: Fix a false negative for
Layout/LeadingCommentSpace
when using#+
or#-
as they are not RDoc comments. ([@koic][]) -
#12113: Fix a false positive for
Bundler/DuplicatedGroup
when groups are duplicated butsource
,git
,platforms
, orpath
values are different. ([@koic][]) -
#12134: Fix a false positive for
Style/MethodCallWithArgsParentheses
when parentheses are used in one-linein
pattern matching. ([@koic][]) -
#12111: Fix an error for
Bundler/DuplicatedGroup
group declaration has keyword option. ([@koic][]) -
#12109: Fix an error for
Style/ArgumentsForwarding
cop when forwarding kwargs/block arg and an additional arg. ([@ydah][]) -
#12117: Fix a false positive for
Style/ArgumentsForwarding
cop when not always forwarding block. ([@owst][]) -
#12115: Fix an error for
Style/Lambda
when using numbered parameter with a multiline->
call. ([@koic][]) -
#12124: Fix false positives for
Style/RedundantParentheses
when parentheses insuper
oryield
call with multiline style argument. ([@koic][]) -
#12120: Fix false positives for
Style/SymbolArray
when%i
array containing unescaped[
,]
,(
, or)
. ([@koic][]) -
#12133: Fix
Style/RedundantSelfAssignmentBranch
to handle heredocs. ([@r7kamura][]) -
#12105: Fix target ruby
Gem::Requirement
matcher and version parsing to support multiple version constraints. ([@ItsEcholot][])
v1.56.0
New features
-
#12074: Add new
Bundler/DuplicatedGroup
cop. ([@OwlKing][]) -
#12078: Make LSP server support
rubocop.formatAutocorrectsAll
execute command. ([@koic][])
Bug fixes
-
#12106: Fix a false negative for
Style/RedundantReturn
when returning value with guard clause andreturn
is used. ([@koic][]) -
#12095: Fix a false positive for
Style/Alias
whenEncforcedStyle: prefer_alias
and usingalias
with interpolated symbol argument. ([@koic][]) -
#12098: Fix a false positive for
Style/ClassEqualityComparison
when comparing interpolated string class name for equality. ([@koic][]) -
#12102: Fix an error for
Style/LambdaCall
when using nested lambda callx.().()
. ([@koic][]) -
#12099: Fix an incorrect autocorrect for
Style/Alias
whenEncforcedStyle: prefer_alias_method
and usingalias
with interpolated symbol argument. ([@koic][]) -
#12085: Fix an error for
Lint/SuppressedException
whenAllowNil: true
is set and endless method definition is used. ([@koic][]) -
#12087: Fix false positives for
Style/ArgumentsForwarding
with additional args/kwargs in def/send nodes. ([@owst][]) -
#12071: Fix
Style/SymbolArray
false positives when using square brackets or interpolation in a symbol literal in a percent style array. ([@jasondoc3][]) - #12061: Support regex in StringLiteralsInInterpolation. ([@jonas054][])
-
#12091: With
--fail-level A
ignore non-correctable offenses at :info severity. ([@naveg][])
Changes
v1.55.1
Bug fixes
-
#12068: Fix a false positive for
Style/ReturnNilInPredicateMethodDefinition
when the last method argument in method definition isnil
. ([@koic][]) -
#12082: Fix an error for
Lint/UselessAssignment
when a variable is assigned and unreferenced infor
with multiple variables. ([@koic][]) -
#12079: Fix an error for
Style/MixinGrouping
when mixin method has no arguments. ([@koic][]) -
#11637: Correct Rubocop for
private_class_method
method documentation. ([@bigzed][]) -
#12070: Fix false positive in
Style/ArgumentsForwarding
when receiver forwards args/kwargs. ([@owst][])
v1.55.0
New features
-
#11794: Add support to
Style/ArgumentsForwarding
for anonymous arg/kwarg forwarding in Ruby 3.2. ([@owst][]) -
#12044: Make LSP server support
layoutMode
option to run layout cops. ([@koic][]) -
#12056: Make LSP server support
lintMode
option to run lint cops. ([@koic][]) -
#12046: Make
ReturnNilInPredicateMethodDefinition
aware ofnil
at the end of predicate method definition. ([@koic][])
Bug fixes
-
#12055: Allow parentheses in single-line match patterns when using the
omit_parentheses
style ofStyle/MethodCallWithArgsParentheses
. ([@gsamokovarov][]) -
#12050: Fix a false positive for
Layout/RedundantLineBreak
when inspecting the%
form string%\n\n
. ([@koic][]) -
#12063: Fix
Style/CombinableLoops
when one of the loops is empty. ([@fatkodima][]) -
#12059: Fix a false negative for
Style/StringLiteralsInInterpolation
for symbols with interpolation. ([@fatkodima][]) - #11834: Fix false positive for when variable in inside conditional branch in nested node. ([@alexeyschepin][])
-
#11802: Improve handling of
[]
and()
with percent symbol arrays. ([@jasondoc3][]) - #12052: Fix "Subfolders can't include glob special characters". ([@meric426][], [@loveo][])
-
#12062: Fix
LoadError
when loading RuboCop from a symlinked location on Windows. ([@p0deje][])
Changes
-
#12064: Make
Style/RedundantArgument
aware ofexit
andexit!
. ([@koic][]) -
#12015: Mark
Style/HashConversion
as unsafe autocorrection. ([@koic][])
v1.54.2
Bug fixes
-
#12043: Fix a false negative for
Layout/ExtraSpacing
when some characters are vertically aligned. ([@koic][]) -
#12040: Fix a false positive for
Layout/TrailingEmptyLines
to prevent the following incorrect autocorrection when inspecting the%
form string%\n\n
. ([@koic][]) -
#1867: Fix an error when
AllCops:Exclude
is empty in .rubocop.yml. ([@koic][]) - #12034: Fix invalid byte sequence in UTF-8 error when using an invalid encoding string. ([@koic][])
- #12038: Output the "server restarting" message to stderr. ([@knu][])
v1.54.1
Bug fixes
-
#12024: Fix a false positive for
Lint/RedundantRegexpQuantifiers
when interpolation is used in a regexp literal. ([@koic][]) -
#12020: This MR fixes an infinite loop error for
Layout/SpaceAfterComma
withLayout/SpaceBeforeSemicolon
when autocorrection conflicts. ([@koic][]) -
#12014: Fix an error for
Lint/UselessAssignment
when part of a multiple assignment is enclosed in parentheses. ([@koic][]) -
#12011: Fix an error for
Metrics/MethodLength
when using a heredoc in a block without block arguments. ([@koic][]) -
#12010: Fix false negatives for
Style/RedundantRegexpArgument
when using safe navigation operator. ([@koic][])
v1.54.0
New features
Bug fixes
-
#12005: Fix a false negative for
Lint/Debugger
when using debugger method inside lambda. ([@koic][]) -
#11986: Fix a false positive for
Lint/MixedCaseRange
when the number of characters at the start or end of range is other than 1. ([@koic][]) -
#11992: Fix an unexpected
NoMethodError
for built-in language server when an internal error occurs. ([@koic][]) -
#11994: Fix an error for
Layout/LineEndStringConcatenationIndentation
when inspecting the%
from string%\n\n
. ([@koic][]) -
#12007: Fix an error for
Layout/SpaceAroundOperators
when using unary operator with double colon. ([@koic][]) -
#11996: Fix an error for
Style/IfWithSemicolon
when without branch bodies. ([@koic][]) -
#12009: Fix an error for
Style/YodaCondition
when equality check method is used without the first argument. ([@koic][]) - #11998: Fix an error when inspecting blank heredoc delimiter. ([@koic][])
-
#11989: Fix an incorrect autocorrect for
Style/RedundantRegexpArgument
when using unicode chars. ([@koic][]) - #12001: Fix code length calculator for method calls with heredoc. ([@fatkodima][])
-
#12002: Fix
Lint/Void
cop for__ENCODING__
constant. ([@fatkodima][])
Changes
-
#11983: Add Ridgepole files to default
Include
list. ([@ydah][]) - #11738: Enhances empty_line_between_defs to treat configured macros like defs. ([@catwomey][])
v1.53.1
Bug fixes
-
#11974: Fix an error for
Style/RedundantCurrentDirectoryInPath
when using string interpolation inrequire_relative
. ([@koic][]) -
#11981: Fix an incorrect autocorrect for
Style/RedundantRegexpArgument
when using double quote and single quote characters. ([@koic][]) -
#11836: Should not offense single-quoted symbol containing double quotes in
Lint/SymbolConversion
. ([@KessaPassa][])
v1.53.0
New features
-
#11561: Add new
Lint/MixedCaseRange
cop. ([@rwstauner][]) -
#11565: Add new
Lint/RedundantRegexpQuantifiers
cop. ([@jaynetics][]) -
#11925: Add new
Style/RedundantCurrentDirectoryInPath
cop. ([@koic][]) -
#11595: Add new
Style/RedundantRegexpArgument
cop. ([@koic][]) -
#11967: Add new
Style/ReturnNilInPredicateMethodDefinition
cop. ([@koic][]) -
#11745: Add new
Style/YAMLFileRead
cop. ([@koic][]) - #11926: Support built-in LSP server. ([@koic][])
Bug fixes
-
#11953: Fix a false negative for
Lint/DuplicateHashKey
when there is a duplicated constant key in the hash literal. ([@koic][]) -
#11945: Fix a false negative for
Style/RedundantSelfAssignmentBranch
when using method chaining or arguments in ternary branch. ([@koic][]) -
#11949: Fix a false positive for
Layout/RedundantLineBreak
when using a line broken string. ([@koic][]) -
#11931: Fix a false positive for
Lint/RedundantRequireStatement
when usingPP.pp
. ([@koic][]) -
#11946: Fix an error for
Lint/NumberConversion
when using multiple number conversion methods. ([@koic][]) -
#11972: Fix an error for
Lint/Void
whenCheckForMethodsWithNoSideEffects: true
and using a method definition. ([@koic][]) -
#11958: Fix error for
Style/IdenticalConditionalBranches
when using empty parentheses in theif
branch. ([@koic][]) -
#11962: Fix an error for
Style/RedundantStringEscape
when an escaped double quote precedes interpolation in a symbol literal. ([@koic][]) -
#11947: Fix an error for
Style/ConditionalAssignment
with an assignment that usesif
branch bodies, which include a block. ([@koic][]) -
#11959: Fix false negatives for
Layout/EmptyLinesAroundExceptionHandlingKeywords
when using Ruby 2.5'srescue
inside block and Ruby 2.7's numbered block. ([@koic][]) -
#10902: Fix an error for
Style/RedundantRegexpEscape
string with invalid byte sequence in UTF-8. ([@ydah][]) -
#11562: Fixed escaped octal handling and detection in
Lint/DuplicateRegexpCharacterClassElement
. ([@rwstauner][])
Changes
-
#11904: Mark
Layout/ClassStructure
as unsafe to autocorrect. ([@nevans][]) -
#8506: Add
AllowedParentClasses
config toLint/MissingSuper
. ([@iMacTia][])
v1.52.1
Bug fixes
-
#11944: Fix an incorrect autocorrect for
Style/SoleNestedConditional
withStyle/MethodCallWithArgsParentheses
. ([@koic][]) -
#11930: Fix exception on
Lint/InheritException
when class definition has non-constant siblings. ([@rafaelfranca][]) -
#11919: Fix an error for
Lint/UselessAssignment
when a variable is assigned and unreferenced infor
. ([@koic][]) -
#11928: Fix an incorrect autocorrect for
Lint/AmbiguousBlockAssociation
. ([@koic][]) -
#11915: Fix a false positive for
Lint/RedundantSafeNavigation
when&.
is used forto_s
,to_i
,to_d
, and other coercion methods. ([@lucthev][])
Changes
v1.52.0
New features
-
#11873: Add
ComparisonsThreshold
config option toStyle/MultipleComparison
. ([@fatkodima][]) -
#11886: Add new
Style/RedundantArrayConstructor
cop. ([@koic][]) -
#11873: Add new
Style/RedundantRegexpConstructor
cop. ([@koic][]) -
#11841: Add new
Style/RedundantFilterChain
cop. ([@fatkodima][]) -
#11908: Support
AllowedReceivers
forStyle/CollectionMethods
. ([@koic][])
Bug fixes
-
#11890: Fix a false negative for
Lint/RedundantSafeNavigation
when&.
is used forto_d
. ([@koic][]) -
#11880: Fix a false positive for
Style/ExactRegexpMatch
when using literal with quantifier in regexp. ([@koic][]) -
#11902: Fix a false positive for
Style/RequireOrder
when single-quoted string and double-quoted string are mixed. ([@koic][]) -
#11879: Fix a false positive for
Style/SelectByRegexp
when Ruby 2.2 or lower analysis. ([@koic][]) -
#11891: Fix
Style/AccessorGrouping
to accept macros separated from accessors by space. ([@fatkodima][]) -
#11905: Fix an error for
Lint/UselessAssignment
when a variable is assigned with rest assignment and unreferenced. ([@koic][]) -
#11899: Fix an incorrect autocorrect for
Style/SingleLineMethods
when using Ruby 3.0 andStyle/EndlessMethod
is disabled. ([@koic][]) -
#11884: Make
rubocop -V
display rubocop-factory_bot version when using it. ([@koic][]) -
#11893: Fix a false positive for
Lint/InheritException
when inheritingException
with omitted namespace. ([@koic][]) -
#11898: Fix offences in calls inside blocks with braces for
Style/MethodCallWithArgsParentheses
withomit_parentheses
enforced style. ([@gsamokovarov][]) - #11857: Server mode: only read $stdin when -s or --stdin argument provided. ([@naveg][])
v1.51.0
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][])
- #11791: (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][])
v1.50.2
Bug fixes
-
#11799: Fix a false positive for
Style/CollectionCompact
when usingreject
on hash to reject nils in Ruby 2.3 analysis. ([@koic][]) -
#11792: Fix an error for
Lint/DuplicateMatchPattern
when using hash pattern withif
guard. ([@koic][]) -
#11800: Mark
Style/InvertibleUnlessCondition
as unsafe. ([@koic][])
v1.50.1
Bug fixes
-
#11787: Fix a false positive for
Lint/DuplicateMatchPattern
when repeatedin
patterns but differentif
guard is used. ([@koic][]) -
#11789: Fix false negatives for
Style/ParallelAssignment
when Ruby 2.7+. ([@koic][]) -
#11783: Fix a false positive for
Style/RedundantLineContinuation
using line concatenation for assigning a return value and without argument parentheses. ([@koic][])
v1.50.0
New features
-
#11749: Add new
Lint/DuplicateMatchPattern
cop. ([@koic][]) -
#11773: Make
Layout/ClassStructure
aware of singleton class. ([@koic][]) -
#11779: Make
Lint/RedundantStringCoercion
aware of print method arguments. ([@koic][]) -
#11776: Make
Metrics/ClassLength
aware of singleton class. ([@koic][]) -
#11775: Make
Style/TrailingBodyOnClass
aware of singleton class. ([@koic][])
Bug fixes
-
#11758: Fix a false positive for
Style/RedundantLineContinuation
when line continuations for string. ([@koic][]) -
#11754: Fix a false positive for
Style/RedundantLineContinuation
when using&&
and||
with a multiline condition. ([@ydah][]) -
#11765: Fix an error for
Style/MultilineMethodSignature
when line break afterdef
keyword. ([@koic][]) -
#11762: Fix an incorrect autocorrect for
Style/ClassEqualityComparison
when comparing a variable or return value for equality. ([@koic][]) -
#11752: Fix a false positive for
Style/RedundantLineContinuation
when using line concatenation and calling a method without parentheses. ([@koic][])
v1.49.0
New features
-
#11122: Add new
Style/RedundantLineContinuation
cop. ([@ydah][]) -
#11696: Add new
Style/DataInheritance
cop. ([@ktopolski][]) -
#11746: Make
Layout/EndAlignment
aware of pattern matching. ([@koic][]) -
#11750: Make
Metrics/BlockNesting
aware of numbered parameter. ([@koic][]) -
#11699: Make
Style/ClassEqualityComparison
aware ofClass#to_s
andClass#inspect
for class equality comparison. ([@koic][]) -
#11737: Make
Style/MapToHash
andStyle/MapToSet
aware of numbered parameters. ([@koic][]) -
#11732: Make
Style/MapToHash
andStyle/MapToSet
aware of symbol proc. ([@koic][]) -
#11703: Make
Naming/InclusiveLanguage
support autocorrection when there is only one suggestion. ([@koic][])
Bug fixes
-
#11730: Fix an error for
Layout/HashAlignment
when using anonymous keyword rest arguments. ([@koic][]) -
#11704: Fix a false positive for
Lint/UselessMethodDefinition
when method definition with non access modifier containing onlysuper
call. ([@koic][]) -
#11723: Fix a false positive for
Style/IfUnlessModifier
when using one-line pattern matching as aif
condition. ([@koic][]) - #11725: Fix an error when insufficient permissions to server cache dir are granted. ([@koic][])
- #11715: Ensure default configuration loads. ([@koic][])
- #11742: Fix error handling in bundler standalone mode. ([@composerinteralia][])
-
#11712: Fix a crash in
Lint/EmptyConditionalBody
. ([@gsamokovarov][]) -
#11641: Fix a false negative for
Layout/ExtraSpacing
when there are many comments with extra spaces. ([@nobuyo][]) -
#11740: Fix a false positive for
Lint/NestedMethodDefinition
when nested definition inside*_eval
and*_exec
method call with a numblock. ([@ydah][]) -
#11685: Fix incorrect directive comment insertion when percent array violates
Layout/LineLength
cop. ([@nobuyo][]) -
#11706: Fix infinite loop when
--disable-uncorrectable
option and there is a multi-line percent array violatesLayout/LineLength
. ([@nobuyo][]) -
#11697: Fix
Lint/Syntax
behavior when--only
is not given the cop name. ([@koic][]) -
#11709: Fix value omission false positive in
Style/MethodCallWithArgsParentheses
. ([@gsamokovarov][])
Changes
-
#11739: Make
Style/RedundantParentheses
aware of redundant method argument parentheses. ([@koic][]) -
#10766: Use the path given by
--cache-root
to be the parent forrubocop_cache
dir like other ways to specify it. ([@nobuyo][])
v1.48.1
Bug fixes
-
#11673: Fix incorrect
Style/HashSyntax
autocorrection for assignment methods. ([@gsamokovarov][]) -
#11682: Fix a false positive for
Lint/UselessRescue
when usingThread#raise
inrescue
clause. ([@koic][]) -
#11672: Fix an error for
Layout/BlockEndNewline
when multiline block}
is not on its own line and it is used as multiple arguments. ([@koic][]) -
#11675:
Style/AccessorGrouping
: Fix sibling detection for methods with type sigs. ([@issyl0][]) -
#11658: Fix
Lint/Debugger
should not allow pry. ([@ThHareau][]) -
#11689: Fix
Lint/Syntax
behavior whenEnabled: false
ofLint
department. ([@koic][]) -
#11677: Fix the severity for
Lint/Syntax
. ([@koic][]) -
#11691: Fix an error for
Gemspec/DependencyVersion
when method called on gem name argument foradd_dependency
. ([@koic][])
v1.48.0
New features
-
#11628: Add new
Style/DirEmpty
cop. ([@ydah][]) -
#11629: Add new
Style/FileEmpty
cop. ([@ydah][])
Bug fixes
-
#11654: Fix a false positive for
Lint/MissingSuper
when nosuper
call and when defining some method. ([@koic][]) -
#11661: Fix an error for
Style/Documentation
when namespace is a variable. ([@koic][]) -
#11647: Fix an error for
Style/IfWithBooleanLiteralBranches
when using()
as a condition. ([@koic][]) -
#11646: Fix an error for
Style/NegatedIfElseCondition
when using()
as a condition. ([@koic][]) -
#11659: Fix an incorrect autocorrect for
Lint/OrAssignmentToConstant
when using or-assignment to a constant in method definition. ([@koic][]) -
#11663: Fix an incorrect autocorrect for
Style/BlockDelimiters
when multi-line blocks to{
and}
with arithmetic operation method chain. ([@koic][]) -
#11638: Fix a false positive for
Lint/UselessAccessModifier
when using same access modifier inside and outside theincluded
block. ([@ydah][]) -
#11164: Suppress server mode message with
-f json
. ([@jasondoc3][]) - #11643: Fix incorrect shorthand autocorrections in calls inside parentheses. ([@gsamokovarov][])
-
#11650:
Style/AccessorGrouping
: Fix detection of Sorbetsig {}
blocks. ([@issyl0][]) - #11657: Use cop name to check if cop inside registry is enabled. Previously, it was able to cause large memory usage during linting. ([@fatkodima][])
Changes
-
#11482: Avoid comment deletion by
Style/IfUnlessModifier
when the modifier form expression has long comment. ([@nobuyo][]) -
#11649: Support
MinBranchesCount
config forStyle/CaseLikeIf
cop. ([@fatkodima][])
v1.47.0
New features
-
#11475: Add autocorrect for hash in
Lint/LiteralInInterpolation
. ([@KessaPassa][]) -
#11584: Add
Metrics/CollectionLiteralLength
cop. ([@sambostock][])
Bug fixes
-
#11615: Fix a false negative for
Lint/MissingSuper
when nosuper
call withClass.new
block. ([@koic][]) -
#11615: Fix a false negative for
Lint/MissingSuper
when usingClass.new
without parent class argument. ([@koic][]) -
#11040: Fix a false positive for
Style/IfUnlessModifier
whendefined?
's argument value is undefined. ([@koic][]) -
#11607: Fix a false positive for
Style/RedundantRegexpEscape
when an escaped hyphen follows after an escaped opening square bracket within a character class. ([@SparLaimor][]) -
#11626: Fix a false positive for
Style/ZeroLengthPredicate
when usingFile.new(path).size.zero?
. ([@koic][]) -
#11620: Fix an error for
Lint/ConstantResolution
when using__ENCODING__
. ([@koic][]) -
#11625: Fix an error for
Lint/EmptyConditionalBody
when missingif
body and using method call for return value. ([@koic][]) -
#11631: Fix an incorrect autocorrect for
Style/ArgumentsForwarding
when using arguments forwarding for.()
call. ([@koic][]) -
#11621: Fix an incorrect autocorrect for
Layout/ClassStructure
using heredoc inside method. ([@fatkodima][]) -
#3591: Handle modifier
while
anduntil
expressions inLint/UselessAssignment
. ([@bfad][]) -
#11202: Fixed usage of
--only
flag with--auto-gen-config
. ([@istvanfazakas][])
Changes
v1.46.0
New features
Bug fixes
- #11574: Fix a broken shorthand syntax autocorrection. ([@gsamokovarov][])
-
#11599: Fix a false positive for
Layout/LineContinuationSpacing
when using percent literals. ([@koic][]) -
#11556: Fix a false positive for
Lint/Debugger
whenp
is an argument of method call. ([@koic][]) -
#11591: Fix a false positive for
Lint/ToEnumArguments
when enumerator is not created for__callee__
and__callee__
methods. ([@koic][]) - #11603: Actually run temporarily enabled cops. ([@tdeo][])
-
#11579: Fix an error for
Layout/HeredocArgumentClosingParenthesis
when heredoc is a method argument in a parenthesized block argument. ([@koic][]) -
#11576: Fix an error for
Lint/UselessRescue
whenrescue
does not exception variable andensure
has empty body. ([@koic][]) -
#11608: Fix an error for
Lint/RefinementImportMethods
when usinginclude
on the top level. ([@koic][]) -
#11589: Fix an error for
Layout/HeredocArgumentClosingParenthesis
when heredoc is a branch body in a method argument of a parenthesized argument. ([@koic][]) -
#11567: Fix
Layout/EndAlignment
false negative. ([@j-miyake][]) - #11582: Fix checking if token with large offset begins its line. ([@fatkodima][])
-
#11412: Mark
Style/ArrayIntersect
as unsafe. ([@koic][]) -
#11559: Fixed false positives and negatives in
Style/RedundantRegexpCharacterClass
when using octal escapes (e.g. "\0"). ([@jaynetics][]) - #11575: Fix parentheses in value omissions for multiple assignments. ([@gsamokovarov][])
Changes
-
#11586: Handle
ruby2_keywords
inStyle/DocumentationMethod
cop. ([@fatkodima][]) -
#11604: Make
Naming/VariableNumber
to allowx86_64
CPU architecture name by default. ([@koic][]) -
#11596: Make
Style/AccessorGrouping
aware of method call before accessor. ([@koic][]) -
#11588: Optimize
Style/WordArray
complex matrix check. ([@sambostock][]) -
#11573: Handle hash patterns and pins in
Lint/OutOfRangeRegexpRef
cop. ([@fatkodima][]) -
#11564: Remove print debug methods from default for
Lint/Debugger
. ([@koic][])
v1.45.1
Bug fixes
-
#11552: Fix a false positive for
Lint/Debugger
when methods containing different method chains. ([@ydah][]) -
#11548: Fix an error for
Style/AccessModifierDeclarations
when if a non method definition was included. ([@ydah][]) -
#11554: Fix an error for
Style/RedundantCondition
when the branches contains empty hash literal argument. ([@koic][]) -
#11549: Fix an error for third party cops when inheriting
RuboCop::Cop::Cop
. ([@koic][])
v1.45.0
New features
- #10839: Add API for 3rd party template support. ([@r7kamura][])
-
#11528: Add new
Style/RedundantHeredocDelimiterQuotes
cop. ([@koic][]) -
#11188: Add a
--no-detach
option for--start-server
. This will start the server process in the foreground, which can be helpful when running within Docker where detaching the process terminates the container. ([@f1sherman][]) -
#11546: Make
Lint/UselessAccessModifier
aware of Ruby 3.2'sData.define
. ([@koic][]) -
#11396: Add ability to profile rubocop execution via
--profile
and--memory
options. ([@fatkodima][])
Bug fixes
-
#11491: Fix a crash on
Lint/UselessAssignment
. ([@gsamokovarov][]) -
#11515: Fix a false negative for
Naming/HeredocDelimiterNaming
when using lowercase. ([@koic][]) -
#11511: Fix a false negative for
Style/YodaCondition
when using constant. ([@koic][]) -
#11520: Fix a false negative for
Style/YodaExpression
when using constant. ([@koic][]) -
#11521: Fix a false positive for
Lint/FormatParameterMismatch
when usingKernel.format
with the interpolated number of decimal places fields match. ([@koic][]) -
#11545: Fix the following false positive for
Lint/NestedMethodDefinition
when using numbered parameter. ([@koic][]) -
#11535: Fix a false positive for
Style/NumberedParametersLimit
when only_2
or higher numbered parameter is used. ([@koic][]) -
#11508: Fix a false positive for
Style/OperatorMethodCall
when using multiple arguments for operator method. ([@koic][]) -
#11503: Fix a false positive for
Style/RedundantCondition
when using method argument with operator. ([@koic][]) -
#11529: Fix an incorrect autocorrect for
Layout/ClassStructure
when definitions that need to be sorted are defined alternately. ([@ydah][]) -
#11530: Fix an incorrect autocorrect for
Style/AccessModifierDeclarations
when multiple groupable access modifiers are defined. ([@ydah][]) -
#10910: Fix an incorrect autocorrect for
Style/MultilineTernaryOperator
when contains a comment. ([@ydah][]) -
#11522: Don't flag default keyword arguments in
Style/ArgumentsForwarding
. ([@splattael][]) -
#11547: Fix a false positive for
Lint/NestedMethodDefinition
when using Ruby 3.2'sData.define
. ([@koic][]) -
#11537: Fix an infinite loop error for
Layout/ArrayAlignment
when using assigning unbracketed array elements. ([@koic][]) - #11516: Fix missing parentheses in shorthand hash syntax as argument calls. ([@gsamokovarov][])
Changes
-
#11504: Allow
initialize
method inStyle/DocumentationMethod
. ([@koic][]) -
#11541: Enable autocorrection for
Layout/LineContinuationLeadingSpace
. ([@eugeneius][]) -
#11542: Mark
Layout/AssignmentIndentation
as safe andLint/AssignmentInCondition
as unsafe for autocorrection. ([@eugeneius][]) -
#11517: Make
Lint/Debugger
aware ofp
,PP.pp
, andpp
methods. ([@koic][]) -
#11539: Remove
bundler
from defaultAllowedGems
ofGemspec/DevelopmentDependencies
. ([@koic][])
v1.44.1
Bug fixes
-
#11492: Fix an error for
Lint/Void
when configuringCheckForMethodsWithNoSideEffects: true
. ([@koic][]) -
#11400: Fix an incorrect autocorrect for
Naming/BlockForwarding
andLint/AmbiguousOperator
when autocorrection conflicts for ambiguous splat argument. ([@fatkodima][]) -
#11483: Fix
Layout/ClosingParenthesisIndentation
for keyword splat arguments. ([@fatkodima][]) -
#11487: Fix a false positive for
Lint/FormatParameterMismatch
when format string is only interpolated string. ([@ydah][]) -
#11485: Fix a false positive for
Lint/UselessAssignment
when using numbered block parameter. ([@koic][])
v1.44.0
New features
-
#11410: Add new
Style/InvertibleUnlessCondition
cop. ([@fatkodima][]) -
#11338: Add new
Style/ComparableClamp
cop. ([@koic][]) -
#11350: Make
Lint/DeprecatedClassMethods
aware of deprecatedattr
with boolean 2nd argument. ([@koic][]) -
#11457: Make
Metrics/BlockNesting
aware of pattern matching. ([@koic][]) -
#11458: Make
Metrics/CyclomaticComplexity
aware of pattern matching. ([@koic][]) -
#11469: Add
Gemspec/DevelopmentDependencies
cop. ([@sambostock][])
Bug fixes
-
#11445: Fix an incorrect autocorrect for
Style/BlockDelimiters
when there is a comment after the closing brace and bracket. ([@koic][]) - #11428: Apply value omission exceptions in super invocations. ([@gsamokovarov][])
-
#11420: Fix a false positive for
Lint/UselessRescue
when using exception variable inensure
clause. ([@koic][]) -
#11460: Fix an error for
Style/OperatorMethodCall
when usingfoo.> 42
. ([@koic][]) -
#11456: Fix value omissions in
yield
invocations. ([@gsamokovarov][]) -
#11467: Fix a false negative for
Style/MethodCallWithoutArgsParentheses
when calling method on a receiver and assigning to a variable with the same name. ([@koic][]) -
#11430: Fix an infinite loop error for
Layout/BlockEndNewline
when multiline blocks with newlines before the; end
. ([@koic][]) - #11442: Fix a crash during anonymous rest argument forwarding. ([@gsamokovarov][])
-
#11447: Fix an incorrect autocorrect for
Style/RedundantDoubleSplatHashBraces
when using nested double splat hash braces. ([@koic][]) -
#11459: Make
Lint/UselessRuby2Keywords
aware of conditions. ([@splattael][]) -
#11415: Fix a false positive for
Lint/UselessMethodDefinition
when method definition contains rest arguments. ([@koic][]) -
#11418: Fix a false positive for
Style/MethodCallWithArgsParentheses
when using anonymous rest arguments or anonymous keyword rest arguments. ([@koic][]) -
#11431: Fix a crash in
Style/HashSyntax
. ([@gsamokovarov][]) -
#11444: Fix a false positive for
Lint/ShadowingOuterLocalVariable
when using numbered block parameter. ([@koic][]) - #11477: Fix an error when using YAML alias with server mode. ([@koic][])
-
#11419: Fix a false positive for
Lint/RedundantRequireStatement
when usingpretty_inspect
. ([@koic][]) -
#11439: Fix an incorrect autocorrect for
Style/MinMaxComparison
when usinga < b a : b
withelsif/else
. ([@ydah][]) -
#11464: Fix a false negative for
Lint/FormatParameterMismatch
when include interpolated string. ([@ydah][]) -
#11425: Fix a false negative for
Lint/Void
when using methods that takes blocks. ([@krishanbhasin-shopify][]) -
#11437: Fix an error for
Style/AccessModifierDeclarations
when access modifier is inlined with a method on the top level. ([@koic][]) -
#11455: Fix crash with
super value_omission:
followed by a method call. ([@gsamokovarov][])
Changes
-
#11465: Make
Style/Semicolon
aware of redundant semicolon in block. ([@koic][]) - #11471: Change to not output not configured warning when renamed and pending cop. ([@ydah][])
v1.43.0
New features
-
#11359: Add new
Lint/UselessRescue
cop. ([@fatkodima][]) -
#11389: Add autocorrect for
Style/MissingElse
. ([@FnControlOption][])
Bug fixes
-
#11386: Fix a false positive for
Style/OperatorMethodCall
when using anonymous forwarding. ([@koic][]) -
#11409: Fix an incorrect autocorrect for
Style/HashSyntax
when using hash value omission andEnforcedStyle: no_mixed_keys
. ([@koic][]) -
#11405: Fix undefined method
range_between' for
Style/WhileUntilModifier`. ([@such][]) -
#11374: Fix an error for
Style/StringHashKeys
when using invalid symbol in encoding UTF-8 as keys. ([@koic][]) -
#11392: Fix an incorrect autocorrect for
Style/RedundantDoubleSplatHashBraces
using double splat in double splat hash braces. ([@koic][]) -
#8990: Make
Style/HashEachMethods
aware of built-inThread.current
. ([@koic][]) -
#11390: Fix an incorrect autocorrect for
Style/HashSyntax
when hash first argument key and hash value only are the same which has a method call on the next line. ([@koic][]) -
#11379: Fix a false negative for
Style/OperatorMethodCall
when usinga.+ b.something
. ([@koic][]) -
#11180: Fix an error for
Style/RedundantRegexpEscape
when using%r
to provide regexp expressions. ([@si-lens][]) -
#11403: Fix bad offense for parenthesised calls in literals for
omit_parentheses
style inStyle/MethodCallWithArgsParentheses
. ([@gsamokovarov][]) -
#11407: Fix an error for
Style/HashSyntax
when expression follows hash key assignment. ([@fatkodima][]) -
#11377: Fix
Style/OperatorMethodCall
when forwarding arguments. ([@sambostock][])
Changes
Configuration
-
If you want to rebase/retry this MR, check this box
This MR has been generated by Renovate Bot.
Edited by renovate-bot