When DEBUG is False, Django serves your own 404, 500, 403 and 400 pages. Here's how to wire up the templates and handler views, dodge the 500 context ...
MicroPyramid Blog
Articles that strengthen our current focus on AI systems, modernization, and product engineering, alongside the broader engineering archive.
Older posts still cover Django, Python, AWS, Salesforce, React, Flutter, and Svelte, but the clearest current signal is around the three service lanes below.
AI Systems
RAG, knowledge workflows, search, and practical AI system design.
Explore service pageModernization
Legacy cleanup, migration planning, Django rescue, and safer system change.
Explore service pageProduct Engineering
Full-stack delivery, dashboards, portals, MVPs, and AI-ready product work.
Explore service pageA practical, Django 5.x guide to custom view decorators for role- and permission-based access control: functools.wraps, PermissionDenied vs login redi...
Integrate PayPal into Django the modern way. A 2026 guide to the JavaScript SDK Smart Payment Buttons, the REST Orders API v2 (create and capture), an...
Django's built-in ManyToManyField can only point at one model. Learn how to build a generic many-to-many relation in Django 5.x with the contenttypes ...
A practical, Django 5.x guide to GenericForeignKey and the contenttypes framework: how ContentType, content_type, object_id and content_object fit tog...
A practical, up-to-date guide to Django's messages framework in Django 5.x β the flash messages that survive a redirect. Learn the API, message levels...
A 2026, Django 5.x deep dive into model and inline formsets: when to use each, the mandatory management form, factory options, saving with commit=Fals...
A practical, up-to-date guide to Django's template engine (Django 5.x): how the TEMPLATES setting works, how templates load and render, the DTL essent...
A Django 5.x guide to model Managers, custom QuerySets, and properties: the objects interface, get_queryset() overrides, Manager.from_queryset() for c...
A current, Django 5.x guide to adding CAPTCHA and bot protection to your forms. Install django-recaptcha for reCAPTCHA v2 and v3, compare Cloudflare T...
Learn how Django middleware works in Django 5.x: the request/response cycle, writing custom middleware as a factory or class, MIDDLEWARE ordering, the...
Django's QuerySet.extra() injects raw SQL into ORM queries but is discouraged in 2026. See honest .extra() examples and the modern annotate(), Subquer...