ruby/rubygems · error · Bundler::ProductionError

The following gems are missing OS dependencies: * #{spec.na

Error message

The following gems are missing OS dependencies:
 * #{spec.name}: #{path}

What it means

Error "The following gems are missing OS dependencies: * #{spec.name}: #{path}" thrown in ruby/rubygems.

Source

Thrown at lib/bundler/cli/doctor/diagnose.rb:107

            lookup_with_fiddle(f)
          end
          if bad_paths.any?
            broken_links[spec] ||= []
            broken_links[spec].concat(bad_paths)
          end
        end
      end

      permissions_valid = check_home_permissions

      if broken_links.any?
        message = "The following gems are missing OS dependencies:"
        broken_links.flat_map do |spec, paths|
          paths.uniq.map do |path|
            "\n * #{spec.name}: #{path}"
          end
        end.sort.each {|m| message += m }
        raise ProductionError, message
      elsif permissions_valid
        Bundler.ui.info "No issues found with the installed bundle"
      end
    end

    private

    def check_home_permissions
      require "find"
      files_not_readable = []
      files_not_readable_and_owned_by_different_user = []
      files_not_owned_by_current_user_but_still_readable = []
      broken_symlinks = []
      Find.find(Bundler.bundle_path.to_s).each do |f|
        if !File.exist?(f)
          broken_symlinks << f
        elsif !File.readable?(f)
          if File.stat(f).uid != Process.uid

View on GitHub (pinned to 86cbb817a3)

When it happens

Trigger: Thrown at lib/bundler/cli/doctor/diagnose.rb:107 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/1cc9a5d38bbce7db. Report an issue: GitHub.