# HG changeset patch # User Aurelien Campeas # Date 1229618354 -3600 # Node ID 27b958dc72ae4c1b392fb94b04fa81348a243a6b # Parent 20d6de0fdcb1e7db0fb2a21f80c3a277dd54d877 [lxml] lxml version < 2 does not provide an iter method on some elements hence we fall back on another implementation of safe_cut diff -r 20d6de0fdcb1 -r 27b958dc72ae common/uilib.py --- a/common/uilib.py Thu Dec 18 15:43:39 2008 +0100 +++ b/common/uilib.py Thu Dec 18 17:39:14 2008 +0100 @@ -108,7 +108,8 @@ try: from lxml import etree -except ImportError: + etree.HTML('
test
').iter +except (ImportError, AttributeError): # gae environment: lxml not availabel def soup2xhtml(data, encoding):