Caddix - PostgreSQL Connection Assistant
Caddix is a lightweight, high-performance Python helper library built on top of psycopg 3 designed to make interacting with PostgreSQL databases easier, faster, and safer.
🚀 Key Features & Advantages
- Boilerplate-Free CRUD: High-level Python methods for querying, inserting, updating, and deleting rows without writing raw SQL strings for simple tasks.
- Built-in Connection Pooling: Thread-safe connection pool with configurable Time-To-Live (
TTL), automatic health checks, and reconnects. - Transaction Safety (Rollback-by-Default): Sessions automatically roll back uncommitted changes when exiting context manager blocks or on unhandled exceptions.
- SQL-Injection Safe: Secure SQL generation using
psycopg.sql.Identifierand strict parameter binding. - Blazing Fast Mass Ingestion:
insert_batchleverages native PostgreSQLCOPY FROM STDINstreaming for inserting thousands of records in milliseconds. - Rich Row Factories: Easily map rows to Python
dict,tuple,namedtuple, or custom@dataclassobjects. - Keyword-Friendly: Automatically handles Python reserved words in column names (e.g.
_from,_class,_import).
📦 Installation & Requirements
Caddix requires Python 3.10+. The database driver psycopg (version 3.x) is automatically installed as a core dependency.
Using pip
pip install caddix
Using uv (Recommended)
uv add caddix
💡 Performance Note: For optimal performance without needing a local C compiler, you can optionally install the pre-compiled binary PostgreSQL driver via
pip install "psycopg[binary]"oruv add "psycopg[binary]".
⚡ Quickstart Guide
Here is a 30-second quickstart demonstrating how simple it is to configure and use Caddix:
import caddix
# 1. Configure the database connection
caddix.Setup(
databasename='app_db',
username='postgres',
password='mysecretpassword',
hostname='localhost',
port=5432
)
# 2. Open a session and execute queries
with caddix.DatabaseSession() as db:
# SQL-free query: fetches a single row as a dictionary
user = db.select_one('users', id=1)
print("User found:", user)
# Insert a new record and commit
db.insert('logs', message='User 1 logged in')
db.commit()
📚 Documentation & Deep Dives
For in-depth guides, complete API listings, and developer documentation, explore our documentation suite:
- User Guide & Manual: Comprehensive walkthrough covering configuration, connection pooling, transactions, raw SQL, CRUD helpers, bulk operations, stored procedures, and row factories.
- API Reference: Full technical reference of all classes, methods, parameters, and exceptions.
- Architecture & Internals: Component mapping, lifecycle workflows, and security architecture.
- Developer & Contributor Guide: Setup instructions, testing guidelines, and conventions for contributors.
- Changelog: Release history, breaking changes, and migration notes.
👤 Author & License
- Author: Marcus Gros (
marcus-gros@freenet.de) - Copyright: 2026 Marcus Gros
- License: MIT
Have fun building fast, secure PostgreSQL applications with Caddix! 🐘
Logo AI-generated via perchance.org
Metadata
Release files for caddix 1.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| caddix-1.1.0.tar.gz | 162.1 kB | With provenance | Details for caddix-1.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| caddix-1.1.0-py3-none-any.whl | Python 3 | none | any | Details for caddix-1.1.0-py3-none-any.whl |
Total release size: 176.7 kB
Release files / caddix-1.1.0.tar.gz
| Download URL | caddix-1.1.0.tar.gz |
|---|---|
| Size | 162.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f640eece5f65ed32c7b0e81428232f88cf3ed71b905d5f992748ad6f74eff152
|
|
BLAKE2b-256 checksum How to use checksums |
90a9f7508caa1e3161c60c3dc9479cddbef6ebdf7b7185d42ebf6bfd91fd2de5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 21, 2026.
Transparency logRelease files / caddix-1.1.0-py3-none-any.whl
| Download URL | caddix-1.1.0-py3-none-any.whl |
|---|---|
| Size | 14.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d287a67100c378fc10bdc9d3e513f79bc02e674864b959711ddb4c95bf725d9f
|
|
BLAKE2b-256 checksum How to use checksums |
9ea3c7fbaf24d36a4ffbaaef9c7ee22b9656dd61e6c83c0ff6bca0a3c4406880
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 21, 2026.
Transparency logSecurity for caddix 1.1.0
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.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for caddix-1.1.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 21, 2026.
Transparency logA 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.