From: Kurt Stephens Date: 2008-02-01T15:49:00+09:00 Subject: Re: Gem install error on head Luis Lavena wrote:
On Jan 31, 2008 11:45 PM, Kurt Stephens <ks@kurtstephens.com> wrote:
  
This has been happening for me for a *long* time.  I can also recreate
this error; I thought it was just my environment.  What's the best way
to get gem to produce a useful stack trace?

    

gem install --debug gem_name

  

Here's the new result with gem install --debug rake:
(Note: /home/stephens/local/ruby/trunk is the ruby config --prefix of a clean install on Linux)

+ gem install --debug -y rake
Exception `NameError' at /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/command_manager.rb:132 - uninitialized constant Gem::Commands::InstallCommand
INFO:�� `gem install -y` is now default and will be removed
INFO:�� use --ignore-dependencies to install only the gems you list
Exception `Gem::LoadError' at /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems.rb:385 - Could not find RubyGem sources (> 0.0.1)
Exception `LoadError' at /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/tmpdir.rb:14 - no such file to load -- Win32API
Exception `NoMethodError' at /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/open-uri.rb:411 - undefined method `[]=' for nil:NilClass
Exception `NoMethodError' at /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/delegate.rb:146 - undefined method `[]=' for nil:NilClass
Exception `Gem::OperationNotSupportedError' at /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/source_index.rb:366 - No quick index found: undefined method `[]=' for nil:NilClass
Bulk updating Gem source index for: http://gems.rubyforge.org
Exception `NoMethodError' at /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/open-uri.rb:411 - undefined method `[]=' for nil:NilClass
Exception `NoMethodError' at /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/delegate.rb:146 - undefined method `[]=' for nil:NilClass
Exception `NoMethodError' at /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/open-uri.rb:411 - undefined method `[]=' for nil:NilClass
Exception `NoMethodError' at /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/delegate.rb:146 - undefined method `[]=' for nil:NilClass
Exception `NoMethodError' at /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/open-uri.rb:411 - undefined method `[]=' for nil:NilClass
Exception `NoMethodError' at /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/delegate.rb:146 - undefined method `[]=' for nil:NilClass
Exception `Gem::RemoteSourceException' at /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/source_index.rb:354 - Error fetching remote gem cache: undefined method `[]=' for nil:NilClass
ERROR:�� While executing gem ... (Gem::RemoteSourceException)
������ Error fetching remote gem cache: undefined method `[]=' for nil:NilClass
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/source_index.rb:354:in `raise'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/source_index.rb:354:in `fetch_bulk_index'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/source_index.rb:292:in `update'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/source_info_cache_entry.rb:33:in `refresh'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/source_info_cache.rb:135:in `block in refresh'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/source_info_cache.rb:128:in `each'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/source_info_cache.rb:128:in `refresh'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/source_info_cache.rb:40:in `cache'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/source_info_cache.rb:56:in `search_with_source'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/dependency_installer.rb:110:in `find_gems_with_sources'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/dependency_installer.rb:77:in `initialize'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/commands/install_command.rb:69:in `new'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/commands/install_command.rb:69:in `block in execute'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/commands/install_command.rb:67:in `each'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/commands/install_command.rb:67:in `execute'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/command.rb:136:in `invoke'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/command_manager.rb:104:in `process_args'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/command_manager.rb:74:in `run'
�������������� /home/stephens/local/ruby/trunk/lib/ruby/1.9.0/rubygems/gem_runner.rb:39:in `run'
�������������� /home/stephens/local/ruby/trunk/bin/gem:22:in `<main>'
INFO:�� `gem install -y` is now default and will be removed
INFO:�� use --ignore-dependencies to install only the gems you list
Bulk updating Gem source index for: http://gems.rubyforge.org
removing /tmp/open-uri20080201-15694-1ufzwvc-0...done
removing /tmp/open-uri20080201-15694-1n74qbf-0...done
removing /tmp/open-uri20080201-15694-1kb8qlc-0...done
removing /tmp/open-uri20080201-15694-iwkd4t-0...done
removing /tmp/open-uri20080201-15694-1j55r0r-0...done

I'll do a bit more digging.

http://kurtstephens.com