Created
December 7, 2011 02:03
-
-
Save dnagir/1441091 to your computer and use it in GitHub Desktop.
No Stacktrace in JRuby
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
> rvm use jruby | |
Using /Users/dnagir/.rvm/gems/jruby-1.6.5 | |
> bundle exec rspec spec/models/user_spec.rb --backtrace | |
NameError: uninitialized constant ActiveRecord | |
> rvm use 1.9.3 | |
Using /Users/dnagir/.rvm/gems/ruby-1.9.3-p0 | |
> bundle exec rspec spec/models/user_spec.rb --backtrace | |
/Users/dnagir/proj/abc/lib/extensions/has_address.rb:15:in `<top (required)>': uninitialized constant ActiveRecord (NameError) | |
from /Users/dnagir/proj/abc/config/initializers/extensions.rb:2:in `block in <top (required)>' | |
from /Users/dnagir/proj/abc/config/initializers/extensions.rb:1:in `each' | |
from /Users/dnagir/proj/abc/config/initializers/extensions.rb:1:in `<top (required)>' | |
from /Users/dnagir/.rvm/gems/ruby-1.9.3-p0/gems/railties-3.1.3/lib/rails/engine.rb:556:in |
--trace
is similar to --backtrace
in RSpec. But in any case, it indeed doesn't help.
Interesting thing is that it only seems to happen in the Rails initializers.
The exact answer was I think it's just a problem printing out backtraces when we're running the ^C exit hook.
.
Whatever the problem is I hope it will be fixed soon.
BTW, if you're keen to try it (which I doubt :-) ), here is my repro: https://gist.github.com/1441257
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Not sure why wouldn't it help. Rake prints a stack trace upon exception in any ruby machine. "Not enough time" sounds ridiculous indeed.