edx-django-utils
EdX utilities for Django Application development.
What it is and what it does
edx-django-utils is a collection of reusable utilities built for the Open edX platform to support common Django application patterns. It provides modular tools for request-scoped caching via RequestCache and TieredCache, user and group management helpers, IP address extraction and handling, structured logging with encryption support, monitoring middleware with multiple backend support (including Datadog), a plugin system for enhanced Django extensibility, Content Security Policy middleware, and management commands for generating test data from model factories.
The package is designed as a shared library where each utility exposes its public API through module __init__.py files. It targets Django 4.2 and 5.2 on Python 3.12, with active maintenance that recently removed the newrelic dependency to let users install monitoring backends independently. Most utilities are optional in nature—you import only what you need—making it suitable for both small and large Django projects that want to avoid reimplementing common patterns.
Use it for:
- Add request-scoped caching to Django views without managing cache lifecycle manually.
- Implement multi-tier caching strategies combining in-memory and distributed caches.
- Extract and normalize client IP addresses from requests, handling proxies and forwarding headers.
- Add encrypted logging for sensitive data in production Django applications.
- Integrate application monitoring with Datadog or other backends via the monitoring middleware.
- Build extensible Django applications using the plugin infrastructure for third-party integrations.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Provides a collection of shared utilities for Django applications, including caching, user/group management, IP handling, logging, monitoring, plugin infrastructure, security headers, and data generation.
Yes, if you are building or maintaining a Django application and want to avoid reimplementing common utilities like request caching, monitoring middleware, or plugin infrastructure. The package is actively maintained, has no known vulnerabilities, and uses a permissive license. Install it if you need one or more of its utilities; the modular design means you only pay for what you use. Not necessary if your project has already solved these problems with other libraries or internal code.
Install
edx-django-utils on PyPI
pip
pip install edx-django-utilsuv
uv add edx-django-utilspoetry
poetry add edx-django-utilsInstalling edx-django-utils
Before you install
Low install friction with a pure-Python wheel. Active maintenance as of 2026-08-10 with recent updates addressing deprecated dependencies (newrelic removed in 8.0.0). Depends on 7 runtime packages including Django, PyNaCl, click, django-crum, django-waffle, psutil, and stevedore.
License in practice
Licensed under Apache License 2.0 (permissive). No restrictions on commercial or private use; modifications and redistribution are permitted under the same license terms.
Quickstart
pip install edx-django-utils
from edx_django_utils.cache import RequestCache
from edx_django_utils.monitoring import set_monitoring_transaction_name
cache = RequestCache()
cache.set('key', 'value')
set_monitoring_transaction_name('transaction_name')
Requires Django and Python 3.12; package dropped support for Python versions below 3.12 as of version 6.0.0.
Verify before relying
- Whether all 7 runtime dependencies are required for all utilities or if some are optional/conditional.
- Specific Django 4.2 and 5.2 compatibility details and any known issues with those versions.
- Performance characteristics or scalability limits of the caching and monitoring utilities.
- Whether the plugin infrastructure supports dynamic loading at runtime or only at startup.
Package facts
| License | not declared (permissive) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 7 — Django, PyNaCl, click, django-crum, django-waffle, psutil, stevedore |
| Maintenance | actively maintained — 319 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 110,118/month — #12,482 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: edx_django_utils-8.0.1-py2.py3-none-any.whl
Keywords: Django, edx
Tags
More Application Frameworks packages
FastAPI is a Python web framework for building…
permissive · top 100 on PyPI
annotated-docProvides a way to document function parameters,…
permissive · top 100 on PyPI
textualTextual is a Python framework for building…
permissive · top 100 on PyPI
typerTyper builds command-line applications from…
permissive · top 1,000 on PyPI
mcpBuild and connect to Model Context Protocol…
permissive · top 1,000 on PyPI
WerkzeugWerkzeug is a WSGI utility library providing…
permissive · top 1,000 on PyPI
edx-django-release-utilProvides Django utilities and middleware for…
agpl · top 15,000 on PyPI
edx-enterpriseA Django application that provides enterprise…
agpl · top 15,000 on PyPI
openedx-eventsProvides event definitions and tooling for the…
permissive · top 15,000 on PyPI
edx-togglesProvides Django-integrated feature toggle…
agpl · top 15,000 on PyPI
edx-rest-api-clientProvides OAuth2 and JWT utilities for…
permissive · top 15,000 on PyPI
XBlockXBlock is a Python component architecture for…
permissive · top 15,000 on PyPI
edx-drf-extensionsProvides JWT authentication, CSRF token…
permissive · top 15,000 on PyPI
edx-i18n-toolsCommand-line tool for extracting, compiling,…
permissive · top 15,000 on PyPI
allianceauth-app-utilsProvides reusable utility functions and classes…
permissive · top 15,000 on PyPI
django-invitationsProvides a generic invitation system for Django…
copyleft · top 15,000 on PyPI