From: Dan Cruickshank Date: 2010-05-13T12:40:06+09:00 Subject: Re: Need help using Savon gem! (SOAP) Brian Candler wrote: > Dan Cruickshank wrote: > > Do you have the soap4r gem installed? yes. 1.5.8 > Worse, perhaps you have loaded > part of the old soap4r before gems are activated, and another part > afterwards. Might be (more on that below) > At the line before the error in fax_api.rb you could break into debugger > and poke around, or add debugging statements like > STDERR.puts $LOAD_PATH.inspect Done (below) > > Also: take your working test code and run it using > script/runner whatever.rb > which will first boot up the rails environment, then run the script you > provide. Does it now fail? script/runner lib/fax_api.rb RUNS and submits the fax these two lines will also connect to it - script/console - >> require "lib/fax_api" I've added (api = FaxAPi.new; api.send(...) to the bottom of my class) > > What about using script/console instead of irb? > > If you can make a standalone test case which is just a couple of lines > that you run from script/runner or script/console, that would be an > ideal way to get the problem resolved quickly. Does anything above help us solve this quicker? I've created a new bare bones rails application and it fails as well with called in a controller. ::SOAP::WSDLDriverFactory.new("https://ws.interfax.net/dfs.asmx?WSDL") -> uninitialized constant SOAP error Now, the last thing I found was this ticket that implies many problems between rails and SOAP4R. I didn't realize originally that I was using SOAP4R underneath all this, but I guess I am. http://dev.ctor.org/soap4r/ticket/433 They imply that there is a problem between rails and soap4r and the order of things. I think they say I should be able to put "gem 'soap4r'" at the top of my environment.rb or somewhere in my boot.rb, but I haven't had any luck with that yet. This sounds like the most promising avenue however. -- Posted via http://www.ruby-forum.com/.