Skip Menu |

This queue is for tickets about the SOAP-WSDL CPAN distribution.

Report information
The Basics
Id: 71351
Status: open
Priority: 0/
Queue: SOAP-WSDL

People
Owner: Nobody in particular
Requestors: tim [...] timsheahan.com
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 2.00.10
Fixed in: (no value)



Subject: Interface-Operation POD template does not handle empty method replies
Hi, I think I have identified an issue where Interface/POD/Operation.tt fails to work against methods whose reply messages don't contain any fields. For example, I am working against https://provisioning.fetchtv.com.au/provisioning/ws/service.wsdl which defines a method response element like this: <xsd:element name="activateTerminalResponse" type="tns:activateTerminalResponse" /> When generating POD documentation, Operation.tt tries to load the first response part and document it, If there is no first response part because the message is empty, an error such as 'undef error - no node' occurs as the template tries to access it. The attached file fixes the problem by handling the case of a method reply which contains no parts. It tests the first member of the parts array and documents the method response as empty if the part is not present. I am running perl v5.8.8 on Debian with CPAN's current version of SOAP::WSDL (2.00.10)
Subject: Operation.tt
Download Operation.tt
application/octet-stream 1k

Message body not shown because it is not plain text.

Hi, i solved the probem by following change on wsdl2perl: diff /usr/bin/wsdl2perl.pl wsdl2perl.pl 122d121 < 152,153c151,152 < $generator->generate_interface() if ! $opt{server}; < $generator->generate_server() if $opt{server}; --- Show quoted text
> $generator->generate_interface({ NO_POD => 1 }) if ! $opt{server}; > $generator->generate_server({ NO_POD => 1 }) if $opt{server};
regards, palik Am Fr 30. Sep 2011, 01:07:26, sheahant schrieb: Show quoted text
> Hi, > > I think I have identified an issue where Interface/POD/Operation.tt > fails to work against methods whose reply messages don't contain any > fields. > > For example, I am working against > https://provisioning.fetchtv.com.au/provisioning/ws/service.wsdl which > defines a method response element like this: > > <xsd:element name="activateTerminalResponse" > type="tns:activateTerminalResponse" /> > > When generating POD documentation, Operation.tt tries to load the first > response part and document it, If there is no first response part > because the message is empty, an error such as 'undef error - no node' > occurs as the template tries to access it. > > The attached file fixes the problem by handling the case of a method > reply which contains no parts. It tests the first member of the parts > array and documents the method response as empty if the part is not > present. > > I am running perl v5.8.8 on Debian with CPAN's current version of > SOAP::WSDL (2.00.10)
Subject: Re: [rt.cpan.org #71351] Interface-Operation POD template does not handle empty method replies
Date: Tue, 15 Nov 2011 09:01:16 +1100
To: bug-SOAP-WSDL [...] rt.cpan.org
From: Tim Sheahan <tim [...] timsheahan.com>
Hi Palik, and thanks for your attention. True, disabling POD generation would certainly work around the issue, at the expense of the documentation functionality. This could be useful for some people to know if they need to get something working in a hurry. It seems to me, however, the ideal scenario would be if the templates could handle this circumstance, such as the altered Operation.tt in my original report. - Tim On 14/11/2011 8:48 PM, A. Pastuchov via RT wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=71351> > > Hi, > > i solved the probem by following change on wsdl2perl: > > ...