From 8818e0ca9745d76bfd61e2ed1a692f1f7de62c4b Mon Sep 17 00:00:00 2001 From: Joshua Boverhof Date: Tue, 24 Jan 2006 20:51:57 +0000 Subject: [PATCH] ---------------------------------------------------------------------- Committing in . Modified Files: ZSI/wstools/Utility.py -- add little check for None $ wsdl2py.py -f authority.xml.html Traceback (most recent call last): File "/Library/Frameworks/Python.framework/Versions/2.4/bin/wsdl2py.py", line 7, in ? execfile(__file__) File "/Users/boverhof/Desktop/Workspace/Python/zsi/scripts/wsdl2py.py", line 196, in ? main() File "/Users/boverhof/Desktop/Workspace/Python/zsi/scripts/wsdl2py.py", line 183, in main wsm.writeClient(fd) File "/Users/boverhof/Desktop/Workspace/Python/zsi/ZSI/generate/wsdl2python.py", line 211, in writeClient sd.fromWsdl(service, **kw) File "/Users/boverhof/Desktop/Workspace/Python/zsi/ZSI/generate/wsdl2python.py", line 273, in fromWsdl self.locator.setUp(service) File "/Users/boverhof/Desktop/Workspace/Python/zsi/ZSI/generate/containers.py", line 331, in setUp info = (p.getBinding().getPortType().name, p.getBinding().name, ab.location) File "/Users/boverhof/Desktop/Workspace/Python/zsi/ZSI/wstools/WSDLTools.py", line 1106, in getBinding return wsdl.bindings[self.binding] File "/Users/boverhof/Desktop/Workspace/Python/zsi/ZSI/wstools/Utility.py", line 1169, in __getitem__ return self.data[nsuri][name] KeyError: u'http://www.omg.org/LSID/2003/AuthorityServiceSOAPBindings' ---------------------------------------------------------------------- --- Utility.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Utility.py b/Utility.py index 17b1e99..b9353b3 100755 --- a/Utility.py +++ b/Utility.py @@ -611,7 +611,7 @@ class DOM: """Return a true value if two namespace uri values match.""" if value == wanted or (type(wanted) is tt) and value in wanted: return 1 - if not strict: + if not strict and value is not None: wanted = type(wanted) is tt and wanted or (wanted,) value = value[-1:] != '/' and value or value[:-1] for item in wanted: