[Checkins] SVN: z3c.pt/trunk/z3c/pt/translation.py API change for lxml 2.x series.

Malthe Borch mborch at gmail.com
Wed May 14 06:15:26 EDT 2008


Log message for revision 86727:
  API change for lxml 2.x series.

Changed:
  U   z3c.pt/trunk/z3c/pt/translation.py

-=-
Modified: z3c.pt/trunk/z3c/pt/translation.py
===================================================================
--- z3c.pt/trunk/z3c/pt/translation.py	2008-05-14 10:12:43 UTC (rev 86726)
+++ z3c.pt/trunk/z3c/pt/translation.py	2008-05-14 10:15:25 UTC (rev 86727)
@@ -366,8 +366,8 @@
 parser = lxml.etree.XMLParser()
 parser.setElementClassLookup(lookup)
 
-lxml.etree.Namespace('http://www.w3.org/1999/xhtml')[None] = Element
-lxml.etree.Namespace('http://xml.zope.org/namespaces/tal')[None] = TALElement
+lookup.get_namespace('http://www.w3.org/1999/xhtml')[None] = Element
+lookup.get_namespace('http://xml.zope.org/namespaces/tal')[None] = TALElement
 
 def translate_xml(body, *args, **kwargs):
     tree = lxml.etree.parse(StringIO(body), parser)



More information about the Checkins mailing list