Atom

archive module

Compress data and create, inspect, or extract ZIP archives.

Import it with 'use archive'.

Atom
use archive
use binary
bytes = archive.compress('Atom')
print(binary.text(archive.decompress(bytes)))
Output
Atom

Requires ATOM_WITH_ARCHIVE. Compress/decompress use a zlib stream. ZIP operations are in-memory. Inputs can be raw packed bytes, or text interpreted as UTF-8 bytes. ZIP entries use safe relative names separated by slash. Empty, absolute, backslash-bearing, colon-bearing, dot or parent components are rejected. Directory entries are skipped when reading. Neither ZIP operation writes files to disk.

Functions