Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Won't Fix
    • Affects Version/s: JRuby 1.6RC3
    • Fix Version/s: None
    • Component/s: Interpreter
    • Labels:
      None
    • Environment:
      MacOSX 1.0.6
    • Testcase included:
      yes
    • Number of attachments :
      0

      Description

      Here's the error

      LoadError: no such file to load -- whois/answer/parser/whois.nic
         require at org/jruby/RubyKernel.java:1037
         require at /Users/weppos/.rvm/rubies/jruby-1.6.0.RC3/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:29
          (root) at ./test/whois/answer/parser/whois.nic.so_test.rb:2
            load at org/jruby/RubyKernel.java:1062
        __file__ at /Users/weppos/.rvm/gems/jruby-1.6.0.RC3/gems/rake-0.8.7/lib/rake/rake_test_loader.rb:5
            each at org/jruby/RubyArray.java:1572
          (root) at /Users/weppos/.rvm/gems/jruby-1.6.0.RC3/gems/rake-0.8.7/lib/rake/rake_test_loader.rb:5
      rake aborted!
      

      You can reproduce it by trying to execute the test suite of the Whois Gem.
      https://github.com/weppos/whois/tree/222f9244884ed745842a4050909708b9b663376c

      The whois.nic.so_test.rb file attempts to include a whois.nic.so.rb file using the following syntax

      require 'whois/answer/parser/whois.nic.so'
      

        Issue Links

          Activity

          Hide
          Simone Carletti added a comment -

          Charles,

          I know you read ruby-core, but for the records, here's the link to the ML
          http://www.ruby-forum.com/topic/1248205

          Show
          Simone Carletti added a comment - Charles, I know you read ruby-core, but for the records, here's the link to the ML http://www.ruby-forum.com/topic/1248205
          Hide
          Charles Oliver Nutter added a comment -

          This fix makes it work, but breaks other things (presumably that depend on us normalizing extension extensions to ".jar" for searching purposes: https://gist.github.com/863022

          Perhaps we should wait and see what ruby-core thinks about this failover behavior.

          Show
          Charles Oliver Nutter added a comment - This fix makes it work, but breaks other things (presumably that depend on us normalizing extension extensions to ".jar" for searching purposes: https://gist.github.com/863022 Perhaps we should wait and see what ruby-core thinks about this failover behavior.
          Hide
          Charles Oliver Nutter added a comment -

          Simone: Thanks for posting that. I'll reply as well.

          Show
          Charles Oliver Nutter added a comment - Simone: Thanks for posting that. I'll reply as well.
          Hide
          Daniel Berger added a comment -

          I think the logic can be found in the search_required function in eval.c. Not pretty.

          Show
          Daniel Berger added a comment - I think the logic can be found in the search_required function in eval.c. Not pretty.
          Hide
          Charles Oliver Nutter added a comment -

          I'm satisfied calling this "Won't Fix".

          I believe the consistency from having .so and other extensions trigger an "extension load" in require is better than having to also do all the .rb searching on top of those extensions (which would slow extension file searches even more, and possibly load a .rb file when you really want it to load a .so.)

          Workaround is to simply require the full name (foo.so.rb) if you know it's a .rb file.

          Show
          Charles Oliver Nutter added a comment - I'm satisfied calling this "Won't Fix". I believe the consistency from having .so and other extensions trigger an "extension load" in require is better than having to also do all the .rb searching on top of those extensions (which would slow extension file searches even more, and possibly load a .rb file when you really want it to load a .so.) Workaround is to simply require the full name (foo.so.rb) if you know it's a .rb file.

            People

            • Assignee:
              Charles Oliver Nutter
              Reporter:
              Simone Carletti
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: