class Bundler::Molinillo::CircularDependencyError

Parent:
Bundler::Molinillo::ResolverError

An error caused by attempting to fulfil a dependency that was circular

@note This exception will be thrown iff a {Vertex} is added to a

{DependencyGraph} that has a {DependencyGraph::Vertex#path_to?} an
existing {DependencyGraph::Vertex}

Attributes

dependencies[R]
Set<Object>

the dependencies responsible for causing the error

Public Class Methods

new(vertices) Show source
# File lib/bundler/vendor/molinillo/lib/molinillo/errors.rb, line 47
def initialize(vertices)
  super "There is a circular dependency between #{vertices.map(&:name).join(' and ')}"
  @dependencies = vertices.map { |vertex| vertex.payload.possibilities.last }.to_set
end

Initializes a new error with the given circular vertices. @param [Array<DependencyGraph::Vertex>] vertices the vertices in the dependency

that caused the error
Calls superclass method Exception::new

Ruby Core © 1993–2017 Yukihiro Matsumoto
Licensed under the Ruby License.
Ruby Standard Library © contributors
Licensed under their own licenses.