Spead2

Latest version: v4.3.2

Safety actively analyzes 693883 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 18 of 19

0.3.0

This release contains a number of backwards-incompatible changes in the Python
bindings, although most uses will probably not notice:

- When a received character array is returned as a string, it is now of type
:py:class:`str` (previously it was :py:class:`unicode` in Python 2).

- An array of characters with a numpy descriptor with type `S1` will no longer
automatically be turned back into a string. Only using a format of
`[('c', 8)]` will do so.

- The `c` format code may now only be used with a length of 8.

- When sending, values will now always be converted to a numpy array first,
even if this isn't the final representation that will be put on the network.
This may lead to some subtle changes in behaviour.

- The `BUG_COMPAT_NO_SCALAR_NUMPY` introduced in 0.2.2 has been removed. Now,
specifying an old-style format will always use that format at the protocol
level, rather than replacing it with a numpy descriptor.

There are also some other bug-fixes and improvements:

- Fix incorrect warnings about send buffer size.

- Added --descriptors option to spead2_recv.py.

- The `dtype` argument to :py:meth:`spead2.ItemGroup.add_item` is now
optional, removing the need to specify `dtype=None` when passing a format.

0.2.2

- Workaround for a PySPEAD bug that would cause PySPEAD to fail if sent a
simple scalar value. The user must still specify scalars with a format
rather than a dtype to make things work.

0.2.1

- Fix compilation on OS X again. The extension binary will be slightly larger as
a result, but still much smaller than before 0.2.0.

0.2.0

- **backwards-incompatible change**: for sending, the heap count is now tracked
internally by the stream, rather than an attribute of the heap. This affects
both C++ and Python bindings, although Python code that always uses
:py:class:`~spead2.send.HeapGenerator` rather than directly creating heaps
will not be affected.

- The :py:class:`~spead2.send.HeapGenerator` is extended to allow items to be
added to an existing heap and to give finer control over whether descriptors
and/or values are put in the heap.

- Fixes a bug that caused some values to be cast to non-native endian.

- Added overloaded equality tests on Flavour objects.

- Strip the extension binary to massively reduce its size

0.1.2

- Coerce values to int for legacy 'u' and 'i' fields

- Fix flavour selection in example code

0.1.1

- Fixes to support OS X

Page 18 of 19

© 2025 Safety CLI Cybersecurity Inc. All Rights Reserved.