Rubocop v0.51.0 Release Notes
Release Date: 2017-10-18 // over 6 years ago-
๐ New features
- ๐
#4791: Add new
Rails/UnknownEnv
cop. ([@pocke][]) - ๐ #4690: Add new
Lint/UnneededRequireStatement
cop. ([@koic][]) - ๐
#4813: Add new
Style/StderrPuts
cop. ([@koic][]) - ๐ #4796: Add new
Lint/RedundantWithObject
cop. ([@koic][]) - ๐
#4663: Add new
Style/CommentedKeyword
cop. ([@donjar][]) - โ Add
IndentationWidth
configuration forLayout/Tab
cop. ([@rrosenblum][]) - ๐ #4854: Add new
Lint/RegexpAsCondition
cop. ([@pocke][]) - #4862: Add
MethodDefinitionMacros
option toNaming/PredicateName
cop. ([@koic][]) - #4874: Add new
Gemspec/OrderedDependencies
cop. ([@sue445][]) - ๐
#4840: Add new
Style/MixinUsage
cop. ([@koic][]) - ๐
#1952: Add new
Style/DateTime
cop. ([@dpostorivo][]) - ๐ #4727: Make
Lint/Void
check for nonmutating methods as well. ([@donjar][])
๐ Bug fixes
- ๐
#3312: Make
Rails/Date
Correct false positive on#to_time
for strings ending in UTC-"Z".([@erikdstock][]) - ๐
#4741: Make
Style/SafeNavigation
correctly exclude methods called without dot. ([@drenmi][]) - ๐ #4740: Make
Lint/RescueWithoutErrorClass
aware of modifier formrescue
. ([@drenmi][]) - ๐
#4745: Make
Style/SafeNavigation
ignore negated continuations. ([@drenmi][]) - ๐ #4732: Prevent
Performance/HashEachMethods
from registering an offense when#each
follows#to_a
. ([@drenmi][]) - ๐ #4730: False positive on Lint/InterpolationCheck. ([@koic][])
- ๐
#4751: Prevent
Rails/HasManyOrHasOneDependent
cop from registering offense if:through
option was specified. ([@smakagon][]) - #4737: Fix ReturnInVoidContext cop when
return
is in top scope. ([@frodsan][]) - #4776: Non utf-8 magic encoding comments are now respected. ([@deivid-rodriguez][])
- ๐
#4241: Prevent
Rails/Blank
andRails/Present
from breaking when there is no explicit receiver. ([@rrosenblum][]) - ๐
#4814: Prevent
Rails/Blank
from breaking on send with an argument. ([@pocke][]) - #4759: Make
Naming/HeredocDelimiterNaming
andNaming/HeredocDelimiterCase
aware of more delimiter patterns. ([@drenmi][]) - ๐ #4823: Make
Lint/UnusedMethodArgument
andLint/UnusedBlockArgument
aware of overriding assignments. ([@akhramov][]) - ๐ #4830: Prevent
Lint/BooleanSymbol
from truncating symbol's value in the message when offense is located in the new syntax hash. ([@akhramov][]) - ๐
#4747: Fix
Rails/HasManyOrHasOneDependent
cop incorrectly flagswith_options
blocks. ([@koic][]) - ๐
#4836: Make
Rails/OutputSafety
aware of safe navigation operator. ([@drenmi][]) - ๐ #4843: Make
Lint/ShadowedException
cop aware of same system error code. ([@koic][]) - ๐
#4757: Make
Style/TrailingUnderscoreVariable
work for nested assignments. ([@donjar][]) - ๐
#4597: Fix
Style/StringLiterals
cop not registering an offense on single quoted strings containing an escaped single quote when configured to use double quotes. ([@promisedlandt][]) - ๐ #4850:
Lint/UnusedMethodArgument
respectsIgnoreEmptyMethods
setting by ignoring unused method arguments for singleton methods. ([@jmks][]) - #2040: Document how to write a custom cop. ([@jonatas][])
๐ Changes
- ๐ #4746: The
Lint/InvalidCharacterLiteral
cop has been removed since it was never being actually triggered. ([@deivid-rodriguez][]) - ๐ #4789: Analyzing code that needs to support MRI 1.9 is no longer supported. ([@deivid-rodriguez][])
- ๐ง #4582:
Severity
and other common parameters can be configured on department level. ([@jonas054][]) - ๐ #4787: Analyzing code that needs to support MRI 2.0 is no longer supported. ([@deivid-rodriguez][])
- #4787: RuboCop no longer installs on MRI 2.0. ([@deivid-rodriguez][])
- #4266: Download the inherited config files of a remote file from the same remote. ([@tdeo][])
- ๐ #4853: Make
Lint/LiteralInCondition
cop aware of!
andnot
. ([@pocke][]) - ๐ #4864: Rename
Lint/LiteralInCondition
toLint/LiteralAsCondition
. ([@pocke][])
- ๐
#4791: Add new