Python binding to the Brotli library
This library contains Python bindings for the reference Brotli encoder/decoder, available here. This allows Python software to use the Brotli compression algorithm directly from Python code.
To use it simply, try this:
import brotli data = brotli.decompress(compressed_data)
More information can be found in the documentation.
The source code of brotlipy is available under the MIT license. Brotli itself is made available under the Version 2.0 of the Apache Software License. See the LICENSE and libbrotli/LICENSE files for more information.
- Update to v0.6.0 of the Brotli library.
- Resolved a bug where decompress() would return an empty bytestring instead of erroring if the provided bytestring was small enough.
- Added the finish() method to the streaming decompressor.
- Update to v0.5.2 of the Brotli library.
- Add new exception type (Error).
- Add compatiblity with C++ brotli library by aliasing Error to error.
- Extra error checking of input parameters to the compressor.
- Update to v0.5.0 of the Brotli library.
- Extend one-shot compression API to include all control parameters.
- Added streaming/incremental compression API.
- Added flags to control compression mode.
Update to v0.4.0 of the Brotli library.
Update to v0.3.0 of the Brotli library.
Fix broken brotli.compress support on Windows.
- Added basic for brotli.compress through a C wrapper included in this library.
Release history Release notifications
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.