Hello community,
here is the log from the commit of package python-msgpack-numpy for
openSUSE:Factory checked in at 2020-10-25 18:06:44
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-msgpack-numpy (Old)
and /work/SRC/openSUSE:Factory/.python-msgpack-numpy.new.3463 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-msgpack-numpy"
Sun Oct 25 18:06:44 2020 rev:4 rq:841148 version:0.4.7.1
Changes:
--------
---
/work/SRC/openSUSE:Factory/python-msgpack-numpy/python-msgpack-numpy.changes
2020-04-25 20:36:49.791074406 +0200
+++
/work/SRC/openSUSE:Factory/.python-msgpack-numpy.new.3463/python-msgpack-numpy.changes
2020-10-25 18:06:52.611359869 +0100
@@ -1,0 +2,20 @@
+Sat Oct 10 19:05:16 UTC 2020 - Arun Persaud <[email protected]>
+
+- specfile:
+ * changed .rst to .md
+
+- update to version 0.4.7.1:
+ * Fix Python 2.7 regression (#45).
+
+- changes from version 0.4.7:
+ * Fix bug unpacking nested, structured dtypes (#42).
+
+- changes from version 0.4.6.1:
+ * Deprecate support for msgpack < 1.0.0 (#41).
+
+- changes from version 0.4.6:
+ * Set default use_bin_type and raw params of Packer and Unpacker
+ classes the same as in msgpack (#39).
+ * Convert docs to Markdown.
+
+-------------------------------------------------------------------
Old:
----
msgpack-numpy-0.4.5.tar.gz
New:
----
msgpack-numpy-0.4.7.1.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-msgpack-numpy.spec ++++++
--- /var/tmp/diff_new_pack.jPDZGQ/_old 2020-10-25 18:06:54.111361289 +0100
+++ /var/tmp/diff_new_pack.jPDZGQ/_new 2020-10-25 18:06:54.115361292 +0100
@@ -18,7 +18,7 @@
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name: python-msgpack-numpy
-Version: 0.4.5
+Version: 0.4.7.1
Release: 0
Summary: Numpy data serialization library using msgpack
License: BSD-3-Clause
@@ -58,8 +58,8 @@
%python_exec -B tests.py
%files %{python_files}
-%doc AUTHORS.rst CHANGES.rst README.rst
-%license LICENSE.rst
+%doc AUTHORS.md CHANGES.md README.md
+%license LICENSE.md
%{python_sitelib}/msgpack_numpy-%{version}-py*.egg-info
%{python_sitelib}/msgpack_numpy.*
%pycache_only %{python_sitelib}/__pycache__
++++++ msgpack-numpy-0.4.5.tar.gz -> msgpack-numpy-0.4.7.1.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/msgpack-numpy-0.4.5/AUTHORS.md
new/msgpack-numpy-0.4.7.1/AUTHORS.md
--- old/msgpack-numpy-0.4.5/AUTHORS.md 1970-01-01 01:00:00.000000000 +0100
+++ new/msgpack-numpy-0.4.7.1/AUTHORS.md 2020-09-30 23:20:50.000000000
+0200
@@ -0,0 +1,17 @@
+<!---
+-*- mode:markdown -*-
+vi:ft=markdown
+-->
+
+Authors
+=======
+This software was written and packaged by [Lev E.
Givon](https://github.com/lebedov)
+
+Special thanks are due to the following parties for their contributions:
+
+- [Alex Ford](https://github.com/asford) - bug fix.
+- [Colin Jermain](https://github.com/cjermain) - Python 3 support.
+- [John Tyree](https://github.com/johntyree) - support for numpy scalar
booleans.
+- [Mehdi Sadeghi](https://github.com/mehdisadeghi) - bug reports.
+- [Sujoy Roy](https://github.com/tvkpz) - bug reports.
+- [Jose Coutinho](https://github.com/tiagocoutinho) - make msgpack-numpy
params consistent with msgpack-python.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/msgpack-numpy-0.4.5/AUTHORS.rst
new/msgpack-numpy-0.4.7.1/AUTHORS.rst
--- old/msgpack-numpy-0.4.5/AUTHORS.rst 2017-12-28 15:08:23.000000000 +0100
+++ new/msgpack-numpy-0.4.7.1/AUTHORS.rst 1970-01-01 01:00:00.000000000
+0100
@@ -1,15 +0,0 @@
-.. -*- rst -*-
-
-Authors
-=======
-This software was written and packaged by `Lev E. Givon <[email protected]>`_.
-
-Special thanks are due to the following parties for their contributions:
-
-- `Colin Jermain <https://github.com/cjermain>`_ - Python 3 support.
-- `John Tyree <https://github.com/johntyree>`_ - support for numpy scalar
- booleans.
-- `Mehdi Sadeghi <https://github.com/mehdisadeghi>`_ - bug reports.
-- `Sujoy Roy <https://github.com/tvkpz>`_ - bug reports.
-- `Jose Coutinho <https://github.com/tiagocoutinho>`_ - make msgpack-numpy
- params consistent with msgpack-python.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/msgpack-numpy-0.4.5/CHANGES.md
new/msgpack-numpy-0.4.7.1/CHANGES.md
--- old/msgpack-numpy-0.4.5/CHANGES.md 1970-01-01 01:00:00.000000000 +0100
+++ new/msgpack-numpy-0.4.7.1/CHANGES.md 2020-09-30 23:22:08.000000000
+0200
@@ -0,0 +1,144 @@
+<!--
+-*- mode:markdown -*-
+vi:ft=markdown
+-->
+Change Log
+==========
+
+Release 0.4.7.1 (September 30, 2020)
+------------------------------------
+* Fix Python 2.7 regression (#45).
+
+Release 0.4.7 (September 16, 2020)
+----------------------------------
+* Fix bug unpacking nested, structured dtypes (#42).
+
+Release 0.4.6.1 (July 28, 2020)
+-------------------------------
+* Deprecate support for msgpack < 1.0.0 (#41).
+
+Release 0.4.6 (May 25, 2020)
+----------------------------
+* Set default use_bin_type and raw params of Packer and Unpacker classes the
same as in msgpack (#39).
+* Convert docs to Markdown.
+
+Release 0.4.5 (April 12, 2020)
+------------------------------
+* Set defaults appropriate to msgpack 1.0.0 (#38).
+
+Release 0.4.4.3 (May 16, 2019)
+------------------------------
+* Configure contiguous integration with Travis.
+* Move unit tests out of msgpack_numpy module.
+* Add workaround for issue handling n-dim arrays on MacOS (#35).
+
+Release 0.4.4.2 (November 8, 2018)
+----------------------------------
+* Fix regression handling noncontiguous arrays (#34).
+
+Release 0.4.4.1 (September 26, 2018)
+------------------------------------
+* Check Py version before defining encode and tostr funcs.
+* Eliminate deprecation warnings, raise minimum required msgpack version (#31).
+* Fix Python 2 support (#32).
+
+Release 0.4.4 (September 25, 2018)
+----------------------------------
+* Access ndarray memory view directly to slightly speed up encoding (#30).
+
+Release 0.4.3.2 - (September 17, 2018)
+--------------------------------------
+* Update classifiers to list Py3 support (#29).
+
+Release 0.4.3.1 - (July 11, 2018)
+---------------------------------
+* Switch to numpy.frombuffer to avoid deprecation warning (#27).
+
+Release 0.4.3 - (February 25, 2018)
+-----------------------------------
+* Change dependency name due to package name change (#25).
+
+Release 0.4.2 - (December 2, 2017)
+----------------------------------
+* Make decoding/encoding defaults identical to those of msgpack-python 0.4.*
(#19).
+* Fix handling of nested arrays in Py3 (#21).
+* Improve decoding of complex values in Py3.
+* Use numpy.testing functions to make unit test errors more informative.
+* Make object_hook params consistent with those of msgack-python (#23).
+
+Release 0.4.1 - (July 6, 2017)
+------------------------------
+* Improve ability to decode data serialized with versions before 0.3.9 (#20).
+
+Release 0.4.0 - (May 24, 2017)
+------------------------------
+* Remove deprecated ez_setup.
+* Add numpy >= 1.9.0 dependency (#18).
+
+Release 0.3.9 - (February 7, 2017)
+----------------------------------
+* Complex type handling fixes.
+* Handle structured dtypes (#15).
+* Note: data serialized with earlier versions cannot be deserialized with
0.3.9
+ (#17).
+
+Release 0.3.8 - (Februrary 4, 2017)
+-----------------------------------
+* Fix deserialization with Python 3.5 (#13).
+
+Release 0.3.7 - (March 12, 2016)
+--------------------------------
+* Add Python 3 support (#11).
+
+Release 0.3.6 - (July 8, 2015)
+------------------------------
+* Fall back to pure Python msgpack if compiled extension is unavailable (#6).
+
+Release 0.3.5 - (February 12, 2015)
+-----------------------------------
+* Add support for numpy scalar booleans (#8).
+
+Release 0.3.4 - (December 12, 2014)
+-----------------------------------
+* Add badges, update README.
+
+Release 0.3.3 - (October 21, 2014)
+----------------------------------
+* Add missing ez_setup.py file.
+
+Release 0.3.2 - (May 6, 2014)
+-----------------------------
+* Simplify encoding/decoding of numpy scalars.
+
+Release 0.3.1.1 - (March 2, 2014)
+---------------------------------
+* Make package a simple module to fix dependency installation issues.
+
+Release 0.3.1 - (March 2, 2014)
+-------------------------------
+* Switch to PEP 440 version numbering.
+* Update to setuptools 2.2 ez_setup.py
+
+Release 0.03 - (October 30, 2013)
+---------------------------------
+* Add support for msgpack 0.4.0.
+* Rename to msgpack-numpy.
+
+Release 0.022 - (September 10, 2013)
+------------------------------------
+* Fix decoding of string arrays (#4).
+* Fix decoding of dicts containing ndarrays (#5).
+
+Release 0.021 - (May 29, 2013)
+------------------------------
+* Improve encoding/decoding performance for arrays.
+* Fix numpy type support on different platforms (#3).
+
+Release 0.02 - (February 21, 2013)
+----------------------------------
+* Add support for msgpack 0.3.0 (contributed by crispamares).
+
+Release 0.01 - (February 07, 2013)
+----------------------------------
+* First public release.
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/msgpack-numpy-0.4.5/CHANGES.rst
new/msgpack-numpy-0.4.7.1/CHANGES.rst
--- old/msgpack-numpy-0.4.5/CHANGES.rst 2020-04-13 04:00:52.000000000 +0200
+++ new/msgpack-numpy-0.4.7.1/CHANGES.rst 1970-01-01 01:00:00.000000000
+0100
@@ -1,125 +0,0 @@
-.. -*- rst -*-
-
-Change Log
-==========
-
-Release 0.4.5 (April 12, 2020)
-------------------------------
-* Set defaults appropriate to msgpack 1.0.0 (#38).
-
-Release 0.4.4.3 (May 16, 2019)
-------------------------------
-* Configure contiguous integration with Travis.
-* Move unit tests out of msgpack_numpy module.
-* Add workaround for issue handling n-dim arrays on MacOS (#35).
-
-Release 0.4.4.2 (November 8, 2018)
-----------------------------------
-* Fix regression handling noncontiguous arrays (#34).
-
-Release 0.4.4.1 (September 26, 2018)
-------------------------------------
-* Check Py version before defining encode and tostr funcs.
-* Eliminate deprecation warnings, raise minimum required msgpack version (#31).
-* Fix Python 2 support (#32).
-
-Release 0.4.4 (September 25, 2018)
-----------------------------------
-* Access ndarray memory view directly to slightly speed up encoding (#30).
-
-Release 0.4.3.2 - (September 17, 2018)
---------------------------------------
-* Update classifiers to list Py3 support (#29).
-
-Release 0.4.3.1 - (July 11, 2018)
----------------------------------
-* Switch to numpy.frombuffer to avoid deprecation warning (#27).
-
-Release 0.4.3 - (February 25, 2018)
------------------------------------
-* Change dependency name due to package name change (#25).
-
-Release 0.4.2 - (December 2, 2017)
-----------------------------------
-* Make decoding/encoding defaults identical to those of msgpack-python 0.4.*
(#19).
-* Fix handling of nested arrays in Py3 (#21).
-* Improve decoding of complex values in Py3.
-* Use numpy.testing functions to make unit test errors more informative.
-* Make object_hook params consistent with those of msgack-python (#23).
-
-Release 0.4.1 - (July 6, 2017)
-------------------------------
-* Improve ability to decode data serialized with versions before 0.3.9 (#20).
-
-Release 0.4.0 - (May 24, 2017)
-------------------------------
-* Remove deprecated ez_setup.
-* Add numpy >= 1.9.0 dependency (#18).
-
-Release 0.3.9 - (February 7, 2017)
-----------------------------------
-* Complex type handling fixes.
-* Handle structured dtypes (#15).
-* Note: data serialized with earlier versions cannot be deserialized with
0.3.9
- (#17).
-
-Release 0.3.8 - (Februrary 4, 2017)
------------------------------------
-* Fix deserialization with Python 3.5 (#13).
-
-Release 0.3.7 - (March 12, 2016)
---------------------------------
-* Add Python 3 support (#11).
-
-Release 0.3.6 - (July 8, 2015)
-------------------------------
-* Fall back to pure Python msgpack if compiled extension is unavailable (#6).
-
-Release 0.3.5 - (February 12, 2015)
------------------------------------
-* Add support for numpy scalar booleans (#8).
-
-Release 0.3.4 - (December 12, 2014)
------------------------------------
-* Add badges, update README.
-
-Release 0.3.3 - (October 21, 2014)
-----------------------------------
-* Add missing ez_setup.py file.
-
-Release 0.3.2 - (May 6, 2014)
------------------------------
-* Simplify encoding/decoding of numpy scalars.
-
-Release 0.3.1.1 - (March 2, 2014)
----------------------------------
-* Make package a simple module to fix dependency installation issues.
-
-Release 0.3.1 - (March 2, 2014)
--------------------------------
-* Switch to PEP 440 version numbering.
-* Update to setuptools 2.2 ez_setup.py
-
-Release 0.03 - (October 30, 2013)
----------------------------------
-* Add support for msgpack 0.4.0.
-* Rename to msgpack-numpy.
-
-Release 0.022 - (September 10, 2013)
-------------------------------------
-* Fix decoding of string arrays (#4).
-* Fix decoding of dicts containing ndarrays (#5).
-
-Release 0.021 - (May 29, 2013)
-------------------------------
-* Improve encoding/decoding performance for arrays.
-* Fix numpy type support on different platforms (#3).
-
-Release 0.02 - (February 21, 2013)
-----------------------------------
-* Add support for msgpack 0.3.0 (contributed by crispamares).
-
-Release 0.01 - (February 07, 2013)
-----------------------------------
-* First public release.
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/msgpack-numpy-0.4.5/LICENSE.md
new/msgpack-numpy-0.4.7.1/LICENSE.md
--- old/msgpack-numpy-0.4.5/LICENSE.md 1970-01-01 01:00:00.000000000 +0100
+++ new/msgpack-numpy-0.4.7.1/LICENSE.md 2020-09-16 14:43:27.000000000
+0200
@@ -0,0 +1,35 @@
+<!---
+-*- mode:markdown -*-
+vi:ft=markdown
+-->
+License
+=======
+
+Copyright (c) 2013-2020, Lev E. Givon.
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are
+met:
+
+* Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the above
+ copyright notice, this list of conditions and the following
+ disclaimer in the documentation and/or other materials provided
+ with the distribution.
+* Neither the name of Lev E. Givon nor the names of any
+ contributors may be used to endorse or promote products derived
+ from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/msgpack-numpy-0.4.5/LICENSE.rst
new/msgpack-numpy-0.4.7.1/LICENSE.rst
--- old/msgpack-numpy-0.4.5/LICENSE.rst 2020-04-13 03:57:32.000000000 +0200
+++ new/msgpack-numpy-0.4.7.1/LICENSE.rst 1970-01-01 01:00:00.000000000
+0100
@@ -1,33 +0,0 @@
-.. -*- rst -*-
-
-License
-=======
-
-Copyright (c) 2013-2020, Lev E. Givon.
-All rights reserved.
-
-Redistribution and use in source and binary forms, with or without
-modification, are permitted provided that the following conditions are
-met:
-
-* Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
-* Redistributions in binary form must reproduce the above
- copyright notice, this list of conditions and the following
- disclaimer in the documentation and/or other materials provided
- with the distribution.
-* Neither the name of Lev E. Givon nor the names of any
- contributors may be used to endorse or promote products derived
- from this software without specific prior written permission.
-
-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/msgpack-numpy-0.4.5/PKG-INFO
new/msgpack-numpy-0.4.7.1/PKG-INFO
--- old/msgpack-numpy-0.4.5/PKG-INFO 2020-04-13 04:02:38.000000000 +0200
+++ new/msgpack-numpy-0.4.7.1/PKG-INFO 2020-09-30 23:22:59.973143800 +0200
@@ -1,6 +1,6 @@
-Metadata-Version: 1.1
+Metadata-Version: 2.1
Name: msgpack-numpy
-Version: 0.4.5
+Version: 0.4.7.1
Summary: Numpy data serialization using msgpack
Home-page: https://github.com/lebedov/msgpack-numpy
Author: Lev E. Givon
@@ -10,26 +10,23 @@
-------------------
This package provides encoding and decoding routines that enable the
serialization and deserialization of numerical and array data types
provided by
- `numpy <http://www.numpy.org/>`_ using the highly efficient
- `msgpack <http://msgpack.org/>`_ format. Serialization of Python's
+ [numpy](http://www.numpy.org/) using the highly efficient
+ [msgpack](http://msgpack.org/) format. Serialization of Python's
native complex data types is also supported.
- .. image:: https://img.shields.io/pypi/v/msgpack-numpy.svg
- :target: https://pypi.python.org/pypi/msgpack-numpy
- :alt: Latest Version
- .. image::
https://travis-ci.org/lebedov/msgpack-numpy.svg?branch=master
- :target: https://travis-ci.org/lebedov/msgpack-numpy
+ [](https://pypi.python.org/pypi/msgpack-numpy)
+ [](https://travis-ci.org/lebedov/msgpack-numpy)
Installation
------------
msgpack-numpy requires msgpack-python and numpy. If you
- have `pip <http://www.pip-installer.org/>`_ installed on your
- system, run ::
+ have [pip](http://www.pip-installer.org/) installed on your
+ system, run
pip install msgpack-numpy
to install the package and all dependencies. You can also download
- the source tarball, unpack it, and run ::
+ the source tarball, unpack it, and run
python setup.py install
@@ -38,7 +35,7 @@
Usage
-----
The easiest way to use msgpack-numpy is to call its monkey patching
- function after importing the Python msgpack package: ::
+ function after importing the Python msgpack package:
import msgpack
import msgpack_numpy as m
@@ -47,7 +44,7 @@
This will automatically force all msgpack serialization and
deserialization
routines (and other packages that use them) to become numpy-aware.
Of course, one can also manually pass the encoder and
- decoder provided by msgpack-numpy to the msgpack routines: ::
+ decoder provided by msgpack-numpy to the msgpack routines:
import msgpack
import msgpack_numpy as m
@@ -71,23 +68,40 @@
of this overhead by writing a custom encoder/decoder pair that
produces more
efficient serializations for those specific use cases.
+ Note that numpy arrays deserialized by msgpack-numpy are read-only and
must be copied
+ if they are to be modified.
+
Development
-----------
- The latest source code can be obtained from
- `GitHub <https://github.com/lebedov/msgpack-numpy/>`_.
+ The latest source code can be obtained from
[GitHub](https://github.com/lebedov/msgpack-numpy/).
+
+ msgpack-numpy maintains compatibility with python versions 2.7 and
3.5+.
+
+ Install [`tox`](https://tox.readthedocs.io/en/latest/) to support
testing
+ across multiple python versions in your development environment. If you
+ use [`conda`](https://docs.conda.io/en/latest/) to install `python` use
+ [`tox-conda`](https://github.com/tox-dev/tox-conda) to automatically
manage
+ testing across all supported python versions.
+
+ # Using a system python
+ pip install tox
+
+ # Additionally, using a conda-provided python
+ pip install tox tox-conda
+
+ Execute tests across supported python versions:
+
+ tox
Authors
-------
- See the included `AUTHORS.rst
- <https://github.com/lebedov/msgpack-numpy/blob/master/AUTHORS.rst>`_
file for
+ See the included
[AUTHORS.md](https://github.com/lebedov/msgpack-numpy/blob/master/AUTHORS.md)
file for
more information.
License
-------
- This software is licensed under the `BSD License
- <http://www.opensource.org/licenses/bsd-license>`_.
- See the included `LICENSE.rst
- <https://github.com/lebedov/msgpack-numpy/blob/master/LICENSE.rst>`_
file for
+ This software is licensed under the [BSD
License](http://www.opensource.org/licenses/bsd-license).
+ See the included
[LICENSE.md](https://github.com/lebedov/msgpack-numpy/blob/master/LICENSE.md)
file for
more information.
Platform: UNKNOWN
@@ -103,5 +117,7 @@
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
+Classifier: Programming Language :: Python :: 3.8
Classifier: Topic :: Scientific/Engineering
Classifier: Topic :: Software Development
+Description-Content-Type: text/markdown
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/msgpack-numpy-0.4.5/README.md
new/msgpack-numpy-0.4.7.1/README.md
--- old/msgpack-numpy-0.4.5/README.md 1970-01-01 01:00:00.000000000 +0100
+++ new/msgpack-numpy-0.4.7.1/README.md 2020-09-30 23:19:44.000000000 +0200
@@ -0,0 +1,104 @@
+<!---
+-*- mode:markdown -*-
+vi:ft=markdown
+-->
+Numpy Data Type Serialization Using Msgpack
+===========================================
+
+Package Description
+-------------------
+This package provides encoding and decoding routines that enable the
+serialization and deserialization of numerical and array data types provided
by
+[numpy](http://www.numpy.org/) using the highly efficient
+[msgpack](http://msgpack.org/) format. Serialization of Python's
+native complex data types is also supported.
+
+[](https://pypi.python.org/pypi/msgpack-numpy)
+[](https://travis-ci.org/lebedov/msgpack-numpy)
+
+Installation
+------------
+msgpack-numpy requires msgpack-python and numpy. If you
+have [pip](http://www.pip-installer.org/) installed on your
+system, run
+
+ pip install msgpack-numpy
+
+to install the package and all dependencies. You can also download
+the source tarball, unpack it, and run
+
+ python setup.py install
+
+from within the source directory.
+
+Usage
+-----
+The easiest way to use msgpack-numpy is to call its monkey patching
+function after importing the Python msgpack package:
+
+ import msgpack
+ import msgpack_numpy as m
+ m.patch()
+
+This will automatically force all msgpack serialization and deserialization
+routines (and other packages that use them) to become numpy-aware.
+Of course, one can also manually pass the encoder and
+decoder provided by msgpack-numpy to the msgpack routines:
+
+ import msgpack
+ import msgpack_numpy as m
+ import numpy as np
+
+ x = np.random.rand(5)
+ x_enc = msgpack.packb(x, default=m.encode)
+ x_rec = msgpack.unpackb(x_enc, object_hook=m.decode)
+
+msgpack-numpy will try to use the binary (fast) extension in msgpack by
default.
+If msgpack was not compiled with Cython (or if the ``MSGPACK_PUREPYTHON``
+variable is set), it will fall back to using the slower pure Python msgpack
+implementation.
+
+Notes
+-----
+The primary design goal of msgpack-numpy is ensuring preservation of numerical
+data types during msgpack serialization and deserialization. Inclusion of type
+information in the serialized data necessarily incurs some storage overhead; if
+preservation of type information is not needed, one may be able to avoid some
+of this overhead by writing a custom encoder/decoder pair that produces more
+efficient serializations for those specific use cases.
+
+Note that numpy arrays deserialized by msgpack-numpy are read-only and must be
copied
+if they are to be modified.
+
+Development
+-----------
+The latest source code can be obtained from
[GitHub](https://github.com/lebedov/msgpack-numpy/).
+
+msgpack-numpy maintains compatibility with python versions 2.7 and 3.5+.
+
+Install [`tox`](https://tox.readthedocs.io/en/latest/) to support testing
+across multiple python versions in your development environment. If you
+use [`conda`](https://docs.conda.io/en/latest/) to install `python` use
+[`tox-conda`](https://github.com/tox-dev/tox-conda) to automatically manage
+testing across all supported python versions.
+
+ # Using a system python
+ pip install tox
+
+ # Additionally, using a conda-provided python
+ pip install tox tox-conda
+
+Execute tests across supported python versions:
+
+ tox
+
+Authors
+-------
+See the included
[AUTHORS.md](https://github.com/lebedov/msgpack-numpy/blob/master/AUTHORS.md)
file for
+more information.
+
+License
+-------
+This software is licensed under the [BSD
License](http://www.opensource.org/licenses/bsd-license).
+See the included
[LICENSE.md](https://github.com/lebedov/msgpack-numpy/blob/master/LICENSE.md)
file for
+more information.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/msgpack-numpy-0.4.5/README.rst
new/msgpack-numpy-0.4.7.1/README.rst
--- old/msgpack-numpy-0.4.5/README.rst 2019-10-24 21:42:12.000000000 +0200
+++ new/msgpack-numpy-0.4.7.1/README.rst 1970-01-01 01:00:00.000000000
+0100
@@ -1,88 +0,0 @@
-.. -*- rst -*-
-
-Numpy Data Type Serialization Using Msgpack
-===========================================
-
-Package Description
--------------------
-This package provides encoding and decoding routines that enable the
-serialization and deserialization of numerical and array data types provided
by
-`numpy <http://www.numpy.org/>`_ using the highly efficient
-`msgpack <http://msgpack.org/>`_ format. Serialization of Python's
-native complex data types is also supported.
-
-.. image:: https://img.shields.io/pypi/v/msgpack-numpy.svg
- :target: https://pypi.python.org/pypi/msgpack-numpy
- :alt: Latest Version
-.. image:: https://travis-ci.org/lebedov/msgpack-numpy.svg?branch=master
- :target: https://travis-ci.org/lebedov/msgpack-numpy
-
-Installation
-------------
-msgpack-numpy requires msgpack-python and numpy. If you
-have `pip <http://www.pip-installer.org/>`_ installed on your
-system, run ::
-
- pip install msgpack-numpy
-
-to install the package and all dependencies. You can also download
-the source tarball, unpack it, and run ::
-
- python setup.py install
-
-from within the source directory.
-
-Usage
------
-The easiest way to use msgpack-numpy is to call its monkey patching
-function after importing the Python msgpack package: ::
-
- import msgpack
- import msgpack_numpy as m
- m.patch()
-
-This will automatically force all msgpack serialization and deserialization
-routines (and other packages that use them) to become numpy-aware.
-Of course, one can also manually pass the encoder and
-decoder provided by msgpack-numpy to the msgpack routines: ::
-
- import msgpack
- import msgpack_numpy as m
- import numpy as np
-
- x = np.random.rand(5)
- x_enc = msgpack.packb(x, default=m.encode)
- x_rec = msgpack.unpackb(x_enc, object_hook=m.decode)
-
-msgpack-numpy will try to use the binary (fast) extension in msgpack by
default.
-If msgpack was not compiled with Cython (or if the ``MSGPACK_PUREPYTHON``
-variable is set), it will fall back to using the slower pure Python msgpack
-implementation.
-
-Notes
------
-The primary design goal of msgpack-numpy is ensuring preservation of numerical
-data types during msgpack serialization and deserialization. Inclusion of type
-information in the serialized data necessarily incurs some storage overhead; if
-preservation of type information is not needed, one may be able to avoid some
-of this overhead by writing a custom encoder/decoder pair that produces more
-efficient serializations for those specific use cases.
-
-Development
------------
-The latest source code can be obtained from
-`GitHub <https://github.com/lebedov/msgpack-numpy/>`_.
-
-Authors
--------
-See the included `AUTHORS.rst
-<https://github.com/lebedov/msgpack-numpy/blob/master/AUTHORS.rst>`_ file for
-more information.
-
-License
--------
-This software is licensed under the `BSD License
-<http://www.opensource.org/licenses/bsd-license>`_.
-See the included `LICENSE.rst
-<https://github.com/lebedov/msgpack-numpy/blob/master/LICENSE.rst>`_ file for
-more information.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/msgpack-numpy-0.4.5/msgpack_numpy.egg-info/PKG-INFO
new/msgpack-numpy-0.4.7.1/msgpack_numpy.egg-info/PKG-INFO
--- old/msgpack-numpy-0.4.5/msgpack_numpy.egg-info/PKG-INFO 2020-04-13
04:02:38.000000000 +0200
+++ new/msgpack-numpy-0.4.7.1/msgpack_numpy.egg-info/PKG-INFO 2020-09-30
23:22:59.000000000 +0200
@@ -1,6 +1,6 @@
-Metadata-Version: 1.1
+Metadata-Version: 2.1
Name: msgpack-numpy
-Version: 0.4.5
+Version: 0.4.7.1
Summary: Numpy data serialization using msgpack
Home-page: https://github.com/lebedov/msgpack-numpy
Author: Lev E. Givon
@@ -10,26 +10,23 @@
-------------------
This package provides encoding and decoding routines that enable the
serialization and deserialization of numerical and array data types
provided by
- `numpy <http://www.numpy.org/>`_ using the highly efficient
- `msgpack <http://msgpack.org/>`_ format. Serialization of Python's
+ [numpy](http://www.numpy.org/) using the highly efficient
+ [msgpack](http://msgpack.org/) format. Serialization of Python's
native complex data types is also supported.
- .. image:: https://img.shields.io/pypi/v/msgpack-numpy.svg
- :target: https://pypi.python.org/pypi/msgpack-numpy
- :alt: Latest Version
- .. image::
https://travis-ci.org/lebedov/msgpack-numpy.svg?branch=master
- :target: https://travis-ci.org/lebedov/msgpack-numpy
+ [](https://pypi.python.org/pypi/msgpack-numpy)
+ [](https://travis-ci.org/lebedov/msgpack-numpy)
Installation
------------
msgpack-numpy requires msgpack-python and numpy. If you
- have `pip <http://www.pip-installer.org/>`_ installed on your
- system, run ::
+ have [pip](http://www.pip-installer.org/) installed on your
+ system, run
pip install msgpack-numpy
to install the package and all dependencies. You can also download
- the source tarball, unpack it, and run ::
+ the source tarball, unpack it, and run
python setup.py install
@@ -38,7 +35,7 @@
Usage
-----
The easiest way to use msgpack-numpy is to call its monkey patching
- function after importing the Python msgpack package: ::
+ function after importing the Python msgpack package:
import msgpack
import msgpack_numpy as m
@@ -47,7 +44,7 @@
This will automatically force all msgpack serialization and
deserialization
routines (and other packages that use them) to become numpy-aware.
Of course, one can also manually pass the encoder and
- decoder provided by msgpack-numpy to the msgpack routines: ::
+ decoder provided by msgpack-numpy to the msgpack routines:
import msgpack
import msgpack_numpy as m
@@ -71,23 +68,40 @@
of this overhead by writing a custom encoder/decoder pair that
produces more
efficient serializations for those specific use cases.
+ Note that numpy arrays deserialized by msgpack-numpy are read-only and
must be copied
+ if they are to be modified.
+
Development
-----------
- The latest source code can be obtained from
- `GitHub <https://github.com/lebedov/msgpack-numpy/>`_.
+ The latest source code can be obtained from
[GitHub](https://github.com/lebedov/msgpack-numpy/).
+
+ msgpack-numpy maintains compatibility with python versions 2.7 and
3.5+.
+
+ Install [`tox`](https://tox.readthedocs.io/en/latest/) to support
testing
+ across multiple python versions in your development environment. If you
+ use [`conda`](https://docs.conda.io/en/latest/) to install `python` use
+ [`tox-conda`](https://github.com/tox-dev/tox-conda) to automatically
manage
+ testing across all supported python versions.
+
+ # Using a system python
+ pip install tox
+
+ # Additionally, using a conda-provided python
+ pip install tox tox-conda
+
+ Execute tests across supported python versions:
+
+ tox
Authors
-------
- See the included `AUTHORS.rst
- <https://github.com/lebedov/msgpack-numpy/blob/master/AUTHORS.rst>`_
file for
+ See the included
[AUTHORS.md](https://github.com/lebedov/msgpack-numpy/blob/master/AUTHORS.md)
file for
more information.
License
-------
- This software is licensed under the `BSD License
- <http://www.opensource.org/licenses/bsd-license>`_.
- See the included `LICENSE.rst
- <https://github.com/lebedov/msgpack-numpy/blob/master/LICENSE.rst>`_
file for
+ This software is licensed under the [BSD
License](http://www.opensource.org/licenses/bsd-license).
+ See the included
[LICENSE.md](https://github.com/lebedov/msgpack-numpy/blob/master/LICENSE.md)
file for
more information.
Platform: UNKNOWN
@@ -103,5 +117,7 @@
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
+Classifier: Programming Language :: Python :: 3.8
Classifier: Topic :: Scientific/Engineering
Classifier: Topic :: Software Development
+Description-Content-Type: text/markdown
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/msgpack-numpy-0.4.5/msgpack_numpy.egg-info/SOURCES.txt
new/msgpack-numpy-0.4.7.1/msgpack_numpy.egg-info/SOURCES.txt
--- old/msgpack-numpy-0.4.5/msgpack_numpy.egg-info/SOURCES.txt 2020-04-13
04:02:38.000000000 +0200
+++ new/msgpack-numpy-0.4.7.1/msgpack_numpy.egg-info/SOURCES.txt
2020-09-30 23:22:59.000000000 +0200
@@ -1,7 +1,7 @@
-AUTHORS.rst
-CHANGES.rst
-LICENSE.rst
-README.rst
+AUTHORS.md
+CHANGES.md
+LICENSE.md
+README.md
msgpack_numpy.py
setup.cfg
setup.py
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/msgpack-numpy-0.4.5/msgpack_numpy.py
new/msgpack-numpy-0.4.7.1/msgpack_numpy.py
--- old/msgpack-numpy-0.4.5/msgpack_numpy.py 2020-04-13 03:59:53.000000000
+0200
+++ new/msgpack-numpy-0.4.7.1/msgpack_numpy.py 2020-09-30 23:19:44.000000000
+0200
@@ -11,6 +11,7 @@
import sys
import functools
+import warnings
import msgpack
from msgpack import Packer as _Packer, Unpacker as _Unpacker, \
@@ -87,11 +88,11 @@
else:
descr = obj[b'type']
return np.frombuffer(obj[b'data'],
- dtype=np.dtype(descr)).reshape(obj[b'shape'])
+ dtype=_unpack_dtype(descr)).reshape(obj[b'shape'])
else:
descr = obj[b'type']
return np.frombuffer(obj[b'data'],
- dtype=np.dtype(descr))[0]
+ dtype=_unpack_dtype(descr))[0]
elif b'complex' in obj:
return complex(tostr(obj[b'data']))
else:
@@ -99,6 +100,23 @@
except KeyError:
return obj if chain is None else chain(obj)
+def _unpack_dtype(dtype):
+ """
+ Unpack dtype descr, recursively unpacking nested structured dtypes.
+ """
+
+ if isinstance(dtype, (list, tuple)):
+ # Unpack structured dtypes of the form: (name, type, *shape)
+ dtype = [
+ (subdtype[0], _unpack_dtype(subdtype[1])) + tuple(subdtype[2:])
+ for subdtype in dtype
+ ]
+ return np.dtype(dtype)
+
+if msgpack.version < (1, 0, 0):
+ warnings.warn('support for msgpack < 1.0.0 will be removed in a future
release',
+ DeprecationWarning)
+
# Maintain support for msgpack < 0.4.0:
if msgpack.version < (0, 4, 0):
class Packer(_Packer):
@@ -135,7 +153,7 @@
unicode_errors='strict',
use_single_float=False,
autoreset=1,
- use_bin_type=0,
+ use_bin_type=True,
strict_types=False):
default = functools.partial(encode, chain=default)
super(Packer, self).__init__(default=default,
@@ -147,7 +165,7 @@
class Unpacker(_Unpacker):
def __init__(self, file_like=None, read_size=0, use_list=None,
- raw=True,
+ raw=False,
object_hook=None,
object_pairs_hook=None, list_hook=None,
unicode_errors='strict', max_buffer_size=0,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/msgpack-numpy-0.4.5/setup.py
new/msgpack-numpy-0.4.7.1/setup.py
--- old/msgpack-numpy-0.4.5/setup.py 2020-04-13 03:57:20.000000000 +0200
+++ new/msgpack-numpy-0.4.7.1/setup.py 2020-09-30 23:20:35.000000000 +0200
@@ -6,14 +6,15 @@
from setuptools import setup
NAME = 'msgpack-numpy'
-VERSION = '0.4.5'
+VERSION = '0.4.7.1'
AUTHOR = 'Lev E. Givon'
AUTHOR_EMAIL = '[email protected]'
URL = 'https://github.com/lebedov/msgpack-numpy'
DESCRIPTION = 'Numpy data serialization using msgpack'
-with open('README.rst', 'r') as f:
+with open('README.md', 'r') as f:
LONG_DESCRIPTION = f.read()
LONG_DESCRIPTION = re.search('.*(^Package Description.*)', LONG_DESCRIPTION,
re.MULTILINE|re.DOTALL).group(1)
+LONG_DESCRIPTION_CONTENT_TYPE = 'text/markdown'
DOWNLOAD_URL = URL
LICENSE = 'BSD'
CLASSIFIERS = [
@@ -29,6 +30,7 @@
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
+ 'Programming Language :: Python :: 3.8',
'Topic :: Scientific/Engineering',
'Topic :: Software Development']
@@ -45,6 +47,7 @@
classifiers = CLASSIFIERS,
description = DESCRIPTION,
long_description = LONG_DESCRIPTION,
+ long_description_content_type = LONG_DESCRIPTION_CONTENT_TYPE,
url = URL,
py_modules = ['msgpack_numpy'],
install_requires = ['numpy>=1.9.0',
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/msgpack-numpy-0.4.5/tests.py
new/msgpack-numpy-0.4.7.1/tests.py
--- old/msgpack-numpy-0.4.5/tests.py 2019-05-16 14:10:59.000000000 +0200
+++ new/msgpack-numpy-0.4.7.1/tests.py 2020-09-16 14:43:27.000000000 +0200
@@ -26,41 +26,41 @@
def setUp(self):
patch()
- def encode_decode(self, x, use_bin_type=False, raw=True,
- use_list=True, max_bin_len=-1):
- x_enc = msgpack.packb(x, use_bin_type=use_bin_type)
- return msgpack.unpackb(x_enc, raw=raw, use_list=use_list,
+ def encode_decode(self, x, use_list=True, max_bin_len=-1):
+ x_enc = msgpack.packb(x)
+ return msgpack.unpackb(x_enc, use_list=use_list,
max_bin_len=max_bin_len)
def encode_thirdparty(self, obj):
- return dict(__thirdparty__=True, foo=obj.foo)
+ return {b'__thirdparty__': True, b'foo': obj.foo}
def decode_thirdparty(self, obj):
if b'__thirdparty__' in obj:
return ThirdParty(foo=obj[b'foo'])
return obj
- def encode_decode_thirdparty(self, x, use_bin_type=False, raw=True,
+ def encode_decode_thirdparty(self, x,
use_list=True, max_bin_len=-1):
- x_enc = msgpack.packb(x, default=self.encode_thirdparty,
- use_bin_type=use_bin_type)
- return msgpack.unpackb(x_enc, raw=raw,
+ x_enc = msgpack.packb(x, default=self.encode_thirdparty)
+ return msgpack.unpackb(x_enc,
object_hook=self.decode_thirdparty,
use_list=use_list, max_bin_len=max_bin_len)
def test_bin(self):
- # Since bytes == str in Python 2.7, the following
- # should pass on both 2.7 and 3.*
- assert_equal(type(self.encode_decode(b'foo')), bytes)
+ # str == bytes on Python 2:
+ if sys.version_info.major == 2:
+ assert_equal(type(self.encode_decode(b'foo')), str)
+ else:
+ assert_equal(type(self.encode_decode(b'foo')), bytes)
def test_str(self):
- assert_equal(type(self.encode_decode('foo')), bytes)
+ # str != unicode on Python 2:
if sys.version_info.major == 2:
+ assert_equal(type(self.encode_decode('foo')), str)
+ assert_equal(type(self.encode_decode(u'foo')), unicode)
+ else:
assert_equal(type(self.encode_decode(u'foo')), str)
- # Test non-default string encoding/decoding:
- assert_equal(type(self.encode_decode(u'foo', True, False)),
unicode)
-
def test_numpy_scalar_bool(self):
x = np.bool_(True)
x_rec = self.encode_decode(x)
@@ -204,9 +204,8 @@
"""
Unit test for weird data loss error on MacOS (#35).
"""
- x = np.random.rand(5,5).astype(np.float32)
- x_rec = self.encode_decode(x, use_bin_type=True, raw=False,
- use_list=False, max_bin_len=50000000)
+ x = np.random.rand(5, 5).astype(np.float32)
+ x_rec = self.encode_decode(x, use_list=False, max_bin_len=50000000)
assert_array_equal(x, x_rec)
assert_equal(x.dtype, x_rec.dtype)
@@ -244,5 +243,44 @@
x_rec = self.encode_decode_thirdparty(x)
self.assertEqual(x, x_rec)
+ def test_numpy_structured_array(self):
+ structured_dtype = np.dtype([("a", float), ("b", int)])
+
+ x = np.empty((10,), dtype=structured_dtype)
+ x["a"] = np.arange(10)
+ x["b"] = np.arange(10)
+
+ x_rec = self.encode_decode(x)
+
+ assert_array_equal(x, x_rec)
+ self.assertEqual(x.dtype, x_rec.dtype)
+
+ def test_numpy_shaped_structured_array(self):
+ shaped_structured_dtype = np.dtype([("a", float, 3), ("b", int)])
+
+ x = np.empty((10,), dtype=shaped_structured_dtype)
+ x["a"] = np.arange(30).reshape(10, 3)
+ x["b"] = np.arange(10)
+
+ x_rec = self.encode_decode(x)
+
+ assert_array_equal(x, x_rec)
+ self.assertEqual(x.dtype, x_rec.dtype)
+
+ def test_numpy_nested_structured_array(self):
+ structured_dtype = np.dtype([("a", float), ("b", int)])
+ nested_dtype = np.dtype([("foo", structured_dtype), ("bar",
structured_dtype)])
+
+ x = np.empty((10,), dtype=nested_dtype)
+ x["foo"]["a"] = np.arange(10)
+ x["foo"]["b"] = np.arange(10)
+ x["bar"]["a"] = np.arange(10) + 10
+ x["bar"]["b"] = np.arange(10) + 10
+
+ x_rec = self.encode_decode(x)
+
+ assert_array_equal(x, x_rec)
+ self.assertEqual(x.dtype, x_rec.dtype)
+
if __name__ == '__main__':
main()