Skip to main content

Django PowerCRUD

PyPI Run Test Matrix Security codecov License

Python Django

Advanced CRUD for perfectionists with deadlines. An opinionated Django package for shipping production-grade CRUD screens with filtering, bulk operations, inline editing, and async workflows.

PowerCRUD extends Neapolitan’s view layer with the practical infrastructure needed for real operational interfaces.

Why PowerCRUD

  • Production-ready CRUD – faster
    HTMX responses, modal forms, inline row editing, and filter sidebars are configured through class attributes rather than custom templates.

  • Bulk operations that scale
    Start synchronously with selection persistence and validation controls, then opt into async queueing with conflict locks, progress polling, and an optional dashboard when jobs run longer.

  • One async toolkit everywhere
    The async manager, conflict handling, and progress API are reusable from admin actions, management commands, or bespoke launch sites so background work behaves consistently.

  • Batteries included
    Sample app, Docker dev stack, management commands, Tailwind safelist tooling, and a maintained pytest/Playwright suite keep the project teachable and testable.

See the full documentation.

Key Features

  • HTMX-enabled CRUD views with modal create/edit/delete flows.
  • Inline row editing with dependency-aware widgets, lock checks, and permission guards.
  • Bulk edit/delete with selection persistence and an optional async path.
  • Async infrastructure: conflict locks, progress cache, django-q2 workers, cleanup command, optional dashboard persistence.
  • Filtering, sorting, and pagination helpers backed by tuned templates.
  • First-party presentation packs: built-in DaisyUI and maintained Bootstrap 5 templates, assets, and widget presentation.
  • Independent template packs: a tested public contract for authors to create and publish another framework integration.
  • Styling controls, template and pack scaffolding, and Tailwind safelist extraction.
  • Production extension points: persistence hooks, permission-aware actions, queryset annotation columns, lazy evaluation, and optional saved favourites.
  • Two supported API styles: the direct Base Configuration API plus structured declarations for reusable field and action intent.
  • Tooling support: Dockerised dev environment, management commands, pytest + Playwright coverage.

Quick Examples

Core CRUD (synchronous)

from neapolitan.views import CRUDView
from powercrud.mixins import PowerCRUDMixin


class ProjectCRUDView(PowerCRUDMixin, CRUDView):
    model = Project
    base_template_path = "core/base.html"

    # Core configuration
    fields = ["name", "owner", "status", "created_date"]
    properties = ["is_overdue"]
    filterset_fields = ["owner", "status", "created_date"]
    paginate_by = 25

    # UX helpers
    use_htmx = True
    use_modal = True
    inline_edit_fields = ["status", "owner"]

    # Bulk operations (synchronous)
    bulk_fields = ["status", "owner"]
    bulk_delete = True

This single view serves a filtered list, modal forms, inline edits, and synchronous bulk edits - no async stack required.

Structured declarations for repeated intent

The Base Configuration API above remains the most direct place to start. When the same field participates in several surfaces, the Structured Declaration API can keep that intent together and make it reusable:

from neapolitan.views import CRUDView
from powercrud.mixins import PowerCRUDMixin
from powercrud.powerfields import PowerField


PROJECT_STATUS = PowerField(
    "status",
    default_list=True,
    form=True,
    inline=True,
    bulk=True,
)


class ProjectCRUDView(PowerCRUDMixin, CRUDView):
    model = Project
    power_fields = [
        PowerField("name", default_list=True, form=True),
        PowerField("owner", default_list=True, form=True),
        PROJECT_STATUS,
    ]

Choose either Base Configuration field-intent attributes or power_fields within one view inheritance chain; do not mix them. PowerAction and PowerButton provide reusable action and toolbar declarations and may be mixed with Base API action dictionaries. See Choosing an API Style for the decision guide.

Async bulk (opt-in)

from neapolitan.views import CRUDView
from powercrud.mixins import PowerCRUDAsyncMixin


class ProjectAsyncCRUDView(PowerCRUDAsyncMixin, CRUDView):
    model = Project
    base_template_path = "core/base.html"

    bulk_fields = ["status", "owner"]
    bulk_delete = True
    bulk_async = True
    bulk_min_async_records = 20
    bulk_async_conflict_checking = True

    # Optional async dashboard manager
    async_manager_class_path = "myapp.async_manager.AppAsyncManager"

Here async queueing is explicit: you opt in by using PowerCRUDAsyncMixin, enabling bulk_async, and configuring django-q2 (django_q in INSTALLED_APPS, Q_CLUSTER, and any POWERCRUD_SETTINGS overrides you need).

Getting Started

Tooling & References

  • Sample app – complete walkthrough of every feature.
  • Docker dev environment – Django, Postgres, Redis, Vite, django-q2.
  • Management commands – template and pack scaffolding, Tailwind safelist extraction, async cleanup.
  • Testing – pytest matrix, blocking Playwright smoke tests, and a fuller local browser regression suite.

