Registry / web-framework / django-post-office

django-post-office

JSON →
library3.11.2pypypiunverified

A Django app to monitor and send mail asynchronously, complete with template support. Current version 3.11.2, released Feb 2026. Release cadence is irregular, roughly 2-4 minor versions per year.

pip install django-post-office
INSTALL
IMPORT
SIG · DJANGO-POST-OFFICE
D
django-post-office
web-frameworkpythonv3.11.2
Install
3.6s avg
Import
Disk
69MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v3.11.2 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.95 runs
installs and imports cleanly · install 0.0s · import 0.000s · 69.8MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 3.6s · import 0.000s · 70MB
69MB installed
● package 69MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

mail
from post_office import mail
from post_office import mail

Send an email immediately using django-post-office.

import django os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'your_project.settings') django.setup() from post_office import mail mail.send( recipients=['user@example.com'], sender='from@example.com', subject='Test email', message='Hello, World!', priority='now' )
Debug
Known issues
breakingIn v3.11.0, the dependency `bleach` was replaced with `nh3` for HTML sanitization. If you rely on `bleach` directly or indirectly, update your code.
fix
Ensure `nh3` is installed, and remove any direct use of `bleach` in post_office contexts.
affects: >=3.11
breakingIn v3.7.0, JSON columns were changed from third-party `jsonfield` to Django's native `JSONField`. If you have custom migrations that depend on `jsonfield`, they will break.
fix
Run `makemigrations` to regenerate migrations after upgrading. Remove any explicit dependency on `jsonfield`.
affects: >=3.7
deprecatedThe `date_hierarchy` option was removed in v3.7.1 from the Email admin, causing slow loading on large databases. If you rely on date-based drilldown in admin, implement custom admin filters.
fix
Do not rely on `date_hierarchy`. Use list_filters or custom filters instead.
affects: >=3.7.1
gotchaWhen using `mail.send` with a template, context must include all variables needed, but if the template is missing or invalid, the email fails silently. Always check the backend logs.
fix
Use `template='your_template'` and pass context as a dict. Test with `priority='now'` to see errors immediately.
affects: all
Upgrade
Version history
3.11.2latest on PyPI · released Apr 16, 2026
Audit
Dependencies
djangorequiredCore framework
nh3requiredHTML sanitization
jsonfieldoptionalDeprecated in v3.7.0, use Django's JSONField
Agent activity
23 hits · last 30 days
node
20
OpenAI (training)
1
Resources
django-post-office — pip install django-post-office · libregistry