﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
18239	Only use custom subclass of HTMLParser for Python versions with buggy stdlib HTMLParser	Carl Meyer	nobody	"Django currently has its own subclass of `HTMLParser` (in `django.utils.html_parser.HTMLParser`). It exists in order to patch [http://bugs.python.org/issue670664 a bug] in the standard library's `HTMLParser` in Python 2.5 and older versions of 2.6 and 2.7. The bug has been fixed in Python 2.6.8, 2.7.3, and will be fixed in the upcoming 3.3 as well. There are also other fixes in 3.3's `HTMLParser` which conflict with the patched version in Django, since it relies on numerous undocumented internals.

For better forward-compatibility, we should only use our patched subclass for versions of Python known to contain the bug, and otherwise simply use the standard library's `HTMLParser` directly.

When we make this change, we can also roll back r17456, as that was simply papering over a breakage due to the modified `HTMLParser` in 2.6.8 and 2.7.3 - that will no longer be a problem if we don't try to use our subclass with those (and newer) Pythons."	Bug	closed	Core (Other)	1.3	Release blocker	fixed		Raphaël Hertzog	Accepted	1	0	0	0	0	0
