Hello community, here is the log from the commit of package python-bleach for openSUSE:Factory checked in at 2017-12-11 18:56:32 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-bleach (Old) and /work/SRC/openSUSE:Factory/.python-bleach.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-bleach" Mon Dec 11 18:56:32 2017 rev:3 rq:555534 version:2.1.2 Changes: -------- --- /work/SRC/openSUSE:Factory/python-bleach/python-bleach.changes 2017-11-15 16:57:52.779858595 +0100 +++ /work/SRC/openSUSE:Factory/.python-bleach.new/python-bleach.changes 2017-12-11 18:56:36.934239885 +0100 @@ -1,0 +2,12 @@ +Thu Dec 7 16:50:14 UTC 2017 - [email protected] + +- specfile: + * update copyright year + +- update to version 2.1.2: + * Bug fixes + + Support html5lib-python 1.0.1. (#337) + + Add deprecation warning for supporting html5lib-python < 1.0. + + Switch to semver. + +------------------------------------------------------------------- Old: ---- bleach-2.1.1.tar.gz New: ---- bleach-2.1.2.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-bleach.spec ++++++ --- /var/tmp/diff_new_pack.eEOkmD/_old 2017-12-11 18:56:37.478213975 +0100 +++ /var/tmp/diff_new_pack.eEOkmD/_new 2017-12-11 18:56:37.482213784 +0100 @@ -19,7 +19,7 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-bleach -Version: 2.1.1 +Version: 2.1.2 Release: 0 Summary: An easy whitelist-based HTML-sanitizing tool License: Apache-2.0 @@ -28,6 +28,7 @@ Source: https://files.pythonhosted.org/packages/source/b/bleach/bleach-%{version}.tar.gz BuildRequires: %{python_module devel} BuildRequires: %{python_module html5lib >= 0.99999999} +BuildRequires: %{python_module pytest-runner} BuildRequires: %{python_module pytest} BuildRequires: %{python_module setuptools} BuildRequires: %{python_module six} ++++++ bleach-2.1.1.tar.gz -> bleach-2.1.2.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bleach-2.1.1/CHANGES new/bleach-2.1.2/CHANGES --- old/bleach-2.1.1/CHANGES 2017-10-02 20:45:41.000000000 +0200 +++ new/bleach-2.1.2/CHANGES 2017-12-07 17:01:22.000000000 +0100 @@ -1,6 +1,30 @@ Bleach Changes ============== +Version 2.1.2 (December 7th, 2017) +---------------------------------- + +**Security fixes** + +None + +**Backwards incompatible changes** + +None + +**Features** + +None + +**Bug fixes** + +* Support html5lib-python 1.0.1. (#337) + +* Add deprecation warning for supporting html5lib-python < 1.0. + +* Switch to semver. + + Version 2.1.1 (October 2nd, 2017) --------------------------------- diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bleach-2.1.1/PKG-INFO new/bleach-2.1.2/PKG-INFO --- old/bleach-2.1.1/PKG-INFO 2017-10-02 20:46:17.000000000 +0200 +++ new/bleach-2.1.2/PKG-INFO 2017-12-07 17:02:05.000000000 +0100 @@ -1,6 +1,6 @@ Metadata-Version: 1.1 Name: bleach -Version: 2.1.1 +Version: 2.1.2 Summary: An easy safelist-based HTML-sanitizing tool. Home-page: http://github.com/mozilla/bleach Author: Will Kahn-Greene @@ -17,7 +17,7 @@ .. image:: https://badge.fury.io/py/bleach.svg :target: http://badge.fury.io/py/bleach - Bleach is a allowed-list-based HTML sanitizing library that escapes or strips + Bleach is an allowed-list-based HTML sanitizing library that escapes or strips markup and attributes. Bleach can also linkify text safely, applying filters that Django's ``urlize`` @@ -133,6 +133,30 @@ Bleach Changes ============== + Version 2.1.2 (December 7th, 2017) + ---------------------------------- + + **Security fixes** + + None + + **Backwards incompatible changes** + + None + + **Features** + + None + + **Bug fixes** + + * Support html5lib-python 1.0.1. (#337) + + * Add deprecation warning for supporting html5lib-python < 1.0. + + * Switch to semver. + + Version 2.1.1 (October 2nd, 2017) --------------------------------- diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bleach-2.1.1/README.rst new/bleach-2.1.2/README.rst --- old/bleach-2.1.1/README.rst 2017-10-02 20:45:41.000000000 +0200 +++ new/bleach-2.1.2/README.rst 2017-12-07 17:01:22.000000000 +0100 @@ -8,7 +8,7 @@ .. image:: https://badge.fury.io/py/bleach.svg :target: http://badge.fury.io/py/bleach -Bleach is a allowed-list-based HTML sanitizing library that escapes or strips +Bleach is an allowed-list-based HTML sanitizing library that escapes or strips markup and attributes. Bleach can also linkify text safely, applying filters that Django's ``urlize`` diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bleach-2.1.1/bleach/__init__.py new/bleach-2.1.2/bleach/__init__.py --- old/bleach-2.1.1/bleach/__init__.py 2017-10-02 20:45:41.000000000 +0200 +++ new/bleach-2.1.2/bleach/__init__.py 2017-12-07 17:01:22.000000000 +0100 @@ -2,6 +2,7 @@ from __future__ import unicode_literals +import warnings from pkg_resources import parse_version from bleach.linkifier import ( @@ -17,10 +18,24 @@ ) +import html5lib +try: + _html5lib_version = html5lib.__version__.split('.') + if len(_html5lib_version) < 2: + _html5lib_version = _html5lib_version + ['0'] +except Exception: + _h5ml5lib_version = ['unknown', 'unknown'] + + +# Bleach 3.0.0 won't support html5lib-python < 1.0.0. +if _html5lib_version < ['1', '0'] or 'b' in _html5lib_version[1]: + warnings.warn('Support for html5lib-python < 1.0.0 is deprecated.', DeprecationWarning) + + # yyyymmdd -__releasedate__ = '20171002' -# x.y or x.y.dev0 -__version__ = '2.1.1' +__releasedate__ = '20171207' +# x.y.z or x.y.z.dev0 -- semver +__version__ = '2.1.2' VERSION = parse_version(__version__) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bleach-2.1.1/bleach/sanitizer.py new/bleach-2.1.2/bleach/sanitizer.py --- old/bleach-2.1.1/bleach/sanitizer.py 2017-10-02 20:45:41.000000000 +0200 +++ new/bleach-2.1.2/bleach/sanitizer.py 2017-12-07 17:01:22.000000000 +0100 @@ -9,11 +9,15 @@ import html5lib from html5lib.constants import ( entities, - ReparseException, namespaces, prefixes, tokenTypes, ) +try: + from html5lib.constants import ReparseException +except ImportError: + # html5lib-python 1.0 changed the name + from html5lib.constants import _ReparseException as ReparseException from html5lib.filters.base import Filter from html5lib.filters import sanitizer from html5lib.serializer import HTMLSerializer @@ -194,7 +198,9 @@ """ if not isinstance(text, six.string_types): - raise TypeError('argument must be of text type') + message = "argument cannot be of '{name}' type, must be of text type".format( + name=text.__class__.__name__) + raise TypeError(message) if not text: return u'' diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bleach-2.1.1/bleach.egg-info/PKG-INFO new/bleach-2.1.2/bleach.egg-info/PKG-INFO --- old/bleach-2.1.1/bleach.egg-info/PKG-INFO 2017-10-02 20:46:17.000000000 +0200 +++ new/bleach-2.1.2/bleach.egg-info/PKG-INFO 2017-12-07 17:02:05.000000000 +0100 @@ -1,6 +1,6 @@ Metadata-Version: 1.1 Name: bleach -Version: 2.1.1 +Version: 2.1.2 Summary: An easy safelist-based HTML-sanitizing tool. Home-page: http://github.com/mozilla/bleach Author: Will Kahn-Greene @@ -17,7 +17,7 @@ .. image:: https://badge.fury.io/py/bleach.svg :target: http://badge.fury.io/py/bleach - Bleach is a allowed-list-based HTML sanitizing library that escapes or strips + Bleach is an allowed-list-based HTML sanitizing library that escapes or strips markup and attributes. Bleach can also linkify text safely, applying filters that Django's ``urlize`` @@ -133,6 +133,30 @@ Bleach Changes ============== + Version 2.1.2 (December 7th, 2017) + ---------------------------------- + + **Security fixes** + + None + + **Backwards incompatible changes** + + None + + **Features** + + None + + **Bug fixes** + + * Support html5lib-python 1.0.1. (#337) + + * Add deprecation warning for supporting html5lib-python < 1.0. + + * Switch to semver. + + Version 2.1.1 (October 2nd, 2017) --------------------------------- diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bleach-2.1.1/tests/test_clean.py new/bleach-2.1.2/tests/test_clean.py --- old/bleach-2.1.1/tests/test_clean.py 2017-10-02 20:45:41.000000000 +0200 +++ new/bleach-2.1.2/tests/test_clean.py 2017-12-07 17:01:22.000000000 +0100 @@ -432,11 +432,13 @@ assert bleach.clean(some_text) == some_text - with pytest.raises(TypeError): + with pytest.raises(TypeError) as e: bleach.clean(some_type) + assert "argument cannot be of 'type' type" in str(e) - with pytest.raises(TypeError): + with pytest.raises(TypeError) as e: bleach.clean(no_type) + assert "NoneType" in str(e) class TestCleaner: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bleach-2.1.1/tox.ini new/bleach-2.1.2/tox.ini --- old/bleach-2.1.1/tox.ini 2017-10-02 20:45:41.000000000 +0200 +++ new/bleach-2.1.2/tox.ini 2017-12-07 17:01:22.000000000 +0100 @@ -5,7 +5,7 @@ [tox] envlist = - py{27,33,34,35,36}-html5lib{99999999,999999999,10b9,10b10} + py{27,33,34,35,36}-html5lib{99999999,999999999,10b9,10b10,101} pypy-html5lib99999999 py{27,33,34,35,36}-build-no-lang docs @@ -24,6 +24,7 @@ html5lib999999999: html5lib==0.999999999 html5lib10b9: html5lib==1.0b9 html5lib10b10: html5lib==1.0b10 + html5lib101: html5lib==1.0.1 commands = py.test {posargs:-v} python setup.py build
