Skip to content

Commit c19f08b

Browse files
authored
Merge pull request #20158 from Homebrew/revert-20145-some-bundle-files-werent-typed-at-all-but-now-some-are
Revert "Make some of the `bundle` commands Sorbet `typed: true`"
2 parents d590e39 + 68dbf12 commit c19f08b

File tree

3 files changed

+6
-16
lines changed

3 files changed

+6
-16
lines changed

Library/Homebrew/bundle/brew_dumper.rb

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# typed: true
1+
# typed: false # rubocop:todo Sorbet/TrueSigil
22
# frozen_string_literal: true
33

44
require "json"
@@ -189,12 +189,7 @@ def formula_to_hash(formula)
189189

190190
class Topo < Hash
191191
include TSort
192-
193-
def each_key(&block)
194-
keys.each(&block)
195-
end
196192
alias tsort_each_node each_key
197-
198193
def tsort_each_child(node, &block)
199194
fetch(node.downcase).sort.each(&block)
200195
end
@@ -235,8 +230,8 @@ def sort!(formulae)
235230

236231
odie <<~EOS
237232
Formulae dependency graph sorting failed (likely due to a circular dependency):
238-
#{cycle_first}: #{topo[cycle_first] if topo}
239-
#{cycle_last}: #{topo[cycle_last] if topo}
233+
#{cycle_first}: #{topo[cycle_first]}
234+
#{cycle_last}: #{topo[cycle_last]}
240235
Please run the following commands and try again:
241236
brew update
242237
brew uninstall --ignore-dependencies --force #{cycle_first} #{cycle_last}

Library/Homebrew/bundle/checker.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# typed: true
1+
# typed: false # rubocop:todo Sorbet/TrueSigil
22
# frozen_string_literal: true
33

44
module Homebrew
@@ -23,7 +23,7 @@ def failure_reason(name, no_upgrade:)
2323
else
2424
"needs to be installed or updated."
2525
end
26-
"#{self.class.const_get(:PACKAGE_TYPE_NAME)} #{name} #{reason}"
26+
"#{self.class::PACKAGE_TYPE_NAME} #{name} #{reason}"
2727
end
2828

2929
def full_check(packages, no_upgrade:)
@@ -33,7 +33,7 @@ def full_check(packages, no_upgrade:)
3333

3434
def checkable_entries(all_entries)
3535
require "bundle/skipper"
36-
all_entries.select { |e| e.type == self.class.const_get(:PACKAGE_TYPE) }
36+
all_entries.select { |e| e.type == self.class::PACKAGE_TYPE }
3737
.reject(&Bundle::Skipper.method(:skip?))
3838
end
3939

Library/Homebrew/sorbet/rbi/dsl/homebrew/bundle/brew_dumper.rbi

Lines changed: 0 additions & 5 deletions
This file was deleted.

0 commit comments

Comments
 (0)