conflict between soap4r gem and stdlib

Discussion in 'Ruby' started by Joel VanderWerf, Jun 6, 2008.

  1. I installed a newer version of soap4r as a gem, but, when I require
    soap, the old version (which came with ruby) is the one that is loaded.

    $ ruby -r soap/soap -e 'p SOAP::VERSION'
    "1.5.5"
    $ grep VERSION
    /usr/local/lib/ruby/gems/1.8/gems/soap4r-1.5.8/lib/soap/soap.rb
    VERSION = Version = '1.5.8'
    $ ruby -v
    ruby 1.8.6 (2008-03-03 patchlevel 114) [i686-linux]


    I can hack around this easily enough (install from a tar, maybe), but
    why isn't the gem found first?

    --
    vjoel : Joel VanderWerf : path berkeley edu : 510 665 3407
     
    Joel VanderWerf, Jun 6, 2008
    #1
    1. Advertising

  2. Joel VanderWerf

    Eric Hodel Guest

    On Jun 5, 2008, at 21:24 PM, Joel VanderWerf wrote:
    > I installed a newer version of soap4r as a gem, but, when I require
    > soap, the old version (which came with ruby) is the one that is
    > loaded.
    >
    > $ ruby -r soap/soap -e 'p SOAP::VERSION'
    > "1.5.5"
    > $ grep VERSION /usr/local/lib/ruby/gems/1.8/gems/soap4r-1.5.8/lib/
    > soap/soap.rb
    > VERSION = Version = '1.5.8'
    > $ ruby -v
    > ruby 1.8.6 (2008-03-03 patchlevel 114) [i686-linux]
    >
    > I can hack around this easily enough (install from a tar, maybe),
    > but why isn't the gem found first?


    RubyGems will only search for a file in a gem when it isn't in
    $LOAD_PATH. Use gem 'soap4r' to put the gem in $LOAD_PATH before the
    stdlib version before you require anything from soap4r. (I believe
    this is included in the soap4r documentation.)
     
    Eric Hodel, Jun 6, 2008
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    2
    Views:
    580
  2. charles cashion

    css conflict (or html conflict)

    charles cashion, Feb 18, 2009, in forum: HTML
    Replies:
    2
    Views:
    805
    charles cashion
    Feb 18, 2009
  3. hqin
    Replies:
    24
    Views:
    2,927
    Keith Thompson
    Jan 17, 2011
  4. Austin 7873
    Replies:
    5
    Views:
    198
    Eric Hodel
    Jan 27, 2007
  5. Heesob Park

    gem libray name conflict problem

    Heesob Park, Jun 24, 2009, in forum: Ruby
    Replies:
    5
    Views:
    283
    Eric Hodel
    Jul 22, 2009
Loading...

Share This Page