Exception: Gem::Resolver::Molinillo::NoSuchDependencyError
Relationships & Source Files | |
Super Chains via Extension / Inclusion / Inheritance | |
Class Chain:
self,
ResolverError,
StandardError
|
|
Instance Chain:
self,
ResolverError,
StandardError
|
|
Inherits: |
Gem::Resolver::Molinillo::ResolverError
|
Defined in: | lib/rubygems/resolver/molinillo/lib/molinillo/errors.rb |
Overview
An error caused by searching for a dependency that is completely unknown, i.e. has no versions available whatsoever.
Class Method Summary
-
.new(dependency, required_by = []) ⇒ NoSuchDependencyError
constructor
Initializes a new error with the given missing dependency.
Instance Attribute Summary
Instance Method Summary
-
#message
The error message for the missing dependency, including the specifications that had this dependency.
Constructor Details
.new(dependency, required_by = []) ⇒ NoSuchDependencyError
Initializes a new error with the given missing dependency.
# File 'lib/rubygems/resolver/molinillo/lib/molinillo/errors.rb', line 18
def initialize(dependency, required_by = []) @dependency = dependency @required_by = required_by super() end
Instance Attribute Details
#dependency ⇒ Object
(rw)
# File 'lib/rubygems/resolver/molinillo/lib/molinillo/errors.rb', line 10
attr_accessor :dependency
#required_by ⇒ Array
<Object
> (rw)
# File 'lib/rubygems/resolver/molinillo/lib/molinillo/errors.rb', line 13
attr_accessor :required_by
Instance Method Details
#message
The error message for the missing dependency, including the specifications that had this dependency.
# File 'lib/rubygems/resolver/molinillo/lib/molinillo/errors.rb', line 26
def sources = required_by.map { |r| "`#{r}`" }.join(' and ') = "Unable to find a specification for `#{dependency}`" += " depended upon by #{sources}" unless sources.empty? end