node-soap icon indicating copy to clipboard operation
node-soap copied to clipboard

wsdl:import

Open vartana opened this issue 14 years ago • 9 comments

failing at child type wsdl:import

code //

var soap = require('soap');

var url = 'https://service.com/test.svc?wsdl'; var args = {name: 'value'}; soap.createClient(url, function(err, client) { console.log('here'); client.MyFunction(args, function(err, result) { console.log(result); }); });

///

assert.js:104 throw new assert.AssertionError({ ^ AssertionError: Invalid child type at [object Object].addChild (/Users/vartanarabyan/Development/testtest/node_modules/soap/lib/wsdl.js:318:9) at [object Object].endElement (/Users/vartanarabyan/Development/testtest/node_modules/soap/lib/wsdl.js:108:20) at [object Object]. (/Users/vartanarabyan/Development/testtest/node_modules/soap/lib/wsdl.js:897:13) at [object Object].emit (events.js:87:17) at [object Object].emit (/Users/vartanarabyan/Development/testtest/node_modules/soap/node_modules/node-expat/lib/node-expat.js:18:12) at [object Object].parse (/Users/vartanarabyan/Development/testtest/node_modules/soap/node_modules/node-expat/lib/node-expat.js:24:24) at [object Object]._parse (/Users/vartanarabyan/Development/testtest/node_modules/soap/lib/wsdl.js:900:12) at [object Object]._fromXML (/Users/vartanarabyan/Development/testtest/node_modules/soap/lib/wsdl.js:908:29) at /Users/vartanarabyan/Development/testtest/node_modules/soap/lib/wsdl.js:578:18 at EventEmitter._tickCallback (node.js:235:9)

vartana avatar May 18 '12 21:05 vartana

me too^

code: // var soap = require('soap'); var url = 'http://192.168.1.100:8001/soa-infra/services/default/RznSearchService/RznSearchService_ep?WSDL';

soap.createClient(url, function(err, client) { console.log(err, client); });

console: // user161@webrzn:~/rznWebApp$ node soap

node.js:201 throw e; // process.nextTick error, or 'error' event on first tick ^ AssertionError: Invalid child type at [object Object].addChild (/home/user161/rznWebApp/node_modules/soap/lib/wsdl.js:318:9) at [object Object].endElement (/home/user161/rznWebApp/node_modules/soap/lib/wsdl.js:108:20) at [object Object]. (/home/user161/rznWebApp/node_modules/soap/lib/wsdl.js:897:13) at [object Object].emit (events.js:67:17) at [object Object].emit (/home/user161/rznWebApp/node_modules/soap/node_modules/node-expat/lib/node-expat.js:18:12) at [object Object].parse (/home/user161/rznWebApp/node_modules/soap/node_modules/node-expat/lib/node-expat.js:24:24) at [object Object]._parse (/home/user161/rznWebApp/node_modules/soap/lib/wsdl.js:900:12) at [object Object]._fromXML (/home/user161/rznWebApp/node_modules/soap/lib/wsdl.js:908:29) at Array.1 (/home/user161/rznWebApp/node_modules/soap/lib/wsdl.js:578:18) at EventEmitter._tickCallback (node.js:192:41)

muffik avatar Jun 21 '12 04:06 muffik

+1 here

ghost avatar Feb 12 '13 14:02 ghost

Most of the code assumes a single WSDL with no imports. I had to fork the code to get multi-WSDL support on a single server/client.

alanbly avatar Feb 12 '13 16:02 alanbly

+1. Have any of you guys found/implemented a workaround?

courthead avatar Sep 16 '13 04:09 courthead

@alanbly How did you do that?

vartana avatar Jan 06 '14 06:01 vartana

same error here for 0.4.0

abbaspour avatar Mar 06 '14 04:03 abbaspour

@courthead @vartana @abbaspour 0.4.1 was released last night. Can you try recreating the issue with the latest version? Thanks!

jsdevel avatar Mar 06 '14 05:03 jsdevel

@jsdevel Tried again with 0.4.2 and problem persists. Are imports the issue?

ruaanvds avatar Mar 28 '14 12:03 ruaanvds

@ruaanvds that is something I'm not entirely sure of. What would really help, is if you could recreate the issue, either with a wsdl under test/wsdl, or test/request-response-samples.

@abbaspour @ruaanvds, can you guys collaborate on this, or find the time to fix this? It would be greatly appreciated. Thanks!

jsdevel avatar Mar 29 '14 07:03 jsdevel