Supported Versions

PowerCRUD is tested against the following combinations:

  • Python 3.12 with Django 5.2 and 6.1
  • Python 3.13 with Django 5.2 and 6.1
  • Python 3.14 with Django 5.2 and 6.1

The CI matrix exercises each supported pairing automatically.

Development Setup

PowerCRUD’s development environment is Docker-first. From the project root:

./runproj up          # build images, start services, enter the Django container
./runtests           # run the full local suite, including Playwright and focused Bootstrap coverage

Dependencies are managed with uv; the Docker image installs them into the system interpreter so you never need to activate a virtual environment inside the container. See the Dockerised Development Environment guide for full details.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django_powercrud-0.9.12.tar.gz (457.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

django_powercrud-0.9.12-py3-none-any.whl (572.1 kB view details)

Uploaded Python 3

File details

Details for the file django_powercrud-0.9.12.tar.gz.

File metadata

  • Download URL: django_powercrud-0.9.12.tar.gz
  • Upload date:
  • Size: 457.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.14.7

File hashes

Hashes for django_powercrud-0.9.12.tar.gz
Algorithm Hash digest
SHA256 98046a72a15696b28aa52213a02753eabba478fd31a2e7a704831273cf041276
MD5 6fd16e91506bd3f52aef89b9fa22d235
BLAKE2b-256 5c8073f8c4e6a9e5c9a1d25f52f6e55d77b591d45aa92cbe1a1515bcf4af9e58

See more details on using hashes here.

File details

Details for the file django_powercrud-0.9.12-py3-none-any.whl.

File metadata

File hashes

Hashes for django_powercrud-0.9.12-py3-none-any.whl
Algorithm Hash digest
SHA256 2324b28da562c3d4341a0ff958274bd3ef86bb0831058348da59a0fbc2dcbf39
MD5 4e9b7f393641ec3c317ff6f7a5aa161e
BLAKE2b-256 03e125d4f8faba46053b6afa78e1b35c4396d56a50f119d5ee20a2bcd31bcc47

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.9.12 This release

2 files

0.9.11

2 files

0.9.10

2 files

0.9.9

2 files

0.9.8

2 files

0.9.7

2 files

0.9.6

2 files

0.9.5

2 files

0.9.4

2 files

0.9.3

2 files

0.9.2

2 files

0.9.1

2 files

0.9.0

2 files

0.8.6

2 files

0.8.5

2 files

0.8.4

2 files

0.8.3

2 files

0.8.2

2 files

0.8.1

2 files

0.8.0

2 files

0.7.15

2 files

0.7.14

2 files

0.7.13

2 files

0.7.12

2 files

0.7.11

2 files

0.7.10

2 files

0.7.9

2 files

0.7.8

2 files

0.7.7

2 files

0.7.6

2 files

0.7.5

2 files

0.7.4

2 files

0.7.3

2 files

0.7.2

2 files

0.7.1

2 files

0.7.0

2 files

0.6.12

2 files

0.6.11

2 files

0.6.10

2 files

0.6.9

2 files

0.6.8

2 files

0.6.7

2 files

0.6.6

2 files

0.6.5

2 files

0.6.4

2 files

0.6.3

2 files

0.6.2

2 files

0.6.1

2 files

0.6.0

2 files

0.5.47

2 files

0.5.46

2 files

0.5.45

2 files

0.5.44

2 files

0.5.43

2 files

0.5.42

2 files

0.5.41

2 files

0.5.40

2 files

0.5.39

2 files

0.5.38

2 files

0.5.36

2 files

0.5.35

2 files

0.5.34

2 files

0.5.33

2 files

0.5.32

2 files

0.5.31

2 files

0.5.30

2 files

0.5.29

2 files

0.5.28

2 files

0.5.27

2 files

0.5.26

2 files

0.5.25

2 files

0.5.24

2 files

0.5.23

2 files

0.5.22

2 files

0.5.21

2 files

0.5.20

2 files

0.5.18

2 files

0.5.17

2 files

0.5.16

2 files

0.5.15

2 files

0.5.14

2 files

0.5.13

2 files

0.5.12

2 files

0.5.11

2 files

0.5.10

2 files

0.5.9

2 files

0.5.8

2 files

0.5.6

2 files

0.5.3

2 files

0.5.2

2 files

0.5.1

2 files

0.4.19

2 files

0.4.18

2 files

0.4.17

2 files

0.4.16

2 files

0.4.15

2 files

0.4.14

2 files

0.4.13

2 files

0.4.12

2 files

0.4.11

2 files

0.4.10

2 files

0.4.9

2 files

0.4.8

2 files

0.4.7

2 files

0.4.6

2 files

0.4.5

2 files

0.4.4

2 files

0.4.3

2 files

0.4.2

2 files

0.3.6

2 files

0.3.3

2 files

0.3.2

2 files

0.3.1

2 files

0.3.0

2 files

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