我正在运行命令“gem update --system”。我收到以下错误消息。任何帮助将不胜感激!
我正在运行Rails 1.9.2补丁136和ruby 3.0.3。
Users/woshea/.rvm/gems/ruby-1.9.2-p136@rails3tutorial/gems/rubygems-update-1.4.1/lib/rubygems/source_index.rb:62:in `installed_spec_directories': undefined method `path' for Gem:Module (NoMethodError)
from /Users/woshea/.rvm/gems/ruby-1.9.2-p136@rails3tutorial/gems/rubygems-update-1.4.1/lib/rubygems/source_index.rb:52:in `from_installed_gems'
from /Users/woshea/.rvm/gems/ruby-1.9.2-p136@rails3tutorial/gems/rubygems-update-1.4.1/lib/rubygems.rb:914:in `source_index'
from /Users/woshea/.rvm/gems/ruby-1.9.2-p136@rails3tutorial/gems/rubygems-update-1.4.1/lib/rubygems/gem_path_searcher.rb:98:in `init_gemspecs'
from /Users/woshea/.rvm/gems/ruby-1.9.2-p136@rails3tutorial/gems/rubygems-update-1.4.1/lib/rubygems/gem_path_searcher.rb:13:in `initialize'
from /Users/woshea/.rvm/gems/ruby-1.9.2-p136@rails3tutorial/gems/rubygems-update-1.4.1/lib/rubygems.rb:873:in `new'
from /Users/woshea/.rvm/gems/ruby-1.9.2-p136@rails3tutorial/gems/rubygems-update-1.4.1/lib/rubygems.rb:873:in `searcher'
from /Users/woshea/.rvm/gems/ruby-1.9.2-p136@rails3tutorial/gems/rubygems-update-1.4.1/lib/rubygems.rb:495:in `find_files'
from /Users/woshea/.rvm/gems/ruby-1.9.2-p136@rails3tutorial/gems/rubygems-update-1.4.1/lib/rubygems.rb:1034:in `load_plugins'
from /Users/woshea/.rvm/gems/ruby-1.9.2-p136@rails3tutorial/gems/rubygems-update-1.4.1/lib/rubygems/gem_runner.rb:84:in `<top (required)>'
from <internal:lib/rubygems/custom_require>:29:in `require'
from <internal:lib/rubygems/custom_require>:29:in `require'
from setup.rb:25:in `<main>'
我的环境如下:
答案 0 :(得分:6)
截至2011年1月2日,RubyGems 1.4.0 / 1.4.1版本不适用于MRI Ruby 1.9。记录在案:见the release post。
由于您正在运行MRI Ruby 1.9,请与我一起等待更新的MRI Ruby 1.9,它将支持更新的RubyGems 1.4。