Skip to main content

bz3 compress and decompress

Project description

✨ python-bz3 ✨

The python binding for bzip3

pypi python implementation wheel license action

Usage

from bz3 import compress, decompress, test


with open("test_inp.txt", "rb") as inp, open("compressed.bz3", "wb") as out:
    compress(inp, out, 1000 * 1000)

with open("compressed.bz3", "rb") as inp:
    test(inp, True)    

with open("compressed.bz3", "rb") as inp, open("output.txt", "wb") as out:
    decompress(inp, out)

public functions

from typing import IO

def crc32(crc: int, buf: bytes) -> int: ...
def compress(input: IO, output: IO, block_size: int) -> None: ...
def decompress(input: IO, output: IO) -> None: ...
def test(input: IO, should_raise: bool = ...) -> bool: ...

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bzip3-0.0.1.dev1.tar.gz (308.1 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page