Rails 3.1 and Ruby 1.9.3p125: ruby-debug19 still crashes with Symbol not found: _ruby_threadptr_data_type
A fork of ruby-debug just called 'debugger' now exists that incorporates many of the fixes people had been deploying on top of ruby-debug19, so you should be able to just change your Gemfile to
gem 'debugger'
... and off you go.
How do you install (build) Ruby 1.9.3 on OSX Lion?
I just ran into this issue myself, and it seem to be an issue with how ruby-1.9.3-125 works with clang. Once I run it against gcc it worked like a charm.
Check to make sure you have the actual gcc installed with which gcc-4.2
. If it isn't you'll need to install Xcode or something akin to the os x gcc installer. If it is installed running rvm install 1.9.3 --with-gcc=gcc-4.2
is what did the trick for me.
rubymine crashes on debug
Just update your ruby-debug-base19x gem with gem install ruby-debug-base19x --pre
Stange random crashes with Rails 3.1 in production
solution: if your validation line says this ...
validates :tag, :uniqueness => {:scope => :post}
... then change it to reference column name instead of association name like this ...
validates :tag_id, :uniqueness => {:scope => :post_id}
I recreated your failure in rails 3.1.0.rc5 and produced the same error message. The short explanation is that the code in the build_relation method is expecting a literal column name, not an association name.
For a more thorough explanation including code snippets see my blog at http://thetenelements.blogspot.com/2011/08/undefined-method-text-for-nilnilclass.html
how do I install ruby-debug in ruby 1.9.3 / Rails 3.2.1
Thanks to @Marc Talbot's comment in the OP, I found a working recipe.
download linecache19 and ruby-debug-base19 from RubyForge:
% curl -OL http://rubyforge.org/frs/download.php/75414/linecache19-0.5.13.gem
% curl -OL http://rubyforge.org/frs/download.php/75415/ruby-debug-base19-0.11.26.gem
compile the two gems
% gem install linecache19-0.5.13.gem
Building native extensions. This could take a while...
Successfully installed linecache19-0.5.13
1 gem installed
...
% gem install ruby-debug-base19-0.11.26.gem -- --with-ruby-include=$SANDBOX/packages/ruby-1.9.3-p0
Building native extensions. This could take a while...
Successfully installed ruby-debug-base19-0.11.26
1 gem installed
...
update your Gemfile
# file: Gemfile
...
group :development do
gem 'linecache19', '0.5.13'
gem 'ruby-debug-base19', '0.11.26'
gem 'ruby-debug19', :require => 'ruby-debug'
end
bundle install and test the debugger
% bundle install
Fetching source index for http://rubygems.org/
...
Your bundle is complete! Use `bundle show [gemname]` to see where a bundled gem is installed.
% irb
irb(main):001:0> require 'ruby-debug'
=> true
irb(main):002:0> debugger
$SANDBOX/usr/lib/ruby/1.9.1/irb/context.rb:166
@last_value = value
(rdb:1) p 'hooray'
"hooray"
Hopefully this will help others.
Ruby crashes when trying to debug Rails with RubyMine
The crash seems to happen inside Rails 3 activesupport. If you've updated your Ruby version recently, it could help if you rebuild gems with native extensions.
I'd try to remove all the debug gems and install them again using the following commands:
gem install ruby-debug-base19x --pre
gem install ruby-debug-ide --pre
(or appropriate rvm commands)
You should get the following versions only:
ruby-debug-base19x (0.11.30.pre4)
ruby-debug-ide (0.4.17.beta8)
Other debug gems are not needed. Also try to reinstall Rails 3 gems.
If it doesn't help, try Ruby 1.9.3.
Using ruby-debug with rails 3.1.1 and ruby 1.9.3
Just put the line gem 'ruby-debug19', :require => 'ruby-debug'
in your Gemfile should do. Then run bundle install
ruby-debug with Ruby 1.9.3?
Update (April 28, 2012)
Try the new debugger gem as a replacement for ruby-debug.
(credit to @ryanb)
Update (March 2, 2012)
Installation of linecache19 and ruby-debug-base19 can be easily done with:
bash < <(curl -L https://raw.github.com/gist/1333785)
(credit to @fredostarr)
Original answer
Have you looked at ruby-debug19 on ruby-1.9.3-preview1?
Here's a temporary solution:
http://blog.wyeworks.com/2011/11/1/ruby-1-9-3-and-ruby-debugExcerpt from the site:
First download linecache19-0.5.13.gem and
ruby-debug-base19-0.11.26.gem from
http://rubyforge.org/frs/?group_id=8883, then …$ gem install linecache19-0.5.13.gem
Building native extensions. This could take a while...
Successfully installed linecache19-0.5.13
1 gem installed
$ gem install ruby-debug-base19-0.11.26.gem -- --with-ruby-include=/Users/santiago/.rbenv/source/ruby-1.9.3-p0
Building native extensions. This could take a while...
Successfully installed ruby-debug-base19-0.11.26
1 gem installed
$ irb
irb(main):001:0> require 'ruby-debug'
=> true
Related Topics
How to Get a Date from Date_Select or Select_Date in Rails
Really Cheap Command-Line Option Parsing in Ruby
Undefined Method 'Visit' When Using Rspec and Capybara in Rails
Set Socket Timeout in Ruby Via So_Rcvtimeo Socket Option
Can Ruby Print Out Time Difference (Duration) Readily
Ignoring Gem Because Its Extensions Are Not Built
Best Practices for New Rails Deployments on Linux
How to Split a String to Get All the Substrings by Ruby
Ruby: How to Turn a Hash into Http Parameters
How to Remove Blank Elements from an Array
Devise Custom Routes and Login Pages
Parallel Assignment Operator in Ruby
Paperclip::Errors::Missingrequired
validatorerror With Rails 4
Using Rvm on Ubuntu 12.04 to Use Rails. the Program 'Rails' Is Currently Not Installed