def fetch(name)
      name = name.to_sym

      if @seen.include?(name)
        path = [*@seen, name].join(' -> ')
        raise Wireless::CycleError, "cycle detected: #{path}"
      end

      unless (resolver = @registry[name])
        raise Wireless::KeyError.new(
          "dependency not found: #{name}",
          key: name,
          receiver: self
        )
      end

      fetcher = lambda do
        seen = @seen.dup
        seen.add(name)
        Fetcher.new(registry: @registry, seen: seen)
      end

      resolver.resolve(fetcher)
    end
def fetch(name)
      name = name.to_sym

      if @seen.include?(name)
        path = [*@seen, name].join(' -> ')
        raise Wireless::CycleError, "cycle detected: #{path}"
      end

      unless (resolver = @registry[name])
        raise Wireless::KeyError.new(
          "dependency not found: #{name}",
          key: name,
          receiver: self
        )
      end

      fetcher = lambda do
        seen = @seen.dup
        seen.add(name)
        Fetcher.new(registry: @registry, seen: seen)
      end

      resolver.resolve(fetcher)
    end
Fetches the dependency with the specified name. Creates the dependency if
 it doesn't exist. Raises a Wireless::KeyError if the dependency is not
 defined or a Wireless::CycleError if resolving the dependency results in
 a cycle.