David Winter | 19 Jan 11:48

Rails/Gem errors?


Is anyone else getting annoying warning messages?

/usr/local/bin/rails:17:Warning: require_gem is obsolete.  Use gem
instead.

I get these messages when using the rails command, rake, script/generate
etc etc.

I'm using Rails 1.2.1

--

-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@...
To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe@...
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Alan Francis | 19 Jan 11:56

Re: Rails/Gem errors?


David Winter wrote:
> Is anyone else getting annoying warning messages?
> 
> /usr/local/bin/rails:17:Warning: require_gem is obsolete.  Use gem
> instead.
> 
> I get these messages when using the rails command, rake, script/generate
> etc etc.
> 
> I'm using Rails 1.2.1

You can fix it in environment.rb.  Find the 'require_gem' lines and 
replace them with 'gem'

--

-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@...
To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe@...
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

David Winter | 19 Jan 16:32

Re: Rails/Gem errors?


Alan Francis wrote:
> David Winter wrote:
>> Is anyone else getting annoying warning messages?
>> 
>> /usr/local/bin/rails:17:Warning: require_gem is obsolete.  Use gem
>> instead.
>> 
>> I get these messages when using the rails command, rake, script/generate
>> etc etc.
>> 
>> I'm using Rails 1.2.1
> 
> You can fix it in environment.rb.  Find the 'require_gem' lines and 
> replace them with 'gem'

Actually, do:

    gem pristine --all

From: http://comments.gmane.org/gmane.comp.lang.ruby.rails/117220

--

-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@...
To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe@...
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en
(Continue reading)

Alan Francis | 19 Jan 16:54

Re: Rails/Gem errors?


David Winter wrote:
> Alan Francis wrote:

>> You can fix it in environment.rb.  Find the 'require_gem' lines and 
>> replace them with 'gem'
> 
> Actually, do:
> 
>     gem pristine --all
> 
> From: http://comments.gmane.org/gmane.comp.lang.ruby.rails/117220

I don't think that'll work. I did it on my machine immediatly I upgraded 
gems, and *still* had to fix my rails app.

I got the impression it only fixed the binstubs - 'rails', 'rake', 'cap' 
etc  I dont think it'll search out uses of require_gem in rb files on 
your machine ?

A.

--

-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@...
To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe@...
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en
(Continue reading)

David Winter | 19 Jan 16:59

Re: Rails/Gem errors?


Alan Francis wrote:
> David Winter wrote:
>> Alan Francis wrote:
> 
>>> You can fix it in environment.rb.  Find the 'require_gem' lines and 
>>> replace them with 'gem'
>> 
>> Actually, do:
>> 
>>     gem pristine --all
>> 
>> From: http://comments.gmane.org/gmane.comp.lang.ruby.rails/117220
> 
> I don't think that'll work. I did it on my machine immediatly I upgraded 
> gems, and *still* had to fix my rails app.
> 
> I got the impression it only fixed the binstubs - 'rails', 'rake', 'cap' 
> etc  I dont think it'll search out uses of require_gem in rb files on 
> your machine ?
> 
> A.

You're right. The moment I saw it, I thought it was the 'official' fix. 
I was wrong. Doing a `rake db:migrate` produces the warning. Very 
irritating.

--

-- 
Posted via http://www.ruby-forum.com/.

(Continue reading)

David Winter | 19 Jan 17:01

Re: Rails/Gem errors?


Here's the ticket for it:

http://dev.rubyonrails.org/ticket/6886

I hope it'll get fixed soon. It's very off-putting seeing that warning 
each time doing something.

--

-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@...
To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe@...
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Anonymous Coward | 19 Jan 17:09

Re: Rails/Gem errors?


David Winter wrote:
> Here's the ticket for it:
> 
> http://dev.rubyonrails.org/ticket/6886
> 
> I hope it'll get fixed soon. It's very off-putting seeing that warning 
> each time doing something.

You can fix it by editing your environment.rb as described earlier in 
the thread.

A.

--

-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@...
To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe@...
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

David Winter | 19 Jan 18:04

Re: Rails/Gem errors?


Anonymous Coward wrote:
> David Winter wrote:
>> Here's the ticket for it:
>> 
>> http://dev.rubyonrails.org/ticket/6886
>> 
>> I hope it'll get fixed soon. It's very off-putting seeing that warning 
>> each time doing something.
> 
> You can fix it by editing your environment.rb as described earlier in 
> the thread.
> 
> A.

boot.rb contains the `require_gem` piece of code.

--

-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@...
To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe@...
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

askegg | 19 Jan 12:28

Re: Rails/Gem errors?


David Winter wrote:
> Is anyone else getting annoying warning messages?
> 
> /usr/local/bin/rails:17:Warning: require_gem is obsolete.  Use gem
> instead.
> 
> I get these messages when using the rails command, rake, script/generate
> etc etc.
> 
> I'm using Rails 1.2.1

This has more to do with the new rubygems than rails - new versions of 
everything seem to be coming out at once!

--

-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@...
To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe@...
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Craig White | 20 Jan 05:26

Re: Rails/Gem errors?


