Forum: Ruby SOAP '-' problem

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Krzysztof Kaczmarek (Guest)
on 2008-10-08 13:35
(Received via mailing list)
Hello,

I try to use this wsdl: http://webapi.allegro.pl/uploader.php?wsdl .
The problem is: variables are like "country-id". When I use 'soap/
wsdlDriver' or soap4r I become message like this:

 `@country-id' is not allowed as an instance variable name

How can i solve this problem? Maybe there are another soap library?

Sorry for my english =)

best regards
Krzysztof Kaczmarek
Mark T. (Guest)
on 2008-10-08 17:20
(Received via mailing list)
On Oct 8, 5:33 am, Krzysztof Kaczmarek
<removed_email_address@domain.invalid> wrote:
> Hello,
>
> I try to use this wsdl:http://webapi.allegro.pl/uploader.php?wsdl.
> The problem is: variables are like "country-id". When I use 'soap/
> wsdlDriver' or soap4r I become message like this:
>
>  `@country-id' is not allowed as an instance variable name
>
> How can i solve this problem? Maybe there are another soap library?

That looks like a bug from an old version of soap4r. With soap4r
1.5.8, I performed the following:

wsdl2ruby --wsdl http://webapi.allegro.pl/uploader.php?wsdl --type
client

and the generated classes had instance variables with underscores,
like @country_id. So I recommend that you install the latest via 'gem
install soap4r'

-- Mark.
This topic is locked and can not be replied to.