Skip to main content

PDFFile

A ZipFile like API for PDFs using PyMuPDF as a backend.

📜 News

PDFFile has a NEWS file to summarize changes that affect users.

🕸️ HTML Docs

HTML formatted docs are available here

📦 Dependencies

PDFFile depends on pymupdf-lite, PyMuPDF without the layout-analysis engine. It has no dependencies of its own and provides the same import pymupdf API. PDFFile only renders pages, extracts images and embedded files, and reads and writes metadata, so it needs none of the ONNX layout stack the full pymupdf package pulls in.

pymupdf-lite ships abi3 wheels for Python 3.11 and later on Linux x86_64 and aarch64 (glibc), musl Linux x86_64, macOS x86_64 and arm64, and Windows x86, x64 and arm64. Anywhere else pip compiles MuPDF from source, which needs a C/C++ toolchain. See the PyMuPDF installation docs.

Full PyMuPDF

If something else in your environment needs the full pymupdf package, install it in place of pymupdf-lite. With uv, drop pymupdf-lite from the dependency graph and depend on pymupdf directly:

[tool.uv]
exclude-dependencies = ["pymupdf-lite"]

With pip, install pymupdf and PDFFile's other dependencies first, then PDFFile without its dependencies:

pip install pymupdf filetype python-dateutil
pip install --no-deps comicbox-pdffile

🧶 Data Types

MuPDF reads and writes all data types as strings. PDFFile automatically converts pdf date strings to python datetimes and pdf/xml boolean strings to python bools and back.

The helper functions to_datetime, to_pdf_date, to_bool, and to_xml_bool are available on the PDFFile class.

🛠️ API

Attached to these docs in the navigation header there are some auto generated API docs that might be better than nothing. But the code is really small and shouldn't be difficult to interpret.

🛠 Development

PDFfile code is hosted at Github

Metadata

Release files for comicbox-pdffile 1.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for comicbox-pdffile 1.1.2
File Size Uploaded Provenance Actions
comicbox_pdffile-1.1.2.tar.gz 233.6 kB Without provenance Details for comicbox_pdffile-1.1.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for comicbox-pdffile 1.1.2
File Interpreter ABI Platform Actions
comicbox_pdffile-1.1.2-py3-none-any.whl Python 3 none any Details for comicbox_pdffile-1.1.2-py3-none-any.whl

Total release size: 248.8 kB

Release files / comicbox_pdffile-1.1.2.tar.gz

Download URL comicbox_pdffile-1.1.2.tar.gz
Size 233.6 kB
Tags Source
SHA-256 checksum
How to use checksums
b94bb6355331ed6a12af8daad6e206c44885cc0e694fae717c0b9a7e1c9180fb
BLAKE2b-256 checksum
How to use checksums
ad05a35e3d34ca329b25e72a06c88e9bafbc96385977263643333bc3e3efba91
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.7 {"installer":{"name":"uv","version":"0.13.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / comicbox_pdffile-1.1.2-py3-none-any.whl

Download URL comicbox_pdffile-1.1.2-py3-none-any.whl
Size 15.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a78cbb4d9fb7a3bdd3f0764dcffd1be7948b7c866a2ee2bbb29b1147a8b14edd
BLAKE2b-256 checksum
How to use checksums
e292b3716469950542662a96494a62cc81a81ec925b14c2296902f0a13e5428e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.7 {"installer":{"name":"uv","version":"0.13.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for comicbox-pdffile 1.1.2

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.

Release history Release notifications | RSS feed

This release

1.1.2 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page