{"record":{"id":"3ad52b63476ec7cb","repo":"ruby/rubygems","slug":"your-platform-is-not-supported-3ad52b","errorCode":null,"errorMessage":"your platform is not supported","messagePattern":"your platform is not supported","errorType":"validation","errorClass":"Gem::OptionParser::InvalidOption","httpStatus":null,"severity":"error","filePath":"lib/rubygems/install_update_options.rb","lineNumber":66,"sourceCode":"               \"generate.  For example: rdoc,ri\") do |value, options|\n      options[:document] = case value\n                           when nil   then %w[ri]\n                           when false then []\n                           else value\n      end\n    end\n\n    add_option(:\"Install/Update\", \"--build-root DIR\",\n               \"Temporary installation root. Useful for building\",\n               \"packages. Do not use this when installing remote gems.\") do |value, options|\n      options[:build_root] = File.expand_path(value)\n    end\n\n    add_option(:\"Install/Update\", \"--vendor\",\n               \"Install gem into the vendor directory.\",\n               \"Only for use by gem repackagers.\") do |_value, options|\n      unless Gem.vendor_dir\n        raise Gem::OptionParser::InvalidOption.new \"your platform is not supported\"\n      end\n\n      options[:vendor] = true\n      options[:install_dir] = Gem.vendor_dir\n    end\n\n    add_option(:\"Install/Update\", \"-N\", \"--no-document\",\n               \"Disable documentation generation\") do |_value, options|\n      options[:document] = []\n    end\n\n    add_option(:\"Install/Update\", \"-E\", \"--[no-]env-shebang\",\n               \"Rewrite the shebang line on installed\",\n               \"scripts to use /usr/bin/env\") do |value, options|\n      options[:env_shebang] = value\n    end\n\n    add_option(:\"Install/Update\", \"-f\", \"--[no-]force\",","sourceCodeStart":48,"sourceCodeEnd":84,"githubUrl":"https://github.com/ruby/rubygems/blob/86cbb817a38ce8477b181c17467a703ded3f2be8/lib/rubygems/install_update_options.rb#L48-L84","documentation":"Error \"your platform is not supported\" thrown in ruby/rubygems.","triggerScenarios":"Thrown at lib/rubygems/install_update_options.rb:66 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Install the gem for your platform: `gem install <gem> --platform <platform>`","Use a Ruby build/platform that the gem supports (e.g. avoid mswin-only gems on Linux)"],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"86cbb817a38ce8477b181c17467a703ded3f2be8","analyzedAt":"2026-08-23T06:27:48.159Z","schemaVersion":2},"datasetVersion":"2026-08-23T08:06:27.607Z"}