openSUSE Commits
Threads by month
- ----- 2025 -----
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2007 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2006 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
December 2016
- 1 participants
- 377 discussions
Hello community,
here is the log from the commit of package python-zake for openSUSE:Factory checked in at 2016-12-08 00:30:08
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-zake (Old)
and /work/SRC/openSUSE:Factory/.python-zake.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-zake"
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-zake/python-zake.changes 2015-05-19 23:47:47.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.python-zake.new/python-zake.changes 2016-12-08 00:30:09.000000000 +0100
@@ -1,0 +2,5 @@
+Tue Nov 15 10:10:15 UTC 2016 - dmueller(a)suse.com
+
+- update to 0.2.2
+
+-------------------------------------------------------------------
Old:
----
zake-0.2.1.tar.gz
New:
----
zake-0.2.2.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-zake.spec ++++++
--- /var/tmp/diff_new_pack.YabV0B/_old 2016-12-08 00:30:10.000000000 +0100
+++ /var/tmp/diff_new_pack.YabV0B/_new 2016-12-08 00:30:10.000000000 +0100
@@ -1,7 +1,7 @@
#
# spec file for package python-zake
#
-# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -17,13 +17,13 @@
Name: python-zake
-Version: 0.2.1
+Version: 0.2.2
Release: 0
Summary: Testing utilities for the kazoo library
License: Apache-2.0
Group: Development/Languages/Python
Url: https://github.com/yahoo/Zake
-Source: https://pypi.python.org/packages/source/z/zake/zake-%{version}.tar.gz
+Source: https://pypi.io/packages/source/z/zake/zake-%{version}.tar.gz
BuildRequires: python-devel
BuildRequires: python-kazoo
BuildRequires: python-nose
++++++ zake-0.2.1.tar.gz -> zake-0.2.2.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zake-0.2.1/PKG-INFO new/zake-0.2.2/PKG-INFO
--- old/zake-0.2.1/PKG-INFO 2015-03-11 01:47:47.000000000 +0100
+++ new/zake-0.2.2/PKG-INFO 2015-05-27 07:06:07.000000000 +0200
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: zake
-Version: 0.2.1
+Version: 0.2.2
Summary: A python package that works to provide a nice set of testing utilities for the kazoo library.
Home-page: https://github.com/yahoo/Zake
Author: Joshua Harlow
@@ -41,5 +41,4 @@
Classifier: Programming Language :: Python :: 2.6
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: 3
-Classifier: Programming Language :: Python :: 3.3
Classifier: Programming Language :: Python :: 3.4
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zake-0.2.1/setup.cfg new/zake-0.2.2/setup.cfg
--- old/zake-0.2.1/setup.cfg 2015-03-11 01:47:47.000000000 +0100
+++ new/zake-0.2.2/setup.cfg 2015-05-27 07:06:07.000000000 +0200
@@ -1,6 +1,9 @@
[global]
verbose = 0
+[bdist_wheel]
+universal = 1
+
[egg_info]
tag_build =
tag_date = 0
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zake-0.2.1/setup.py new/zake-0.2.2/setup.py
--- old/zake-0.2.1/setup.py 2015-03-11 01:47:03.000000000 +0100
+++ new/zake-0.2.2/setup.py 2015-05-27 07:02:33.000000000 +0200
@@ -26,7 +26,7 @@
setup(
name='zake',
- version='0.2.1',
+ version='0.2.2',
description='A python package that works to provide a nice set of '
'testing utilities for the kazoo library.',
author="Joshua Harlow",
@@ -34,7 +34,7 @@
url='https://github.com/yahoo/Zake',
license="ASL 2.0",
install_requires=[
- 'kazoo',
+ 'kazoo>=1.3.1,!=2.1',
'six',
],
classifiers=[
@@ -47,7 +47,6 @@
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
- "Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
],
keywords="kazoo testing zookeeper",
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zake-0.2.1/zake.egg-info/PKG-INFO new/zake-0.2.2/zake.egg-info/PKG-INFO
--- old/zake-0.2.1/zake.egg-info/PKG-INFO 2015-03-11 01:47:47.000000000 +0100
+++ new/zake-0.2.2/zake.egg-info/PKG-INFO 2015-05-27 07:06:07.000000000 +0200
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: zake
-Version: 0.2.1
+Version: 0.2.2
Summary: A python package that works to provide a nice set of testing utilities for the kazoo library.
Home-page: https://github.com/yahoo/Zake
Author: Joshua Harlow
@@ -41,5 +41,4 @@
Classifier: Programming Language :: Python :: 2.6
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: 3
-Classifier: Programming Language :: Python :: 3.3
Classifier: Programming Language :: Python :: 3.4
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zake-0.2.1/zake.egg-info/SOURCES.txt new/zake-0.2.2/zake.egg-info/SOURCES.txt
--- old/zake-0.2.1/zake.egg-info/SOURCES.txt 2015-03-11 01:47:47.000000000 +0100
+++ new/zake-0.2.2/zake.egg-info/SOURCES.txt 2015-05-27 07:06:07.000000000 +0200
@@ -10,6 +10,7 @@
zake.egg-info/PKG-INFO
zake.egg-info/SOURCES.txt
zake.egg-info/dependency_links.txt
+zake.egg-info/pbr.json
zake.egg-info/requires.txt
zake.egg-info/top_level.txt
zake/tests/__init__.py
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zake-0.2.1/zake.egg-info/pbr.json new/zake-0.2.2/zake.egg-info/pbr.json
--- old/zake-0.2.1/zake.egg-info/pbr.json 1970-01-01 01:00:00.000000000 +0100
+++ new/zake-0.2.2/zake.egg-info/pbr.json 2015-05-27 07:06:07.000000000 +0200
@@ -0,0 +1 @@
+{"is_release": false, "git_version": "f9b3f58"}
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zake-0.2.1/zake.egg-info/requires.txt new/zake-0.2.2/zake.egg-info/requires.txt
--- old/zake-0.2.1/zake.egg-info/requires.txt 2015-03-11 01:47:47.000000000 +0100
+++ new/zake-0.2.2/zake.egg-info/requires.txt 2015-05-27 07:06:07.000000000 +0200
@@ -1,2 +1,2 @@
-kazoo
+kazoo>=1.3.1,!=2.1
six
\ No newline at end of file
1
0
Hello community,
here is the log from the commit of package python-msgpack-python for openSUSE:Factory checked in at 2016-12-08 00:30:04
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-msgpack-python (Old)
and /work/SRC/openSUSE:Factory/.python-msgpack-python.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-msgpack-python"
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-msgpack-python/python-msgpack-python.changes 2015-10-20 00:08:29.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.python-msgpack-python.new/python-msgpack-python.changes 2016-12-08 00:30:05.000000000 +0100
@@ -1,0 +2,5 @@
+Tue Nov 15 10:08:12 UTC 2016 - dmueller(a)suse.com
+
+- update to 0.4.8
+
+-------------------------------------------------------------------
Old:
----
msgpack-python-0.4.6.tar.gz
New:
----
msgpack-python-0.4.8.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-msgpack-python.spec ++++++
--- /var/tmp/diff_new_pack.BDXBry/_old 2016-12-08 00:30:06.000000000 +0100
+++ /var/tmp/diff_new_pack.BDXBry/_new 2016-12-08 00:30:06.000000000 +0100
@@ -1,7 +1,7 @@
#
# spec file for package python-msgpack-python
#
-# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -19,13 +19,13 @@
%bcond_without test
Name: python-msgpack-python
-Version: 0.4.6
+Version: 0.4.8
Release: 0
Summary: MessagePack (de)serializer
License: Apache-2.0
Group: Development/Languages/Python
Url: http://msgpack.org/
-Source: https://pypi.python.org/packages/source/m/msgpack-python/msgpack-python-%{v…
+Source: https://pypi.io/packages/source/m/msgpack-python/msgpack-python-%{version}.…
BuildRequires: gcc-c++
%if 0%{?suse_version} && 0%{?suse_version} <= 1110
BuildRequires: python-argparse
++++++ msgpack-python-0.4.6.tar.gz -> msgpack-python-0.4.8.tar.gz ++++++
++++ 25042 lines of diff (skipped)
1
0
Hello community,
here is the log from the commit of package python-jsonpointer for openSUSE:Factory checked in at 2016-12-08 00:29:58
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-jsonpointer (Old)
and /work/SRC/openSUSE:Factory/.python-jsonpointer.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-jsonpointer"
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-jsonpointer/python-jsonpointer.changes 2016-08-17 12:05:20.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.python-jsonpointer.new/python-jsonpointer.changes 2016-12-08 00:29:59.000000000 +0100
@@ -1,0 +2,7 @@
+Tue Nov 15 10:51:34 UTC 2016 - dmueller(a)suse.com
+
+- update to 1.10:
+ * Drop support for Python 3.2
+ * Add support for Python 3.5
+
+-------------------------------------------------------------------
Old:
----
jsonpointer-1.9.tar.gz
New:
----
jsonpointer-1.10.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-jsonpointer.spec ++++++
--- /var/tmp/diff_new_pack.5nAJGF/_old 2016-12-08 00:30:00.000000000 +0100
+++ /var/tmp/diff_new_pack.5nAJGF/_new 2016-12-08 00:30:00.000000000 +0100
@@ -1,7 +1,7 @@
#
# spec file for package python-jsonpointer
#
-# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -17,13 +17,13 @@
Name: python-jsonpointer
-Version: 1.9
+Version: 1.10
Release: 0
Summary: Identify specific nodes in a JSON document
License: BSD-3-Clause
Group: Development/Languages/Python
Url: https://github.com/stefankoegl/python-json-pointer
-Source: http://pypi.python.org/packages/source/j/jsonpointer/jsonpointer-%{version}…
+Source: https://pypi.io/packages/source/j/jsonpointer/jsonpointer-%{version}.tar.gz
BuildRequires: python-devel
BuildRequires: python-setuptools
Requires(post): update-alternatives
++++++ jsonpointer-1.9.tar.gz -> jsonpointer-1.10.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/jsonpointer-1.9/PKG-INFO new/jsonpointer-1.10/PKG-INFO
--- old/jsonpointer-1.9/PKG-INFO 2015-05-07 18:01:17.000000000 +0200
+++ new/jsonpointer-1.10/PKG-INFO 2015-10-28 20:12:49.000000000 +0100
@@ -1,34 +1,27 @@
Metadata-Version: 1.1
Name: jsonpointer
-Version: 1.9
+Version: 1.10
Summary: Identify specific nodes in a JSON document (RFC 6901)
Home-page: https://github.com/stefankoegl/python-json-pointer
Author: Stefan Kögl
Author-email: stefan(a)skoegl.net
License: Modified BSD License
-Description: python-json-pointer `|Build Status| <https://travis-ci.org/stefankoegl/python-json-pointer>`_ `|Coverage Status| <https://coveralls.io/r/stefankoegl/python-json-pointer?branch=master>`_ |Downloads| |Version|
- ===============================================================================================================================================================================================================
+Description: python-json-pointer [![Build Status](https://secure.travis-ci.org/stefankoegl/python-json-pointer.png?br… [![Coverage Status](https://coveralls.io/repos/stefankoegl/python-json-pointer/badge.png?branch=master)](https://coveralls.io/r/stefankoegl/python-json-pointer?branch=master) ![Downloads](https://pypip.in/d/jsonpointer/badge.png) ![Version](https://pypip.in/v/jsonpointer/badge.png)
+ ===================
Resolve JSON Pointers in Python
-------------------------------
- Library to resolve JSON Pointers according to `RFC
- 6901 <http://tools.ietf.org/html/rfc6901>`_
+ Library to resolve JSON Pointers according to
+ [RFC 6901](http://tools.ietf.org/html/rfc6901)
- See Sourcecode for Examples \* Website:
- https://github.com/stefankoegl/python-json-pointer \* Repository:
- https://github.com/stefankoegl/python-json-pointer.git \* Documentation:
- https://python-json-pointer.readthedocs.org/ \* PyPI:
- https://pypi.python.org/pypi/jsonpointer \* Travis-CI:
- https://travis-ci.org/stefankoegl/python-json-pointer \* Coveralls:
- https://coveralls.io/r/stefankoegl/python-json-pointer
-
- .. |Build
- Status| image:: https://secure.travis-ci.org/stefankoegl/python-json-pointer.png?branch=mas…
- .. |Coverage
- Status| image:: https://coveralls.io/repos/stefankoegl/python-json-pointer/badge.png?branch…
- .. |Downloads| image:: https://pypip.in/d/jsonpointer/badge.png
- .. |Version| image:: https://pypip.in/v/jsonpointer/badge.png
+ See Sourcecode for Examples
+ * Website: https://github.com/stefankoegl/python-json-pointer
+ * Repository: https://github.com/stefankoegl/python-json-pointer.git
+ * Documentation: https://python-json-pointer.readthedocs.org/
+ * PyPI: https://pypi.python.org/pypi/jsonpointer
+ * Travis-CI: https://travis-ci.org/stefankoegl/python-json-pointer
+ * Coveralls: https://coveralls.io/r/stefankoegl/python-json-pointer
Platform: UNKNOWN
Classifier: Development Status :: 5 - Production/Stable
@@ -41,9 +34,9 @@
Classifier: Programming Language :: Python :: 2.6
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: 3
-Classifier: Programming Language :: Python :: 3.2
Classifier: Programming Language :: Python :: 3.3
Classifier: Programming Language :: Python :: 3.4
+Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
Classifier: Topic :: Software Development :: Libraries
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/jsonpointer-1.9/jsonpointer.egg-info/PKG-INFO new/jsonpointer-1.10/jsonpointer.egg-info/PKG-INFO
--- old/jsonpointer-1.9/jsonpointer.egg-info/PKG-INFO 2015-05-07 18:01:17.000000000 +0200
+++ new/jsonpointer-1.10/jsonpointer.egg-info/PKG-INFO 2015-10-28 20:12:49.000000000 +0100
@@ -1,34 +1,27 @@
Metadata-Version: 1.1
Name: jsonpointer
-Version: 1.9
+Version: 1.10
Summary: Identify specific nodes in a JSON document (RFC 6901)
Home-page: https://github.com/stefankoegl/python-json-pointer
Author: Stefan Kögl
Author-email: stefan(a)skoegl.net
License: Modified BSD License
-Description: python-json-pointer `|Build Status| <https://travis-ci.org/stefankoegl/python-json-pointer>`_ `|Coverage Status| <https://coveralls.io/r/stefankoegl/python-json-pointer?branch=master>`_ |Downloads| |Version|
- ===============================================================================================================================================================================================================
+Description: python-json-pointer [![Build Status](https://secure.travis-ci.org/stefankoegl/python-json-pointer.png?br… [![Coverage Status](https://coveralls.io/repos/stefankoegl/python-json-pointer/badge.png?branch=master)](https://coveralls.io/r/stefankoegl/python-json-pointer?branch=master) ![Downloads](https://pypip.in/d/jsonpointer/badge.png) ![Version](https://pypip.in/v/jsonpointer/badge.png)
+ ===================
Resolve JSON Pointers in Python
-------------------------------
- Library to resolve JSON Pointers according to `RFC
- 6901 <http://tools.ietf.org/html/rfc6901>`_
+ Library to resolve JSON Pointers according to
+ [RFC 6901](http://tools.ietf.org/html/rfc6901)
- See Sourcecode for Examples \* Website:
- https://github.com/stefankoegl/python-json-pointer \* Repository:
- https://github.com/stefankoegl/python-json-pointer.git \* Documentation:
- https://python-json-pointer.readthedocs.org/ \* PyPI:
- https://pypi.python.org/pypi/jsonpointer \* Travis-CI:
- https://travis-ci.org/stefankoegl/python-json-pointer \* Coveralls:
- https://coveralls.io/r/stefankoegl/python-json-pointer
-
- .. |Build
- Status| image:: https://secure.travis-ci.org/stefankoegl/python-json-pointer.png?branch=mas…
- .. |Coverage
- Status| image:: https://coveralls.io/repos/stefankoegl/python-json-pointer/badge.png?branch…
- .. |Downloads| image:: https://pypip.in/d/jsonpointer/badge.png
- .. |Version| image:: https://pypip.in/v/jsonpointer/badge.png
+ See Sourcecode for Examples
+ * Website: https://github.com/stefankoegl/python-json-pointer
+ * Repository: https://github.com/stefankoegl/python-json-pointer.git
+ * Documentation: https://python-json-pointer.readthedocs.org/
+ * PyPI: https://pypi.python.org/pypi/jsonpointer
+ * Travis-CI: https://travis-ci.org/stefankoegl/python-json-pointer
+ * Coveralls: https://coveralls.io/r/stefankoegl/python-json-pointer
Platform: UNKNOWN
Classifier: Development Status :: 5 - Production/Stable
@@ -41,9 +34,9 @@
Classifier: Programming Language :: Python :: 2.6
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: 3
-Classifier: Programming Language :: Python :: 3.2
Classifier: Programming Language :: Python :: 3.3
Classifier: Programming Language :: Python :: 3.4
+Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
Classifier: Topic :: Software Development :: Libraries
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/jsonpointer-1.9/jsonpointer.py new/jsonpointer-1.10/jsonpointer.py
--- old/jsonpointer-1.9/jsonpointer.py 2015-05-07 18:00:28.000000000 +0200
+++ new/jsonpointer-1.10/jsonpointer.py 2015-10-28 20:06:33.000000000 +0100
@@ -41,7 +41,7 @@
# Will be parsed by setup.py to determine package metadata
__author__ = 'Stefan Kögl <stefan(a)skoegl.net>'
-__version__ = '1.9'
+__version__ = '1.10'
__website__ = 'https://github.com/stefankoegl/python-json-pointer'
__license__ = 'Modified BSD License'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/jsonpointer-1.9/setup.py new/jsonpointer-1.10/setup.py
--- old/jsonpointer-1.9/setup.py 2015-04-23 22:08:29.000000000 +0200
+++ new/jsonpointer-1.10/setup.py 2015-10-28 20:05:06.000000000 +0100
@@ -45,9 +45,9 @@
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
- 'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
+ 'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: Implementation :: PyPy',
'Topic :: Software Development :: Libraries',
1
0
Hello community,
here is the log from the commit of package python-jsonpatch for openSUSE:Factory checked in at 2016-12-08 00:29:53
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-jsonpatch (Old)
and /work/SRC/openSUSE:Factory/.python-jsonpatch.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-jsonpatch"
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-jsonpatch/python-jsonpatch.changes 2016-08-17 12:05:45.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.python-jsonpatch.new/python-jsonpatch.changes 2016-12-08 00:29:54.000000000 +0100
@@ -1,0 +2,5 @@
+Tue Nov 15 10:53:42 UTC 2016 - dmueller(a)suse.com
+
+- udpate to 1.14.0
+
+-------------------------------------------------------------------
Old:
----
jsonpatch-1.11.tar.gz
New:
----
jsonpatch-1.14.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-jsonpatch.spec ++++++
--- /var/tmp/diff_new_pack.w2wWiU/_old 2016-12-08 00:29:55.000000000 +0100
+++ /var/tmp/diff_new_pack.w2wWiU/_new 2016-12-08 00:29:55.000000000 +0100
@@ -1,7 +1,7 @@
#
# spec file for package python-jsonpatch
#
-# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -17,13 +17,13 @@
Name: python-jsonpatch
-Version: 1.11
+Version: 1.14
Release: 0
Summary: Python - JSON-Patches
License: BSD-3-Clause
Group: Development/Languages/Python
Url: https://github.com/stefankoegl/python-json-patch
-Source: http://pypi.python.org/packages/source/j/jsonpatch/jsonpatch-%{version}.tar…
+Source: https://pypi.io/packages/source/j/jsonpatch/jsonpatch-%{version}.tar.gz
BuildRequires: python-devel
BuildRequires: python-jsonpointer
Requires: python-jsonpointer >= 1.9
++++++ jsonpatch-1.11.tar.gz -> jsonpatch-1.14.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/jsonpatch-1.11/PKG-INFO new/jsonpatch-1.14/PKG-INFO
--- old/jsonpatch-1.11/PKG-INFO 2015-05-08 18:10:53.000000000 +0200
+++ new/jsonpatch-1.14/PKG-INFO 2016-05-31 20:24:55.000000000 +0200
@@ -1,34 +1,46 @@
Metadata-Version: 1.1
Name: jsonpatch
-Version: 1.11
+Version: 1.14
Summary: Apply JSON-Patches (RFC 6902)
Home-page: https://github.com/stefankoegl/python-json-patch
Author: Stefan Kögl
Author-email: stefan(a)skoegl.net
License: Modified BSD License
-Description: python-json-patch [![Build Status](https://secure.travis-ci.org/stefankoegl/python-json-patch.png?bran… [![Coverage Status](https://coveralls.io/repos/stefankoegl/python-json-patch/badge.png?branch=master)](https://coveralls.io/r/stefankoegl/python-json-patch?branch=master) ![Downloads](https://pypip.in/d/jsonpatch/badge.png) ![Version](https://pypip.in/v/jsonpatch/badge.png)
- =================
+Description: python-json-patch |Build Status| |Coverage Status| |Downloads| |Version|
+ ========================================================================
+
Applying JSON Patches in Python
-------------------------------
- Library to apply JSON Patches according to
- [RFC 6902](http://tools.ietf.org/html/rfc6902)
+ Library to apply JSON Patches according to `RFC
+ 6902 <http://tools.ietf.org/html/rfc6902>`__
See Sourcecode for Examples
- * Website: https://github.com/stefankoegl/python-json-patch
- * Repository: https://github.com/stefankoegl/python-json-patch.git
- * Documentation: https://python-json-patch.readthedocs.org/
- * PyPI: https://pypi.python.org/pypi/jsonpatch
- * Travis-CI: https://travis-ci.org/stefankoegl/python-json-patch
- * Coveralls: https://coveralls.io/r/stefankoegl/python-json-patch
+ - Website: https://github.com/stefankoegl/python-json-patch
+ - Repository: https://github.com/stefankoegl/python-json-patch.git
+ - Documentation: https://python-json-patch.readthedocs.org/
+ - PyPI: https://pypi.python.org/pypi/jsonpatch
+ - Travis-CI: https://travis-ci.org/stefankoegl/python-json-patch
+ - Coveralls: https://coveralls.io/r/stefankoegl/python-json-patch
Running external tests
----------------------
- To run external tests (such as those from https://github.com/json-patch/json-patch-tests) use ext_test.py
+
+ To run external tests (such as those from
+ https://github.com/json-patch/json-patch-tests) use ext\_test.py
+
+ ::
./ext_tests.py ../json-patch-tests/tests.json
+ .. |Build Status| image:: https://secure.travis-ci.org/stefankoegl/python-json-patch.png?branch=master
+ :target: https://travis-ci.org/stefankoegl/python-json-patch
+ .. |Coverage Status| image:: https://coveralls.io/repos/stefankoegl/python-json-patch/badge.png?branch=m…
+ :target: https://coveralls.io/r/stefankoegl/python-json-patch?branch=master
+ .. |Downloads| image:: https://pypip.in/d/jsonpatch/badge.png
+ .. |Version| image:: https://pypip.in/v/jsonpatch/badge.png
+
Platform: UNKNOWN
Classifier: Development Status :: 5 - Production/Stable
Classifier: Environment :: Console
@@ -43,6 +55,7 @@
Classifier: Programming Language :: Python :: 3.2
Classifier: Programming Language :: Python :: 3.3
Classifier: Programming Language :: Python :: 3.4
+Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
Classifier: Topic :: Software Development :: Libraries
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/jsonpatch-1.11/ext_tests.py new/jsonpatch-1.14/ext_tests.py
--- old/jsonpatch-1.11/ext_tests.py 2013-12-25 12:54:46.000000000 +0100
+++ new/jsonpatch-1.14/ext_tests.py 2016-02-13 15:35:46.000000000 +0100
@@ -60,12 +60,15 @@
)
else:
- res = jsonpatch.apply_patch(test['doc'], test['patch'])
+ try:
+ res = jsonpatch.apply_patch(test['doc'], test['patch'])
+ except jsonpatch.JsonPatchException as jpe:
+ raise Exception(test.get('comment', '')) from jpe
# if there is no 'expected' we only verify that applying the patch
# does not raies an exception
if 'expected' in test:
- self.assertEquals(res, test['expected'])
+ self.assertEquals(res, test['expected'], test.get('comment', ''))
def make_test_case(tests):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/jsonpatch-1.11/jsonpatch.egg-info/PKG-INFO new/jsonpatch-1.14/jsonpatch.egg-info/PKG-INFO
--- old/jsonpatch-1.11/jsonpatch.egg-info/PKG-INFO 2015-05-08 18:10:53.000000000 +0200
+++ new/jsonpatch-1.14/jsonpatch.egg-info/PKG-INFO 2016-05-31 20:24:55.000000000 +0200
@@ -1,34 +1,46 @@
Metadata-Version: 1.1
Name: jsonpatch
-Version: 1.11
+Version: 1.14
Summary: Apply JSON-Patches (RFC 6902)
Home-page: https://github.com/stefankoegl/python-json-patch
Author: Stefan Kögl
Author-email: stefan(a)skoegl.net
License: Modified BSD License
-Description: python-json-patch [![Build Status](https://secure.travis-ci.org/stefankoegl/python-json-patch.png?bran… [![Coverage Status](https://coveralls.io/repos/stefankoegl/python-json-patch/badge.png?branch=master)](https://coveralls.io/r/stefankoegl/python-json-patch?branch=master) ![Downloads](https://pypip.in/d/jsonpatch/badge.png) ![Version](https://pypip.in/v/jsonpatch/badge.png)
- =================
+Description: python-json-patch |Build Status| |Coverage Status| |Downloads| |Version|
+ ========================================================================
+
Applying JSON Patches in Python
-------------------------------
- Library to apply JSON Patches according to
- [RFC 6902](http://tools.ietf.org/html/rfc6902)
+ Library to apply JSON Patches according to `RFC
+ 6902 <http://tools.ietf.org/html/rfc6902>`__
See Sourcecode for Examples
- * Website: https://github.com/stefankoegl/python-json-patch
- * Repository: https://github.com/stefankoegl/python-json-patch.git
- * Documentation: https://python-json-patch.readthedocs.org/
- * PyPI: https://pypi.python.org/pypi/jsonpatch
- * Travis-CI: https://travis-ci.org/stefankoegl/python-json-patch
- * Coveralls: https://coveralls.io/r/stefankoegl/python-json-patch
+ - Website: https://github.com/stefankoegl/python-json-patch
+ - Repository: https://github.com/stefankoegl/python-json-patch.git
+ - Documentation: https://python-json-patch.readthedocs.org/
+ - PyPI: https://pypi.python.org/pypi/jsonpatch
+ - Travis-CI: https://travis-ci.org/stefankoegl/python-json-patch
+ - Coveralls: https://coveralls.io/r/stefankoegl/python-json-patch
Running external tests
----------------------
- To run external tests (such as those from https://github.com/json-patch/json-patch-tests) use ext_test.py
+
+ To run external tests (such as those from
+ https://github.com/json-patch/json-patch-tests) use ext\_test.py
+
+ ::
./ext_tests.py ../json-patch-tests/tests.json
+ .. |Build Status| image:: https://secure.travis-ci.org/stefankoegl/python-json-patch.png?branch=master
+ :target: https://travis-ci.org/stefankoegl/python-json-patch
+ .. |Coverage Status| image:: https://coveralls.io/repos/stefankoegl/python-json-patch/badge.png?branch=m…
+ :target: https://coveralls.io/r/stefankoegl/python-json-patch?branch=master
+ .. |Downloads| image:: https://pypip.in/d/jsonpatch/badge.png
+ .. |Version| image:: https://pypip.in/v/jsonpatch/badge.png
+
Platform: UNKNOWN
Classifier: Development Status :: 5 - Production/Stable
Classifier: Environment :: Console
@@ -43,6 +55,7 @@
Classifier: Programming Language :: Python :: 3.2
Classifier: Programming Language :: Python :: 3.3
Classifier: Programming Language :: Python :: 3.4
+Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
Classifier: Topic :: Software Development :: Libraries
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/jsonpatch-1.11/jsonpatch.egg-info/SOURCES.txt new/jsonpatch-1.14/jsonpatch.egg-info/SOURCES.txt
--- old/jsonpatch-1.11/jsonpatch.egg-info/SOURCES.txt 2015-05-08 18:10:53.000000000 +0200
+++ new/jsonpatch-1.14/jsonpatch.egg-info/SOURCES.txt 2016-05-31 20:24:55.000000000 +0200
@@ -5,6 +5,7 @@
ext_tests.py
jsonpatch.py
requirements.txt
+setup.cfg
setup.py
tests.py
bin/jsondiff
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/jsonpatch-1.11/jsonpatch.egg-info/requires.txt new/jsonpatch-1.14/jsonpatch.egg-info/requires.txt
--- old/jsonpatch-1.11/jsonpatch.egg-info/requires.txt 2015-05-08 18:10:53.000000000 +0200
+++ new/jsonpatch-1.14/jsonpatch.egg-info/requires.txt 2016-05-31 20:24:55.000000000 +0200
@@ -1 +1 @@
-jsonpointer>=1.9
+jsonpointer>=1.9
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/jsonpatch-1.11/jsonpatch.py new/jsonpatch-1.14/jsonpatch.py
--- old/jsonpatch-1.11/jsonpatch.py 2015-05-08 18:07:25.000000000 +0200
+++ new/jsonpatch-1.14/jsonpatch.py 2016-05-31 18:51:21.000000000 +0200
@@ -51,7 +51,7 @@
# Will be parsed by setup.py to determine package metadata
__author__ = 'Stefan Kögl <stefan(a)skoegl.net>'
-__version__ = '1.11'
+__version__ = '1.14'
__website__ = 'https://github.com/stefankoegl/python-json-patch'
__license__ = 'Modified BSD License'
@@ -484,6 +484,10 @@
except (KeyError, IndexError) as ex:
raise JsonPatchConflict(str(ex))
+ # If source and target are equal, this is a no-op
+ if self.pointer == from_ptr:
+ return obj
+
if isinstance(subobj, MutableMapping) and \
self.pointer.contains(from_ptr):
raise JsonPatchConflict('Cannot move values into its own children')
@@ -641,7 +645,7 @@
(by[0], by[0] + y[0])),
_split_by_common_seq(src[x[1]:], dst[y[1]:],
(bx[0] + x[1], bx[0] + len(src)),
- (bx[0] + y[1], bx[0] + len(dst)))]
+ (by[0] + y[1], by[0] + len(dst)))]
def _compare(path, src, dst, left, right):
@@ -756,11 +760,18 @@
def _optimize_using_replace(prev, cur):
- """Optimises JSON patch by using ``replace`` operation instead of
- ``remove`` and ``add`` against the same path."""
+ """Optimises by replacing ``add``/``remove`` with ``replace`` on same path
+
+ For nested strucures, tries to recurse replacement, see #36 """
prev['op'] = 'replace'
if cur['op'] == 'add':
- prev['value'] = cur['value']
+ # make recursive patch
+ patch = make_patch(prev['value'], cur['value'])
+ if len(patch.patch) == 1 and patch.patch[0]['op'] != 'remove':
+ prev['path'] = prev['path'] + patch.patch[0]['path']
+ prev['value'] = patch.patch[0]['value']
+ else:
+ prev['value'] = cur['value']
def _optimize_using_move(prev_item, item):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/jsonpatch-1.11/setup.cfg new/jsonpatch-1.14/setup.cfg
--- old/jsonpatch-1.11/setup.cfg 2015-05-08 18:10:53.000000000 +0200
+++ new/jsonpatch-1.14/setup.cfg 2016-05-31 20:24:55.000000000 +0200
@@ -1,5 +1,8 @@
+[bdist_wheel]
+universal = 1
+
[egg_info]
-tag_build =
-tag_date = 0
tag_svn_revision = 0
+tag_date = 0
+tag_build =
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/jsonpatch-1.11/setup.py new/jsonpatch-1.14/setup.py
--- old/jsonpatch-1.11/setup.py 2014-10-25 15:26:26.000000000 +0200
+++ new/jsonpatch-1.14/setup.py 2016-02-13 19:04:52.000000000 +0100
@@ -1,4 +1,5 @@
#!/usr/bin/env python
+# -*- coding: utf-8 -*-
import sys
import io
@@ -66,6 +67,7 @@
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
+ 'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: Implementation :: PyPy',
'Topic :: Software Development :: Libraries',
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/jsonpatch-1.11/tests.py new/jsonpatch-1.14/tests.py
--- old/jsonpatch-1.11/tests.py 2015-05-08 18:03:57.000000000 +0200
+++ new/jsonpatch-1.14/tests.py 2016-05-31 18:46:45.000000000 +0200
@@ -317,6 +317,15 @@
res = jsonpatch.apply_patch(src, patch)
self.assertEqual(res, dst)
+ def test_use_replace_instead_of_remove_add_nested(self):
+ src = {'foo': [{'bar': 1, 'baz': 2}, {'bar': 2, 'baz': 3}]}
+ dst = {'foo': [{'bar': 1}, {'bar': 2, 'baz': 3}]}
+ patch = list(jsonpatch.make_patch(src, dst))
+ self.assertEqual(len(patch), 1)
+ self.assertEqual(patch[0]['op'], 'replace')
+ res = jsonpatch.apply_patch(src, patch)
+ self.assertEqual(res, dst)
+
def test_use_move_instead_of_remove_add(self):
src = {'foo': [4, 1, 2, 3]}
dst = {'foo': [1, 2, 3, 4]}
@@ -359,6 +368,29 @@
res = patch.apply(src)
self.assertEqual(res, dst)
+ def test_issue40(self):
+ """ Tests an issue in _split_by_common_seq reported in #40 """
+
+ src = [8, 7, 2, 1, 0, 9, 4, 3, 5, 6]
+ dest = [7, 2, 1, 0, 9, 4, 3, 6, 5, 8]
+ patch = jsonpatch.make_patch(src, dest)
+
+ def test_minimal_patch(self):
+ """ Test whether a minimal patch is created, see #36 """
+ src = [{"foo": 1, "bar": 2}]
+ dst = [{"foo": 2, "bar": 2}]
+ patch = jsonpatch.make_patch(src, dst)
+
+ exp = [
+ {
+ "path": "/0/foo",
+ "value": 2,
+ "op": "replace"
+ }
+ ]
+
+ self.assertEqual(patch.patch, exp)
+
class InvalidInputTests(unittest.TestCase):
@@ -414,30 +446,30 @@
self.assertRaises(jsonpatch.JsonPatchConflict, jsonpatch.apply_patch, src, patch_obj)
-
-modules = ['jsonpatch']
+if __name__ == '__main__':
+ modules = ['jsonpatch']
-def get_suite():
- suite = unittest.TestSuite()
- suite.addTest(doctest.DocTestSuite(jsonpatch))
- suite.addTest(unittest.makeSuite(ApplyPatchTestCase))
- suite.addTest(unittest.makeSuite(EqualityTestCase))
- suite.addTest(unittest.makeSuite(MakePatchTestCase))
- suite.addTest(unittest.makeSuite(InvalidInputTests))
- suite.addTest(unittest.makeSuite(ConflictTests))
- return suite
+ def get_suite():
+ suite = unittest.TestSuite()
+ suite.addTest(doctest.DocTestSuite(jsonpatch))
+ suite.addTest(unittest.makeSuite(ApplyPatchTestCase))
+ suite.addTest(unittest.makeSuite(EqualityTestCase))
+ suite.addTest(unittest.makeSuite(MakePatchTestCase))
+ suite.addTest(unittest.makeSuite(InvalidInputTests))
+ suite.addTest(unittest.makeSuite(ConflictTests))
+ return suite
-suite = get_suite()
+ suite = get_suite()
-for module in modules:
- m = __import__(module, fromlist=[module])
- suite.addTest(doctest.DocTestSuite(m))
+ for module in modules:
+ m = __import__(module, fromlist=[module])
+ suite.addTest(doctest.DocTestSuite(m))
-runner = unittest.TextTestRunner(verbosity=1)
+ runner = unittest.TextTestRunner(verbosity=1)
-result = runner.run(suite)
+ result = runner.run(suite)
-if not result.wasSuccessful():
- sys.exit(1)
+ if not result.wasSuccessful():
+ sys.exit(1)
1
0
Hello community,
here is the log from the commit of package python-futures for openSUSE:Factory checked in at 2016-12-08 00:29:49
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-futures (Old)
and /work/SRC/openSUSE:Factory/.python-futures.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-futures"
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-futures/python-futures.changes 2015-09-17 09:20:30.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.python-futures.new/python-futures.changes 2016-12-08 00:29:50.000000000 +0100
@@ -1,0 +2,9 @@
+Tue Nov 15 10:18:20 UTC 2016 - dmueller(a)suse.com
+
+- update to 3.0.5:
+ - Fixed OverflowError with ProcessPoolExecutor on Windows (regression introduced in 3.0.4)
+ - Fixed inability to forcibly terminate the process if there are pending workers
+ - Fixed AttributeErrors on exit on Python 2.x
+ - remove upstreamed fix-testsuite.patch
+
+-------------------------------------------------------------------
Old:
----
fix-testsuite.patch
futures-3.0.2.tar.gz
New:
----
futures-3.0.5.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-futures.spec ++++++
--- /var/tmp/diff_new_pack.6Cf9Da/_old 2016-12-08 00:29:51.000000000 +0100
+++ /var/tmp/diff_new_pack.6Cf9Da/_new 2016-12-08 00:29:51.000000000 +0100
@@ -1,7 +1,7 @@
#
# spec file for package python-futures
#
-# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -17,15 +17,13 @@
Name: python-futures
-Version: 3.0.2
+Version: 3.0.5
Release: 0
Summary: Backport of the concurrent.futures package from Python 3.2
License: BSD-2-Clause
Group: Development/Languages/Python
Url: http://code.google.com/p/pythonfutures
Source: http://pypi.python.org/packages/source/f/futures/futures-%{version}.tar.gz
-# PATCH-FIX-OPENSUSE fix-testsuite.patch -- fix testsuite expectations
-Patch0: fix-testsuite.patch
BuildRequires: python-devel
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%if 0%{?suse_version} && 0%{?suse_version} <= 1110
@@ -43,7 +41,6 @@
%prep
%setup -q -n futures-%{version}
-%patch0 -p1
%build
python setup.py build
++++++ futures-3.0.2.tar.gz -> futures-3.0.5.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/futures-3.0.2/CHANGES new/futures-3.0.5/CHANGES
--- old/futures-3.0.2/CHANGES 2015-05-12 08:37:47.000000000 +0200
+++ new/futures-3.0.5/CHANGES 2016-02-14 22:40:14.000000000 +0100
@@ -1,3 +1,21 @@
+3.0.5
+=====
+
+- Fixed OverflowError with ProcessPoolExecutor on Windows (regression introduced in 3.0.4)
+
+
+3.0.4
+=====
+
+- Fixed inability to forcibly terminate the process if there are pending workers
+
+
+3.0.3
+=====
+
+- Fixed AttributeErrors on exit on Python 2.x
+
+
3.0.2
=====
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/futures-3.0.2/PKG-INFO new/futures-3.0.5/PKG-INFO
--- old/futures-3.0.2/PKG-INFO 2015-05-12 08:38:34.000000000 +0200
+++ new/futures-3.0.5/PKG-INFO 2016-02-14 22:51:15.000000000 +0100
@@ -1,6 +1,6 @@
Metadata-Version: 1.0
Name: futures
-Version: 3.0.2
+Version: 3.0.5
Summary: Backport of the concurrent.futures package from Python 3.2
Home-page: https://github.com/agronholm/pythonfutures
Author: Alex Gronholm
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/futures-3.0.2/concurrent/futures/_base.py new/futures-3.0.5/concurrent/futures/_base.py
--- old/futures-3.0.2/concurrent/futures/_base.py 2015-05-03 08:27:36.000000000 +0200
+++ new/futures-3.0.5/concurrent/futures/_base.py 2016-01-18 01:35:19.000000000 +0100
@@ -227,7 +227,8 @@
finally:
for f in fs:
- f._waiters.remove(waiter)
+ with f._condition:
+ f._waiters.remove(waiter)
DoneAndNotDoneFutures = collections.namedtuple(
'DoneAndNotDoneFutures', 'done not_done')
@@ -274,7 +275,8 @@
waiter.event.wait(timeout)
for f in fs:
- f._waiters.remove(waiter)
+ with f._condition:
+ f._waiters.remove(waiter)
done.update(waiter.finished_futures)
return DoneAndNotDoneFutures(done, set(fs) - done)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/futures-3.0.2/concurrent/futures/process.py new/futures-3.0.5/concurrent/futures/process.py
--- old/futures-3.0.2/concurrent/futures/process.py 2015-05-03 07:36:12.000000000 +0200
+++ new/futures-3.0.5/concurrent/futures/process.py 2016-02-14 22:40:41.000000000 +0100
@@ -73,11 +73,11 @@
def _python_exit():
global _shutdown
_shutdown = True
- items = list(_threads_queues.items())
+ items = list(_threads_queues.items()) if _threads_queues else ()
for t, q in items:
q.put(None)
for t, q in items:
- t.join()
+ t.join(sys.maxint)
# Controls how many more calls than processes will be queued in the call queue.
# A smaller number will mean that processes spend more time idle waiting for
@@ -347,7 +347,7 @@
# Wake up queue management thread
self._result_queue.put(None)
if wait:
- self._queue_management_thread.join()
+ self._queue_management_thread.join(sys.maxint)
# To reduce the risk of openning too many files, remove references to
# objects that use file descriptors.
self._queue_management_thread = None
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/futures-3.0.2/concurrent/futures/thread.py new/futures-3.0.5/concurrent/futures/thread.py
--- old/futures-3.0.2/concurrent/futures/thread.py 2015-05-03 07:36:12.000000000 +0200
+++ new/futures-3.0.5/concurrent/futures/thread.py 2016-01-18 01:38:32.000000000 +0100
@@ -32,11 +32,11 @@
def _python_exit():
global _shutdown
_shutdown = True
- items = list(_threads_queues.items())
+ items = list(_threads_queues.items()) if _threads_queues else ()
for t, q in items:
q.put(None)
for t, q in items:
- t.join()
+ t.join(sys.maxint)
atexit.register(_python_exit)
@@ -130,5 +130,5 @@
self._work_queue.put(None)
if wait:
for t in self._threads:
- t.join()
+ t.join(sys.maxint)
shutdown.__doc__ = _base.Executor.shutdown.__doc__
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/futures-3.0.2/docs/index.rst new/futures-3.0.5/docs/index.rst
--- old/futures-3.0.2/docs/index.rst 2015-05-03 07:36:12.000000000 +0200
+++ new/futures-3.0.5/docs/index.rst 2016-01-18 01:35:19.000000000 +0100
@@ -112,7 +112,7 @@
.. class:: ThreadPoolExecutor(max_workers)
- Executes calls asynchronously using at pool of at most *max_workers* threads.
+ Executes calls asynchronously using a pool of at most *max_workers* threads.
.. _threadpoolexecutor-example:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/futures-3.0.2/futures.egg-info/PKG-INFO new/futures-3.0.5/futures.egg-info/PKG-INFO
--- old/futures-3.0.2/futures.egg-info/PKG-INFO 2015-05-12 08:38:34.000000000 +0200
+++ new/futures-3.0.5/futures.egg-info/PKG-INFO 2016-02-14 22:51:15.000000000 +0100
@@ -1,6 +1,6 @@
Metadata-Version: 1.0
Name: futures
-Version: 3.0.2
+Version: 3.0.5
Summary: Backport of the concurrent.futures package from Python 3.2
Home-page: https://github.com/agronholm/pythonfutures
Author: Alex Gronholm
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/futures-3.0.2/futures.egg-info/pbr.json new/futures-3.0.5/futures.egg-info/pbr.json
--- old/futures-3.0.2/futures.egg-info/pbr.json 2015-05-03 08:29:11.000000000 +0200
+++ new/futures-3.0.5/futures.egg-info/pbr.json 2015-06-12 23:44:51.000000000 +0200
@@ -1 +1 @@
-{"is_release": false, "git_version": "fdbc9c3"}
\ No newline at end of file
+{"is_release": false, "git_version": "6532a74"}
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/futures-3.0.2/setup.py new/futures-3.0.5/setup.py
--- old/futures-3.0.2/setup.py 2015-05-12 08:37:47.000000000 +0200
+++ new/futures-3.0.5/setup.py 2016-02-14 22:40:23.000000000 +0100
@@ -1,4 +1,11 @@
#!/usr/bin/env python
+from warnings import warn
+import sys
+
+if sys.version_info[0] > 2:
+ warn('This backport is meant only for Python 2.\n'
+ 'Python 3 users do not need it, as the concurrent.futures '
+ 'package is available in the standard library.')
extras = {}
try:
@@ -8,7 +15,7 @@
from distutils.core import setup
setup(name='futures',
- version='3.0.2',
+ version='3.0.5',
description='Backport of the concurrent.futures package from Python 3.2',
author='Brian Quinlan',
author_email='brian(a)sweetapp.com',
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/futures-3.0.2/test_futures.py new/futures-3.0.5/test_futures.py
--- old/futures-3.0.2/test_futures.py 2015-05-03 07:36:12.000000000 +0200
+++ new/futures-3.0.5/test_futures.py 2015-06-12 23:48:50.000000000 +0200
@@ -7,6 +7,7 @@
import logging
import re
import time
+import gc
from StringIO import StringIO
from test import test_support
@@ -222,6 +223,7 @@
executor.map(abs, range(-5, 5))
threads = executor._threads
del executor
+ gc.collect()
for t in threads:
t.join()
@@ -257,6 +259,7 @@
queue_management_thread = executor._queue_management_thread
processes = executor._processes
del executor
+ gc.collect()
queue_management_thread.join()
for p in processes:
@@ -575,19 +578,19 @@
def test_repr(self):
self.assertRegexpMatches(repr(PENDING_FUTURE),
- '<Future at 0x[0-9a-f]+ state=pending>')
+ '<Future at 0x[0-9a-f]+L? state=pending>')
self.assertRegexpMatches(repr(RUNNING_FUTURE),
- '<Future at 0x[0-9a-f]+ state=running>')
+ '<Future at 0x[0-9a-f]+L? state=running>')
self.assertRegexpMatches(repr(CANCELLED_FUTURE),
- '<Future at 0x[0-9a-f]+ state=cancelled>')
+ '<Future at 0x[0-9a-f]+L? state=cancelled>')
self.assertRegexpMatches(repr(CANCELLED_AND_NOTIFIED_FUTURE),
- '<Future at 0x[0-9a-f]+ state=cancelled>')
+ '<Future at 0x[0-9a-f]+L? state=cancelled>')
self.assertRegexpMatches(
repr(EXCEPTION_FUTURE),
- '<Future at 0x[0-9a-f]+ state=finished raised IOError>')
+ '<Future at 0x[0-9a-f]+L? state=finished raised IOError>')
self.assertRegexpMatches(
repr(SUCCESSFUL_FUTURE),
- '<Future at 0x[0-9a-f]+ state=finished returned int>')
+ '<Future at 0x[0-9a-f]+L? state=finished returned int>')
def test_cancel(self):
f1 = create_future(state=PENDING)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/futures-3.0.2/tox.ini new/futures-3.0.5/tox.ini
--- old/futures-3.0.2/tox.ini 2015-05-02 22:49:00.000000000 +0200
+++ new/futures-3.0.5/tox.ini 2015-06-12 23:35:55.000000000 +0200
@@ -1,5 +1,5 @@
[tox]
-envlist = py26,py27
+envlist = py26,py27,pypy,jython
[testenv]
commands={envpython} test_futures.py []
1
0
Hello community,
here is the log from the commit of package python-django-appconf for openSUSE:Factory checked in at 2016-12-08 00:29:40
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-django-appconf (Old)
and /work/SRC/openSUSE:Factory/.python-django-appconf.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-django-appconf"
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-django-appconf/python-django-appconf.changes 2015-05-05 00:56:08.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.python-django-appconf.new/python-django-appconf.changes 2016-12-08 00:29:41.000000000 +0100
@@ -1,0 +2,7 @@
+Tue Nov 15 10:28:09 UTC 2016 - dmueller(a)suse.com
+
+- update to 1.0.2:
+ * Update supported Django and Python versions, in line with Django's
+ own supported versions.
+
+-------------------------------------------------------------------
Old:
----
django-appconf-1.0.1.tar.gz
New:
----
django-appconf-1.0.2.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-django-appconf.spec ++++++
--- /var/tmp/diff_new_pack.Sgclc4/_old 2016-12-08 00:29:42.000000000 +0100
+++ /var/tmp/diff_new_pack.Sgclc4/_new 2016-12-08 00:29:42.000000000 +0100
@@ -1,7 +1,7 @@
#
# spec file for package python-django-appconf
#
-# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -17,13 +17,13 @@
Name: python-django-appconf
-Version: 1.0.1
+Version: 1.0.2
Release: 0
Url: http://django-appconf.readthedocs.org/
Summary: A Helper Class for Handling Configuration Defaults of Packaged Apps
License: BSD-3-Clause
Group: Development/Languages/Python
-Source: http://pypi.python.org/packages/source/d/django-appconf/django-appconf-%{ve…
+Source: https://pypi.io/packages/source/d/django-appconf/django-appconf-%{version}.…
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: python-devel
BuildRequires: python-setuptools
++++++ django-appconf-1.0.1.tar.gz -> django-appconf-1.0.2.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/.coveragerc new/django-appconf-1.0.2/.coveragerc
--- old/django-appconf-1.0.1/.coveragerc 2015-02-15 14:20:37.000000000 +0100
+++ new/django-appconf-1.0.2/.coveragerc 1970-01-01 01:00:00.000000000 +0100
@@ -1,6 +0,0 @@
-[run]
-source = appconf
-branch = 1
-
-[report]
-omit = *tests*
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/.gitignore new/django-appconf-1.0.2/.gitignore
--- old/django-appconf-1.0.1/.gitignore 2015-02-15 14:20:37.000000000 +0100
+++ new/django-appconf-1.0.2/.gitignore 1970-01-01 01:00:00.000000000 +0100
@@ -1,9 +0,0 @@
-build
-dist
-MANIFEST
-*.pyc
-*.egg-info
-*.egg
-docs/_build/
-.coverage
-.tox/
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/.travis.yml new/django-appconf-1.0.2/.travis.yml
--- old/django-appconf-1.0.1/.travis.yml 2015-02-15 14:20:37.000000000 +0100
+++ new/django-appconf-1.0.2/.travis.yml 1970-01-01 01:00:00.000000000 +0100
@@ -1,30 +0,0 @@
-language: python
-env:
- - TOXENV=flake8-py27
- - TOXENV=flake8-py33
- - TOXENV=py26-dj14
- - TOXENV=py27-dj14
- - TOXENV=py26-dj15
- - TOXENV=py26-dj16
- - TOXENV=py27-dj15
- - TOXENV=py27-dj16
- - TOXENV=py32-dj15
- - TOXENV=py32-dj16
- - TOXENV=py33-dj15
- - TOXENV=py33-dj16
- - TOXENV=py27-dj17
- - TOXENV=py27-dj18
- - TOXENV=py27-dj19
- - TOXENV=py32-dj17
- - TOXENV=py32-dj18
- - TOXENV=py32-dj19
- - TOXENV=py33-dj17
- - TOXENV=py33-dj18
- - TOXENV=py33-dj19
- - TOXENV=py34-dj17
- - TOXENV=py34-dj18
- - TOXENV=py34-dj19
-install:
- - pip install tox
-script:
- - tox
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/PKG-INFO new/django-appconf-1.0.2/PKG-INFO
--- old/django-appconf-1.0.1/PKG-INFO 2015-02-15 14:32:20.000000000 +0100
+++ new/django-appconf-1.0.2/PKG-INFO 2016-04-19 21:20:59.000000000 +0200
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: django-appconf
-Version: 1.0.1
+Version: 1.0.2
Summary: A helper class for handling configuration defaults of packaged apps gracefully.
Home-page: http://django-appconf.readthedocs.org/
Author: Jannis Leidel
@@ -9,9 +9,13 @@
Description: django-appconf
==============
- .. image:: https://secure.travis-ci.org/jezdez/django-appconf.png?branch=develop
+ .. image:: http://codecov.io/github/django-compressor/django-appconf/coverage.svg?bran…
+ :alt: Code Coverage
+ :target: http://codecov.io/github/django-compressor/django-appconf?branch=develop
+
+ .. image:: https://secure.travis-ci.org/django-compressor/django-appconf.png?branch=de…
:alt: Build Status
- :target: http://travis-ci.org/jezdez/django-appconf
+ :target: http://travis-ci.org/django-compressor/django-appconf
A helper class for handling configuration defaults of packaged Django
apps gracefully.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/README.rst new/django-appconf-1.0.2/README.rst
--- old/django-appconf-1.0.1/README.rst 2015-02-15 14:20:37.000000000 +0100
+++ new/django-appconf-1.0.2/README.rst 2016-04-19 21:20:40.000000000 +0200
@@ -1,9 +1,13 @@
django-appconf
==============
-.. image:: https://secure.travis-ci.org/jezdez/django-appconf.png?branch=develop
+.. image:: http://codecov.io/github/django-compressor/django-appconf/coverage.svg?bran…
+ :alt: Code Coverage
+ :target: http://codecov.io/github/django-compressor/django-appconf?branch=develop
+
+.. image:: https://secure.travis-ci.org/django-compressor/django-appconf.png?branch=de…
:alt: Build Status
- :target: http://travis-ci.org/jezdez/django-appconf
+ :target: http://travis-ci.org/django-compressor/django-appconf
A helper class for handling configuration defaults of packaged Django
apps gracefully.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/appconf/__init__.py new/django-appconf-1.0.2/appconf/__init__.py
--- old/django-appconf-1.0.1/appconf/__init__.py 2015-02-15 14:31:55.000000000 +0100
+++ new/django-appconf-1.0.2/appconf/__init__.py 2016-04-19 21:20:40.000000000 +0200
@@ -1,4 +1,4 @@
from __future__ import absolute_import
from .base import AppConf # noqa
-__version__ = "1.0.1"
+__version__ = "1.0.2"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/appconf/base.py new/django-appconf-1.0.2/appconf/base.py
--- old/django-appconf-1.0.1/appconf/base.py 2015-02-15 14:20:45.000000000 +0100
+++ new/django-appconf-1.0.2/appconf/base.py 2016-04-19 21:20:40.000000000 +0200
@@ -1,8 +1,7 @@
import sys
-import six
-
from django.core.exceptions import ImproperlyConfigured
+from django.utils import six
from .utils import import_attribute
@@ -123,11 +122,6 @@
def configured_data(self):
return self._meta.configured_data
- # For Python < 2.6:
- @property
- def __members__(self):
- return self.__dir__()
-
def __getattr__(self, name):
if self._meta.proxy:
return getattr(self._meta.holder, name)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/django_appconf.egg-info/PKG-INFO new/django-appconf-1.0.2/django_appconf.egg-info/PKG-INFO
--- old/django-appconf-1.0.1/django_appconf.egg-info/PKG-INFO 2015-02-15 14:32:19.000000000 +0100
+++ new/django-appconf-1.0.2/django_appconf.egg-info/PKG-INFO 2016-04-19 21:20:48.000000000 +0200
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: django-appconf
-Version: 1.0.1
+Version: 1.0.2
Summary: A helper class for handling configuration defaults of packaged apps gracefully.
Home-page: http://django-appconf.readthedocs.org/
Author: Jannis Leidel
@@ -9,9 +9,13 @@
Description: django-appconf
==============
- .. image:: https://secure.travis-ci.org/jezdez/django-appconf.png?branch=develop
+ .. image:: http://codecov.io/github/django-compressor/django-appconf/coverage.svg?bran…
+ :alt: Code Coverage
+ :target: http://codecov.io/github/django-compressor/django-appconf?branch=develop
+
+ .. image:: https://secure.travis-ci.org/django-compressor/django-appconf.png?branch=de…
:alt: Build Status
- :target: http://travis-ci.org/jezdez/django-appconf
+ :target: http://travis-ci.org/django-compressor/django-appconf
A helper class for handling configuration defaults of packaged Django
apps gracefully.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/django_appconf.egg-info/SOURCES.txt new/django-appconf-1.0.2/django_appconf.egg-info/SOURCES.txt
--- old/django-appconf-1.0.1/django_appconf.egg-info/SOURCES.txt 2015-02-15 14:32:20.000000000 +0100
+++ new/django-appconf-1.0.2/django_appconf.egg-info/SOURCES.txt 2016-04-19 21:20:59.000000000 +0200
@@ -1,21 +1,15 @@
-.coveragerc
-.gitignore
-.travis.yml
AUTHORS
LICENSE
MANIFEST.in
README.rst
setup.cfg
setup.py
-tox.ini
appconf/__init__.py
appconf/base.py
appconf/utils.py
django_appconf.egg-info/PKG-INFO
django_appconf.egg-info/SOURCES.txt
django_appconf.egg-info/dependency_links.txt
-django_appconf.egg-info/pbr.json
-django_appconf.egg-info/requires.txt
django_appconf.egg-info/top_level.txt
docs/Makefile
docs/changelog.rst
@@ -23,9 +17,4 @@
docs/index.rst
docs/make.bat
docs/reference.rst
-docs/usage.rst
-tests/__init__.py
-tests/models.py
-tests/settings.py
-tests/test_settings.py
-tests/tests.py
\ No newline at end of file
+docs/usage.rst
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/django_appconf.egg-info/pbr.json new/django-appconf-1.0.2/django_appconf.egg-info/pbr.json
--- old/django-appconf-1.0.1/django_appconf.egg-info/pbr.json 2015-02-15 14:32:19.000000000 +0100
+++ new/django-appconf-1.0.2/django_appconf.egg-info/pbr.json 1970-01-01 01:00:00.000000000 +0100
@@ -1 +0,0 @@
-{"is_release": true, "git_version": "75c8ca4"}
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/django_appconf.egg-info/requires.txt new/django-appconf-1.0.2/django_appconf.egg-info/requires.txt
--- old/django-appconf-1.0.1/django_appconf.egg-info/requires.txt 2015-02-15 14:32:19.000000000 +0100
+++ new/django-appconf-1.0.2/django_appconf.egg-info/requires.txt 1970-01-01 01:00:00.000000000 +0100
@@ -1 +0,0 @@
-six
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/docs/changelog.rst new/django-appconf-1.0.2/docs/changelog.rst
--- old/django-appconf-1.0.1/docs/changelog.rst 2015-02-15 14:20:37.000000000 +0100
+++ new/django-appconf-1.0.2/docs/changelog.rst 2016-04-19 21:20:40.000000000 +0200
@@ -1,6 +1,15 @@
Changelog
=========
+1.0.2 (2016-04-19)
+------------------
+
+* Minor fixes to test setup
+
+* Update supported Django and Python versions, in line with Django's
+ own supported versions.
+
+
1.0 (2015-02-15)
----------------
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/setup.py new/django-appconf-1.0.2/setup.py
--- old/django-appconf-1.0.1/setup.py 2015-02-15 14:20:37.000000000 +0100
+++ new/django-appconf-1.0.2/setup.py 2016-04-19 21:20:40.000000000 +0200
@@ -29,7 +29,7 @@
license='BSD',
url='http://django-appconf.readthedocs.org/',
packages=['appconf'],
- install_requires=['six'],
+ install_requires=[],
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Web Environment',
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/tests/models.py new/django-appconf-1.0.2/tests/models.py
--- old/django-appconf-1.0.1/tests/models.py 2015-02-15 14:20:37.000000000 +0100
+++ new/django-appconf-1.0.2/tests/models.py 1970-01-01 01:00:00.000000000 +0100
@@ -1,66 +0,0 @@
-from appconf import AppConf
-
-
-class CustomHolder(object):
- HOLDER_VALUE = True
-
-custom_holder = CustomHolder()
-
-
-class TestConf(AppConf):
-
- SIMPLE_VALUE = True
-
- CONFIGURED_VALUE = 'wrong'
-
- def configure_configured_value(self, value):
- return 'correct'
-
- def configure(self):
- self.configured_data['CONFIGURE_METHOD_VALUE'] = True
- return self.configured_data
-
-
-class PrefixConf(TestConf):
-
- class Meta:
- prefix = 'prefix'
-
-
-class YetAnotherPrefixConf(PrefixConf):
-
- SIMPLE_VALUE = False
-
- class Meta:
- prefix = 'yetanother_prefix'
-
-
-class SeparateConf(AppConf):
-
- SEPARATE_VALUE = True
-
- class Meta(PrefixConf.Meta):
- pass
-
-
-class SubclassConf(TestConf):
-
- def configure(self):
- self.configured_data['CONFIGURE_METHOD_VALUE2'] = False
- return self.configured_data
-
-
-class ProxyConf(TestConf):
-
- class Meta:
- proxy = True
-
-
-class CustomHolderConf(AppConf):
-
- SIMPLE_VALUE = True
-
- class Meta:
- # instead of django.conf.settings
- holder = 'tests.models.custom_holder'
- prefix = 'custom_holder'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/tests/settings.py new/django-appconf-1.0.2/tests/settings.py
--- old/django-appconf-1.0.1/tests/settings.py 2015-02-15 14:20:37.000000000 +0100
+++ new/django-appconf-1.0.2/tests/settings.py 1970-01-01 01:00:00.000000000 +0100
@@ -1,3 +0,0 @@
-SIMPLE_VALUE = True
-
-CONFIGURED_VALUE = 'wrong'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/tests/test_settings.py new/django-appconf-1.0.2/tests/test_settings.py
--- old/django-appconf-1.0.1/tests/test_settings.py 2015-02-15 14:20:37.000000000 +0100
+++ new/django-appconf-1.0.2/tests/test_settings.py 1970-01-01 01:00:00.000000000 +0100
@@ -1,23 +0,0 @@
-import django
-
-SITE_ID = 1
-
-DATABASES = {
- 'default': {
- 'ENGINE': 'django.db.backends.sqlite3',
- 'NAME': ':memory:',
- }
-}
-
-INSTALLED_APPS = [
- 'django.contrib.contenttypes',
- 'django.contrib.sites',
- 'django.contrib.auth',
- 'django.contrib.admin',
- 'tests',
-]
-
-if django.VERSION[:2] < (1, 6):
- TEST_RUNNER = 'discover_runner.DiscoverRunner'
-
-SECRET_KEY = 'local'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/tests/tests.py new/django-appconf-1.0.2/tests/tests.py
--- old/django-appconf-1.0.1/tests/tests.py 2015-02-15 14:20:37.000000000 +0100
+++ new/django-appconf-1.0.2/tests/tests.py 1970-01-01 01:00:00.000000000 +0100
@@ -1,146 +0,0 @@
-from __future__ import absolute_import
-from django.conf import settings
-from django.core.exceptions import ImproperlyConfigured
-from django.test import TestCase
-
-from .models import (AppConf, TestConf, PrefixConf,
- YetAnotherPrefixConf, SeparateConf,
- ProxyConf, CustomHolderConf, custom_holder)
-
-
-class TestConfTests(TestCase):
-
- def test_basic(self):
- self.assertEqual(TestConf._meta.prefix, 'tests')
-
- def test_simple(self):
- self.assertTrue(hasattr(settings, 'TESTS_SIMPLE_VALUE'))
- self.assertEqual(settings.TESTS_SIMPLE_VALUE, True)
-
- def test_configured(self):
- self.assertTrue(hasattr(settings, 'TESTS_CONFIGURED_VALUE'))
- self.assertEqual(settings.TESTS_CONFIGURED_VALUE, 'correct')
-
- def test_configure_method(self):
- self.assertTrue(hasattr(settings, 'TESTS_CONFIGURE_METHOD_VALUE'))
- self.assertEqual(settings.TESTS_CONFIGURE_METHOD_VALUE, True)
-
- def test_init_kwargs(self):
- custom_conf = TestConf(CUSTOM_VALUE='custom')
- self.assertEqual(custom_conf.CUSTOM_VALUE, 'custom')
- self.assertEqual(settings.TESTS_CUSTOM_VALUE, 'custom')
- self.assertRaises(AttributeError,
- lambda: custom_conf.TESTS_CUSTOM_VALUE)
- custom_conf.CUSTOM_VALUE_SETATTR = 'custom'
- self.assertEqual(settings.TESTS_CUSTOM_VALUE_SETATTR, 'custom')
- custom_conf.custom_value_lowercase = 'custom'
- self.assertRaises(AttributeError,
- lambda: settings.custom_value_lowercase)
-
- def test_init_kwargs_with_prefix(self):
- custom_conf = TestConf(TESTS_CUSTOM_VALUE2='custom2')
- self.assertEqual(custom_conf.TESTS_CUSTOM_VALUE2, 'custom2')
- self.assertEqual(settings.TESTS_CUSTOM_VALUE2, 'custom2')
-
- def test_proxy(self):
- custom_conf = ProxyConf(CUSTOM_VALUE3='custom3')
- self.assertEqual(custom_conf.CUSTOM_VALUE3, 'custom3')
- self.assertEqual(settings.TESTS_CUSTOM_VALUE3, 'custom3')
- self.assertEqual(custom_conf.TESTS_CUSTOM_VALUE3, 'custom3')
- self.assertTrue('tests' in custom_conf.INSTALLED_APPS)
-
- def test_dir_members(self):
- custom_conf = TestConf()
- self.assertTrue('TESTS_SIMPLE_VALUE' in dir(settings))
- if hasattr(settings, '__members__'): # django 1.5 removed __members__
- self.assertTrue('TESTS_SIMPLE_VALUE' in settings.__members__)
- self.assertTrue('SIMPLE_VALUE' in dir(custom_conf))
- self.assertTrue('SIMPLE_VALUE' in custom_conf.__members__)
- self.assertFalse('TESTS_SIMPLE_VALUE' in dir(custom_conf))
- self.assertFalse('TESTS_SIMPLE_VALUE' in custom_conf.__members__)
-
- def test_custom_holder(self):
- CustomHolderConf()
- self.assertTrue(hasattr(custom_holder, 'CUSTOM_HOLDER_SIMPLE_VALUE'))
- self.assertEqual(custom_holder.CUSTOM_HOLDER_SIMPLE_VALUE, True)
-
- def test_subclass_configured_data(self):
- self.assertTrue('TESTS_CONFIGURE_METHOD_VALUE2' in dir(settings))
- self.assertEqual(settings.TESTS_CONFIGURE_METHOD_VALUE2, False)
-
-
-class PrefixConfTests(TestCase):
-
- def test_prefix(self):
- self.assertEqual(PrefixConf._meta.prefix, 'prefix')
-
- def test_simple(self):
- self.assertTrue(hasattr(settings, 'PREFIX_SIMPLE_VALUE'))
- self.assertEqual(settings.PREFIX_SIMPLE_VALUE, True)
-
- def test_configured(self):
- self.assertTrue(hasattr(settings, 'PREFIX_CONFIGURED_VALUE'))
- self.assertEqual(settings.PREFIX_CONFIGURED_VALUE, 'correct')
-
- def test_configure_method(self):
- self.assertTrue(hasattr(settings, 'PREFIX_CONFIGURE_METHOD_VALUE'))
- self.assertEqual(settings.PREFIX_CONFIGURE_METHOD_VALUE, True)
-
-
-class YetAnotherPrefixConfTests(TestCase):
-
- def test_prefix(self):
- self.assertEqual(YetAnotherPrefixConf._meta.prefix,
- 'yetanother_prefix')
-
- def test_simple(self):
- self.assertTrue(hasattr(settings,
- 'YETANOTHER_PREFIX_SIMPLE_VALUE'))
- self.assertEqual(settings.YETANOTHER_PREFIX_SIMPLE_VALUE, False)
-
- def test_configured(self):
- self.assertTrue(hasattr(settings,
- 'YETANOTHER_PREFIX_CONFIGURED_VALUE'))
- self.assertEqual(settings.YETANOTHER_PREFIX_CONFIGURED_VALUE,
- 'correct')
-
- def test_configure_method(self):
- self.assertTrue(hasattr(settings,
- 'YETANOTHER_PREFIX_CONFIGURE_METHOD_VALUE'))
- self.assertEqual(settings.YETANOTHER_PREFIX_CONFIGURE_METHOD_VALUE,
- True)
-
-
-class SeparateConfTests(TestCase):
-
- def test_prefix(self):
- self.assertEqual(SeparateConf._meta.prefix, 'prefix')
-
- def test_simple(self):
- self.assertTrue(hasattr(settings, 'PREFIX_SEPARATE_VALUE'))
- self.assertEqual(settings.PREFIX_SEPARATE_VALUE, True)
-
-
-class RequiredSettingsTests(TestCase):
-
- def create_invalid_conf(self):
- class RequirementConf(AppConf):
- class Meta:
- required = ['NOT_PRESENT']
-
- def test_value_is_defined(self):
- class RequirementConf(AppConf):
- class Meta:
- holder = 'tests.models.custom_holder'
- prefix = 'holder'
- required = ['VALUE']
-
- def test_default_is_defined(self):
- class RequirementConf(AppConf):
- SIMPLE_VALUE = True
-
- class Meta:
- required = ['SIMPLE_VALUE']
-
- def test_missing(self):
- self.assertRaises(ImproperlyConfigured, self.create_invalid_conf)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/django-appconf-1.0.1/tox.ini new/django-appconf-1.0.2/tox.ini
--- old/django-appconf-1.0.1/tox.ini 2015-02-15 14:20:37.000000000 +0100
+++ new/django-appconf-1.0.2/tox.ini 1970-01-01 01:00:00.000000000 +0100
@@ -1,50 +0,0 @@
-[tox]
-skipsdist = True
-usedevelop = True
-minversion = 1.8
-envlist =
- flake8-py27,
- flake8-py33,
- py{26,27}-dj14,
- py{26,27,32,33}-dj{15,16},
- py{27,32,33,34}-dj{17,18,19},
-
-[testenv]
-basepython =
- py26: python2.6
- py27: python2.7
- py32: python3.2
- py33: python3.3
- py34: python3.4
- pypy: pypy
-usedevelop = true
-setenv =
- PYTHONPATH = {toxinidir}
- DJANGO_SETTINGS_MODULE=tests.test_settings
-deps =
- flake8
- coverage
- django-discover-runner
- dj13: https://github.com/django/django/archive/stable/1.3.x.zip#egg=django
- dj14: https://github.com/django/django/archive/stable/1.4.x.zip#egg=django
- dj15: https://github.com/django/django/archive/stable/1.5.x.zip#egg=django
- dj16: https://github.com/django/django/archive/stable/1.6.x.zip#egg=django
- dj17: https://github.com/django/django/archive/stable/1.7.x.zip#egg=django
- dj18: https://github.com/django/django/archive/stable/1.8.x.zip#egg=django
- dj19: https://github.com/django/django/archive/master.zip#egg=django
-
-commands =
- coverage run {envbindir}/django-admin.py test -v2 {posargs:tests}
- coverage report
-
-[testenv:flake8-py27]
-commands = flake8 appconf
-deps = flake8
-
-[testenv:flake8-py33]
-commands = flake8 appconf
-deps = flake8
-
-[flake8]
-exclude = .tox
-ignore = E501
1
0
Hello community,
here is the log from the commit of package python-croniter for openSUSE:Factory checked in at 2016-12-08 00:29:34
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-croniter (Old)
and /work/SRC/openSUSE:Factory/.python-croniter.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-croniter"
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-croniter/python-croniter.changes 2016-04-28 16:58:19.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.python-croniter.new/python-croniter.changes 2016-12-08 00:29:35.000000000 +0100
@@ -1,0 +2,5 @@
+Tue Nov 15 10:24:09 UTC 2016 - dmueller(a)suse.com
+
+- update to 0.3.12
+
+-------------------------------------------------------------------
Old:
----
croniter-0.3.5.zip
New:
----
croniter-0.3.12.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-croniter.spec ++++++
--- /var/tmp/diff_new_pack.JeWUqL/_old 2016-12-08 00:29:36.000000000 +0100
+++ /var/tmp/diff_new_pack.JeWUqL/_new 2016-12-08 00:29:36.000000000 +0100
@@ -17,13 +17,13 @@
Name: python-croniter
-Version: 0.3.5
+Version: 0.3.12
Release: 0
Summary: Croniter provides iteration for datetime object with cron like format
License: MIT
Group: Development/Languages/Python
Url: http://github.com/kiorky/croniter
-Source: https://pypi.python.org/packages/source/c/croniter/croniter-%{version}.zip
+Source: https://pypi.io/packages/source/c/croniter/croniter-%{version}.tar.gz
BuildRequires: python-devel
BuildRequires: python-setuptools
BuildRequires: unzip
1
0
Hello community,
here is the log from the commit of package python-colorama for openSUSE:Factory checked in at 2016-12-08 00:29:29
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-colorama (Old)
and /work/SRC/openSUSE:Factory/.python-colorama.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-colorama"
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-colorama/python-colorama.changes 2015-04-21 10:53:49.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.python-colorama.new/python-colorama.changes 2016-12-08 00:29:30.000000000 +0100
@@ -1,0 +2,19 @@
+Tue Nov 15 10:22:24 UTC 2016 - dmueller(a)suse.com
+
+- update to 0.3.7:
+ * Fix issue #84: check if stream has 'closed' attribute before testing it
+ * Fix issue #74: objects might become None at exit
+ * Fix issue #81: fix ValueError when a closed stream was used
+ * Bumping version to re-upload a wheel distribution
+ * Fix issue #47 and #80 - stream redirection now strips ANSI codes on Linux
+ * Fix issue #53 - strip readline markers
+ * Fix issue #32 - assign orig_stdout and orig_stderr when initialising
+ * Fix issue #57 - Fore.RESET did not reset style of LIGHT_EX colors.
+ Fixed by Andy Neff
+ * Fix issue #51 - add context manager syntax. Thanks to Matt Olsen.
+ * Fix issue #48 - colorama didn't work on Windows when environment
+ variable 'TERM' was set.
+ * Fix issue #54 - fix pylint errors in client code.
+ * Changes to readme and other improvements by Marc Abramowitz and Zearin
+
+-------------------------------------------------------------------
Old:
----
colorama-0.3.3.tar.gz
New:
----
colorama-0.3.7.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-colorama.spec ++++++
--- /var/tmp/diff_new_pack.mTPZMK/_old 2016-12-08 00:29:31.000000000 +0100
+++ /var/tmp/diff_new_pack.mTPZMK/_new 2016-12-08 00:29:31.000000000 +0100
@@ -1,7 +1,7 @@
#
# spec file for package python-colorama
#
-# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -17,13 +17,13 @@
Name: python-colorama
-Version: 0.3.3
+Version: 0.3.7
Release: 0
Summary: Cross-platform colored terminal text
License: BSD-3-Clause
Group: Development/Languages/Python
Url: https://github.com/tartley/colorama
-Source: http://pypi.python.org/packages/source/c/colorama/colorama-%{version}.tar.gz
+Source: https://pypi.io/packages/source/c/colorama/colorama-%{version}.tar.gz
BuildRequires: python-devel
BuildRequires: python-setuptools
BuildRoot: %{_tmppath}/%{name}-%{version}-build
++++++ colorama-0.3.3.tar.gz -> colorama-0.3.7.tar.gz ++++++
++++ 1827 lines of diff (skipped)
1
0
Hello community,
here is the log from the commit of package python-betamax for openSUSE:Factory checked in at 2016-12-08 00:29:23
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-betamax (Old)
and /work/SRC/openSUSE:Factory/.python-betamax.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-betamax"
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-betamax/python-betamax.changes 2016-06-09 16:16:49.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.python-betamax.new/python-betamax.changes 2016-12-08 00:29:24.000000000 +0100
@@ -1,0 +2,21 @@
+Tue Nov 15 10:34:38 UTC 2016 - dmueller(a)suse.com
+
+- update to 0.8.0:
+ - Add ``betamax_parametrized_recorder`` and ``betamax_parametrized_session``
+ to our list of pytest fixtures so that users will have parametrized cassette
+ names when writing parametrized tests with our fixtures. (I wonder if I can
+ mention parametrization a bunch more times so I can say parametrize a lot in
+ this bullet note.)
+ - Add ``ValidationError`` and a set of subclasses for each possible validation
+ error.
+ - Raise ``InvalidOption`` on unknown cassette options rather than silently
+ ignoring extra options.
+ - Raise a subclass of ``ValidationError`` when a particular cassette option is
+ invalid, rather than silently ignoring the validation failure.
+ - Fix bug with query string matcher where query-strings without values (e.g.,
+ ``?foo&bar`` as opposed to ``?foo=1&bar=2``) were treated as if there were
+ no query string.
+ - Fix issue #108 by effectively copying the items in the match_requests_on
+ list into the match_options set on a Cassette instance
+
+-------------------------------------------------------------------
Old:
----
betamax-0.7.0.tar.gz
New:
----
betamax-0.8.0.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-betamax.spec ++++++
--- /var/tmp/diff_new_pack.4fpQIn/_old 2016-12-08 00:29:25.000000000 +0100
+++ /var/tmp/diff_new_pack.4fpQIn/_new 2016-12-08 00:29:25.000000000 +0100
@@ -17,7 +17,7 @@
Name: python-betamax
-Version: 0.7.0
+Version: 0.8.0
Release: 0
Summary: A VCR imitation for python-requests
License: Apache-2.0
++++++ betamax-0.7.0.tar.gz -> betamax-0.8.0.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/HISTORY.rst new/betamax-0.8.0/HISTORY.rst
--- old/betamax-0.7.0/HISTORY.rst 2016-04-29 18:18:50.000000000 +0200
+++ new/betamax-0.8.0/HISTORY.rst 2016-08-16 23:59:48.000000000 +0200
@@ -1,6 +1,34 @@
History
=======
+0.8.0 - 2016-08-16
+------------------
+
+- Add ``betamax_parametrized_recorder`` and ``betamax_parametrized_session``
+ to our list of pytest fixtures so that users will have parametrized cassette
+ names when writing parametrized tests with our fixtures. (I wonder if I can
+ mention parametrization a bunch more times so I can say parametrize a lot in
+ this bullet note.)
+- Add ``ValidationError`` and a set of subclasses for each possible validation
+ error.
+- Raise ``InvalidOption`` on unknown cassette options rather than silently
+ ignoring extra options.
+- Raise a subclass of ``ValidationError`` when a particular cassette option is
+ invalid, rather than silently ignoring the validation failure.
+
+0.7.2 - 2016-08-04
+------------------
+
+- Fix bug with query string matcher where query-strings without values (e.g.,
+ ``?foo&bar`` as opposed to ``?foo=1&bar=2``) were treated as if there were
+ no query string.
+
+0.7.1 - 2016-06-14
+------------------
+
+- Fix issue #108 by effectively copying the items in the match_requests_on
+ list into the match_options set on a Cassette instance
+
0.7.0 - 2016-04-29
------------------
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/PKG-INFO new/betamax-0.8.0/PKG-INFO
--- old/betamax-0.7.0/PKG-INFO 2016-04-29 18:19:50.000000000 +0200
+++ new/betamax-0.8.0/PKG-INFO 2016-08-17 00:00:42.000000000 +0200
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: betamax
-Version: 0.7.0
+Version: 0.8.0
Summary: A VCR imitation for python-requests
Home-page: https://github.com/sigmavirus24/betamax
Author: Ian Cordasco
@@ -98,6 +98,34 @@
History
=======
+ 0.8.0 - 2016-08-16
+ ------------------
+
+ - Add ``betamax_parametrized_recorder`` and ``betamax_parametrized_session``
+ to our list of pytest fixtures so that users will have parametrized cassette
+ names when writing parametrized tests with our fixtures. (I wonder if I can
+ mention parametrization a bunch more times so I can say parametrize a lot in
+ this bullet note.)
+ - Add ``ValidationError`` and a set of subclasses for each possible validation
+ error.
+ - Raise ``InvalidOption`` on unknown cassette options rather than silently
+ ignoring extra options.
+ - Raise a subclass of ``ValidationError`` when a particular cassette option is
+ invalid, rather than silently ignoring the validation failure.
+
+ 0.7.2 - 2016-08-04
+ ------------------
+
+ - Fix bug with query string matcher where query-strings without values (e.g.,
+ ``?foo&bar`` as opposed to ``?foo=1&bar=2``) were treated as if there were
+ no query string.
+
+ 0.7.1 - 2016-06-14
+ ------------------
+
+ - Fix issue #108 by effectively copying the items in the match_requests_on
+ list into the match_options set on a Cassette instance
+
0.7.0 - 2016-04-29
------------------
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/betamax/__init__.py new/betamax-0.8.0/betamax/__init__.py
--- old/betamax-0.7.0/betamax/__init__.py 2016-04-29 18:03:53.000000000 +0200
+++ new/betamax-0.8.0/betamax/__init__.py 2016-08-16 23:57:58.000000000 +0200
@@ -22,5 +22,5 @@
__copyright__ = 'Copyright 2013-2014 Ian Cordasco'
__license__ = 'Apache 2.0'
__title__ = 'betamax'
-__version__ = '0.7.0'
+__version__ = '0.8.0'
__version_info__ = tuple(int(i) for i in __version__.split('.'))
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/betamax/adapter.py new/betamax-0.8.0/betamax/adapter.py
--- old/betamax-0.7.0/betamax/adapter.py 2016-04-29 17:06:30.000000000 +0200
+++ new/betamax-0.8.0/betamax/adapter.py 2016-06-14 23:17:19.000000000 +0200
@@ -94,7 +94,9 @@
if 'record' in self.options:
self.cassette.record_mode = self.options['record']
- self.cassette.match_options = match_requests_on
+ # NOTE(sigmavirus24): Cassette.match_options is a set, might as well
+ # use that instead of overriding it.
+ self.cassette.match_options.update(match_requests_on)
re_record_interval = timedelta.max
if self.options.get('re_record_interval'):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/betamax/exceptions.py new/betamax-0.8.0/betamax/exceptions.py
--- old/betamax-0.7.0/betamax/exceptions.py 2015-12-22 23:10:56.000000000 +0100
+++ new/betamax-0.8.0/betamax/exceptions.py 2016-08-12 13:25:58.000000000 +0200
@@ -8,3 +8,51 @@
class MissingDirectoryError(BetamaxError):
pass
+
+
+class ValidationError(BetamaxError):
+ pass
+
+
+class InvalidOption(ValidationError):
+ pass
+
+
+class BodyBytesValidationError(ValidationError):
+ pass
+
+
+class MatchersValidationError(ValidationError):
+ pass
+
+
+class RecordValidationError(ValidationError):
+ pass
+
+
+class RecordIntervalValidationError(ValidationError):
+ pass
+
+
+class PlaceholdersValidationError(ValidationError):
+ pass
+
+
+class PlaybackRepeatsValidationError(ValidationError):
+ pass
+
+
+class SerializerValidationError(ValidationError):
+ pass
+
+
+validation_error_map = {
+ 'allow_playback_repeats': PlaybackRepeatsValidationError,
+ 'match_requests_on': MatchersValidationError,
+ 'record': RecordValidationError,
+ 'placeholders': PlaceholdersValidationError,
+ 'preserve_exact_body_bytes': BodyBytesValidationError,
+ 're_record_interval': RecordIntervalValidationError,
+ 'serialize': SerializerValidationError, # TODO: Remove this
+ 'serialize_with': SerializerValidationError
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/betamax/fixtures/pytest.py new/betamax-0.8.0/betamax/fixtures/pytest.py
--- old/betamax-0.7.0/betamax/fixtures/pytest.py 2016-02-06 17:30:09.000000000 +0100
+++ new/betamax-0.8.0/betamax/fixtures/pytest.py 2016-08-16 23:51:53.000000000 +0200
@@ -7,28 +7,30 @@
from __future__ import absolute_import
+import re
+import warnings
+
import pytest
import requests
from .. import recorder as betamax
-(a)pytest.fixture
-def betamax_recorder(request):
- """Generate a recorder with a session that has Betamax already installed.
+def _sanitize(name):
+ """Replace whitespace and / with -"""
+ return re.sub('[\s/]+', '-', name)
- This will create a new Betamax instance with a generated cassette name.
- The cassette name is generated by first using the module name from where
- the test is collected, then the class name (if it exists), and then the
- test function name. For example, if your test is in ``test_stuff.py`` and
- is the method ``TestStuffClass.test_stuff`` then your cassette name will be
- ``test_stuff_TestStuffClass_test_stuff``.
+
+def _casette_name(request, parametrized):
+ """Determine a cassette name from request.
:param request:
A request object from pytest giving us context information for the
fixture.
+ :param parametrized:
+ Whether the name should consider parametrized tests.
:returns:
- An instantiated recorder.
+ A cassette name.
"""
cassette_name = ''
@@ -38,8 +40,24 @@
if request.cls is not None:
cassette_name += request.cls.__name__ + '.'
- cassette_name += request.function.__name__
+ if parametrized:
+ cassette_name += _sanitize(request.node.name)
+ else:
+ cassette_name += request.function.__name__
+ if request.node.name != request.function.__name__:
+ warnings.warn(
+ "betamax_recorder and betamax_session currently don't include "
+ "parameters in the cassette name. "
+ "Use betamax_parametrized_recorder/_session to include "
+ "parameters. "
+ "This behavior will be the default in betamax 1.0",
+ FutureWarning, stacklevel=3)
+
+ return cassette_name
+
+def _betamax_recorder(request, parametrized=True):
+ cassette_name = _casette_name(request, parametrized=parametrized)
session = requests.Session()
recorder = betamax.Betamax(session)
recorder.use_cassette(cassette_name)
@@ -49,6 +67,29 @@
@pytest.fixture
+def betamax_recorder(request):
+ """Generate a recorder with a session that has Betamax already installed.
+
+ This will create a new Betamax instance with a generated cassette name.
+ The cassette name is generated by first using the module name from where
+ the test is collected, then the class name (if it exists), and then the
+ test function name. For example, if your test is in ``test_stuff.py`` and
+ is the method ``TestStuffClass.test_stuff`` then your cassette name will be
+ ``test_stuff_TestStuffClass_test_stuff``. If the test is parametrized,
+ the parameters will not be included in the name. In case you need that,
+ use betamax_parametrized_recorder instead. This will change in 1.0.0,
+ where parameters will be included by default.
+
+ :param request:
+ A request object from pytest giving us context information for the
+ fixture.
+ :returns:
+ An instantiated recorder.
+ """
+ return _betamax_recorder(request, parametrized=False)
+
+
+(a)pytest.fixture
def betamax_session(betamax_recorder):
"""Generate a session that has Betamax already installed.
@@ -61,3 +102,45 @@
"""
return betamax_recorder.session
+
+
+(a)pytest.fixture
+def betamax_parametrized_recorder(request):
+ """Generate a recorder with a session that has Betamax already installed.
+
+ This will create a new Betamax instance with a generated cassette name.
+ The cassette name is generated by first using the module name from where
+ the test is collected, then the class name (if it exists), and then the
+ test function name with parameters if parametrized.
+ For example, if your test is in ``test_stuff.py`` and
+ the method is ``TestStuffClass.test_stuff`` with parameter ``True`` then
+ your cassette name will be
+ ``test_stuff_TestStuffClass_test_stuff[True]``.
+
+ :param request:
+ A request object from pytest giving us context information for the
+ fixture.
+ :returns:
+ An instantiated recorder.
+ """
+ warnings.warn(
+ "betamax_parametrized_recorder and betamax_parametrized_session "
+ "will be removed in betamax 1.0. Their behavior will be the "
+ "default.",
+ DeprecationWarning)
+ return _betamax_recorder(request, parametrized=True)
+
+
+(a)pytest.fixture
+def betamax_parametrized_session(betamax_parametrized_recorder):
+ """Generate a session that has Betamax already installed.
+
+ See `betamax_parametrized_recorder` fixture.
+
+ :param betamax_parametrized_recorder:
+ A recorder fixture with a configured request session.
+ :returns:
+ An instantiated requests Session wrapped by Betamax.
+ """
+
+ return betamax_parametrized_recorder.session
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/betamax/matchers/body.py new/betamax-0.8.0/betamax/matchers/body.py
--- old/betamax-0.7.0/betamax/matchers/body.py 2016-01-18 00:59:32.000000000 +0100
+++ new/betamax-0.8.0/betamax/matchers/body.py 2016-08-11 22:39:18.000000000 +0200
@@ -1,6 +1,7 @@
# -*- coding: utf-8 -*-
from .base import BaseMatcher
-from betamax.util import deserialize_prepared_request
+
+from betamax import util
class BodyMatcher(BaseMatcher):
@@ -8,14 +9,14 @@
name = 'body'
def match(self, request, recorded_request):
- recorded_request = deserialize_prepared_request(recorded_request)
+ recorded_request = util.deserialize_prepared_request(recorded_request)
+ request_body = b''
if request.body:
- if isinstance(recorded_request.body, type(request.body)):
- request_body = request.body
- else:
- request_body = request.body.encode('utf-8')
- else:
- request_body = b''
+ request_body = util.coerce_content(request.body)
+
+ recorded_body = b''
+ if recorded_request.body:
+ recorded_body = util.coerce_content(recorded_request.body)
- return recorded_request.body == request_body
+ return recorded_body == request_body
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/betamax/matchers/query.py new/betamax-0.8.0/betamax/matchers/query.py
--- old/betamax-0.7.0/betamax/matchers/query.py 2016-04-26 16:20:58.000000000 +0200
+++ new/betamax-0.8.0/betamax/matchers/query.py 2016-08-04 12:40:43.000000000 +0200
@@ -18,7 +18,10 @@
def to_dict(self, query):
"""Turn the query string into a dictionary."""
- return parse_qs(query or '') # Protect against None
+ return parse_qs(
+ query or '', # Protect against None
+ keep_blank_values=True,
+ )
def match(self, request, recorded_request):
request_query_dict = self.to_dict(urlparse(request.url).query)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/betamax/options.py new/betamax-0.8.0/betamax/options.py
--- old/betamax-0.7.0/betamax/options.py 2016-04-29 17:06:30.000000000 +0200
+++ new/betamax-0.8.0/betamax/options.py 2016-08-12 13:25:58.000000000 +0200
@@ -1,4 +1,5 @@
from .cassette import Cassette
+from .exceptions import InvalidOption, validation_error_map
def validate_record(record):
@@ -19,9 +20,10 @@
def validate_placeholders(placeholders):
"""Validate placeholders is a dict-like structure"""
keys = ['placeholder', 'replace']
- return all(
- sorted(list(p.keys())) == keys for p in placeholders
- )
+ try:
+ return all(sorted(list(p.keys())) == keys for p in placeholders)
+ except TypeError:
+ return False
def translate_cassette_options():
@@ -84,8 +86,9 @@
def validate(self):
for key, value in list(self.data.items()):
if key not in Options.valid_options:
- del self[key]
+ raise InvalidOption('{0} is not a valid option'.format(key))
else:
is_valid = Options.valid_options[key]
if not is_valid(value):
- del self[key]
+ raise validation_error_map[key]('{0!r} is not valid'
+ .format(value))
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/betamax.egg-info/PKG-INFO new/betamax-0.8.0/betamax.egg-info/PKG-INFO
--- old/betamax-0.7.0/betamax.egg-info/PKG-INFO 2016-04-29 18:19:49.000000000 +0200
+++ new/betamax-0.8.0/betamax.egg-info/PKG-INFO 2016-08-17 00:00:40.000000000 +0200
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: betamax
-Version: 0.7.0
+Version: 0.8.0
Summary: A VCR imitation for python-requests
Home-page: https://github.com/sigmavirus24/betamax
Author: Ian Cordasco
@@ -98,6 +98,34 @@
History
=======
+ 0.8.0 - 2016-08-16
+ ------------------
+
+ - Add ``betamax_parametrized_recorder`` and ``betamax_parametrized_session``
+ to our list of pytest fixtures so that users will have parametrized cassette
+ names when writing parametrized tests with our fixtures. (I wonder if I can
+ mention parametrization a bunch more times so I can say parametrize a lot in
+ this bullet note.)
+ - Add ``ValidationError`` and a set of subclasses for each possible validation
+ error.
+ - Raise ``InvalidOption`` on unknown cassette options rather than silently
+ ignoring extra options.
+ - Raise a subclass of ``ValidationError`` when a particular cassette option is
+ invalid, rather than silently ignoring the validation failure.
+
+ 0.7.2 - 2016-08-04
+ ------------------
+
+ - Fix bug with query string matcher where query-strings without values (e.g.,
+ ``?foo&bar`` as opposed to ``?foo=1&bar=2``) were treated as if there were
+ no query string.
+
+ 0.7.1 - 2016-06-14
+ ------------------
+
+ - Fix issue #108 by effectively copying the items in the match_requests_on
+ list into the match_options set on a Cassette instance
+
0.7.0 - 2016-04-29
------------------
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/betamax.egg-info/SOURCES.txt new/betamax-0.8.0/betamax.egg-info/SOURCES.txt
--- old/betamax-0.7.0/betamax.egg-info/SOURCES.txt 2016-04-29 18:19:50.000000000 +0200
+++ new/betamax-0.8.0/betamax.egg-info/SOURCES.txt 2016-08-17 00:00:42.000000000 +0200
@@ -58,6 +58,7 @@
docs/usage_patterns.rst
tests/__init__.py
tests/conftest.py
+tests/cassettes/FakeBetamaxTestCase.test_fake.json
tests/cassettes/GitHub_create_issue.json
tests/cassettes/GitHub_emojis.json
tests/cassettes/global_preserve_exact_body_bytes.json
@@ -70,6 +71,7 @@
tests/cassettes/test.json
tests/cassettes/test_replays_response_on_right_order.json
tests/cassettes/tests.integration.test_fixtures.TestPyTestFixtures.test_pytest_fixture.json
+tests/cassettes/tests.integration.test_fixtures.TestPyTestParametrizedFixtures.test_pytest_fixture[https:-httpbin.org-get].json
tests/integration/__init__.py
tests/integration/helper.py
tests/integration/test_allow_playback_repeats.py
@@ -85,12 +87,14 @@
tests/regression/test_cassettes_retain_global_configuration.py
tests/regression/test_gzip_compression.py
tests/regression/test_once_prevents_new_interactions.py
+tests/regression/test_requests_2_11_body_matcher.py
tests/regression/test_works_with_digest_auth.py
tests/unit/test_adapter.py
tests/unit/test_betamax.py
tests/unit/test_cassette.py
tests/unit/test_configure.py
tests/unit/test_decorator.py
+tests/unit/test_exceptions.py
tests/unit/test_fixtures.py
tests/unit/test_matchers.py
tests/unit/test_options.py
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/docs/api.rst new/betamax-0.8.0/docs/api.rst
--- old/betamax-0.7.0/docs/api.rst 2015-07-16 03:00:31.000000000 +0200
+++ new/betamax-0.8.0/docs/api.rst 2016-08-16 23:56:48.000000000 +0200
@@ -157,8 +157,9 @@
-----------------------------
You may want to force betamax to preserve the exact bytes in the body of a
-response (or request) instead of relying on the `opinions held by the library
-<opinions>`_. In this case you have two ways of telling betamax to do this.
+response (or request) instead of relying on the :ref:`opinions held by the
+library <opinions>`. In this case you have two ways of telling betamax to do
+this.
The first, is on a per-cassette basis, like so:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/setup.cfg new/betamax-0.8.0/setup.cfg
--- old/betamax-0.7.0/setup.cfg 2016-04-29 18:19:50.000000000 +0200
+++ new/betamax-0.8.0/setup.cfg 2016-08-17 00:00:42.000000000 +0200
@@ -2,7 +2,7 @@
universal = 1
[egg_info]
-tag_svn_revision = 0
tag_build =
tag_date = 0
+tag_svn_revision = 0
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/tests/cassettes/FakeBetamaxTestCase.test_fake.json new/betamax-0.8.0/tests/cassettes/FakeBetamaxTestCase.test_fake.json
--- old/betamax-0.7.0/tests/cassettes/FakeBetamaxTestCase.test_fake.json 1970-01-01 01:00:00.000000000 +0100
+++ new/betamax-0.8.0/tests/cassettes/FakeBetamaxTestCase.test_fake.json 2016-08-10 12:45:01.000000000 +0200
@@ -0,0 +1 @@
+{"http_interactions": [], "recorded_with": "betamax/0.7.2"}
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/tests/cassettes/tests.integration.test_fixtures.TestPyTestParametrizedFixtures.test_pytest_fixture[https:-httpbin.org-get].json new/betamax-0.8.0/tests/cassettes/tests.integration.test_fixtures.TestPyTestParametrizedFixtures.test_pytest_fixture[https:-httpbin.org-get].json
--- old/betamax-0.7.0/tests/cassettes/tests.integration.test_fixtures.TestPyTestParametrizedFixtures.test_pytest_fixture[https:-httpbin.org-get].json 1970-01-01 01:00:00.000000000 +0100
+++ new/betamax-0.8.0/tests/cassettes/tests.integration.test_fixtures.TestPyTestParametrizedFixtures.test_pytest_fixture[https:-httpbin.org-get].json 2016-08-16 23:51:53.000000000 +0200
@@ -0,0 +1 @@
+{"recorded_with": "betamax/0.4.2", "http_interactions": [{"recorded_at": "2015-05-25T00:46:42", "response": {"body": {"encoding": null, "string": "{\n \"args\": {}, \n \"headers\": {\n \"Accept\": \"*/*\", \n \"Accept-Encoding\": \"gzip, deflate\", \n \"Host\": \"httpbin.org\", \n \"User-Agent\": \"python-requests/2.6.0 CPython/3.4.2 Darwin/14.1.0\"\n }, \n \"origin\": \"72.160.201.47\", \n \"url\": \"https://httpbin.org/get\"\n}\n"}, "status": {"message": "OK", "code": 200}, "url": "https://httpbin.org/get", "headers": {"connection": ["keep-alive"], "content-type": ["application/json"], "content-length": ["266"], "date": ["Mon, 25 May 2015 00:46:42 GMT"], "access-control-allow-origin": ["*"], "access-control-allow-credentials": ["true"], "server": ["nginx"]}}, "request": {"method": "GET", "body": {"encoding": "utf-8", "string": ""}, "uri": "https://httpbin.org/get", "headers": {"Connection": ["keep-alive"], "User-Agent": ["python-requests/2.6.0 CPython/3.4.2 Darwin/14.1.0"], "Accept": ["*/*"], "Accept-Encoding": ["gzip, deflate"]}}}]}
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/tests/integration/test_fixtures.py new/betamax-0.8.0/tests/integration/test_fixtures.py
--- old/betamax-0.7.0/tests/integration/test_fixtures.py 2015-07-16 04:29:25.000000000 +0200
+++ new/betamax-0.8.0/tests/integration/test_fixtures.py 2016-08-16 23:51:53.000000000 +0200
@@ -24,3 +24,28 @@
"""Exercise the fixture itself."""
resp = betamax_session.get('https://httpbin.org/get')
assert resp.ok
+
+
+(a)pytest.mark.usefixtures('betamax_parametrized_session')
+class TestPyTestParametrizedFixtures:
+ @pytest.fixture(autouse=True)
+ def setup(self, request):
+ """After test hook to assert everything."""
+ def finalizer():
+ test_dir = os.path.abspath('.')
+ cassette_name = ('tests.integration.test_fixtures.' # Module name
+ 'TestPyTestParametrizedFixtures.' # Class name
+ 'test_pytest_fixture' # Test function name
+ '[https:-httpbin.org-get]' # Parameter
+ '.json')
+ file_name = os.path.join(test_dir, 'tests', 'cassettes',
+ cassette_name)
+ assert os.path.exists(file_name) is True
+
+ request.addfinalizer(finalizer)
+
+ @pytest.mark.parametrize('url', ('https://httpbin.org/get',))
+ def test_pytest_fixture(self, betamax_parametrized_session, url):
+ """Exercise the fixture itself."""
+ resp = betamax_parametrized_session.get(url)
+ assert resp.ok
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/tests/regression/test_requests_2_11_body_matcher.py new/betamax-0.8.0/tests/regression/test_requests_2_11_body_matcher.py
--- old/betamax-0.7.0/tests/regression/test_requests_2_11_body_matcher.py 1970-01-01 01:00:00.000000000 +0100
+++ new/betamax-0.8.0/tests/regression/test_requests_2_11_body_matcher.py 2016-08-11 22:39:18.000000000 +0200
@@ -0,0 +1,27 @@
+import os
+import unittest
+
+import pytest
+import requests
+
+from betamax import Betamax
+
+
+class TestRequests211BodyMatcher(unittest.TestCase):
+ def tearDown(self):
+ os.unlink('tests/cassettes/requests_2_11_body_matcher.json')
+
+ @pytest.mark.skipif(requests.__build__ < 0x020401,
+ reason="No json keyword.")
+ def test_requests_with_json_body(self):
+ s = requests.Session()
+ with Betamax(s).use_cassette('requests_2_11_body_matcher',
+ match_requests_on=['body']):
+ r = s.post('https://httpbin.org/post', json={'a': 2})
+ assert r.json() is not None
+
+ s = requests.Session()
+ with Betamax(s).use_cassette('requests_2_11_body_matcher',
+ match_requests_on=['body']):
+ r = s.post('https://httpbin.org/post', json={'a': 2})
+ assert r.json() is not None
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/tests/unit/test_cassette.py new/betamax-0.8.0/tests/unit/test_cassette.py
--- old/betamax-0.7.0/tests/unit/test_cassette.py 2016-04-29 17:06:30.000000000 +0200
+++ new/betamax-0.8.0/tests/unit/test_cassette.py 2016-08-12 13:25:58.000000000 +0200
@@ -3,6 +3,8 @@
import unittest
from datetime import datetime
+import pytest
+
from betamax import __version__
from betamax.cassette import cassette
from betamax import mock_response
@@ -310,6 +312,12 @@
assert i is not None
assert self.interaction is i
+ def test_find_match__missing_matcher(self):
+ self.cassette.match_options = set(['uri', 'method', 'invalid'])
+ self.cassette.record_mode = 'none'
+ with pytest.raises(KeyError):
+ self.cassette.find_match(self.response.request)
+
def test_eject(self):
serializer = self.test_serializer
self.cassette.eject()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/tests/unit/test_exceptions.py new/betamax-0.8.0/tests/unit/test_exceptions.py
--- old/betamax-0.7.0/tests/unit/test_exceptions.py 1970-01-01 01:00:00.000000000 +0100
+++ new/betamax-0.8.0/tests/unit/test_exceptions.py 2016-08-12 13:25:58.000000000 +0200
@@ -0,0 +1,35 @@
+import unittest
+import inspect
+
+from betamax import exceptions
+
+
+def exception_classes():
+ for _, module_object in inspect.getmembers(exceptions):
+ if inspect.isclass(module_object):
+ yield module_object
+
+
+class TestExceptions(unittest.TestCase):
+ def test_all_exceptions_are_betamax_errors(self):
+ for exception_class in exception_classes():
+ assert isinstance(exception_class('msg'), exceptions.BetamaxError)
+
+ def test_all_validation_errors_are_in_validation_error_map(self):
+ validation_error_map_values = exceptions.validation_error_map.values()
+ for exception_class in exception_classes():
+ if exception_class.__name__ == 'ValidationError' or \
+ not exception_class.__name__.endswith('ValidationError'):
+ continue
+ assert exception_class in validation_error_map_values
+
+ def test_all_validation_errors_are_validation_errors(self):
+ for exception_class in exception_classes():
+ if not exception_class.__name__.endswith('ValidationError'):
+ continue
+ assert isinstance(exception_class('msg'),
+ exceptions.ValidationError)
+
+ def test_invalid_option_is_validation_error(self):
+ assert isinstance(exceptions.InvalidOption('msg'),
+ exceptions.ValidationError)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/tests/unit/test_matchers.py new/betamax-0.8.0/tests/unit/test_matchers.py
--- old/betamax-0.7.0/tests/unit/test_matchers.py 2015-04-12 22:43:22.000000000 +0200
+++ new/betamax-0.8.0/tests/unit/test_matchers.py 2016-08-04 12:40:43.000000000 +0200
@@ -140,6 +140,9 @@
)
# Regression test (no query issue)
assert match(self.p, {'uri': 'http://example.com'}) is False
+ # Regression test (query with no value)
+ self.p.url = 'https://example.com/?foo'
+ assert match(self.p, {'uri': 'https://httpbin.org/?foo'}) is True
def test_uri_matcher(self):
match = matchers.matcher_registry['uri'].match
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/betamax-0.7.0/tests/unit/test_options.py new/betamax-0.8.0/tests/unit/test_options.py
--- old/betamax-0.7.0/tests/unit/test_options.py 2013-09-14 00:22:30.000000000 +0200
+++ new/betamax-0.8.0/tests/unit/test_options.py 2016-08-12 13:25:58.000000000 +0200
@@ -1,5 +1,9 @@
import unittest
from itertools import permutations
+
+import pytest
+
+from betamax import exceptions
from betamax.options import Options, validate_record, validate_matchers
@@ -31,21 +35,50 @@
for key in self.data:
assert key in self.options
- def test_invalid_data_is_removed(self):
+ def test_raise_on_unknown_option(self):
data = self.data.copy()
data['fake'] = 'value'
- options = Options(data)
+ with pytest.raises(exceptions.InvalidOption):
+ Options(data)
- for key in self.data:
- assert key in options
+ def test_raise_on_invalid_body_bytes(self):
+ data = self.data.copy()
+ data['preserve_exact_body_bytes'] = None
+ with pytest.raises(exceptions.BodyBytesValidationError):
+ Options(data)
+
+ def test_raise_on_invalid_matchers(self):
+ data = self.data.copy()
+ data['match_requests_on'] = ['foo', 'bar', 'bogus']
+ with pytest.raises(exceptions.MatchersValidationError):
+ Options(data)
- assert 'fake' not in options
+ def test_raise_on_invalid_placeholders(self):
+ data = self.data.copy()
+ data['placeholders'] = None
+ with pytest.raises(exceptions.PlaceholdersValidationError):
+ Options(data)
- def test_values_are_validated(self):
- assert self.options['re_record_interval'] == 10000
- assert self.options['match_requests_on'] == ['method']
+ def test_raise_on_invalid_playback_repeats(self):
+ data = self.data.copy()
+ data['allow_playback_repeats'] = None
+ with pytest.raises(exceptions.PlaybackRepeatsValidationError):
+ Options(data)
+ def test_raise_on_invalid_record(self):
data = self.data.copy()
- data['match_requests_on'] = ['foo', 'bar', 'bogus']
- options = Options(data)
- assert options['match_requests_on'] == ['method', 'uri']
+ data['record'] = None
+ with pytest.raises(exceptions.RecordValidationError):
+ Options(data)
+
+ def test_raise_on_invalid_record_interval(self):
+ data = self.data.copy()
+ data['re_record_interval'] = -1
+ with pytest.raises(exceptions.RecordIntervalValidationError):
+ Options(data)
+
+ def test_raise_on_invalid_serializer(self):
+ data = self.data.copy()
+ data['serialize_with'] = None
+ with pytest.raises(exceptions.SerializerValidationError):
+ Options(data)
1
0
Hello community,
here is the log from the commit of package python-PyMySQL for openSUSE:Factory checked in at 2016-12-08 00:29:15
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-PyMySQL (Old)
and /work/SRC/openSUSE:Factory/.python-PyMySQL.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-PyMySQL"
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-PyMySQL/python-PyMySQL.changes 2016-06-07 23:49:27.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.python-PyMySQL.new/python-PyMySQL.changes 2016-12-08 00:29:16.000000000 +0100
@@ -1,0 +2,13 @@
+Tue Nov 15 10:30:55 UTC 2016 - dmueller(a)suse.com
+
+- update to 0.7.6:
+ * Fix SELECT JSON type cause UnicodeError
+ * Avoid float convertion while parsing microseconds
+ * Warning has number
+ * SSCursor supports warnings
+ * Fix exception raised while importing when getpwuid() fails (#472)
+ * SSCursor supports LOAD DATA LOCAL INFILE (#473)
+ * Fix encoding error happen for JSON type (#477)
+ * Fix test fail on Python 2.7 and MySQL 5.7 (#478)
+
+-------------------------------------------------------------------
Old:
----
PyMySQL-0.7.4.tar.gz
New:
----
PyMySQL-0.7.6.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-PyMySQL.spec ++++++
--- /var/tmp/diff_new_pack.RPoUUi/_old 2016-12-08 00:29:17.000000000 +0100
+++ /var/tmp/diff_new_pack.RPoUUi/_new 2016-12-08 00:29:17.000000000 +0100
@@ -17,7 +17,7 @@
Name: python-PyMySQL
-Version: 0.7.4
+Version: 0.7.6
Release: 0
Summary: Pure Python MySQL Driver
License: MIT
++++++ PyMySQL-0.7.4.tar.gz -> PyMySQL-0.7.6.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/PyMySQL-0.7.4/CHANGELOG new/PyMySQL-0.7.6/CHANGELOG
--- old/PyMySQL-0.7.4/CHANGELOG 2016-05-26 06:13:18.000000000 +0200
+++ new/PyMySQL-0.7.6/CHANGELOG 2016-07-29 05:21:41.000000000 +0200
@@ -1,5 +1,23 @@
# Changes
+## 0.7.6
+
+Release date: 2016-07-29
+
+* Fix SELECT JSON type cause UnicodeError
+* Avoid float convertion while parsing microseconds
+* Warning has number
+* SSCursor supports warnings
+
+## 0.7.5
+
+Release date: 2016-06-28
+
+* Fix exception raised while importing when getpwuid() fails (#472)
+* SSCursor supports LOAD DATA LOCAL INFILE (#473)
+* Fix encoding error happen for JSON type (#477)
+* Fix test fail on Python 2.7 and MySQL 5.7 (#478)
+
## 0.7.4
Release date: 2016-05-26
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/PyMySQL-0.7.4/PKG-INFO new/PyMySQL-0.7.6/PKG-INFO
--- old/PyMySQL-0.7.4/PKG-INFO 2016-05-26 06:14:55.000000000 +0200
+++ new/PyMySQL-0.7.6/PKG-INFO 2016-07-29 05:27:02.000000000 +0200
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: PyMySQL
-Version: 0.7.4
+Version: 0.7.6
Summary: Pure Python MySQL Driver
Home-page: https://github.com/PyMySQL/PyMySQL/
Author: INADA Naoki
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/PyMySQL-0.7.4/PyMySQL.egg-info/PKG-INFO new/PyMySQL-0.7.6/PyMySQL.egg-info/PKG-INFO
--- old/PyMySQL-0.7.4/PyMySQL.egg-info/PKG-INFO 2016-05-26 06:14:54.000000000 +0200
+++ new/PyMySQL-0.7.6/PyMySQL.egg-info/PKG-INFO 2016-07-29 05:27:02.000000000 +0200
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: PyMySQL
-Version: 0.7.4
+Version: 0.7.6
Summary: Pure Python MySQL Driver
Home-page: https://github.com/PyMySQL/PyMySQL/
Author: INADA Naoki
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/PyMySQL-0.7.4/README.rst new/PyMySQL-0.7.6/README.rst
--- old/PyMySQL-0.7.4/README.rst 2016-05-26 06:05:45.000000000 +0200
+++ new/PyMySQL-0.7.6/README.rst 2016-07-28 17:42:45.000000000 +0200
@@ -15,7 +15,8 @@
PyMySQL
=======
-.. contents::
+.. contents:: Table of Contents
+ :local:
This package contains a pure-Python MySQL client library. The goal of PyMySQL
is to be a drop-in replacement for MySQLdb and work on CPython, PyPy and IronPython.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/PyMySQL-0.7.4/pymysql/__init__.py new/PyMySQL-0.7.6/pymysql/__init__.py
--- old/PyMySQL-0.7.4/pymysql/__init__.py 2016-05-26 06:14:03.000000000 +0200
+++ new/PyMySQL-0.7.6/pymysql/__init__.py 2016-07-29 05:21:53.000000000 +0200
@@ -33,7 +33,7 @@
DateFromTicks, TimeFromTicks, TimestampFromTicks
-VERSION = (0, 7, 4, None)
+VERSION = (0, 7, 6, None)
threadsafety = 1
apilevel = "2.0"
paramstyle = "pyformat"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/PyMySQL-0.7.4/pymysql/charset.py new/PyMySQL-0.7.6/pymysql/charset.py
--- old/PyMySQL-0.7.4/pymysql/charset.py 2015-09-29 17:10:42.000000000 +0200
+++ new/PyMySQL-0.7.6/pymysql/charset.py 2016-07-28 17:42:45.000000000 +0200
@@ -11,6 +11,10 @@
self.id, self.name, self.collation = id, name, collation
self.is_default = is_default == 'Yes'
+ def __repr__(self):
+ return "Charset(id=%s, name=%r, collation=%r)" % (
+ self.id, self.name, self.collation)
+
@property
def encoding(self):
name = self.name
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/PyMySQL-0.7.4/pymysql/connections.py new/PyMySQL-0.7.6/pymysql/connections.py
--- old/PyMySQL-0.7.4/pymysql/connections.py 2016-05-26 06:05:45.000000000 +0200
+++ new/PyMySQL-0.7.6/pymysql/connections.py 2016-07-28 17:42:45.000000000 +0200
@@ -35,7 +35,8 @@
import getpass
DEFAULT_USER = getpass.getuser()
del getpass
-except ImportError:
+except (ImportError, KeyError):
+ # KeyError occurs when there's no entry in OS database for a current user.
DEFAULT_USER = None
@@ -405,9 +406,9 @@
def __init__(self, data, encoding):
MysqlPacket.__init__(self, data, encoding)
- self.__parse_field_descriptor(encoding)
+ self._parse_field_descriptor(encoding)
- def __parse_field_descriptor(self, encoding):
+ def _parse_field_descriptor(self, encoding):
"""Parse the 'Field Descriptor' (Metadata) packet.
This is compatible with MySQL 4.1+ (not compatible with MySQL 4.0).
@@ -1318,6 +1319,10 @@
self._read_ok_packet(first_packet)
self.unbuffered_active = False
self.connection = None
+ elif first_packet.is_load_local_packet():
+ self._read_load_local_packet(first_packet)
+ self.unbuffered_active = False
+ self.connection = None
else:
self.field_count = first_packet.read_length_encoded_integer()
self._get_descriptions()
@@ -1427,21 +1432,30 @@
self.fields = []
self.converters = []
use_unicode = self.connection.use_unicode
+ conn_encoding = self.connection.encoding
description = []
+
for i in range_type(self.field_count):
field = self.connection._read_packet(FieldDescriptorPacket)
self.fields.append(field)
description.append(field.description())
field_type = field.type_code
if use_unicode:
- if field_type in TEXT_TYPES:
- charset = charset_by_id(field.charsetnr)
- if charset.is_binary:
+ if field_type == FIELD_TYPE.JSON:
+ # When SELECT from JSON column: charset = binary
+ # When SELECT CAST(... AS JSON): charset = connection encoding
+ # This behavior is different from TEXT / BLOB.
+ # We should decode result by connection encoding regardless charsetnr.
+ # See https://github.com/PyMySQL/PyMySQL/issues/488
+ encoding = conn_encoding # SELECT CAST(... AS JSON)
+ elif field_type in TEXT_TYPES:
+ if field.charsetnr == 63: # binary
# TEXTs with charset=binary means BINARY types.
encoding = None
else:
- encoding = charset.encoding
+ encoding = conn_encoding
else:
+ # Integers, Dates and Times, and other basic data is encoded in ascii
encoding = 'ascii'
else:
encoding = None
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/PyMySQL-0.7.4/pymysql/constants/FIELD_TYPE.py new/PyMySQL-0.7.6/pymysql/constants/FIELD_TYPE.py
--- old/PyMySQL-0.7.4/pymysql/constants/FIELD_TYPE.py 2015-09-29 17:10:42.000000000 +0200
+++ new/PyMySQL-0.7.6/pymysql/constants/FIELD_TYPE.py 2016-07-26 05:09:33.000000000 +0200
@@ -17,6 +17,7 @@
NEWDATE = 14
VARCHAR = 15
BIT = 16
+JSON = 245
NEWDECIMAL = 246
ENUM = 247
SET = 248
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/PyMySQL-0.7.4/pymysql/converters.py new/PyMySQL-0.7.6/pymysql/converters.py
--- old/PyMySQL-0.7.4/pymysql/converters.py 2016-05-26 06:05:45.000000000 +0200
+++ new/PyMySQL-0.7.6/pymysql/converters.py 2016-07-28 17:42:45.000000000 +0200
@@ -2,6 +2,7 @@
import datetime
from decimal import Decimal
+import re
import time
from .constants import FIELD_TYPE, FLAG
@@ -145,6 +146,16 @@
def escape_struct_time(obj, mapping=None):
return escape_datetime(datetime.datetime(*obj[:6]))
+def _convert_second_fraction(s):
+ if not s:
+ return 0
+ # Pad zeros to ensure the fraction length in microseconds
+ s = s.ljust(6, '0')
+ return int(s[:6])
+
+DATETIME_RE = re.compile(r"(\d{1,4})-(\d{1,2})-(\d{1,2})[T ](\d{1,2}):(\d{1,2}):(\d{1,2})(?:.(\d{1,6}))?")
+
+
def convert_datetime(obj):
"""Returns a DATETIME or TIMESTAMP column value as a datetime object:
@@ -163,23 +174,20 @@
"""
if not PY2 and isinstance(obj, (bytes, bytearray)):
obj = obj.decode('ascii')
- if ' ' in obj:
- sep = ' '
- elif 'T' in obj:
- sep = 'T'
- else:
+
+ m = DATETIME_RE.match(obj)
+ if not m:
return convert_date(obj)
try:
- ymd, hms = obj.split(sep, 1)
- usecs = '0'
- if '.' in hms:
- hms, usecs = hms.split('.')
- usecs = float('0.' + usecs) * 1e6
- return datetime.datetime(*[ int(x) for x in ymd.split('-')+hms.split(':')+[usecs] ])
+ groups = list(m.groups())
+ groups[-1] = _convert_second_fraction(groups[-1])
+ return datetime.datetime(*[ int(x) for x in groups ])
except ValueError:
return convert_date(obj)
+TIMEDELTA_RE = re.compile(r"(-)?(\d{1,3}):(\d{1,2}):(\d{1,2})(?:.(\d{1,6}))?")
+
def convert_timedelta(obj):
"""Returns a TIME column as a timedelta object:
@@ -200,16 +208,17 @@
"""
if not PY2 and isinstance(obj, (bytes, bytearray)):
obj = obj.decode('ascii')
+
+ m = TIMEDELTA_RE.match(obj)
+ if not m:
+ return None
+
try:
- microseconds = 0
- if "." in obj:
- (obj, tail) = obj.split('.')
- microseconds = float('0.' + tail) * 1e6
- hours, minutes, seconds = obj.split(':')
- negate = 1
- if hours.startswith("-"):
- hours = hours[1:]
- negate = -1
+ groups = list(m.groups())
+ groups[-1] = _convert_second_fraction(groups[-1])
+ negate = -1 if groups[0] else 1
+ hours, minutes, seconds, microseconds = groups[1:]
+
tdelta = datetime.timedelta(
hours = int(hours),
minutes = int(minutes),
@@ -220,6 +229,9 @@
except ValueError:
return None
+TIME_RE = re.compile(r"(\d{1,2}):(\d{1,2}):(\d{1,2})(?:.(\d{1,6}))?")
+
+
def convert_time(obj):
"""Returns a TIME column as a time object:
@@ -244,17 +256,21 @@
"""
if not PY2 and isinstance(obj, (bytes, bytearray)):
obj = obj.decode('ascii')
+
+ m = TIME_RE.match(obj)
+ if not m:
+ return None
+
try:
- microseconds = 0
- if "." in obj:
- (obj, tail) = obj.split('.')
- microseconds = float('0.' + tail) * 1e6
- hours, minutes, seconds = obj.split(':')
+ groups = list(m.groups())
+ groups[-1] = _convert_second_fraction(groups[-1])
+ hours, minutes, seconds, microseconds = groups
return datetime.time(hour=int(hours), minute=int(minutes),
second=int(seconds), microsecond=int(microseconds))
except ValueError:
return None
+
def convert_date(obj):
"""Returns a DATE column as a date object:
@@ -324,7 +340,7 @@
#def convert_bit(b):
# b = "\x00" * (8 - len(b)) + b # pad w/ zeroes
# return struct.unpack(">Q", b)[0]
-#
+#
# the snippet above is right, but MySQLdb doesn't process bits,
# so we shouldn't either
convert_bit = through
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/PyMySQL-0.7.4/pymysql/cursors.py new/PyMySQL-0.7.6/pymysql/cursors.py
--- old/PyMySQL-0.7.4/pymysql/cursors.py 2016-05-26 06:05:45.000000000 +0200
+++ new/PyMySQL-0.7.6/pymysql/cursors.py 2016-07-28 17:42:45.000000000 +0200
@@ -30,6 +30,8 @@
#: Default value of max_allowed_packet is 1048576.
max_stmt_length = 1024000
+ _defer_warnings = False
+
def __init__(self, connection):
'''
Do not create an instance of a Cursor yourself. Call
@@ -43,6 +45,7 @@
self._executed = None
self._result = None
self._rows = None
+ self._warnings_handled = False
def close(self):
'''
@@ -86,6 +89,9 @@
"""Get the next query set"""
conn = self._get_db()
current_result = self._result
+ # for unbuffered queries warnings are only available once whole result has been read
+ if unbuffered:
+ self._show_warnings()
if current_result is None or current_result is not conn._result:
return None
if not current_result.has_next:
@@ -144,7 +150,7 @@
:param str query: Query to execute.
- :param args: arameters used with query. (optional)
+ :param args: parameters used with query. (optional)
:type args: tuple, list or dict
:return: Number of affected rows
@@ -328,14 +334,18 @@
self.description = result.description
self.lastrowid = result.insert_id
self._rows = result.rows
+ self._warnings_handled = False
- if result.warning_count > 0:
- self._show_warnings(conn)
+ if not self._defer_warnings:
+ self._show_warnings()
- def _show_warnings(self, conn):
- if self._result and self._result.has_next:
+ def _show_warnings(self):
+ if self._warnings_handled:
+ return
+ self._warnings_handled = True
+ if self._result and (self._result.has_next or not self._result.warning_count):
return
- ws = conn.show_warnings()
+ ws = self._get_db().show_warnings()
if ws is None:
return
for w in ws:
@@ -343,7 +353,7 @@
if PY2:
if isinstance(msg, unicode):
msg = msg.encode('utf-8', 'replace')
- warnings.warn(str(msg), err.Warning, 4)
+ warnings.warn(err.Warning(*w[1:3]), stacklevel=4)
def __iter__(self):
return iter(self.fetchone, None)
@@ -404,6 +414,8 @@
possible to scroll backwards, as only the current row is held in memory.
"""
+ _defer_warnings = True
+
def _conv_row(self, row):
return row
@@ -440,6 +452,7 @@
self._check_executed()
row = self.read_next()
if row is None:
+ self._show_warnings()
return None
self.rownumber += 1
return row
@@ -473,6 +486,7 @@
for i in range_type(size):
row = self.read_next()
if row is None:
+ self._show_warnings()
break
rows.append(row)
self.rownumber += 1
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/PyMySQL-0.7.4/pymysql/tests/test_DictCursor.py new/PyMySQL-0.7.6/pymysql/tests/test_DictCursor.py
--- old/PyMySQL-0.7.4/pymysql/tests/test_DictCursor.py 2015-09-29 17:10:42.000000000 +0200
+++ new/PyMySQL-0.7.6/pymysql/tests/test_DictCursor.py 2016-07-28 17:42:45.000000000 +0200
@@ -21,7 +21,9 @@
with warnings.catch_warnings():
warnings.filterwarnings("ignore")
c.execute("drop table if exists dictcursor")
- c.execute("""CREATE TABLE dictcursor (name char(20), age int , DOB datetime)""")
+ # include in filterwarnings since for unbuffered dict cursor warning for lack of table
+ # will only be propagated at start of next execute() call
+ c.execute("""CREATE TABLE dictcursor (name char(20), age int , DOB datetime)""")
data = [("bob", 21, "1990-02-06 23:04:56"),
("jim", 56, "1955-05-09 13:12:45"),
("fred", 100, "1911-09-12 01:01:01")]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/PyMySQL-0.7.4/pymysql/tests/test_basic.py new/PyMySQL-0.7.6/pymysql/tests/test_basic.py
--- old/PyMySQL-0.7.4/pymysql/tests/test_basic.py 2016-05-26 06:05:45.000000000 +0200
+++ new/PyMySQL-0.7.6/pymysql/tests/test_basic.py 2016-07-28 17:42:45.000000000 +0200
@@ -1,15 +1,16 @@
-import pymysql.cursors
-
-from pymysql.tests import base
-from pymysql import util
-from pymysql.err import ProgrammingError
-
-import time
+# coding: utf-8
import datetime
+import json
+import time
import warnings
from unittest2 import SkipTest
+from pymysql import util
+import pymysql.cursors
+from pymysql.tests import base
+from pymysql.err import ProgrammingError
+
__all__ = ["TestConversion", "TestCursor", "TestBulkInserts"]
@@ -238,6 +239,31 @@
self.assertEqual([(1,)], list(c.fetchall()))
c.close()
+ def test_json(self):
+ args = self.databases[0].copy()
+ args["charset"] = "utf8mb4"
+ conn = pymysql.connect(**args)
+ if not self.mysql_server_is(conn, (5, 7, 0)):
+ raise SkipTest("JSON type is not supported on MySQL <= 5.6")
+
+ self.safe_create_table(conn, "test_json", """\
+create table test_json (
+ id int not null,
+ json JSON not null,
+ primary key (id)
+);""")
+ cur = conn.cursor()
+
+ json_str = u'{"hello": "こんにちは"}'
+ cur.execute("INSERT INTO test_json (id, `json`) values (42, %s)", (json_str,))
+ cur.execute("SELECT `json` from `test_json` WHERE `id`=42")
+ res = cur.fetchone()[0]
+ self.assertEqual(json.loads(res), json.loads(json_str))
+
+ cur.execute("SELECT CAST(%s AS JSON) AS x", (json_str,))
+ res = cur.fetchone()[0]
+ self.assertEqual(json.loads(res), json.loads(json_str))
+
class TestBulkInserts(base.PyMySQLTestCase):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/PyMySQL-0.7.4/pymysql/tests/test_converters.py new/PyMySQL-0.7.6/pymysql/tests/test_converters.py
--- old/PyMySQL-0.7.4/pymysql/tests/test_converters.py 2016-01-14 03:51:30.000000000 +0100
+++ new/PyMySQL-0.7.6/pymysql/tests/test_converters.py 2016-07-26 05:09:26.000000000 +0200
@@ -1,3 +1,4 @@
+import datetime
from unittest import TestCase
from pymysql._compat import PY2
@@ -21,3 +22,46 @@
converters.escape_string(b"foo\nbar"),
b"foo\\nbar"
)
+
+ def test_convert_datetime(self):
+ expected = datetime.datetime(2007, 2, 24, 23, 6, 20)
+ dt = converters.convert_datetime('2007-02-24 23:06:20')
+ self.assertEqual(dt, expected)
+
+ def test_convert_datetime_with_fsp(self):
+ expected = datetime.datetime(2007, 2, 24, 23, 6, 20, 511581)
+ dt = converters.convert_datetime('2007-02-24 23:06:20.511581')
+ self.assertEqual(dt, expected)
+
+ def _test_convert_timedelta(self, with_negate=False, with_fsp=False):
+ d = {'hours': 789, 'minutes': 12, 'seconds': 34}
+ s = '%(hours)s:%(minutes)s:%(seconds)s' % d
+ if with_fsp:
+ d['microseconds'] = 511581
+ s += '.%(microseconds)s' % d
+
+ expected = datetime.timedelta(**d)
+ if with_negate:
+ expected = -expected
+ s = '-' + s
+
+ tdelta = converters.convert_timedelta(s)
+ self.assertEqual(tdelta, expected)
+
+ def test_convert_timedelta(self):
+ self._test_convert_timedelta(with_negate=False, with_fsp=False)
+ self._test_convert_timedelta(with_negate=True, with_fsp=False)
+
+ def test_convert_timedelta_with_fsp(self):
+ self._test_convert_timedelta(with_negate=False, with_fsp=True)
+ self._test_convert_timedelta(with_negate=False, with_fsp=True)
+
+ def test_convert_time(self):
+ expected = datetime.time(23, 6, 20)
+ time_obj = converters.convert_time('23:06:20')
+ self.assertEqual(time_obj, expected)
+
+ def test_convert_time_with_fsp(self):
+ expected = datetime.time(23, 6, 20, 511581)
+ time_obj = converters.convert_time('23:06:20.511581')
+ self.assertEqual(time_obj, expected)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/PyMySQL-0.7.4/pymysql/tests/test_issues.py new/PyMySQL-0.7.6/pymysql/tests/test_issues.py
--- old/PyMySQL-0.7.4/pymysql/tests/test_issues.py 2016-01-10 06:17:46.000000000 +0100
+++ new/PyMySQL-0.7.6/pymysql/tests/test_issues.py 2016-07-28 17:42:45.000000000 +0200
@@ -4,6 +4,8 @@
import sys
import pymysql
+from pymysql import cursors
+from pymysql._compat import text_type
from pymysql.tests import base
import unittest2
@@ -457,7 +459,7 @@
# select WKT
query = "SELECT AsText(geom) FROM issue363"
- if sys.version_info[0:2] >= (3,2) and self.mysql_server_is(conn, (5, 7, 0)):
+ if self.mysql_server_is(conn, (5, 7, 0)):
with self.assertWarns(pymysql.err.Warning) as cm:
cur.execute(query)
else:
@@ -467,7 +469,7 @@
# select WKB
query = "SELECT AsBinary(geom) FROM issue363"
- if sys.version_info[0:2] >= (3,2) and self.mysql_server_is(conn, (5, 7, 0)):
+ if self.mysql_server_is(conn, (5, 7, 0)):
with self.assertWarns(pymysql.err.Warning) as cm:
cur.execute(query)
else:
@@ -486,3 +488,28 @@
# don't assert the exact internal binary value, as it could
# vary across implementations
self.assertTrue(isinstance(row[0], bytes))
+
+ def test_issue_491(self):
+ """ Test warning propagation """
+ conn = pymysql.connect(charset="utf8", **self.databases[0])
+
+ with warnings.catch_warnings():
+ # Ignore all warnings other than pymysql generated ones
+ warnings.simplefilter("ignore")
+ warnings.simplefilter("error", category=pymysql.Warning)
+
+ # verify for both buffered and unbuffered cursor types
+ for cursor_class in (cursors.Cursor, cursors.SSCursor):
+ c = conn.cursor(cursor_class)
+ try:
+ c.execute("SELECT CAST('124b' AS SIGNED)")
+ c.fetchall()
+ except pymysql.Warning as e:
+ # Warnings should have errorcode and string message, just like exceptions
+ self.assertEqual(len(e.args), 2)
+ self.assertEqual(e.args[0], 1292)
+ self.assertTrue(isinstance(e.args[1], text_type))
+ else:
+ self.fail("Should raise Warning")
+ finally:
+ c.close()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/PyMySQL-0.7.4/pymysql/tests/test_load_local.py new/PyMySQL-0.7.6/pymysql/tests/test_load_local.py
--- old/PyMySQL-0.7.4/pymysql/tests/test_load_local.py 2016-01-06 03:55:53.000000000 +0100
+++ new/PyMySQL-0.7.6/pymysql/tests/test_load_local.py 2016-07-15 18:43:37.000000000 +0200
@@ -1,4 +1,4 @@
-from pymysql import OperationalError, Warning
+from pymysql import cursors, OperationalError, Warning
from pymysql.tests import base
import os
@@ -42,6 +42,28 @@
finally:
c.execute("DROP TABLE test_load_local")
+ def test_unbuffered_load_file(self):
+ """Test unbuffered load local infile with a valid file"""
+ conn = self.connections[0]
+ c = conn.cursor(cursors.SSCursor)
+ c.execute("CREATE TABLE test_load_local (a INTEGER, b INTEGER)")
+ filename = os.path.join(os.path.dirname(os.path.realpath(__file__)),
+ 'data',
+ 'load_local_data.txt')
+ try:
+ c.execute(
+ ("LOAD DATA LOCAL INFILE '{0}' INTO TABLE " +
+ "test_load_local FIELDS TERMINATED BY ','").format(filename)
+ )
+ c.execute("SELECT COUNT(*) FROM test_load_local")
+ self.assertEqual(22749, c.fetchone()[0])
+ finally:
+ c.close()
+ conn.close()
+ conn.connect()
+ c = conn.cursor()
+ c.execute("DROP TABLE test_load_local")
+
def test_load_warnings(self):
"""Test load local infile produces the appropriate warnings"""
conn = self.connections[0]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/PyMySQL-0.7.4/setup.cfg new/PyMySQL-0.7.6/setup.cfg
--- old/PyMySQL-0.7.4/setup.cfg 2016-05-26 06:14:55.000000000 +0200
+++ new/PyMySQL-0.7.6/setup.cfg 2016-07-29 05:27:02.000000000 +0200
@@ -1,5 +1,5 @@
-[wheel]
-universal = 1
+[bdist_wheel]
+universal = False
[flake8]
ignore = E226,E301,E701
1
0