From cace5c429f33d3fb7747f5525e00763b1d23c284 Mon Sep 17 00:00:00 2001 From: Issy Long Date: Mon, 13 Mar 2023 23:59:25 +0000 Subject: [PATCH] rubocop: Enable `Style/AccessorGrouping` and autofix offenses - With RuboCop 1.48.1 this no longer reports offenses and applies bugged autocorrections for `attr`s with Sorbet `sig`s, so we can enable it. --- Library/.rubocop.yml | 4 ---- Library/Homebrew/utils/pypi.rb | 4 +--- 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/Library/.rubocop.yml b/Library/.rubocop.yml index 45fcd31a91..3746bc98aa 100644 --- a/Library/.rubocop.yml +++ b/Library/.rubocop.yml @@ -301,10 +301,6 @@ Sorbet/StrictSigil: Include: - "**/*.rbi" -# Conflicts with type signatures on `attr_*`s. -Style/AccessorGrouping: - Enabled: false - # Require &&/|| instead of and/or Style/AndOr: EnforcedStyle: always diff --git a/Library/Homebrew/utils/pypi.rb b/Library/Homebrew/utils/pypi.rb index f81c8e904c..3fa0277588 100644 --- a/Library/Homebrew/utils/pypi.rb +++ b/Library/Homebrew/utils/pypi.rb @@ -18,9 +18,7 @@ module PyPI class Package extend T::Sig - attr_accessor :name - attr_accessor :extras - attr_accessor :version + attr_accessor :name, :extras, :version sig { params(package_string: String, is_url: T::Boolean).void } def initialize(package_string, is_url: false)