[Rubygems-developers] [ rubygems-Bugs-27346 ] gem cleanup fails on system wide installed gems with non informative error message

noreply at rubyforge.org noreply at rubyforge.org
Tue Oct 27 18:44:58 EDT 2009


Bugs item #27346, was opened at 2009-10-25 16:55
You can respond by visiting: 
http://rubyforge.org/tracker/?func=detail&atid=575&aid=27346&group_id=126

Category: `gem` commands (other)
Group: None
>Status: Closed
>Resolution: Accepted
Priority: 3
Submitted By: Martin Häcker (dwt)
Assigned to: Nobody (None)
Summary: gem cleanup fails on system wide installed gems with non informative error message

Initial Comment:
Hi there,

I use gem to install stuff in my home directory and today found out that gem cleanup could get me rid of quite a part of old gems.

This however didn't work, as those are installed system wide and I of course don't start gem with root privileges as I totally want it to install only in my home directory.

The error message didn't mention this rights problem and the installed path at all, so I had to search very long till I found out why this failed.

So, please improve the error message, make it state that rights are missing and on what file they are missing.

Regards,
Martin

% gem env
RubyGems Environment:
  - RUBYGEMS VERSION: 1.3.1
  - RUBY VERSION: 1.8.7 (2008-08-11 patchlevel 72) [universal-darwin10.0]
  - INSTALLATION DIRECTORY: /Users/dwt/Library/Ruby/Gems/1.8
  - RUBY EXECUTABLE: /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
  - EXECUTABLE DIRECTORY: /Users/dwt/Library/Ruby/Gems/1.8/bin
  - RUBYGEMS PLATFORMS:
    - ruby
    - universal-darwin-10
  - GEM PATHS:
     - /Users/dwt/Library/Ruby/Gems/1.8
     - /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/gems/1.8
     - /Library/Ruby/Gems/1.8
  - GEM CONFIGURATION:
     - :update_sources => true
     - :verbose => true
     - :benchmark => false
     - :backtrace => false
     - :bulk_threshold => 1000
     - "gempath" => ["/Users/dwt/Library/Ruby/Gems/1.8", "/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/gems/1.8", "/Library/Ruby/Gems/1.8"]
     - "gemhome" => "/Users/dwt/Library/Ruby/Gems/1.8"
  - REMOTE SOURCES:
     - http://gems.rubyforge.org/


----------------------------------------------------------------------

>Comment By: Martin Häcker (dwt)
Date: 2009-10-27 23:44

Message:
Indeed the new error message is quite good.

Strange, I was under the impression that I did do "gem update --system" 
before reporting this - but apparently I missed it.

Thanks for the reply and keep up the good work.

Regards,
Martin

----------------------------------------------------------------------

Comment By: Luis Lavena (luislavena)
Date: 2009-10-25 19:05

Message:
Hello,

Thank you for your report.

Please try updating your RubyGems installation to 1.3.5:

sudo gem update --system

Since several improvements in gem cleanup has been implemented in 1.3.3, which is greater than the version you're reporting from.

Once you do that, try recreate the same scenario and report back the output of the clenaup command with "--debug -V".

Thank you.

----------------------------------------------------------------------

You can respond by visiting: 
http://rubyforge.org/tracker/?func=detail&atid=575&aid=27346&group_id=126


More information about the Rubygems-developers mailing list