Extract Enhanced Deflate ZIP archives with Python’s zipfile API.
Installation
pip install zipfile-inflate64
Usage
Anywhere in a Python codebase:
import zipfile_inflate64 # This has the side effect of patching the zipfile module to support Enhanced Deflate
Alternatively, zipfile_inflate64 re-exports the zipfile API, as a convenience:
import zipfile_inflate64 as zipfile
zipfile.ZipFile(...)
Design Rationale
The Problem
Recent versions of Microsoft Windows Explorer [use Deflate64 compression when creating ZIP files larger than 2GB](https://github.com/dotnet/runtime/issues/17802#issuecomment-231808916). With the ubiquity of Windows and the ease of using “Sent to compressed folder”, a majority of newly-created large ZIP files use Deflate64 compression.
Solution
Python package [inflate64](https://pypi.org/project/inflate64/) provide compression(deflate) and decompression(inflate) by Enhanced Deflate, aka Deflate64, procedure.
To manage ZIP archive extraction operations, the Python standard library [zipfile](https://docs.python.org/3/library/zipfile.html) module provides the essential features and is already ubiquitous in availability and usage. However, zipfile is difficult to extend, as it hardcodes many conditionals for compression formats and does not provide capabilities for easily augmenting or replacing parts of it. Monkey-patching can overcome some of these problems, and the promise of a drop-in, API-compatible patch to a standard library module outweighed the engineering benefits of basing a solution off a more naturally extensible third-party ZIP manipulation package.
History
Zipfile-deflate64 realize extraction of zipfile compressed with DEFLATE64(tm) algorithm by binding with infback9 extension in zlib.
zipfile-inflate64 is a fork that use inflate64 python package to realize compress and decompress of archives.
Copyright & License
zipfile-inflate64 is distributed under GNU General Public License Version 3.0 or (in your choice) later.
zipfile-deflate64 is distributed under Apache-2.0 license. which authored by Kitware, Inc.
Metadata
Release files for zipfile-inflate64 0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| zipfile_inflate64-0.1-py3-none-any.whl | Python 3 | none | any | Details for zipfile_inflate64-0.1-py3-none-any.whl |
Release files / zipfile_inflate64-0.1-py3-none-any.whl
| Download URL | zipfile_inflate64-0.1-py3-none-any.whl |
|---|---|
| Size | 5.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b444f3aea904061d702edbed58f952e544a19dcf20f2ed84bd889cf446b87b7d
|
|
BLAKE2b-256 checksum How to use checksums |
85c00be1a9e4c4cc2a4fd8c361ce10c19a0d091a905a0ad38b8a6f9914dbfcb9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.11.0
|
Security for zipfile-inflate64 0.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.