Skip to main content

Various extensions, helpers, and utilities for Peewee

Project description


Various extensions, helpers, and utilities for Peewee

PyPI Version License Python Supported Versions Code style: black

See the Changelog for release history.


The documentation for this project is currently a work in progress. Please see the source code for complete docs


Peewee+ is available on PyPI and can be installed using Poetry, Pipenv, or Pip:

# Using poetry
poetry add peewee-plus

# Using pipenv
pipenv install peewee-plus

# Using pip
python -m venv peewee
source peewee/bin/activate
python -m pip install peewee-plus

Once installed, Peewee+ can be imported like below:

import peewee_plus



SQLITE_DEFAULT_PRAGMAS - The default pragmas to use with an SQLite database connection, taken directly from the Peewee docs.

SQLITE_DEFAULT_VARIABLE_LIMIT - The maximum number of variables an SQL query can use when using SQLite


calc_batch_size - Helper function for determining how to batch a create/update query with SQLite

flat_transaction - Decorator function for wrapping callables in a database transaction without creating nested transactions


PathField - A Peewee database field for storing Pathlib objects, optionally relative to a runtime value.

PrecisionFloatField - A Peewee database field for storing floats while specifying the MySQL precision parameters M and D

JSONField - A Peewee database field for storing arbitrary JSON-serializable data

EnumField - A Peewee database field for storing Enums by name

For Developers

All project contributors and participants are expected to adhere to the Contributor Covenant Code of Conduct, v2 (external link).

The devel branch has the latest (and potentially unstable) changes. The stable releases are tracked on Github, PyPi, and in the Changelog.

Developing this project requires at least Python 3.7 and at least Poetry 1.0. GNU Make can optionally be used to quickly setup a local development environment, but this is not required.

To setup a local development environment:

# Clone the repository...
# ...over HTTPS
git clone
# ...over SSH
git clone

cd peewee-plus/

# Create and configure the local dev environment
make dev

# See additional make targets
make help

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

peewee-plus-1.1.0.tar.gz (12.1 kB view hashes)

Uploaded source

Built Distribution

peewee_plus-1.1.0-py3-none-any.whl (8.3 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page