From afb630aac3a0bc6c207aa848b0b3a62bb5732e57 Mon Sep 17 00:00:00 2001 From: SauZheR Date: Wed, 16 May 2012 16:46:37 +0200 Subject: [PATCH] regexp was too restrictive. Some SOAP response could not be validated cause of tag like . Instead is better to search for a pattern were _x is specific followed by 4 hexdigits. All other _x matches should be ignored --- src/wstools/XMLname.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/wstools/XMLname.py b/src/wstools/XMLname.py index 5961160..eb5ed4c 100644 --- a/src/wstools/XMLname.py +++ b/src/wstools/XMLname.py @@ -85,6 +85,7 @@ def fromXMLname(string): def fun( matchobj ): return _fromUnicodeHex( matchobj.group(0) ) - retval = sub(r'_x[0-9A-Za-z]+_', fun, retval ) - + + retval = sub(r'_x[0-9A-Fa-f]{4}_', fun, retval ) + return retval