[Fedora-suds-list] type not found in inline WSDL from NIH

Jeff Ortel jortel at redhat.com
Fri Dec 11 16:48:08 UTC 2009


Hey Ben.

On 12/10/2009 04:53 PM, Ben Adida wrote:
>
> Hi folks,
>
> I'm looking to access the NIH's National Library of Medicine SOAP
> service. The WSDL file is here:
>
> http://umlsks.nlm.nih.gov/UMLSKS/services/UMLSKSService?wsdl
>
> It contains a *lot* of inline data types, and for some reason I'm
> getting the dreaded TypeNotFound error. The typical import workaround
> doesn't seem right since this is an inline type.

This wsdl represents something that I have been battling with over the years.  I defines 
18 schemas which reference types from each other and *none* of them have the proper 
<xs:import/>s.  Just because the schema is defined with the same wsdl, they must import 
namespaces defined in other schemas.  That said, I see this all the time.  Some wsdls do 
this properly and others don't.  I've contemplated how to deal with this may times.  I 
could automatically import all schema defined within the wsdl into each other.  My concern 
here is that this is a very heavy handed approach.  Most wsdls have linear dependencies 
between schemas.  But, the author of the NIH wsdl seems to assume that all of the schemas 
defined within the wsdl have magic visibility into each other.

In looking through the wsdl specifications, I can't find anything that addresses directly. 
  Or, indirectly as to what the expectation is when schemas are defined in the wsdl. 
However, based on wsdls I've seen and what the specifications do say, I've maintained the 
position that schemas defined within the wsdl have the same import requirements as those 
defined outside the wsdl.  Comments on this would be appreciated :)

Anyway, the ImportDoctor was defined partially with this kind of wsdl in mind.  But, 
clearly it would be a pain to create an ImportDoctor and correctly add the necessary 
(maybe all 18) Imports.  So, as an **experiment**, I added an **experimental** option in 
0.3.8 beta named 'autoblend'.  This option (and I really might rename it so be careful), 
is false by default but when set to true:

client = Client(url, autoblend=True)

it will automatically ensure that all the schemas defined in the wsdl have imports for 
each other.  This works on the NIH wsdl.  I'm leaving this as **experimantal** because it 
is so heavy handed.

Again, note the emphasis on experimental :)

Hope this helps.

-jeff

>
> This is suds 0.3.7.
>
> -Ben
>
> _______________________________________________
> fedora-suds-list mailing list
> fedora-suds-list at redhat.com
> https://www.redhat.com/mailman/listinfo/fedora-suds-list

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5126 bytes
Desc: S/MIME Cryptographic Signature
Url : http://lists.fedoraproject.org/pipermail/suds/attachments/20091211/92cb293e/attachment.bin 


More information about the suds mailing list