Reputation: 506
When I'm trying to run debugger on Rails application (2.1.3) in Ruby Mine I get the following error:
> /home/vladimirn/.rvm/rubies/ruby-2.1.3/bin/ruby /home/vladimirn/.rvm/gems/ruby-2.1.3/gems/ruby-debug-ide-0.4.23.beta1/bin/rdebug-ide --disable-int-handler --port 38013 --dispatcher-port 33518 -- /home/vladimirn/Dev/Projects/untitled/bin/rails server -b 0.0.0.0 -p 3000 -e development
/home/vladimirn/.rvm/rubies/ruby-2.1.3/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:54:in `require': cannot load such file -- debase_internals (LoadError)
from /home/vladimirn/.rvm/rubies/ruby-2.1.3/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:54:in `require'
from /home/vladimirn/.rvm/gems/ruby-2.1.3/gems/debase-0.0.9/lib/debase.rb:4:in `<top (required)>'
from /home/vladimirn/.rvm/rubies/ruby-2.1.3/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:54:in `require'
from /home/vladimirn/.rvm/rubies/ruby-2.1.3/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:54:in `require'
from /home/vladimirn/.rvm/gems/ruby-2.1.3/gems/ruby-debug-ide-0.4.23.beta1/lib/ruby-debug-ide.rb:8:in `<top (required)>'
from /home/vladimirn/.rvm/gems/ruby-2.1.3/gems/ruby-debug-ide-0.4.23.beta1/bin/rdebug-ide:8:in `require_relative'
from /home/vladimirn/.rvm/gems/ruby-2.1.3/gems/ruby-debug-ide-0.4.23.beta1/bin/rdebug-ide:8:in `<main>'
Process finished with exit code 1
It looks like the problem is with debase gem. When I'm trying to remove it and reinstall with RubyMine i get the following:
> error running Development: untitled: Failed to Install Gems. Following gems were not installed: /home/vladimirn/Dev/RubyMine-6.3.3/rb/gems/debase-0.0.9.gem: Error installing debase-0.0.9.gem: ERROR: Failed to build gem native extension. /home/vladimirn/.rvm/rubies/ruby-2.1.3/bin/ruby -r ./siteconf20141004-13252-i5wsfb.rb extconf.rb checking for vm_core.h... no checking for vm_core.h... no Makefile creation failed ************************************************************************** No source for ruby-2.1.3-p242 provided with debugger-ruby_core_source gem. ************************************************************************** *** extconf.rb failed *** Could not create Makefile due to some reason, probably lack of necessary libraries and/or headers. Check the mkmf.log file for more details. You may need configuration options. Provided configuration options: --with-opt-dir --without-opt-dir --with-opt-include --without-opt-include=${opt-dir}/include --with-opt-lib --without-opt-lib=${opt-dir}/lib --with-make-prog --without-make-prog --srcdir=. --curdir --ruby=/home/vladimirn/.rvm/rubies/ruby-2.1.3/bin/ruby --with-ruby-dir --without-ruby-dir --with-ruby-include=${ruby-dir}/include --with-ruby-lib --without-ruby-lib=${ruby-dir}/lib extconf failed, exit code 1 Gem files will remain installed in /home/vladimirn/.rvm/gems/ruby-2.1.3/gems/debase-0.0.9 for inspection. Results logged to /home/vladimirn/.rvm/gems/ruby-2.1.3/extensions/x86_64-linux/2.1.0/debase-0.0.9/gem_make.out
This looks like there is a problem with debugger-ruby_core_source gem.
I run it manually from terminal:
gem install debugger-ruby_core_source
But if i run afterward gem install debase once again I will get the same error.
Any ideas how i can configure Debugger with RubyMine running on Ubuntu 14?
Upvotes: 7
Views: 3635
Reputation: 3984
Ran into the same problem trying to get the debugger to work with Rubymine for 2.1.4 - I used the specific_install gem to install the latest debase from github which totally fixed it --
bundle exec gem install specific_install
gem specific_install https://github.com/denofevil/debase.git
Upvotes: 4
Reputation: 5258
The problem is that debase 0.1.0
which includes the latest ruby sources hadn't been released.
But it has just been released 20 minutes ago, so if you reinstall Rubymine or the debase
gem now, it should work.
Upvotes: 6
Reputation: 8826
The debugger gem isn't supposed to be used with ruby 2.0+, and literally won't install with ruby 2.1.2(+). You are going to have to switch to byebug.
If you're a fan of pry there is also pry-byebug
Here is how my debugging gems in my Gemfile look like with Rails 4 and Ruby 2.1.2
group :development do
gem 'pry'
gem 'pry-remote'
gem 'pry-rails'
gem 'pry-stack_explorer'
gem 'pry-byebug'
end
Upvotes: 2