When I try to run rails server in debugger mode using "rails server --debugger". I am getting the following error on my console.
/home/navyug/.rvm/gems/ruby-1.9.3-p194#global/gems/rake-0.9.2.2/lib/rake/ext/module.rb:36:in `const_missing': uninitialized constant Debugger::LocalInterface::Readline (NameError)
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/ruby-debug19-0.11.6/cli/ruby-debug/interface.rb:55:in `block (2 levels) in initialize'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/ruby-debug19-0.11.6/cli/ruby-debug/interface.rb:53:in `each'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/ruby-debug19-0.11.6/cli/ruby-debug/interface.rb:53:in `block in initialize'
from /home/navyug/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/open-uri.rb:35:in `open'
from /home/navyug/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/open-uri.rb:35:in `open'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/ruby-debug19-0.11.6/cli/ruby-debug/interface.rb:52:in `initialize'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/ruby-debug19-0.11.6/cli/ruby-debug/processor.rb:61:in `new'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/ruby-debug19-0.11.6/cli/ruby-debug/processor.rb:61:in `initialize'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/ruby-debug19-0.11.6/cli/ruby-debug.rb:9:in `new'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/ruby-debug19-0.11.6/cli/ruby-debug.rb:9:in `<module:Debugger>'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/ruby-debug19-0.11.6/cli/ruby-debug.rb:8:in `<top (required)>'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.7/lib/rails/rack/debugger.rb:9:in `initialize'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/rack-1.4.1/lib/rack/server.rb:295:in `new'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/rack-1.4.1/lib/rack/server.rb:295:in `block in build_app'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/rack-1.4.1/lib/rack/server.rb:291:in `reverse_each'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/rack-1.4.1/lib/rack/server.rb:291:in `build_app'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/rack-1.4.1/lib/rack/server.rb:301:in `wrapped_app'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/rack-1.4.1/lib/rack/server.rb:252:in `start'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.7/lib/rails/commands/server.rb:70:in `start'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.7/lib/rails/commands.rb:55:in `block in <top (required)>'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.7/lib/rails/commands.rb:50:in `tap'
from /home/navyug/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.7/lib/rails/commands.rb:50:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
RubyGems Environment
RUBYGEMS VERSION: 1.8.24
RUBY VERSION: 1.9.3 (2012-04-20 patchlevel 194) [i686-linux]
INSTALLATION DIRECTORY: /home/navyug/.rvm/gems/ruby-1.9.3-p194
RUBY EXECUTABLE: /home/navyug/.rvm/rubies/ruby-1.9.3-p194/bin/ruby
EXECUTABLE DIRECTORY: /home/navyug/.rvm/gems/ruby-1.9.3-p194/bin
RUBYGEMS PLATFORMS:
ruby
x86-linux
GEM PATHS:
/home/navyug/.rvm/gems/ruby-1.9.3-p194
/home/navyug/.rvm/gems/ruby-1.9.3-p194#global
GEM CONFIGURATION:
:update_sources => true
:verbose => true
:benchmark => false
:backtrace => false
:bulk_threshold => 1000
REMOTE SOURCES:
http://rubygems.org/
I think the Readline package is missing in your setup. Since you are using RVM, try and install the readline package via rvm. These links might be helpful:
Previous similar SO question related to readline problem
Fixing Readline for the Ruby on Rails console
RVM package: Readline
Related
I am trying to install insoshi in Rails 3.2.21 with ruby 1.9.3 every thing gone good but now I am stopped with an error when I try $rake gems:install it gives an error
rake aborted!
LoadError: cannot load such file -- test/unit/error
C:/Sites/insoshi/vendor/rails/activesupport/lib/active_support/dependencies.rb:1
53:in `block in require'
C:/Sites/insoshi/vendor/rails/activesupport/lib/active_support/dependencies.rb:5
21:in `new_constants_in'
C:/Sites/insoshi/vendor/rails/activesupport/lib/active_support/dependencies.rb:1
53:in `require'
C:/Sites/insoshi/vendor/rails/activesupport/lib/active_support/deprecation.rb:22
4:in `<top (required)>'
C:/Sites/insoshi/vendor/rails/activesupport/lib/active_support/dependencies.rb:1
53:in `block in require'
C:/Sites/insoshi/vendor/rails/activesupport/lib/active_support/dependencies.rb:5
21:in `new_constants_in'
C:/Sites/insoshi/vendor/rails/activesupport/lib/active_support/dependencies.rb:1
53:in `require'
C:/Sites/insoshi/vendor/rails/activesupport/lib/active_support.rb:37:in `<top (r
equired)>'
C:/Sites/insoshi/vendor/rails/railties/lib/tasks/misc.rake:11:in `<top (required
)>'
C:/Sites/insoshi/vendor/rails/railties/lib/tasks/rails.rb:4:in `load'
C:/Sites/insoshi/vendor/rails/railties/lib/tasks/rails.rb:4:in `block in <top (r
equired)>'
C:/Sites/insoshi/vendor/rails/railties/lib/tasks/rails.rb:4:in `each'
C:/Sites/insoshi/vendor/rails/railties/lib/tasks/rails.rb:4:in `<top (required)>
'
C:/Sites/insoshi/Rakefile:10:in `<top (required)>'
(See full trace by running task with --trace)
I am totally new with rails. hope for help
Try adding following gem into your gem file
gem 'test-unit'
Hope it will solve your problem.
Ever since we updated to Rails 3.2.13 we've been unable to start the heroku rails console. The server is working just fine, but when we try to run the console, it gives the following error:
Loading production environment (Rails 3.2.13)
/app/vendor/bundle/ruby/1.9.1/gems/aws-s3-0.6.3/lib/aws/s3/extensions.rb:212:in `const_missing_from_s3_library': uninitialized constant IRB::ReadlineInputMethod::Readline (NameError)
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb/input-method.rb:113:in `gets'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb.rb:139:in `block (2 levels) in eval_input'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb.rb:273:in `signal_status'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb.rb:138:in `block in eval_input'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb/ruby-lex.rb:188:in `call'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb/ruby-lex.rb:188:in `buf_input'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb/ruby-lex.rb:103:in `getc'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb/slex.rb:205:in `match_io'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb/slex.rb:75:in `match'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb/ruby-lex.rb:286:in `token'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb/ruby-lex.rb:262:in `lex'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb/ruby-lex.rb:233:in `block (2 levels) in each_top_level_statement'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb/ruby-lex.rb:229:in `loop'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb/ruby-lex.rb:229:in `block in each_top_level_statement'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb/ruby-lex.rb:228:in `catch'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb/ruby-lex.rb:228:in `each_top_level_statement'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb.rb:155:in `eval_input'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb.rb:70:in `block in start'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb.rb:69:in `catch'
from /app/vendor/ruby-1.9.3/lib/ruby/1.9.1/irb.rb:69:in `start'
from /app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/commands/console.rb:47:in `start'
from /app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/commands/console.rb:8:in `start'
from /app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/commands.rb:41:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
What is going on? Thanks!
Just experienced this myself. As it turns out the rb-readline gem bumped a version that causes rails console, and other things to fail. Try locking it to '~> 0.4.2'.
gem 'rb-readline', '~> 0.4.2'
I am using ruby 1.8.7 and tried to upgrade the rails version from 3.0.7 to 3.2.11 for the existing application. I have installed all the relative gems and bundle install is also complete but when I start the rails server using rails s, Its showing me the errors.
rails s
=> Booting WEBrick
=> Rails 3.2.11 application starting in development on .....
=> Call with -d to detach
=> Ctrl-C to shutdown server
Exiting
/var/lib/gems/1.8/gems/activesupport-3.2.11/lib/active_support/dependencies.rb:251:in `require': no such file to load -- journey (LoadError)
from /var/lib/gems/1.8/gems/activesupport-3.2.11/lib/active_support/dependencies.rb:251:in `require'
from /var/lib/gems/1.8/gems/activesupport-3.2.11/lib/active_support/dependencies.rb:236:in `load_dependency'
from /var/lib/gems/1.8/gems/activesupport-3.2.11/lib/active_support/dependencies.rb:251:in `require'
from /var/lib/gems/1.8/gems/actionpack-3.2.11/lib/action_dispatch/routing/route_set.rb:1
from /var/lib/gems/1.8/gems/railties-3.2.11/lib/rails/engine.rb:489:in `routes'
from /var/lib/gems/1.8/gems/railties-3.2.11/lib/rails/engine.rb:551
from /var/lib/gems/1.8/gems/railties-3.2.11/lib/rails/initializable.rb:30:in `instance_exec'
from /var/lib/gems/1.8/gems/railties-3.2.11/lib/rails/initializable.rb:30:in `run'
from /var/lib/gems/1.8/gems/railties-3.2.11/lib/rails/initializable.rb:55:in `run_initializers'
from /var/lib/gems/1.8/gems/railties-3.2.11/lib/rails/initializable.rb:54:in `each'
from /var/lib/gems/1.8/gems/railties-3.2.11/lib/rails/initializable.rb:54:in `run_initializers'
from /var/lib/gems/1.8/gems/railties-3.2.11/lib/rails/application.rb:136:in `initialize!'
from /var/lib/gems/1.8/gems/railties-3.2.11/lib/rails/railtie/configurable.rb:30:in `send'
from /var/lib/gems/1.8/gems/railties-3.2.11/lib/rails/railtie/configurable.rb:30:in `method_missing'
from /home/anshul/herematch/config/environment.rb:5
from /var/lib/gems/1.8/gems/activesupport-3.2.11/lib/active_support/dependencies.rb:251:in `require'
from /var/lib/gems/1.8/gems/activesupport-3.2.11/lib/active_support/dependencies.rb:251:in `require'
from /var/lib/gems/1.8/gems/activesupport-3.2.11/lib/active_support/dependencies.rb:236:in `load_dependency'
from /var/lib/gems/1.8/gems/activesupport-3.2.11/lib/active_support/dependencies.rb:251:in `require'
from /home/anshul/herematch/config.ru:3
from /var/lib/gems/1.8/gems/rack-1.2.4/lib/rack/builder.rb:46:in `instance_eval'
from /var/lib/gems/1.8/gems/rack-1.2.4/lib/rack/builder.rb:46:in `initialize'
from /home/anshul/herematch/config.ru:1:in `new'
from /home/anshul/herematch/config.ru:1
Please help me!!!
It seems like I'm having the same issue as the person the OP for:
https://github.com/seyhunak/twitter-bootstrap-rails/issues/27
but I have not been able to fix it.
Doing a basic rails app like described in:
http://railscasts.com/episodes/328-twitter-bootstrap-basics
fails with trying to rails g bootstrap:install.
The base versions of r/r on my system are:
ruby v 1.9.2p320,
rails 3.1.0
on snow leopard 10.6.4
The way I can replicate on my local system:
rails new bsapp --skip-stylesheets
cd bsapp
rails g scaffold product name:string price:decimal --skip-stylesheets
add gem 'twitter-bootstrap-rails' to the assets group in gemfile.
bundle update
rails g bootstrap:install
This is where the problem is.
Hayk-Saakians-Mac:bsapp hayk$ rails g bootstrap:install
/Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/less-2.2.1/lib/less/java_script/v8_context.rb:61:in `rescue in lock': uninitialized constant V8::JSError (NameError)
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/less-2.2.1/lib/less/java_script/v8_context.rb:60:in `lock'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/less-2.2.1/lib/less/java_script/v8_context.rb:19:in `initialize'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/less-2.2.1/lib/less/java_script/v8_context.rb:15:in `new'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/less-2.2.1/lib/less/java_script/v8_context.rb:15:in `instance'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/less-2.2.1/lib/less/loader.rb:10:in `initialize'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/less-2.2.1/lib/less.rb:14:in `new'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/less-2.2.1/lib/less.rb:14:in `<module:Less>'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/less-2.2.1/lib/less.rb:9:in `<top (required)>'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/less-rails-2.2.3/lib/less/rails.rb:6:in `require'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/less-rails-2.2.3/lib/less/rails.rb:6:in `<top (required)>'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/less-rails-2.2.3/lib/less-rails.rb:1:in `require'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/less-rails-2.2.3/lib/less-rails.rb:1:in `<top (required)>'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/twitter-bootstrap-rails-2.1.3/lib/twitter-bootstrap-rails.rb:9:in `require'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/twitter-bootstrap-rails-2.1.3/lib/twitter-bootstrap-rails.rb:9:in `<top (required)>'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320#global/gems/bundler-1.2.0/lib/bundler/runtime.rb:68:in `require'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320#global/gems/bundler-1.2.0/lib/bundler/runtime.rb:68:in `block (2 levels) in require'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320#global/gems/bundler-1.2.0/lib/bundler/runtime.rb:66:in `each'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320#global/gems/bundler-1.2.0/lib/bundler/runtime.rb:66:in `block in require'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320#global/gems/bundler-1.2.0/lib/bundler/runtime.rb:55:in `each'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320#global/gems/bundler-1.2.0/lib/bundler/runtime.rb:55:in `require'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320#global/gems/bundler-1.2.0/lib/bundler.rb:128:in `require'
from /Users/hayk/ror/bsapp/config/application.rb:7:in `<top (required)>'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/railties-3.1.0/lib/rails/commands.rb:21:in `require'
from /Users/hayk/.rvm/gems/ruby-1.9.2-p320/gems/railties-3.1.0/lib/rails/commands.rb:21:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
Hayk-Saakians-Mac:bsapp hayk$
full source: http://pastebin.com/nXBcq2bB
The root of the problem was a bad/old/nonexistent installation of v8/therubyracer/libv8
Certain versions of the libv8 gem just straight up failed to install, and the ones that did -- they took several hours, so I assumed they were hanging/crashing (I am working with a netbook, so that could be expected).
At the moment, the following configuration works for me:
gem "libv8", "3.11.8.13"
gem "therubyracer", :require => 'v8'
gem "less-rails"
gem "twitter-bootstrap-rails"
in development, and in production (heroku)
There was a github issue on either rubyracer or libv8 related to this that mentioned issues with x86/32bit processors -- i don't remember it offhand.
rvm 1.14.5, rvm-capistrano (1.2.2) and capistrano (2.12.0)
My Gemfile is :
group :development, :test do
gem 'rvm-capistrano'
gem 'capistrano'
end
When I try to start passenger, I keep seeing this error :
[ pid=4691 thr=76294140 file=utils.rb:176 time=2012-07-04 11:37:06.179 ]: *** Exception NameError in PhusionPassenger::Rack::ApplicationSpawner (uninitialized constant Capistrano) (process 4691, thread #<Thread:0x9184ff8>):
from /home/ved/.rvm/gems/ruby-1.9.3-p194/gems/rvm-capistrano-1.2.2/lib/rvm/capistrano.rb:3:in `<top (required)>'
from /home/ved/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/runtime.rb:74:in `require'
from /home/ved/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/runtime.rb:74:in `rescue in block in require'
from /home/ved/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/runtime.rb:62:in `block in require'
from /home/ved/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/runtime.rb:55:in `each'
from /home/ved/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/runtime.rb:55:in `require'
from /home/ved/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler.rb:119:in `require'
from /home/ved/rails_projects/grabber/config/application.rb:12:in `<top (required)>'
from /home/ved/rails_projects/grabber/config/environment.rb:3:in `require'
from /home/ved/rails_projects/grabber/config/environment.rb:3:in `<top (required)>'
from config.ru:3:in `require'
from config.ru:3:in `block in <main>'
Just taking a stab here, but make sure that you are excluding the development and test group when your bundle is installed.
bundle install --without test development
It sounds like for some reason your application is trying to load rvm-capistrano.