Skip to content

Gems not being required properly no such file to load -- bundler/shared_helpers #430

@seandunn

Description

@seandunn

Hi All,

jruby-rack (1.1.21); warbler (2.0.5); jruby 9.2.0.0

I'm trying to run a Warbler generated WAR file in a docker Tomcat container. The WAR actually works fine in an older container running on a server but fails with the error shown below on anything more recent.

My suspicion is that this is a $LOAD_PATH issue.
I've got gems being bundled into WEB-INF/gems and everything should be there.

If anyone who could throw some light onto this it would very much appreciated, thanks

org.jruby.rack.RackInitializationException: no such file to load -- bundler/shared_helpers
	from org/jruby/RubyKernel.java:970:in `require'
	from uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:59:in `require'
	from file:/usr/local/tomcat/webapps/test_war/META-INF/init.rb:26:in `<eval>'
	from org/jruby/RubyKernel.java:1037:in `eval'
	from uri:classloader:/jruby/rack/booter.rb:256:in `block in load_settings_from_init_rb'
	from org/jruby/RubyArray.java:1801:in `each'
	from uri:classloader:/jruby/rack/booter.rb:243:in `load_settings_from_init_rb'
	from uri:classloader:/jruby/rack/booter.rb:99:in `boot!'
	from uri:classloader:/jruby/rack/rails_booter.rb:26:in `boot!'
	from uri:classloader:/jruby/rack/boot/rails.rb:10:in `<main>'
	from org/jruby/RubyKernel.java:994:in `load'
	from <script>:1:in `<main>'

	at org.jruby.rack.RackInitializationException.wrap(RackInitializationException.java:29)
	at org.jruby.rack.RackApplicationFactoryDecorator.init(RackApplicationFactoryDecorator.java:104)
	at org.jruby.rack.RackServletContextListener.contextInitialized(RackServletContextListener.java:50)
	at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4792)
	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5256)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
	at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:754)
	at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:730)
	at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734)
	at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:985)
	at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1857)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
Caused by: org.jruby.exceptions.LoadError: (LoadError) no such file to load -- bundler/shared_helpers
	at org.jruby.RubyKernel.require(org/jruby/RubyKernel.java:970)
	at RUBY.require(uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:59)
	at RUBY.<eval>(file:/usr/local/tomcat/webapps/test_war/META-INF/init.rb:26)
	at org.jruby.RubyKernel.eval(org/jruby/RubyKernel.java:1037)
	at RUBY.block in load_settings_from_init_rb(uri:classloader:/jruby/rack/booter.rb:256)
	at org.jruby.RubyArray.each(org/jruby/RubyArray.java:1801)
	at RUBY.load_settings_from_init_rb(uri:classloader:/jruby/rack/booter.rb:243)
	at RUBY.boot!(uri:classloader:/jruby/rack/booter.rb:99)
	at RUBY.boot!(uri:classloader:/jruby/rack/rails_booter.rb:26)
	at RUBY.<main>(uri:classloader:/jruby/rack/boot/rails.rb:10)
	at org.jruby.RubyKernel.load(org/jruby/RubyKernel.java:994)
	at RUBY.<main>(<script>:1)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions