File.realpath on uri-like paths fails #3401

Closed
mkristian opened this Issue Oct 19, 2015 · 0 comments

Comments

Projects
None yet
2 participants
@mkristian
Member

mkristian commented Oct 19, 2015

just came across

Errno::ENOENT: No such file or directory - /Users/cmeier/projects/active/lookout/leafy/examples/hellowarld/file:/Users/cmeier/.m2/repository/io/takari/polyglot/polyglot-ruby/0.1.13-SNAPSHOT/polyglot-ruby-0.1.13-SNAPSHOT.jar!/maven/tools/dsl.rb
          realpath at org/jruby/RubyFile.java:840
  require_relative at file:/Users/cmeier/.m2/repository/org/jruby/jruby-core/1.7.22/jruby-core-1.7.22-noasm.jar!/jruby/kernel19/kernel.rb:11
           gemspec at file:/Users/cmeier/.m2/repository/io/takari/polyglot/polyglot-ruby/0.1.13-SNAPSHOT/polyglot-ruby-0.1.13-SNAPSHOT.jar!/maven/tools/dsl.rb:375
          eval_pom at /Users/cmeier/.rbenv/versions/jruby-9.0.1.0/lib/ruby/stdlib/jars/jar_pom.rb:13

can be reduced to

jruby -e 'p File.realpath("file:/Users/cmeier/.m2/repository/io/takari/polyglot/polyglot-ruby/0.1.13-SNAPSHOT/polyglot-ruby-0.1.13-SNAPSHOT.jar!/maven/tools/dsl.rb")'

with any jar containing ruby files. since this is used by require_relative it always fails when used inside jars like this.

mkristian added a commit to torquebox/maven-tools that referenced this issue Oct 19, 2015

@shorock shorock referenced this issue in archivesspace/archivesspace Oct 21, 2015

Closed

AS 1.4.1, JRuby 1.7.22, require_relative in jar issues #315

mkristian added a commit that referenced this issue Oct 28, 2015

better File.realpath for uri-like paths
realpath needs to honor the various uri-like paths. fixes #3401

Sponsored by Lookout Inc.

@kares kares added this to the JRuby 1.7.23 milestone Oct 30, 2015

mkristian added a commit that referenced this issue Nov 8, 2015

better File.realpath for uri-like paths
realpath needs to honor the various uri-like paths. fixes #3401

Sponsored by Lookout Inc.

@mkristian mkristian closed this in 24fff3b Nov 9, 2015

donv added a commit to ruboto/ruboto that referenced this issue Dec 23, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment