JRuby

NetBeans 6.1 / Jruby 1.1.5 / Rails 1.2.6 breaks on startup with MissingSourceFile error

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: JRuby 1.1.5
  • Fix Version/s: None
  • Component/s: None
  • Labels:
    None
  • Environment:
  • Number of attachments :
    1

Description

When starting Mongrel server 1.1.5 from NetBeams 6.1 I got the following error:

TypeError (can't convert MissingSourceFile into String):
/usr/local/jruby-1.1.5/lib/ruby/gems/1.8/gems/activesupport-1.4.4/lib/active_support/dependencies.rb:100:in `require_or_load'
/usr/local/jruby-1.1.5/lib/ruby/gems/1.8/gems/activesupport-1.4.4/lib/active_support/dependencies.rb:60:in `depend_on'
/usr/local/jruby-1.1.5/lib/ruby/gems/1.8/gems/activesupport-1.4.4/lib/active_support/dependencies.rb:442:in `require_dependency'
/usr/local/jruby-1.1.5/lib/ruby/gems/1.8/gems/rails-1.2.6/lib/dispatcher.rb:109:in `prepare_application'
/usr/local/jruby-1.1.5/lib/ruby/gems/1.8/gems/rails-1.2.6/lib/dispatcher.rb:39:in `dispatch'
/usr/local/jruby-1.1.5/lib/ruby/gems/1.8/gems/rails-1.2.6/lib/webrick_server.rb:113:in `handle_dispatch'
/usr/local/jruby-1.1.5/lib/ruby/gems/1.8/gems/rails-1.2.6/lib/webrick_server.rb:79:in `service'
/usr/local/jruby-1.1.5/lib/ruby/1.8/webrick/httpserver.rb:104:in `service'
/usr/local/jruby-1.1.5/lib/ruby/1.8/webrick/httpserver.rb:65:in `run'
/usr/local/jruby-1.1.5/lib/ruby/1.8/webrick/server.rb:173:in `start_thread'
:1:in `start'

And it breaks while requiring application_api.rb

JRuby 1.1.4 works just fine!

What did you guys break?

Activity

Hide
Jan Berkel added a comment -

getting same error on rails 2.1

Exception in thread "main" vendor/rails/activesupport/lib/active_support/dependencies.rb:518:in `require': can't convert MissingSourceFile into String (TypeError)

JRuby 1.1.4 works ok

Show
Jan Berkel added a comment - getting same error on rails 2.1 Exception in thread "main" vendor/rails/activesupport/lib/active_support/dependencies.rb:518:in `require': can't convert MissingSourceFile into String (TypeError) JRuby 1.1.4 works ok
Hide
Chad Johnson added a comment -

I also have a Rails 1.2.6 app that I can no longer startup due to this exact same error.

Show
Chad Johnson added a comment - I also have a Rails 1.2.6 app that I can no longer startup due to this exact same error.
Hide
Jan Berkel added a comment -

i've just managed to start up rails by removing actionwebservice. dennis, chad: are you using actionwebservice in your apps?

Show
Jan Berkel added a comment - i've just managed to start up rails by removing actionwebservice. dennis, chad: are you using actionwebservice in your apps?
Hide
Chad Johnson added a comment -

Hey, look at that:

(config/environment.rb)
===
config.frameworks -= [ :action_web_service ]
===

And now the app starts up. Thanks Jan.

Also, Jan, have you tried using the new "glassfish" gem to fire your app up?

I continue to get an error to the effect of :

Caused by: java.lang.NumberFormatException: For input string: "e"
at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
at java.lang.Integer.parseInt(Integer.java:447)
at java.lang.Integer.parseInt(Integer.java:497)
at com.sun.grizzly.jruby.rack.RackApplicationChooser.getFactory(RackApplicationChooser.java:53)
at com.sun.grizzly.jruby.RailsAdapter.<init>(RailsAdapter.java:104)
at com.sun.grizzly.jruby.RubyRuntime.<init>(RubyRuntime.java:48)

Show
Chad Johnson added a comment - Hey, look at that: (config/environment.rb) === config.frameworks -= [ :action_web_service ] === And now the app starts up. Thanks Jan. Also, Jan, have you tried using the new "glassfish" gem to fire your app up? I continue to get an error to the effect of : Caused by: java.lang.NumberFormatException: For input string: "e" at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48) at java.lang.Integer.parseInt(Integer.java:447) at java.lang.Integer.parseInt(Integer.java:497) at com.sun.grizzly.jruby.rack.RackApplicationChooser.getFactory(RackApplicationChooser.java:53) at com.sun.grizzly.jruby.RailsAdapter.<init>(RailsAdapter.java:104) at com.sun.grizzly.jruby.RubyRuntime.<init>(RubyRuntime.java:48)
Hide
Jan Berkel added a comment -

no haven't got that far yet, and don't use glassfish.

but i tracked down the real cause of the bug: http://jira.codehaus.org/browse/JRUBY-3135
if you need to use actionwebservice with jruby 1.1.5, put the following somewhere

class Exception
  def to_str
    to_s
  end
end
Show
Jan Berkel added a comment - no haven't got that far yet, and don't use glassfish. but i tracked down the real cause of the bug: http://jira.codehaus.org/browse/JRUBY-3135 if you need to use actionwebservice with jruby 1.1.5, put the following somewhere
class Exception
  def to_str
    to_s
  end
end
Hide
Dennis Granau added a comment -

Thank you Jan!

Show
Dennis Granau added a comment - Thank you Jan!
Hide
Marcin Mielzynski added a comment -

Fixed in r8059 (JRUBY-3135)

Show
Marcin Mielzynski added a comment - Fixed in r8059 (JRUBY-3135)

People

Vote (1)
Watch (2)

Dates

  • Created:
    Updated:
    Resolved: