Is the “rails” command for generating apps actually producing the code with require_gem? Has it not been patched so that RubyGems < 0.9.1 will still work? Other wise…
Is the "rails" command for generating apps actually producing the code with
require_gem? Has it not been patched so that RubyGems < 0.9.1 will still
work? Other wise...
I just ran rake rails:update (per my other post, and thaaanks for
teeelling me about it, guys!), and it fixed my gem() calls by
upgrading them to require_gem().
Steve Longdo wrote:
> Is the "rails" command for generating apps actually producing the code with
> require_gem? Has it not been patched so that RubyGems < 0.9.1 will still
> work? Other wise...
$ script/about
./script/../config/boot.rb:29:Warning: require_gem is obsolete. Use
gem instead.
About your application's environment
Ruby version 1.8.5 (powerpc-darwin8.8.0)
RubyGems version 0.9.1
Rails version 1.2.1
...
The above is from a MacPorts-installed rails. Locomotive has the same issue:
$ script/about
./script/../config/boot.rb:29:Warning: require_gem is obsolete. Use
gem instead.
About your application's environment
Ruby version 1.8.5 (powerpc-darwin7.9.0)
RubyGems version 0.9.1
Rails version 1.2.1
...
> I just ran rake rails:update (per my other post, and thaaanks for
> teeelling me about it, guys!), and it fixed my gem() calls by
> upgrading them to require_gem().
Shouldn't that be the other way 'round?
That was my insinuation. I fixed things manually, like y'all are
discussing, then I ran rails:update, and it un-fixed them.
The base generator is generating the noisily deprecated version.
Oooh, lookie here:
phlip@penbird:~/projects/scratch$ public/dispatch.rb
./public/../config/boot.rb:29:Warning: require_gem is obsolete. Use
gem instead.
Status: 400 Bad Request
/usr/lib/ruby/gems/1.8/gems/activesupport-1.4.0/lib/active_support/dependencies.rb:405:in
`to_constant_name': Anonymous modules ha
ve no name to be referenced by (ArgumentError)
from /usr/lib/ruby/gems/1.8/gems/activesupport-1.4.0/lib/active_support/dependencies.rb:215:in
`qualified_name_for'
from /usr/lib/ruby/gems/1.8/gems/activesupport-1.4.0/lib/active_support/dependencies.rb:477:in
`const_missing'
from /usr/lib/ruby/gems/1.8/gems/rails-1.2.1/lib/dispatcher.rb:117:in
`reset_after_dispatch'
from /usr/lib/ruby/gems/1.8/gems/rails-1.2.1/lib/dispatcher.rb:51:in
`dispatch'
from public/dispatch.rb:10
A brand-new Rails program has the bug that I'm stuck on, as mentioned
in my other post.