added conditional import of lxml to get around py2.6 ElementTree not supporting enough XPath