Message251987
My thinking is that the knowledge that <img> does not have a closing tag is at a higher level than the current HTMLParser class. It is similar to knowing where the following HTML implicitly closes the <li> elements:
<ul><li>Item A<li>Item B</ul>
In both cases I would not expect the HTMLParser to report “virtual” empty or closing tags. I don’t think it should report an empty <img/> or closing </img> tag just because that is easy to do, because it would be inconsistent with other implied HTML tags. But maybe see what other people say.
I don’t know your particular use case, but I would suggest if you need to parse non-XML HTML <img> tags, use the handle_starttag() method and don’t rely on the end tag :) |
|
Date |
User |
Action |
Args |
2015-10-01 02:05:15 | martin.panter | set | recipients:
+ martin.panter, ezio.melotti, josh.r, xiang.zhang, Chenyun Yang |
2015-10-01 02:05:15 | martin.panter | set | messageid: <1443665115.49.0.126579485236.issue25258@psf.upfronthosting.co.za> |
2015-10-01 02:05:15 | martin.panter | link | issue25258 messages |
2015-10-01 02:05:14 | martin.panter | create | |
|