On Fri, 2007-01-19 at 12:28 +0100, askegg wrote:
> David Winter wrote:
> > Is anyone else getting annoying warning messages?
> > 
> > /usr/local/bin/rails:17:Warning: require_gem is obsolete.  Use gem
> > instead.
> > 
> > I get these messages when using the rails command, rake, script/generate
> > etc etc.
> > 
> > I'm using Rails 1.2.1
> 
> This has more to do with the new rubygems than rails - new versions of 
> everything seem to be coming out at once!
----
ok, I updated to 0.9.1 and now...

# gem pristine --all
Restoring gem(s) to pristine condition...
Rebuilt all bin stubs
All installed gem files are already in pristine condition
# gem check
# gem update
Updating installed gems...
ERROR:  While executing gem ... (NoMethodError)
    undefined method `refresh' for #<Hash:0xb7d212cc>

ugh... anyone know how to fix this?

(Continue reading)

David Winter | 20 Jan 10:24

Re: Rails/Gem errors?


Craig White wrote:
> On Fri, 2007-01-19 at 12:28 +0100, askegg wrote:
>> 
>> This has more to do with the new rubygems than rails - new versions of 
>> everything seem to be coming out at once!
> ----
> ok, I updated to 0.9.1 and now...
> 
> # gem pristine --all
> Restoring gem(s) to pristine condition...
> Rebuilt all bin stubs
> All installed gem files are already in pristine condition
> # gem check
> # gem update
> Updating installed gems...
> ERROR:  While executing gem ... (NoMethodError)
>     undefined method `refresh' for #<Hash:0xb7d212cc>
> 
> ugh... anyone know how to fix this?
> 
> Craig

I'm pretty sure you want to do

    sudo gem update

--

-- 
Posted via http://www.ruby-forum.com/.

(Continue reading)

Craig White | 20 Jan 18:34

Re: Rails/Gem errors?


On Sat, 2007-01-20 at 10:24 +0100, David Winter wrote:
> Craig White wrote:
> > On Fri, 2007-01-19 at 12:28 +0100, askegg wrote:
> >> 
> >> This has more to do with the new rubygems than rails - new versions of 
> >> everything seem to be coming out at once!
> > ----
> > ok, I updated to 0.9.1 and now...
> > 
> > # gem pristine --all
> > Restoring gem(s) to pristine condition...
> > Rebuilt all bin stubs
> > All installed gem files are already in pristine condition
> > # gem check
> > # gem update
> > Updating installed gems...
> > ERROR:  While executing gem ... (NoMethodError)
> >     undefined method `refresh' for #<Hash:0xb7d212cc>
> > 
> > ugh... anyone know how to fix this?
> > 
> > Craig
> 
> I'm pretty sure you want to do
> 
>     sudo gem update
----
been there and done that...

(Continue reading)

Craig White | 21 Jan 07:20

Re: Rails/Gem errors?


On Sat, 2007-01-20 at 10:24 +0100, David Winter wrote:
> Craig White wrote:
> > On Fri, 2007-01-19 at 12:28 +0100, askegg wrote:
> >> 
> >> This has more to do with the new rubygems than rails - new versions of 
> >> everything seem to be coming out at once!
> > ----
> > ok, I updated to 0.9.1 and now...
> > 
> > # gem pristine --all
> > Restoring gem(s) to pristine condition...
> > Rebuilt all bin stubs
> > All installed gem files are already in pristine condition
> > # gem check
> > # gem update
> > Updating installed gems...
> > ERROR:  While executing gem ... (NoMethodError)
> >     undefined method `refresh' for #<Hash:0xb7d212cc>
> > 
> > ugh... anyone know how to fix this?
> > 
> > Craig
> 
> I'm pretty sure you want to do
> 
>     sudo gem update
----
I'm pretty sure that I am not alone with this problem since upgrading to
gem 0.9.1
(Continue reading)

Guillermo Marcus | 27 Jan 14:33

Re: Rails/Gem errors?


Craig White wrote:
> On Sat, 2007-01-20 at 10:24 +0100, David Winter wrote:
>> > Rebuilt all bin stubs
>> 
>> I'm pretty sure you want to do
>> 
>>     sudo gem update
> ----
> I'm pretty sure that I am not alone with this problem since upgrading to
> gem 0.9.1
> 
> https://rubyforge.org/tracker/index.php?func=detail&aid=7995&group_id=126&atid=575
> 
> Craig

Removing

/usr/local/lib/ruby/gems/1.8/source_cache

solved the problem for me.

Guillermo

--

-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@...
(Continue reading)

Craig White | 27 Jan 18:43

Re: Rails/Gem errors?


On Sat, 2007-01-27 at 14:33 +0100, Guillermo Marcus wrote:
> Craig White wrote:
> > On Sat, 2007-01-20 at 10:24 +0100, David Winter wrote:
> >> > Rebuilt all bin stubs
> >> 
> >> I'm pretty sure you want to do
> >> 
> >>     sudo gem update
> > ----
> > I'm pretty sure that I am not alone with this problem since upgrading to
> > gem 0.9.1
> > 
> > https://rubyforge.org/tracker/index.php?func=detail&aid=7995&group_id=126&atid=575
> > 
> > Craig
> 
> Removing
> 
> /usr/local/lib/ruby/gems/1.8/source_cache
> 
> solved the problem for me.
----
yeah - it solved it for me too - thanks

Craig

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@...
(Continue reading)


Gmane