rewrite python engine (stop using lxml/etree for parsing)