From: yahalom on
I am trying to work with WS::Client. I parsed the wsdl successfully
(after removing non existing urls). The WSDL contains complex and
array types. When I try to work with the WSDL I get error. What am I
doing wrong.

package require WS::Client
::WS::Client::LoadParsedWsdl {
service {name TeamConnectorServiceService location http://test/services/TedtService}
targetNamespace {{tns1 http://test.com} {tns2 http://test.com}} types
{connectorAction {transportContainer {type TransportContainer comment
{}}} connectorActionResponse {connectorActionReturn {type
TransportContainer comment {}}} connectorActionAsync
{transportContainer {type TransportContainer comment {}}}
ArrayOf_tns1_Property {item {type Property() comment {}}}
ArrayOf_tns1_RoutingNode {item {type RoutingNode() comment {}}}
Property {name {type string comment {}} value {type string comment
{}}} RoutingNode {actionHandlerName {type string comment {}}
asyncRequest {type boolean comment {}} auditRequired {type boolean
comment {}} description {type string comment {}} endPointUrl {type
string comment {}} exceptionMessage {type string comment {}}
onFailureAction {type string comment {}} responseXML {type string
comment {}} returnControl {type boolean comment {}} status {type
string comment {}} teamNodeName {type string comment {}} timeout {type
int comment {}} xmlTransit {type boolean comment {}}}
TransportContainer {actionName {type string comment {}} errorCode
{type string comment {}} errorDescription {type string comment {}}
guid {type string comment {}} packetType {type string comment {}}
positionIndex {type int comment {}} properties {type
ArrayOf_tns1_Property comment {}} requestXML {type string comment {}}
routing {type ArrayOf_tns1_RoutingNode comment {}} routingNodeByIndex
{type RoutingNode() comment {}} subActionName {type string comment
{}}}} operList {connectorAction connectorActionAsync} operation
{connectorAction {style document/literal action {} soapRequestHeader
{{}} soapReplyHeader {{}} inputs connectorAction outputs
connectorActionResponse xns {}} connectorActionAsync {style document/
literal action {} soapRequestHeader {{}} soapReplyHeader {{}} inputs
connectorActionAsync outputs connectorActionAsyncResponse xns {}}}

}
set xml {<?xml version="1.0" encoding="UTF-8"?><Request>
<test>test</test>}

dict set routing actionHandlerName SaleAction
dict set routing asyncRequest null
dict set routing auditRequired null
dict set routing description null
dict set routing endPointUrl null
dict set routing exceptionMessage null
dict set routing onFailureAction null
dict set routing responseXML null
dict set routing returnControl null
dict set routing status null
dict set routing teamNodeName null
dict set routing teamNodeName null
dict set routing timeout 0

dict set tc actionName SaleAction
dict set tc errorCode null
dict set tc errorDescription null
dict set tc guid null
dict set tc packetType null
dict set tc positionIndex null
dict set tc properties null
dict set tc requestXML $xml
dict set tc routing $routing
dict set tc unbounded $routing
dict set tc subActionName ""

puts [::WS::Client::DoCall TeamConnectorServiceService connectorAction
[list connectorAction $tc ]]

I get this error:

key "xns" not known in dictionary
while executing
"dict get [::WS::Utils::GetServiceTypeDef Client $serviceName
$msgType] xns"
(procedure "buildDocLiteralCallquery" line 48)
invoked from within
"buildDocLiteralCallquery $serviceName $operationName $url $argList"
(procedure "buildCallquery" line 10)
invoked from within
"buildCallquery $serviceName $operationName $url $argList"
(procedure "::WS::Client::DoCall" line 13)
invoked from within
"::WS::Client::DoCall TeamConnectorServiceService connectorAction
[list connectorAction $tc ]"
invoked from within
"if {1} {
::WS::Client::LoadParsedWsdl {
service {name TeamConnectorServiceService location http://test/services/test..."
(file "test.tcl" line 2)


From: Gerald W. Lester on
I'll try to take a look at what is going on ASAP (but this is a *VERY* busy
time of year for me so no promises on when that will be).

yahalom wrote:
> I am trying to work with WS::Client. I parsed the wsdl successfully
> (after removing non existing urls). The WSDL contains complex and
> array types. When I try to work with the WSDL I get error. What am I
> doing wrong.
>
> package require WS::Client
> ::WS::Client::LoadParsedWsdl {
> service {name TeamConnectorServiceService location http://test/services/TedtService}
> targetNamespace {{tns1 http://test.com} {tns2 http://test.com}} types
> {connectorAction {transportContainer {type TransportContainer comment
> {}}} connectorActionResponse {connectorActionReturn {type
> TransportContainer comment {}}} connectorActionAsync
> {transportContainer {type TransportContainer comment {}}}
> ArrayOf_tns1_Property {item {type Property() comment {}}}
> ArrayOf_tns1_RoutingNode {item {type RoutingNode() comment {}}}
> Property {name {type string comment {}} value {type string comment
> {}}} RoutingNode {actionHandlerName {type string comment {}}
> asyncRequest {type boolean comment {}} auditRequired {type boolean
> comment {}} description {type string comment {}} endPointUrl {type
> string comment {}} exceptionMessage {type string comment {}}
> onFailureAction {type string comment {}} responseXML {type string
> comment {}} returnControl {type boolean comment {}} status {type
> string comment {}} teamNodeName {type string comment {}} timeout {type
> int comment {}} xmlTransit {type boolean comment {}}}
> TransportContainer {actionName {type string comment {}} errorCode
> {type string comment {}} errorDescription {type string comment {}}
> guid {type string comment {}} packetType {type string comment {}}
> positionIndex {type int comment {}} properties {type
> ArrayOf_tns1_Property comment {}} requestXML {type string comment {}}
> routing {type ArrayOf_tns1_RoutingNode comment {}} routingNodeByIndex
> {type RoutingNode() comment {}} subActionName {type string comment
> {}}}} operList {connectorAction connectorActionAsync} operation
> {connectorAction {style document/literal action {} soapRequestHeader
> {{}} soapReplyHeader {{}} inputs connectorAction outputs
> connectorActionResponse xns {}} connectorActionAsync {style document/
> literal action {} soapRequestHeader {{}} soapReplyHeader {{}} inputs
> connectorActionAsync outputs connectorActionAsyncResponse xns {}}}
>
> }
> set xml {<?xml version="1.0" encoding="UTF-8"?><Request>
> <test>test</test>}
>
> dict set routing actionHandlerName SaleAction
> dict set routing asyncRequest null
> dict set routing auditRequired null
> dict set routing description null
> dict set routing endPointUrl null
> dict set routing exceptionMessage null
> dict set routing onFailureAction null
> dict set routing responseXML null
> dict set routing returnControl null
> dict set routing status null
> dict set routing teamNodeName null
> dict set routing teamNodeName null
> dict set routing timeout 0
>
> dict set tc actionName SaleAction
> dict set tc errorCode null
> dict set tc errorDescription null
> dict set tc guid null
> dict set tc packetType null
> dict set tc positionIndex null
> dict set tc properties null
> dict set tc requestXML $xml
> dict set tc routing $routing
> dict set tc unbounded $routing
> dict set tc subActionName ""
>
> puts [::WS::Client::DoCall TeamConnectorServiceService connectorAction
> [list connectorAction $tc ]]
>
> I get this error:
>
> key "xns" not known in dictionary
> while executing
> "dict get [::WS::Utils::GetServiceTypeDef Client $serviceName
> $msgType] xns"
> (procedure "buildDocLiteralCallquery" line 48)
> invoked from within
> "buildDocLiteralCallquery $serviceName $operationName $url $argList"
> (procedure "buildCallquery" line 10)
> invoked from within
> "buildCallquery $serviceName $operationName $url $argList"
> (procedure "::WS::Client::DoCall" line 13)
> invoked from within
> "::WS::Client::DoCall TeamConnectorServiceService connectorAction
> [list connectorAction $tc ]"
> invoked from within
> "if {1} {
> ::WS::Client::LoadParsedWsdl {
> service {name TeamConnectorServiceService location http://test/services/test..."
> (file "test.tcl" line 2)
>
>


--
+------------------------------------------------------------------------+
| Gerald W. Lester |
|"The man who fights for his ideals is the man who is alive." - Cervantes|
+------------------------------------------------------------------------+
From: Patrick on
Did you ever get this figured out? I am having a similar problem with
an argument being an array of strings.
Patrick
From: drscrypt on
Patrick wrote:
> Did you ever get this figured out? I am having a similar problem with
> an argument being an array of strings.
> Patrick


I am new to the package but without a url to replicate and test things,
it is hard for others to contribute.


DrS
From: yahalom on
On Dec 19, 3:43 am, drscr...(a)gmail.com wrote:
> Patrick wrote:
> > Did you ever get this figured out? I am having a similar problem with
> > an argument being an array of strings.
> > Patrick

not yet :-( Gerald is busy and I hope when New Year cools down he
will find the time and gives us a late Christmas present.

>
> I am new to the package but without a url to replicate and test things,
> it is hard for others to contribute.

Sometimes it is impossible to expose the url. In my case the package
gives the error BEFORE it goes out for http request so the problem is
a wsdl parsing/query building error.

>
> DrS