NameError: uninitialized constant SOAP::Mapping::EncodedRegistry

470 views
Skip to first unread message

ysriram

unread,
Oct 17, 2006, 6:48:52 PM10/17/06
to soap4r
Built the driver classes using wsdl2ruby and attempting to
simply require the xxxxMappingRegistry file produces the error.

NameError: uninitialized constant SOAP::Mapping::EncodedRegistry

How do I fix this.

NAKAMURA, Hiroshi

unread,
Oct 22, 2006, 12:54:41 AM10/22/06
to soa...@googlegroups.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,

Hmm. I cannot reproduce it. Generated fooMappingRegistry.rb should
have 'require "soap/mapping"' line, and
/usr/local/lib/ruby/1.8/soap/mapping.rb should have
'require "soap/mapping/encodedregistry"' line. Can you check it?

Regards,
// NaHi
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.1 (Cygwin)

iQEVAwUBRTr5kB9L2jg5EEGlAQJxWAgAteQ5+tODR1L4ddTax3Sn3UaeYsEtn+TZ
1nqbVxCaYgGe3SSUcxygmVR+R48P9oQeets8M+5H4wbjYPxtvCSz2SBwrBuCLE+c
iv6tMXf/jaeW29lB/cbp00dboDY1AiJWBZSf9qaKlF6Noh5AUYCTOD+Z35RyK+o1
EKLR6rssXZJ+KWyhNcf7AMe+2H6xVcpA+PNm8WkN8WTkWVDFKgAyjPe6EoXCKTb4
CwETTCp14xV9S7BJXhBxxDKbpvYwlTyCbr1Fkm5Z6TWdkIJOR7A3v/cdBqJgeneM
PFt4WVq0coODI/4bJ2T6dBP4L0lPj/MO55HAVflSnCLDX3OzoYfgFQ==
=8HRm
-----END PGP SIGNATURE-----

NAKAMURA, Hiroshi

unread,
Oct 22, 2006, 7:39:04 AM10/22/06
to soa...@googlegroups.com
Hi again,

NAKAMURA, Hiroshi wrote:
> ysriram wrote:
>> Built the driver classes using wsdl2ruby and attempting to
>> simply require the xxxxMappingRegistry file produces the error.
>>
>> NameError: uninitialized constant SOAP::Mapping::EncodedRegistry
>
> Hmm. I cannot reproduce it. Generated fooMappingRegistry.rb should
> have 'require "soap/mapping"' line, and
> /usr/local/lib/ruby/1.8/soap/mapping.rb should have
> 'require "soap/mapping/encodedregistry"' line. Can you check it?

I've found that ruby + soap4r gem causes this problem. I've not yet
looked into the cause, you can install the latest snapshot tarball for a
workaround.

Regards,
// NaHi

ysriram

unread,
Oct 23, 2006, 4:53:44 PM10/23/06
to soap4r
Thanks. Will try.

On Oct 22, 4:39 am, "NAKAMURA, Hiroshi" <nakah...@sarion.co.jp> wrote:
> Hi again,
>
> NAKAMURA, Hiroshi wrote:
> > ysriram wrote:
> >> Built the driver classes using wsdl2ruby and attempting to
> >> simply require the xxxxMappingRegistry file produces the error.
>
> >> NameError: uninitialized constant SOAP::Mapping::EncodedRegistry
>
> > Hmm. I cannot reproduce it. Generated fooMappingRegistry.rb should
> > have 'require "soap/mapping"' line, and
> > /usr/local/lib/ruby/1.8/soap/mapping.rb should have

> > 'require "soap/mapping/encodedregistry"' line. Can you check it?I've found that ruby + soap4r gem causes this problem. I've not yet

mgriggs

unread,
Nov 14, 2006, 7:56:46 AM11/14/06
to soap4r
Hello Nahi,
Please forgive me for my lack of knowledge but i am also getting the
"uninitialized constant EncodedRegistry" error when i add the "require
'defaultDriver.rb'" line to my controller file. It seems this a
compile error that i'm getting because I have commented out all of the
wsdl calls to try and find what's causing this error.

Can someone explain to me how to "install the latest snapshot tarball"?

I'm running rails and I unzipped the tarball in my vendor directory so
it now looks like this..

"my_rails_app/vendor/soap4r-1.5.5/bin"
"my_rails_app/vendor/soap4r-1.5.5/lib"
etc..

I added the following lines to my rails controller
require 'rubygems'
require_gem 'soap4r' #with this one uncommented i get "could not
find RubyGem soap4r"
require 'soap/wsdlDriver'
require 'defaultDriver.rb' #with this one uncommend i get
"uninitialized constant EncodedRegistry"

Can anyone point me in the right direction to get this going?

thanks
mike

ysriram

unread,
Nov 20, 2006, 2:43:32 PM11/20/06
to soap4r
Well I've the issue. Standalone works fine. When I integrate with rails
I get the "uninitialized constant EncodedRegistry" error. I really need
help on this.
Y

On Nov 14, 4:56 am, "mgriggs" <thesupermana...@gmail.com> wrote:
> Hello Nahi,
> Please forgive me for my lack of knowledge but i am also getting the

> "uninitialized constantEncodedRegistry" error when i add the "require


> 'defaultDriver.rb'" line to my controller file. It seems this a
> compile error that i'm getting because I have commented out all of the
> wsdl calls to try and find what's causing this error.
>
> Can someone explain to me how to "install the latest snapshot tarball"?
>

> I'm runningrailsand I unzipped the tarball in my vendor directory so

ysriram

unread,
Nov 22, 2006, 12:06:55 PM11/22/06
to soap4r
Hello:
Here is how I solved it.
Modified boot.rb so that it loads soap4r gem right after loading
rubygems
-----snip-----
require 'rubygems'
require_gem 'soap4r'
-----snip-----
Hope this helps.
Y

On Nov 14, 4:56 am, "mgriggs" <thesupermana...@gmail.com> wrote:

tpo

unread,
Nov 23, 2006, 4:25:23 AM11/23/06
to soap4r
On Nov 22, 6:06 pm, "ysriram" <ysri...@strongmail.com> wrote:
> Hello:
> Here is how I solved it.
> Modified boot.rb so that it loads soap4r gem right after loading
> rubygems
> -----snip-----
> require 'rubygems'
> require_gem 'soap4r'
> -----snip-----
> Hope this helps.
> Y

Nice, I've added it to the soap4r wiki.
*t

mgriggs

unread,
Nov 23, 2006, 1:33:04 PM11/23/06
to soap4r
Hello NaHi,
I'm also getting the uninitialized constant error
I checked the "mapping.rb" file and it has the following..

require 'soap/mapping/mapping'
require 'soap/mapping/registry'

it's doesn't have "soap/mapping/encodedregistry"

i'm running ruby 1.8.4

can you paste your mapping.rb file in here?

do i need to add "encodedregistry" or is there something else that
needs to be done?
thanks
mike

On Oct 22, 5:54 am, "NAKAMURA, Hiroshi" <nakah...@sarion.co.jp> wrote:
>
> > NameError: uninitialized constant SOAP::Mapping::EncodedRegistryHmm. I cannot reproduce it. Generated fooMappingRegistry.rb should

Reply all
Reply to author
Forward
0 new messages