Documentation: https://zlib-fast.readthedocs.io
Source Code: https://github.com/bdraco/zlib-fast
A wrapper to use the fastest available zlib
zlib is be a bottleneck for creating backups with tarfile
. zlib-fast
replaces usage of zlib
with isal
which is a drop-in faster replacement.
Unlike the base isal implementation, this module maps zlib compression
levels for compressobj
to their nearest isal
equivalent which allows
it to be used as a drop in replacement with tarfile
.
Install this via pip (or your favourite package manager):
pip install zlib-fast
Enable zlib-fast support by calling zlib_fast.enable()
.
import zlib_fast
zlib_fast.enable()
zlib_fast.disable()
The most common use case is for use with tarfile
which does a late import. enable
will only be effective for future imports of zlib
, and will not redirect existing imports. If you need to use this module for other use cases, be sure to call zlib_fast.enable()
before any code that loads zlib
.
Thanks goes to these wonderful people (emoji key):
This project follows the all-contributors specification. Contributions of any kind welcome!
This package was created with Copier and the browniebroke/pypackage-template project template.