Some Rails update force you to upgrade RubyGems? Welcome to the pain (or not quite) of solving those small annoyances with RubyGems… at least on Windows
‘gem update –system’ is not really updating?
Sometimes RubyGems, like any software, get confused. Help him find it’s way. Becca Girl at ruby-talk found this problem (read it here).
I suggest that, if after a gem update you get some weird errors or the same old version when query for gem -v, don’t waste your time and proceed with the following:
- Download latest rubygems source package from here (zip format recommended).
- Extract the package contents somewhere (a new folder close to your root C:/ or D:/ will be a good option).
- Jump into the command line and disable RUBYOPT (
set RUBYOPT=) - cd into the folder you extracted RubyGems and run
ruby setup.rb install - Done!.
Now you should have the updated version of RubyGems (check with gem -v).
What about ‘rake.bat:24: undefined method’ errors or something like that?
If you updated from a release of RubyGems previous 0.9.4, you will see that some of your previous gems will show these problems, mostly due some deprecations and changes in the way batch files are generated.
An advice: sweep your gems!
- Remove offending gem:
gem uninstall rake - confirm removal of
rakeexecutable - Install gem again:
gem install rake
Starting from RubyGems 1.1 and enhanced in 1.2, perform updates and install of new gems is faster, so thank all the RubyGems team for making you have more tiem to actual coding instead of performing updates!
And what about mongrel?
Jumping form 0.9.4 to 1.1 version of RubyGems broke binaries of mongrel in Windows (as commented in previous post here)
At this time you should have no problems, but if still find them, don’t hesitate to search mongrel-users mailing list (using Ruby-Forum) to find or post if new issues.
Two in distress makes sorrow less
Even I know there is no consolation in saying that Windows users are not the only one facing problems with RubyGems, I can only conclude that no matter which OS is your preference, each one will have it’s own glitches that will make you love or hate your platform.
Anyway, enough for today.
PS: Are you ready for Rails Summit Latin America?
[...] Problems with RubyGems? Find here some handy tips [...]
I tryed to read a lot about’t but I still couldn’t fix this:
=> Booting Mongrel (use ’script/server webrick’ to force WEBrick)
=> Rails 2.1.0 application starting on http://0.0.0.0:3000
=> Call with -d to detach
=> Ctrl-C to shutdown server
Exiting
C:/Ruby18/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_
require’: no such file to load — win32/service (MissingSourceFile)
from C:/Ruby18/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `
require’
from C:/Ruby18/lib/ruby/gems/1.8/gems/activesupport-2.1.0/lib/active_sup
port/dependencies.rb:509:in `require’
from C:/Ruby18/lib/ruby/gems/1.8/gems/activesupport-2.1.0/lib/active_sup
port/dependencies.rb:354:in `new_constants_in’
from C:/Ruby18/lib/ruby/gems/1.8/gems/activesupport-2.1.0/lib/active_sup
port/dependencies.rb:509:in `require’
from C:/Ruby18/lib/ruby/gems/1.8/gems/mongrel_service-0.1/lib/mongrel_se
rvice/init.rb:5
from C:/Ruby18/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `
gem_original_require’
from C:/Ruby18/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `
require’
from C:/Ruby18/lib/ruby/gems/1.8/gems/activesupport-2.1.0/lib/active_sup
port/dependencies.rb:509:in `require’
… 17 levels…
from C:/Ruby18/lib/ruby/gems/1.8/gems/rails-2.1.0/lib/commands/server.rb
:39
from C:/Ruby18/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `
gem_original_require’
from C:/Ruby18/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `
require’
from script/server:3
please help
Thank You
I really don’t know what version of Mongrel are you using, but I cannot replicate your problem with any of my mongrel installations.
Looks your supplied @-d@ parameter, which is daemonize and is not supported on windows:
You should jump to mongrel-users mailing list and ask there with proper information about your environment.
RubyGems: With power comes responsibility…
Sounds like a movie, but should be applicable on every day work. I found that even you can trick RubyGems to do something, it doesn’t meant it is right. Please keep reading to understand my opinion.
more>The power behind—platform
Sin…
hi,
i’m using MacBook Pro OS X 10.6 Leopard. installed RubyOSX 1-click installer, (did not know Ruby was built in).
now i get the ff error:
Rails requires Rubygems >=1.3.2 (you have 1.3.1). Please ‘gem update –system’ and try again.
when i issue ‘gem update…’, i get ‘Nothing to update’.
because i’ve already got 1.3.5
can somebody please help me fix this problem.
thanks in advance, really appreciate it.