在jRuby下运行黄瓜时java.lang.StackOverflowError

时间:2012-02-02 11:36:37

标签: ruby-on-rails cucumber jruby bundler

我在windows下使用cucumber和jRuby有以下问题:

load error: bundler/definition -- java.lang.StackOverflowError: null (LoadError)

在运行我的任何功能之前,甚至在“clear”rails项目中也会发生这种情况。

我正在使用jruby 1.6.6 (ruby-1.8.7-p357) (2012-01-30 5673572),这是我的bundle list https://gist.github.com/2bc58e136cb982fc9bae

这是完整的堆栈跟踪:

Using the default profile...
load error: bundler/definition -- java.lang.StackOverflowError: null (LoadError)
c:/jruby-1.6.6/lib/ruby/gems/1.8/gems/bundler-1.0.21/lib/bundler.rb:138:in `definition'
c:/jruby-1.6.6/lib/ruby/gems/1.8/gems/bundler-1.0.21/lib/bundler.rb:126:in `load'
c:/jruby-1.6.6/lib/ruby/gems/1.8/gems/bundler-1.0.21/lib/bundler.rb:110:in `setup'
c:/jruby-1.6.6/lib/ruby/gems/1.8/gems/bundler-1.0.21/lib/bundler/setup.rb:17:in `(root)'
org/jruby/RubyKernel.java:1027:in `require'
c:/jruby-1.6.6/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:59:in `require'
c:/jruby-1.6.6/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:55:in `require'
c:/jruby-1.6.6/lib/ruby/gems/1.8/gems/bundler-1.0.21/lib/bundler/setup.rb:6:in `(root)'
org/jruby/RubyKernel.java:1027:in `require'
c:/jruby-1.6.6/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:55:in `require'
D:/users/tgieniusz/workspace/rails/config/boot.rb:1:in `(root)'
org/jruby/RubyKernel.java:1027:in `require'
c:/jruby-1.6.6/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:55:in `require'
D:/users/tgieniusz/workspace/rails/config/application.rb:2:in `(root)'
org/jruby/RubyKernel.java:1027:in `require'
c:/jruby-1.6.6/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:55:in `require'
D:/users/tgieniusz/workspace/rails/config/environment.rb:7:in `(root)'
org/jruby/RubyKernel.java:1027:in `require'
c:/jruby-1.6.6/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:59:in `require'
c:/jruby-1.6.6/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:55:in `require'
c:/jruby-1.6.6/lib/ruby/gems/1.8/gems/cucumber-rails-1.2.1/lib/cucumber/rails.rb:7:in `(root)'
org/jruby/RubyKernel.java:1052:in `load'
D:/users/tgieniusz/workspace/rails/features/support/env.rb:129:in `load_code_file'
c:/jruby-1.6.6/lib/ruby/gems/1.8/gems/cucumber-1.1.4/bin/../lib/cucumber/runtime/support_code.rb:171:in `load_file'
c:/jruby-1.6.6/lib/ruby/gems/1.8/gems/cucumber-1.1.4/bin/../lib/cucumber/runtime/support_code.rb:83:in `load_files!'
org/jruby/RubyArray.java:1614:in `each'
c:/jruby-1.6.6/lib/ruby/gems/1.8/gems/cucumber-1.1.4/bin/../lib/cucumber/runtime/support_code.rb:82:in `load_files!'
c:/jruby-1.6.6/lib/ruby/gems/1.8/gems/cucumber-1.1.4/bin/../lib/cucumber/runtime.rb:174:in `load_step_definitions'
c:/jruby-1.6.6/lib/ruby/gems/1.8/gems/cucumber-1.1.4/bin/../lib/cucumber/runtime.rb:40:in `run!'
c:/jruby-1.6.6/lib/ruby/gems/1.8/gems/cucumber-1.1.4/bin/../lib/cucumber/cli/main.rb:43:in `execute!'
c:/jruby-1.6.6/lib/ruby/gems/1.8/gems/cucumber-1.1.4/bin/../lib/cucumber/cli/main.rb:20:in `execute'
c:/jruby-1.6.6/lib/ruby/gems/1.8/gems/cucumber-1.1.4/bin/cucumber:14:in `(root)'
org/jruby/RubyKernel.java:1052:in `load'
C:\jruby-1.6.6\lib\ruby\gems\1.8\bin\cucumber:19:in `(root)'  

1 个答案:

答案 0 :(得分:0)

JRuby 1.6.6中存在此错误

Here's a quickfix,而不是修复错误的实际原因。

黄瓜家伙已经意识到这一点,正在准备修复。