Unable to install rack gem

R

Robert Stackhouse

I have been trying to install the twitter gem on Ubuntu and have been
unable to do so. Rack and Thin are both dependencies of the twitter gem
and there seems to be a circular dependency between rack and thin. When
I try to install rack I get:

(e-mail address removed):~$ gem install rack
Bulk updating Gem source index for: http://gems.rubyforge.org
ERROR: While executing gem ... (Gem::GemNotFoundException)
Could not find rack (> 0) in any repository
rstackhouse@rstackhouse:~$ sudo gem install rack
[sudo] password for user:
Need to update 36 gems from http://gems.rubyforge.org
....................................
complete
Install required dependency thin? [Yn] Y
Select which gem to install for your platform (x86_64-linux)
1. thin 1.2.1 (i386-mswin32)
2. thin 1.2.1 (ruby)
3. thin 1.0.0 (ruby)
4. thin 1.0.0 (i386-mswin32)
5. Skip this gem
6. Cancel installation
Install required dependency rack? [Yn]



I get the following if I try to install thin:

rstackhouse@rstackhouse:~$ sudo gem install thin
Select which gem to install for your platform (x86_64-linux)
1. thin 1.2.1 (i386-mswin32)
2. thin 1.2.1 (ruby)
3. thin 1.0.0 (ruby)
4. thin 1.0.0 (i386-mswin32)
5. Skip this gem
6. Cancel installation
Install required dependency rack? [Yn] Y
Install required dependency thin? [Yn]



So it seems pretty obvious to me that there is a circular dependency
between these two gems. Can anyone help me resolve this problem?
 
H

Hassan Schroeder

So it seems pretty obvious to me that there is a circular dependency
between these two gems.

Uh, well --

[hassan@sailboat ~]$ sudo gem install rack
Successfully installed rack-1.0.0
1 gem installed
Installing ri documentation for rack-1.0.0...
Installing RDoc documentation for rack-1.0.0...
[hassan@sailboat ~]$ sudo gem install thin
Building native extensions. This could take a while...
Building native extensions. This could take a while...
Successfully installed eventmachine-0.12.6
Successfully installed thin-1.2.1
2 gems installed
Installing ri documentation for eventmachine-0.12.6...
Installing ri documentation for thin-1.2.1...
Installing RDoc documentation for eventmachine-0.12.6...
Installing RDoc documentation for thin-1.2.1...
[hassan@sailboat ~]$

(on a RHEL VM, not Ubuntu, but shouldn't matter...)

What version of ruby and rubygems are you running? This was on:
[hassan@sailboat ~]$ gem env
RubyGems Environment:
- RUBYGEMS VERSION: 1.3.1
- RUBY VERSION: 1.8.7 (2009-02-16 patchlevel 5000) [i686-linux]

FWIW,
 
R

Robert Stackhouse

Hassan said:
So it seems pretty obvious to me that there is a circular dependency
between these two gems.

Uh, well --

[hassan@sailboat ~]$ sudo gem install rack
Successfully installed rack-1.0.0
1 gem installed
Installing ri documentation for rack-1.0.0...
Installing RDoc documentation for rack-1.0.0...
[hassan@sailboat ~]$ sudo gem install thin
Building native extensions. This could take a while...
Building native extensions. This could take a while...
Successfully installed eventmachine-0.12.6
Successfully installed thin-1.2.1
2 gems installed
Installing ri documentation for eventmachine-0.12.6...
Installing ri documentation for thin-1.2.1...
Installing RDoc documentation for eventmachine-0.12.6...
Installing RDoc documentation for thin-1.2.1...
[hassan@sailboat ~]$

(on a RHEL VM, not Ubuntu, but shouldn't matter...)

What version of ruby and rubygems are you running? This was on:
[hassan@sailboat ~]$ gem env
RubyGems Environment:
- RUBYGEMS VERSION: 1.3.1
- RUBY VERSION: 1.8.7 (2009-02-16 patchlevel 5000) [i686-linux]

FWIW,

I am running:

(e-mail address removed):~$ gem env
RubyGems Environment:
- VERSION: 0.9.4 (0.9.4)
- INSTALLATION DIRECTORY: /var/lib/gems/1.8
- GEM PATH:
- /var/lib/gems/1.8
- REMOTE SOURCES:
- http://gems.rubyforge.org
(e-mail address removed):~$ ruby --version
ruby 1.8.6 (2007-09-24 patchlevel 111) [x86_64-linux]

Looks like I am running a much older version of rubygems than you are
Hassan. Where/how could I get a more recent version?
 
U

Urban Hafner

Robert said:
Looks like I am running a much older version of rubygems than you are
Hassan. Where/how could I get a more recent version?

gem update --system

Urban
 
R

Robert Stackhouse

Urban said:
gem update --system

Urban

I tried "gem update --system" then I got:

(e-mail address removed):~/rubygems-1.3.3$ gem ver
/usr/bin/gem:10: undefined method `manage_gems' for Gem:Module
(NoMethodError)


So I googled around and was lead to this page:
http://www.jaredlog.com/?p=1045&dsq=9540882. I tried his approach and
got the same error message as above.

Anyone got any ideas?
 
J

Julian Leviston

I tried "gem update --system" then I got:

(e-mail address removed):~/rubygems-1.3.3$ gem ver
/usr/bin/gem:10: undefined method `manage_gems' for Gem:Module
(NoMethodError)


So I googled around and was lead to this page:
http://www.jaredlog.com/?p=1045&dsq=9540882. I tried his approach and
got the same error message as above.

Anyone got any ideas?

Perhaps you need to upgrade by manually installing. Which version of
gem do you have?

Blog: http://random8.zenunit.com/
Twitter: http://twitter.com/random8r
Learn: http://sensei.zenunit.com/
New video up now at http://sensei.zenunit.com/ real fastcgi rails
deploy process! Check it out now!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,012
Latest member
RoxanneDzm

Latest Threads

Top