bbatsov/rubocop

View on GitHub
relnotes/v0.80.0.md

Summary

Maintainability
Test Coverage
### New features

* [#7693](https://github.com/rubocop/rubocop/pull/7693): NodePattern: Add `` ` `` for descendant search. ([@marcandre][])
* [#7577](https://github.com/rubocop/rubocop/pull/7577): Add `AllowGemfileRubyComment` configuration on `Layout/LeadingCommentSpace`. ([@cetinajero][])
* [#7663](https://github.com/rubocop/rubocop/pull/7663): Add new `Style/HashTransformKeys` and `Style/HashTransformValues` cops. ([@djudd][], [@eugeneius][])
* [#7619](https://github.com/rubocop/rubocop/issues/7619): Support autocorrect of legacy cop names for `Migration/DepartmentName`. ([@koic][])
* [#7659](https://github.com/rubocop/rubocop/pull/7659): `Layout/LineLength` autocorrect now breaks up long lines with blocks. ([@maxh][])
* [#7677](https://github.com/rubocop/rubocop/pull/7677): Add new `Style/HashEachMethods` cop for `Hash#each_key` and `Hash#each_value`. ([@jemmaissroff][])
* Add `BracesRequiredMethods` parameter to `Style/BlockDelimiters` to require braces for specific methods such as Sorbet's `sig`. ([@maxh][])
* [#7686](https://github.com/rubocop/rubocop/pull/7686): Add new `JUnitFormatter` formatter based on `rubocop-junit-formatter` gem. ([@koic][])
* [#7715](https://github.com/rubocop/rubocop/pull/7715): Add `Steepfile` to default `Include` list. ([@ybiquitous][])

### Bug fixes

* [#7644](https://github.com/rubocop/rubocop/issues/7644): Fix patterns with named wildcards in unions. ([@marcandre][])
* [#7639](https://github.com/rubocop/rubocop/pull/7639): Fix logical operator edge case in `omit_parentheses` style of `Style/MethodCallWithArgsParentheses`. ([@gsamokovarov][])
* [#7661](https://github.com/rubocop/rubocop/pull/7661): Fix to return correct info from multi-line regexp. ([@Tietew][])
* [#7655](https://github.com/rubocop/rubocop/issues/7655): Fix an error when processing a regexp with a line break at the start of capture parenthesis. ([@koic][])
* [#7647](https://github.com/rubocop/rubocop/issues/7647): Fix an `undefined method on_numblock` error when using Ruby 2.7's numbered parameters. ([@hanachin][])
* [#7675](https://github.com/rubocop/rubocop/issues/7675): Fix a false negative for `Layout/SpaceBeforeFirstArg` when a vertical argument positions are aligned. ([@koic][])
* [#7688](https://github.com/rubocop/rubocop/issues/7688): Fix a bug in `Style/MethodCallWithArgsParentheses` that made `--auto-gen-config` crash. ([@buehmann][])
* [#7203](https://github.com/rubocop/rubocop/issues/7203): Fix an infinite loop error for `Style/TernaryParentheses` with `Style/RedundantParentheses` when using `EnforcedStyle: require_parentheses_when_complex`. ([@koic][])
* [#7708](https://github.com/rubocop/rubocop/issues/7708): Make it possible to use EOL `rubocop:disable` comments on comment lines. ([@jonas054][])
* [#7712](https://github.com/rubocop/rubocop/issues/7712): Fix an incorrect autocorrect for `Style/OrAssignment` when using `elsif` branch. ([@koic][])

### Changes

* [#7636](https://github.com/rubocop/rubocop/issues/7636): Remove `console` from `Lint/Debugger` to prevent false positives. ([@gsamokovarov][])
* [#7641](https://github.com/rubocop/rubocop/issues/7641): **(Breaking)** Remove `Style/BracesAroundHashParameters` cop. ([@pocke][])
* Add the method name to highlight area of `Layout/EmptyLineBetweenDefs` to help provide more context. ([@rrosenblum][])
* [#7652](https://github.com/rubocop/rubocop/pull/7652): Allow `pp` to allowed names of `Naming/MethodParameterName` cop in default config. ([@masarakki][])
* [#7309](https://github.com/rubocop/rubocop/pull/7309): Mark `Lint/UselessSetterCall` an "not safe" and improve documentation. ([@jonas054][])
* [#7723](https://github.com/rubocop/rubocop/pull/7723): Enable `Migration/DepartmentName` cop by default. ([@koic][])

[@marcandre]: https://github.com/marcandre
[@cetinajero]: https://github.com/cetinajero
[@djudd]: https://github.com/djudd
[@eugeneius]: https://github.com/eugeneius
[@koic]: https://github.com/koic
[@maxh]: https://github.com/maxh
[@jemmaissroff]: https://github.com/jemmaissroff
[@ybiquitous]: https://github.com/ybiquitous
[@gsamokovarov]: https://github.com/gsamokovarov
[@Tietew]: https://github.com/Tietew
[@hanachin]: https://github.com/hanachin
[@buehmann]: https://github.com/buehmann
[@jonas054]: https://github.com/jonas054
[@pocke]: https://github.com/pocke
[@rrosenblum]: https://github.com/rrosenblum
[@masarakki]: https://github.com/masarakki