ruby/rubygems · error · InstallError

#{e.message}

Error message

#{e.message}

What it means

Error "#{e.message}" thrown in ruby/rubygems.

Source

Thrown at lib/bundler/source/rubygems.rb:241

          installed_spec = installer.install
        end

        spec.full_gem_path = installed_spec.full_gem_path
        spec.loaded_from = installed_spec.loaded_from
        spec.base_dir = installed_spec.base_dir

        spec.post_install_message
      end

      def cache(spec, custom_path = nil)
        cached_path = Bundler.settings[:cache_all_platforms] ? fetch_gem_if_possible(spec) : cached_gem(spec)
        raise GemNotFound, "Missing gem file '#{spec.file_name}'." unless cached_path
        return if File.dirname(cached_path) == Bundler.app_cache.to_s
        Bundler.ui.info "  * #{File.basename(cached_path)}"
        FileUtils.cp(cached_path, Bundler.app_cache(custom_path))
      rescue Errno::EACCES => e
        Bundler.ui.debug(e)
        raise InstallError, e.message
      end

      def cached_built_in_gem(spec, local: false)
        cached_path = cached_gem(spec)
        if cached_path.nil? && !local
          remote_spec = remote_spec_for(spec)
          if remote_spec
            cached_path = fetch_gem(remote_spec)
            spec.remote = remote_spec.remote
          else
            Bundler.ui.warn "#{spec.full_name} is built in to Ruby, and can't be cached because your Gemfile doesn't have any sources that contain it."
          end
        end
        cached_path
      end

      def add_remote(source, cooldown: nil)
        uri = normalize_uri(source)

View on GitHub (pinned to 86cbb817a3)

When it happens

Trigger: Thrown at lib/bundler/source/rubygems.rb:241 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of ruby/rubygems@86cbb817a3 (2026-08-23). Data as JSON: /api/errors/2039c811abe04c5c. Report an issue: GitHub.