Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

RDoc uninitialized constant error rails 2.3.12

Posted on 2011-09-07
7
Medium Priority
?
804 Views
Last Modified: 2012-05-12
still troubleshooting:

[21:51:46]kevin[ndthub]$ rake -T
rake aborted!
uninitialized constant RDoc

*** LOCAL GEMS ***

actionmailer (2.3.12, 2.3.11)
actionpack (2.3.12, 2.3.11)
activerecord (2.3.12, 2.3.11)
activeresource (2.3.12, 2.3.11)
activesupport (2.3.12, 2.3.11)
babosa (0.3.5)
builder (3.0.0)
bundler (1.0.18)
hoptoad_notifier (2.4.11)
multi_json (1.0.3)
rack (1.1.2)
rails (2.3.12, 2.3.11)
rake (0.9.2, 0.9.0)
rdoc (3.9.4, 2.5.11, 2.4.3)
rdoc-data (2.5.3)
sqlite3 (1.3.4)

[21:54:01]kevin[ndthub]$ rvm gemset list

gemsets for ruby-1.8.7-p352 (found in /Users/kevin/.rvm/gems/ruby-1.8.7-p352)
   global
=> rails2
0
Comment
Question by:depassion
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
7 Comments
 
LVL 12

Accepted Solution

by:
JESii earned 2000 total points
ID: 36498832
this is a known problem with Rails 2.3.12 and rake...

see https://github.com/rails/rails/issues/1551 for the bug report and discussion of various work-arounds.
0
 

Author Comment

by:depassion
ID: 36503643
that solution didn't work for me

#Gemfile
gem "rails", "2.3.12"
gem "rdoc"
gem "rake", "0.8.7"

#Rakefile
require 'rake'
require 'rake/testtask'
require 'tasks/rails'
require 'rdoc/task'
0
 

Author Comment

by:depassion
ID: 36505686
21:36:56]kevin[ndthub]$ rake --trace
rake aborted!
uninitialized constant RDoc
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@global/gems/rake-0.9.2/lib/rake/ext/module.rb:36:in `const_missing'
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@rails2/gems/rails-2.3.12/lib/tasks/documentation.rake:3
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@global/gems/rake-0.9.2/lib/rake/task_manager.rb:207:in `in_namespace'
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@global/gems/rake-0.9.2/lib/rake/dsl_definition.rb:95:in `namespace'
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@rails2/gems/rails-2.3.12/lib/tasks/documentation.rake:1
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@rails2/gems/rails-2.3.12/lib/tasks/rails.rb:4:in `load'
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@rails2/gems/rails-2.3.12/lib/tasks/rails.rb:4
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@rails2/gems/rails-2.3.12/lib/tasks/rails.rb:4:in `each'
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@rails2/gems/rails-2.3.12/lib/tasks/rails.rb:4
/Users/kevin/projects/ndthub/Rakefile:8:in `require'
/Users/kevin/projects/ndthub/Rakefile:8
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@global/gems/rake-0.9.2/lib/rake/rake_module.rb:25:in `load'
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@global/gems/rake-0.9.2/lib/rake/rake_module.rb:25:in `load_rakefile'
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@global/gems/rake-0.9.2/lib/rake/application.rb:495:in `raw_load_rakefile'
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@global/gems/rake-0.9.2/lib/rake/application.rb:78:in `load_rakefile'
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@global/gems/rake-0.9.2/lib/rake/application.rb:129:in `standard_exception_handling'
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@global/gems/rake-0.9.2/lib/rake/application.rb:77:in `load_rakefile'
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@global/gems/rake-0.9.2/lib/rake/application.rb:61:in `run'
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@global/gems/rake-0.9.2/lib/rake/application.rb:129:in `standard_exception_handling'
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@global/gems/rake-0.9.2/lib/rake/application.rb:59:in `run'
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@global/gems/rake-0.9.2/bin/rake:32
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@rails2/bin/rake:19:in `load'
/Users/kevin/.rvm/gems/ruby-1.8.7-p352@rails2/bin/rake:19
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 12

Expert Comment

by:JESii
ID: 36510212
OK; check out the comments on this post
     http://weblog.rubyonrails.org/2011/6/8/ann-rails-2-3-12-has-been-released
It mentions some changes to your rakefile.

There's also this suggestion:
     "It [dependency on the rdoc gem] is a shadow dependency that breaks functionality out of the box. Since it isn't required by core rails but only in the Rakefiles, I got away with "gem 'rdoc', :require => nil" in my Gemfile."
in this commit (https://github.com/rails/rails/commit/79aa54d0c781ea518e09d62c48e70d2d5619fe33) which is apparently the one that caused the breakage.

If that doesn't work, you might consider falling back to 2.3.11... or even upgrading to 3.0.x? (I'm still not on Rails 3.1 as it has a major change in asset (javascript, css, ...) handling)
0
 

Assisted Solution

by:depassion
depassion earned 0 total points
ID: 36510229
actually the problem was in my Rakefile:

#Rakefile
require(File.join(File.dirname(__FILE__), 'config', 'boot'))
require 'rake'
require 'rake/testtask'
require 'tasks/rails'
require 'rdoc/task'

the last two lines needed to be swapped around so :

require(File.join(File.dirname(__FILE__), 'config', 'boot'))
require 'rake'
require 'rake/testtask'
require 'rdoc/task'
require 'tasks/rails'




0
 

Author Closing Comment

by:depassion
ID: 36534639
combination of advice on different sites
0
 
LVL 12

Expert Comment

by:JESii
ID: 36510553
I also noticed that Rails 2.3.14 was released recently
   http://weblog.rubyonrails.org/2011/8/16/ann-rails-2-3-14
and I see that it mentions a fix for "RDoc task errors" which might apply in your case.
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I recently rediscovered rails when I needed a holiday project and decided to build a management dashboard for the company where I work.  With it being a project done in my free time, I could focus my time on learning the basics rather than trying to…
Article by: narshlob
If you've ever programmed in Ruby and have come across either a proc or a lambda, you might have been wondering what the difference is between the two and when you would use one over the other. This article will try to explain the difference between…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
How to fix incompatible JVM issue while installing Eclipse While installing Eclipse in windows, got one error like above and unable to proceed with the installation. This video describes how to successfully install Eclipse. How to solve incompa…
Suggested Courses

609 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question