Re: Parsing HTML with xml.etree in Python 2.7?

2015-10-05 Thread Skip Montanaro
On Mon, Oct 5, 2015 at 9:14 AM, Skip Montanaro wrote: > I wouldn't be surprised if there were some small API changes other than the > name change caused by the move into the xml package. Before I dive into a > rabbit hole and start to modify elementtidy, is there some other stdlib-only > way to pa

Parsing HTML with xml.etree in Python 2.7?

2015-10-05 Thread Skip Montanaro
Back before Fredrik Lundh's elementtree module was sucked into the Python stdlib as xml.etree, I used to use his elementtidy extension module to clean up HTML source so it could be parsed into an ElementTree object. Elementtidy hasn't be updated in about ten years, and still assumes there is a modu