| 1 |
Change Log |
| 2 |
---------- |
| 3 |
|
| 4 |
1.2 |
| 5 |
~~~ |
| 6 |
|
| 7 |
Unreleased yet |
| 8 |
|
| 9 |
Features: |
| 10 |
|
| 11 |
* Add support for the ``<wbr>`` element in the sanitizer, `which indicates |
| 12 |
a line break opportunity <https://html.spec.whatwg.org/#the-wbr-element>`_. |
| 13 |
This element is allowed by default. (#395) (Thank you, Tom Most!) |
| 14 |
* Add support for serializing the ``<ol reversed>`` boolean attribute. (Thank |
| 15 |
you, Tom Most!) (#396) |
| 16 |
* The ``<ol reversed>`` and ``<ol start>`` attributes are now permitted by the |
| 17 |
sanitizer. (#321) (Thank you, Tom Most!) |
| 18 |
|
| 19 |
Bug fixes: |
| 20 |
|
| 21 |
* The sanitizer now permits ``<summary>`` tags. It used to allow ``<details>`` |
| 22 |
already. (#423) |
| 23 |
|
| 24 |
1.1 |
| 25 |
~~~ |
| 26 |
|
| 27 |
Released on June 23, 2020 |
| 28 |
|
| 29 |
Breaking changes: |
| 30 |
|
| 31 |
* Drop support for Python 3.3. (#358) |
| 32 |
* Drop support for Python 3.4. (#421) |
| 33 |
|
| 34 |
Deprecations: |
| 35 |
|
| 36 |
* Deprecate the ``html5lib`` sanitizer (``html5lib.serialize(sanitize=True)`` and |
| 37 |
``html5lib.filters.sanitizer``). We recommend users migrate to `Bleach |
| 38 |
<https://github.com/mozilla/bleach>`. Please let us know if Bleach doesn't suffice for your |
| 39 |
use. (#443) |
| 40 |
|
| 41 |
Other changes: |
| 42 |
|
| 43 |
* Try to import from ``collections.abc`` to remove DeprecationWarning and ensure |
| 44 |
``html5lib`` keeps working in future Python versions. (#403) |
| 45 |
* Drop optional ``datrie`` dependency. (#442) |
| 46 |
|
| 47 |
1.0.1 |
| 48 |
~~~~~ |
| 49 |
|
| 50 |
Released on December 7, 2017 |
| 51 |
|
| 52 |
Breaking changes: |
| 53 |
|
| 54 |
* Drop support for Python 2.6. (#330) (Thank you, Hugo, Will Kahn-Greene!) |
| 55 |
* Remove ``utils/spider.py`` (#353) (Thank you, Jon Dufresne!) |
| 56 |
|
| 57 |
Features: |
| 58 |
|
| 59 |
* Improve documentation. (#300, #307) (Thank you, Jon Dufresne, Tom Most, |
| 60 |
Will Kahn-Greene!) |
| 61 |
* Add iframe seamless boolean attribute. (Thank you, Ritwik Gupta!) |
| 62 |
* Add itemscope as a boolean attribute. (#194) (Thank you, Jonathan Vanasco!) |
| 63 |
* Support Python 3.6. (#333) (Thank you, Jon Dufresne!) |
| 64 |
* Add CI support for Windows using AppVeyor. (Thank you, John Vandenberg!) |
| 65 |
* Improve testing and CI and add code coverage (#323, #334), (Thank you, Jon |
| 66 |
Dufresne, John Vandenberg, Sam Sneddon, Will Kahn-Greene!) |
| 67 |
* Semver-compliant version number. |
| 68 |
|
| 69 |
Bug fixes: |
| 70 |
|
| 71 |
* Add support for setuptools < 18.5 to support environment markers. (Thank you, |
| 72 |
John Vandenberg!) |
| 73 |
* Add explicit dependency for six >= 1.9. (Thank you, Eric Amorde!) |
| 74 |
* Fix regexes to work with Python 3.7 regex adjustments. (#318, #379) (Thank |
| 75 |
you, Benedikt Morbach, Ville Skyttä, Mark Vasilkov!) |
| 76 |
* Fix alphabeticalattributes filter namespace bug. (#324) (Thank you, Will |
| 77 |
Kahn-Greene!) |
| 78 |
* Include license file in generated wheel package. (#350) (Thank you, Jon |
| 79 |
Dufresne!) |
| 80 |
* Fix annotation-xml typo. (#339) (Thank you, Will Kahn-Greene!) |
| 81 |
* Allow uppercase hex chararcters in CSS colour check. (#377) (Thank you, |
| 82 |
Komal Dembla, Hugo!) |
| 83 |
|
| 84 |
|
| 85 |
1.0 |
| 86 |
~~~ |
| 87 |
|
| 88 |
Released and unreleased on December 7, 2017. Badly packaged release. |
| 89 |
|
| 90 |
|
| 91 |
0.999999999/1.0b10 |
| 92 |
~~~~~~~~~~~~~~~~~~ |
| 93 |
|
| 94 |
Released on July 15, 2016 |
| 95 |
|
| 96 |
* Fix attribute order going to the tree builder to be document order |
| 97 |
instead of reverse document order(!). |
| 98 |
|
| 99 |
|
| 100 |
0.99999999/1.0b9 |
| 101 |
~~~~~~~~~~~~~~~~ |
| 102 |
|
| 103 |
Released on July 14, 2016 |
| 104 |
|
| 105 |
* **Added ordereddict as a mandatory dependency on Python 2.6.** |
| 106 |
|
| 107 |
* Added ``lxml``, ``genshi``, ``datrie``, ``charade``, and ``all`` |
| 108 |
extras that will do the right thing based on the specific |
| 109 |
interpreter implementation. |
| 110 |
|
| 111 |
* Now requires the ``mock`` package for the testsuite. |
| 112 |
|
| 113 |
* Cease supporting DATrie under PyPy. |
| 114 |
|
| 115 |
* **Remove PullDOM support, as this hasn't ever been properly |
| 116 |
tested, doesn't entirely work, and as far as I can tell is |
| 117 |
completely unused by anyone.** |
| 118 |
|
| 119 |
* Move testsuite to ``pytest``. |
| 120 |
|
| 121 |
* **Fix #124: move to webencodings for decoding the input byte stream; |
| 122 |
this makes html5lib compliant with the Encoding Standard, and |
| 123 |
introduces a required dependency on webencodings.** |
| 124 |
|
| 125 |
* **Cease supporting Python 3.2 (in both CPython and PyPy forms).** |
| 126 |
|
| 127 |
* **Fix comments containing double-dash with lxml 3.5 and above.** |
| 128 |
|
| 129 |
* **Use scripting disabled by default (as we don't implement |
| 130 |
scripting).** |
| 131 |
|
| 132 |
* **Fix #11, avoiding the XSS bug potentially caused by serializer |
| 133 |
allowing attribute values to be escaped out of in old browser versions, |
| 134 |
changing the quote_attr_values option on serializer to take one of |
| 135 |
three values, "always" (the old True value), "legacy" (the new option, |
| 136 |
and the new default), and "spec" (the old False value, and the old |
| 137 |
default).** |
| 138 |
|
| 139 |
* **Fix #72 by rewriting the sanitizer to apply only to treewalkers |
| 140 |
(instead of the tokenizer); as such, this will require amending all |
| 141 |
callers of it to use it via the treewalker API.** |
| 142 |
|
| 143 |
* **Drop support of charade, now that chardet is supported once more.** |
| 144 |
|
| 145 |
* **Replace the charset keyword argument on parse and related methods |
| 146 |
with a set of keyword arguments: override_encoding, transport_encoding, |
| 147 |
same_origin_parent_encoding, likely_encoding, and default_encoding.** |
| 148 |
|
| 149 |
* **Move filters._base, treebuilder._base, and treewalkers._base to .base |
| 150 |
to clarify their status as public.** |
| 151 |
|
| 152 |
* **Get rid of the sanitizer package. Merge sanitizer.sanitize into the |
| 153 |
sanitizer.htmlsanitizer module and move that to sanitizer. This means |
| 154 |
anyone who used sanitizer.sanitize or sanitizer.HTMLSanitizer needs no |
| 155 |
code changes.** |
| 156 |
|
| 157 |
* **Rename treewalkers.lxmletree to .etree_lxml and |
| 158 |
treewalkers.genshistream to .genshi to have a consistent API.** |
| 159 |
|
| 160 |
* Move a whole load of stuff (inputstream, ihatexml, trie, tokenizer, |
| 161 |
utils) to be underscore prefixed to clarify their status as private. |
| 162 |
|
| 163 |
|
| 164 |
0.9999999/1.0b8 |
| 165 |
~~~~~~~~~~~~~~~ |
| 166 |
|
| 167 |
Released on September 10, 2015 |
| 168 |
|
| 169 |
* Fix #195: fix the sanitizer to drop broken URLs (it threw an |
| 170 |
exception between 0.9999 and 0.999999). |
| 171 |
|
| 172 |
|
| 173 |
0.999999/1.0b7 |
| 174 |
~~~~~~~~~~~~~~ |
| 175 |
|
| 176 |
Released on July 7, 2015 |
| 177 |
|
| 178 |
* Fix #189: fix the sanitizer to allow relative URLs again (as it did |
| 179 |
prior to 0.9999/1.0b5). |
| 180 |
|
| 181 |
|
| 182 |
0.99999/1.0b6 |
| 183 |
~~~~~~~~~~~~~ |
| 184 |
|
| 185 |
Released on April 30, 2015 |
| 186 |
|
| 187 |
* Fix #188: fix the sanitizer to not throw an exception when sanitizing |
| 188 |
bogus data URLs. |
| 189 |
|
| 190 |
|
| 191 |
0.9999/1.0b5 |
| 192 |
~~~~~~~~~~~~ |
| 193 |
|
| 194 |
Released on April 29, 2015 |
| 195 |
|
| 196 |
* Fix #153: Sanitizer fails to treat some attributes as URLs. Despite how |
| 197 |
this sounds, this has no known security implications. No known version |
| 198 |
of IE (5.5 to current), Firefox (3 to current), Safari (6 to current), |
| 199 |
Chrome (1 to current), or Opera (12 to current) will run any script |
| 200 |
provided in these attributes. |
| 201 |
|
| 202 |
* Pass error message to the ParseError exception in strict parsing mode. |
| 203 |
|
| 204 |
* Allow data URIs in the sanitizer, with a whitelist of content-types. |
| 205 |
|
| 206 |
* Add support for Python implementations that don't support lone |
| 207 |
surrogates (read: Jython). Fixes #2. |
| 208 |
|
| 209 |
* Remove localization of error messages. This functionality was totally |
| 210 |
unused (and untested that everything was localizable), so we may as |
| 211 |
well follow numerous browsers in not supporting translating technical |
| 212 |
strings. |
| 213 |
|
| 214 |
* Expose treewalkers.pprint as a public API. |
| 215 |
|
| 216 |
* Add a documentEncoding property to HTML5Parser, fix #121. |
| 217 |
|
| 218 |
|
| 219 |
0.999 |
| 220 |
~~~~~ |
| 221 |
|
| 222 |
Released on December 23, 2013 |
| 223 |
|
| 224 |
* Fix #127: add work-around for CPython issue #20007: .read(0) on |
| 225 |
http.client.HTTPResponse drops the rest of the content. |
| 226 |
|
| 227 |
* Fix #115: lxml treewalker can now deal with fragments containing, at |
| 228 |
their root level, text nodes with non-ASCII characters on Python 2. |
| 229 |
|
| 230 |
|
| 231 |
0.99 |
| 232 |
~~~~ |
| 233 |
|
| 234 |
Released on September 10, 2013 |
| 235 |
|
| 236 |
* No library changes from 1.0b3; released as 0.99 as pip has changed |
| 237 |
behaviour from 1.4 to avoid installing pre-release versions per |
| 238 |
PEP 440. |
| 239 |
|
| 240 |
|
| 241 |
1.0b3 |
| 242 |
~~~~~ |
| 243 |
|
| 244 |
Released on July 24, 2013 |
| 245 |
|
| 246 |
* Removed ``RecursiveTreeWalker`` from ``treewalkers._base``. Any |
| 247 |
implementation using it should be moved to |
| 248 |
``NonRecursiveTreeWalker``, as everything bundled with html5lib has |
| 249 |
for years. |
| 250 |
|
| 251 |
* Fix #67 so that ``BufferedStream`` to correctly returns a bytes |
| 252 |
object, thereby fixing any case where html5lib is passed a |
| 253 |
non-seekable RawIOBase-like object. |
| 254 |
|
| 255 |
|
| 256 |
1.0b2 |
| 257 |
~~~~~ |
| 258 |
|
| 259 |
Released on June 27, 2013 |
| 260 |
|
| 261 |
* Removed reordering of attributes within the serializer. There is now |
| 262 |
an ``alphabetical_attributes`` option which preserves the previous |
| 263 |
behaviour through a new filter. This allows attribute order to be |
| 264 |
preserved through html5lib if the tree builder preserves order. |
| 265 |
|
| 266 |
* Removed ``dom2sax`` from DOM treebuilders. It has been replaced by |
| 267 |
``treeadapters.sax.to_sax`` which is generic and supports any |
| 268 |
treewalker; it also resolves all known bugs with ``dom2sax``. |
| 269 |
|
| 270 |
* Fix treewalker assertions on hitting bytes strings on |
| 271 |
Python 2. Previous to 1.0b1, treewalkers coped with mixed |
| 272 |
bytes/unicode data on Python 2; this reintroduces this prior |
| 273 |
behaviour on Python 2. Behaviour is unchanged on Python 3. |
| 274 |
|
| 275 |
|
| 276 |
1.0b1 |
| 277 |
~~~~~ |
| 278 |
|
| 279 |
Released on May 17, 2013 |
| 280 |
|
| 281 |
* Implementation updated to implement the `HTML specification |
| 282 |
<http://www.whatwg.org/specs/web-apps/current-work/>`_ as of 5th May |
| 283 |
2013 (`SVN <http://svn.whatwg.org/webapps/>`_ revision r7867). |
| 284 |
|
| 285 |
* Python 3.2+ supported in a single codebase using the ``six`` library. |
| 286 |
|
| 287 |
* Removed support for Python 2.5 and older. |
| 288 |
|
| 289 |
* Removed the deprecated Beautiful Soup 3 treebuilder. |
| 290 |
``beautifulsoup4`` can use ``html5lib`` as a parser instead. Note that |
| 291 |
since it doesn't support namespaces, foreign content like SVG and |
| 292 |
MathML is parsed incorrectly. |
| 293 |
|
| 294 |
* Removed ``simpletree`` from the package. The default tree builder is |
| 295 |
now ``etree`` (using the ``xml.etree.cElementTree`` implementation if |
| 296 |
available, and ``xml.etree.ElementTree`` otherwise). |
| 297 |
|
| 298 |
* Removed the ``XHTMLSerializer`` as it never actually guaranteed its |
| 299 |
output was well-formed XML, and hence provided little of use. |
| 300 |
|
| 301 |
* Removed default DOM treebuilder, so ``html5lib.treebuilders.dom`` is no |
| 302 |
longer supported. ``html5lib.treebuilders.getTreeBuilder("dom")`` will |
| 303 |
return the default DOM treebuilder, which uses ``xml.dom.minidom``. |
| 304 |
|
| 305 |
* Optional heuristic character encoding detection now based on |
| 306 |
``charade`` for Python 2.6 - 3.3 compatibility. |
| 307 |
|
| 308 |
* Optional ``Genshi`` treewalker support fixed. |
| 309 |
|
| 310 |
* Many bugfixes, including: |
| 311 |
|
| 312 |
* #33: null in attribute value breaks XML AttValue; |
| 313 |
|
| 314 |
* #4: nested, indirect descendant, <button> causes infinite loop; |
| 315 |
|
| 316 |
* `Google Code 215 |
| 317 |
<http://code.google.com/p/html5lib/issues/detail?id=215>`_: Properly |
| 318 |
detect seekable streams; |
| 319 |
|
| 320 |
* `Google Code 206 |
| 321 |
<http://code.google.com/p/html5lib/issues/detail?id=206>`_: add |
| 322 |
support for <video preload=...>, <audio preload=...>; |
| 323 |
|
| 324 |
* `Google Code 205 |
| 325 |
<http://code.google.com/p/html5lib/issues/detail?id=205>`_: add |
| 326 |
support for <video poster=...>; |
| 327 |
|
| 328 |
* `Google Code 202 |
| 329 |
<http://code.google.com/p/html5lib/issues/detail?id=202>`_: Unicode |
| 330 |
file breaks InputStream. |
| 331 |
|
| 332 |
* Source code is now mostly PEP 8 compliant. |
| 333 |
|
| 334 |
* Test harness has been improved and now depends on ``nose``. |
| 335 |
|
| 336 |
* Documentation updated and moved to https://html5lib.readthedocs.io/. |
| 337 |
|
| 338 |
|
| 339 |
0.95 |
| 340 |
~~~~ |
| 341 |
|
| 342 |
Released on February 11, 2012 |
| 343 |
|
| 344 |
|
| 345 |
0.90 |
| 346 |
~~~~ |
| 347 |
|
| 348 |
Released on January 17, 2010 |
| 349 |
|
| 350 |
|
| 351 |
0.11.1 |
| 352 |
~~~~~~ |
| 353 |
|
| 354 |
Released on June 12, 2008 |
| 355 |
|
| 356 |
|
| 357 |
0.11 |
| 358 |
~~~~ |
| 359 |
|
| 360 |
Released on June 10, 2008 |
| 361 |
|
| 362 |
|
| 363 |
0.10 |
| 364 |
~~~~ |
| 365 |
|
| 366 |
Released on October 7, 2007 |
| 367 |
|
| 368 |
|
| 369 |
0.9 |
| 370 |
~~~ |
| 371 |
|
| 372 |
Released on March 11, 2007 |
| 373 |
|
| 374 |
|
| 375 |
0.2 |
| 376 |
~~~ |
| 377 |
|
| 378 |
Released on January 8, 2007 |