Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions docs/compression/zstd.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,6 @@ Zstd
.. autoattribute:: codec_id
.. automethod:: encode
.. automethod:: decode
.. note::
If the compressed data does not contain the decompressed size, streaming
decompression will be used.
.. automethod:: get_config
.. automethod:: from_config

Expand Down
18 changes: 8 additions & 10 deletions docs/contributing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ Asking for help
---------------

If you have a question about how to use NumCodecs, please post your question on
StackOverflow using the `"numcodecs" tag <https://stackoverflow.com/questions/tagged/numcodecs>`_.
Stack Overflow using the `"numcodecs" tag <https://stackoverflow.com/questions/tagged/numcodecs>`_.
If you don't get a response within a day or two, feel free to raise a `GitHub issue
<https://github.com/zarr-developers/numcodecs/issues/new>`_ including a link to your
StackOverflow question. We will try to respond to questions as quickly as possible, but
Stack Overflow question. We will try to respond to questions as quickly as possible, but
please bear in mind that there may be periods where we have limited time to answer
questions due to other commitments.

Expand Down Expand Up @@ -148,12 +148,12 @@ docstrings. The simplest way to run the unit tests is to invoke::

$ pytest -v

NumCodecs currently supports Python 6-3.9, so the above command must
NumCodecs currently supports Python 3.11+, so the above command must
succeed before code can be accepted into the main code base.

All tests are automatically run via Travis (Linux) and AppVeyor (Windows) continuous
integration services for every pull request. Tests must pass under both services before
code can be accepted.
All tests are automatically run via GitHub Actions continuous
integration services for every pull request. Tests must pass
before code can be accepted.

Code standards
~~~~~~~~~~~~~~
Expand All @@ -167,8 +167,7 @@ Conformance can be checked by running::
Test coverage
~~~~~~~~~~~~~

NumCodecs maintains 100% test coverage under the latest Python stable release (currently
Python 3.9). Both unit tests and docstring doctests are included when computing
NumCodecs maintains 100% test coverage under the latest Python stable release. Both unit tests and docstring doctests are included when computing
coverage. Running ``pytest -v`` will automatically run the test suite with coverage
and produce a coverage report. This should be 100% before code can be accepted into the
main code base.
Expand All @@ -182,8 +181,7 @@ Documentation

Docstrings for user-facing classes and functions should follow the `numpydoc
<https://numpydoc.readthedocs.io/en/latest/format.html#docstring-standard>`_ standard,
including sections for Parameters and Examples. All examples will be run as doctests
under Python 3.9.
including sections for Parameters and Examples. All examples will be run as doctests.

NumCodecs uses Sphinx for documentation, hosted on readthedocs.org. Documentation is
written in the RestructuredText markup language (.rst files) in the ``docs`` folder.
Expand Down
4 changes: 2 additions & 2 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Installation

Numcodecs depends on NumPy. It is generally best to `install NumPy
<https://numpy.org/install/>`_ first using whatever method is most
appropriate for you operating system and Python distribution.
appropriate for your operating system and Python distribution.

Install from PyPI::

Expand Down Expand Up @@ -51,7 +51,7 @@ and then install in editable mode using `pip`.::
$ pip install -e .[test,msgpack,zfpy]

Note: if you prefer to use the GitHub CLI ``gh`` you will need to append ``-- --recurse-submodules``
to the clone command to everything works properly.
to the clone command to ensure everything works properly.

To verify that Numcodecs has been fully installed (including the Blosc
extension) run the test suite::
Expand Down
24 changes: 12 additions & 12 deletions docs/release.rst
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ Enhancements
Fixes
~~~~~

* Fix ``PCodec.decode()`` to handle numpy arrays by calling ``ensure_bytes`` on input buffers.
* Fix ``PCodec.decode()`` to handle NumPy arrays by calling ``ensure_bytes`` on input buffers.
By :user:`Sam Levang <slowjazz>`, :issue:`756`

Maintenance
Expand Down Expand Up @@ -180,14 +180,14 @@ Enhancements
By :user:`Agriya Khetarpal <agriyakhetarpal>`, :issue:`288`.
* Preallocate output buffers and resize directly as needed.
By :user:`John Kirkham <jakirkham>`, :issue:`656`
* ``Checksum32`` is now an abstract base clase, with ``checksum()`` as an abstract method.
* ``Checksum32`` is now an abstract base class, with ``checksum()`` as an abstract method.
This helps ensure that any subclasses implement the ``checksum()`` method.
:issue:`711`

Removals
~~~~~~~~

