End of Life Ruby 3.2 has reached end of life and gets no more fixes. Switch to Ruby 4.0 →
instance method
Gem::Resolver#sort_dependencies
sort_dependencies(dependencies, activated, conflicts)
lib/rubygems/resolver.rb
View on GitHub ↗
# File tmp/rubies/ruby-3.2.0/lib/rubygems/resolver.rb, line 281
def sort_dependencies(dependencies, activated, conflicts)
dependencies.sort_by.with_index do |dependency, i|
name = name_for(dependency)
[
activated.vertex_named(name).payload ? 0 : 1,
amount_constrained(dependency),
conflicts[name] ? 0 : 1,
activated.vertex_named(name).payload ? 0 : search_for(dependency).count,
i, # for stable sort
]
end
end
No documentation available