The following ``blosc`` funcitons are removed, with no replacement.
The following ``blosc`` functions are removed, with no replacement.
This is because they were not intended to be public API.

- ``numcodecs.blosc.init``
Expand All @@ -198,7 +198,7 @@ This is because they were not intended to be public API.

In addition, ``numcodecs.blosc.decompress_partial`` is removed as
has always been experimental and there is no equivalent in the official
blsoc Python package.
blosc Python package.
By :user:`David Stansby <dstansby>`, :issue:`712`

Maintenance
Expand Down Expand Up @@ -248,7 +248,7 @@ This is because they are not intended to be public API.

In addition, ``numcodecs.blosc.decompress_partial`` is deprecated as
has always been experimental and there is no equivalent in the official
blsoc Python package.
blosc Python package.
By :user:`David Stansby <dstansby>`, :issue:`619`

Fixes
Expand Down Expand Up @@ -329,7 +329,7 @@ Maintenance
~~~~~~~~~~~
* The minimum supported Python version is now Python 3.11.
By :user:`David Stansby <dstansby>`, :issue:`622`
* The minimum supported numpy version is now 1.24.
* The minimum supported NumPy version is now 1.24.
By :user:`David Stansby <dstansby>`, :issue:`622`

.. _release_0.13.1:
Expand Down Expand Up @@ -387,17 +387,17 @@ Fix
By :user:`Elliott Sales de Andrade <QuLogic>`, :issue:`487`.
* Fix Upgrade to Zstd 1.5.5 due to potential corruption.
By :user:`Mark Kittisopikul <mkitti>`, :issue:`429`
* Add version constraint(<2.0) for numpy in zfpy.
* Add version constraint(<2.0) for NumPy in zfpy.
By :user:`Tom Liang <px39n>`, :issue:`540`.

Maintenance
~~~~~~~~~~~
* The minimum supported Python version is now Python 3.10.
By :user:`David Stansby <dstansby>`, :issue:`531`
* Add numpy 2 compatibility.
* Add NumPy 2 compatibility.
By :user:`David Stansby <dstansby>`, :issue:`535`
* Update c-blosc to 1.21.0 to 1.21.5, zstd from 1.4.8 to 1.5.5,
lz4 from 1.9.3 to 1.9.4, and zlib from 1.2.8 to to 1.2.13
lz4 from 1.9.3 to 1.9.4, and zlib from 1.2.8 to 1.2.13
By :user:`Mark Kittisopikul <mkitti>`, :issue:`500`


Expand Down Expand Up @@ -483,7 +483,7 @@ Maintenance
By :user:`Dimitri Papadopoulos Orfanos <DimitriPapadopoulos>`, :issue:`369`.

* Drop Python 3.7.
By :user:`John Kirkham <jakirkham>`,, :issue:`405` :issue:`406`.
By :user:`John Kirkham <jakirkham>`, :issue:`405` :issue:`406`.

* Test with zfpy 1.0.0.
By :user:`John Kirkham <jakirkham>`, :issue:`385`.
Expand Down Expand Up @@ -715,7 +715,7 @@ Maintenance
* Automatically release to PyPI.
By :user:`Josh Moore <joshmoore>`, :issue:`241`.

* Build wheels on github actions.
* Build wheels on GitHub Actions.
By :user:`Grzegorz Bokota <Czaki>`, :issue:`224`.

* Add Base64 codec.
Expand Down Expand Up @@ -872,7 +872,7 @@ Maintenance
code readability and maintainability. By :user:`John Kirkham <jakirkham>` and
:user:`Alistair Miles <alimanfoo>`; :issue:`119`, :issue:`121`, :issue:`128`.

* Return values from encode() and decode() methods are now returned as numpy
* Return values from encode() and decode() methods are now returned as NumPy
arrays for consistency across codecs. By :user:`John Kirkham <jakirkham>`,
:issue:`136`.

Expand Down
7 changes: 7 additions & 0 deletions numcodecs/zstd.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -439,6 +439,13 @@ class Zstd(Codec):
return compress(buf, self.level, self.checksum)

def decode(self, buf, out=None):
"""
Notes
-----
If the compressed data does not contain the decompressed size, streaming
decompression will be used.

"""
Comment on lines +442 to +448
Copy link
Contributor Author

@DimitriPapadopoulos DimitriPapadopoulos Feb 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@d-v-b I had to move this from docs/compression/zstd.rst. Not sure if it works with automethod, but at least it should fix the missing decode documentation.

buf = ensure_contiguous_ndarray(buf)
return decompress(buf, out)

Expand Down
Loading