15 Feb 2025
Django community aggregator: Community blog posts
Bookmarklets, defaults-from-GET, and iommi
Phil Gyford wrote an article about how nice it is that the Django admin pre-populates inputs from the GET parameters if there are any. This can be used for bookmarklets as in his examples, or just general bookmarks where you can quickly go to a page with parts of a form prefilled.
Another very useful case for this pattern is to have a link on one page of your product with a link to a create form with prefilled data based on the context of the page you linked from. Like having an artist page with a link to the create album page with the artist filled in.
The Django admin does this, but Django forms do not. Because Django forms have an API that takes a dict for the data and not the request object itself, it can't be retrofitted to have this feature either. It's a nice example of where limiting the API surface area also limits future development.
In iommi, defaults-from-GET is the default for all forms. So if you build with iommi you get this feature across your product for free, not just in the admin. We even handle the edge cases for you like when you have a GET form, and you supply parameters via GET, so the form needs to know if this is from some URL or from a submit of the form. This is handled in iommi for you transparently.
15 Feb 2025 6:00am GMT
14 Feb 2025
Django community aggregator: Community blog posts
Django News - DjangoCon US Call for Proposals - Feb 14th 2025
News
Python 3.14.0 alpha 5 is out
Python 3.14.0a5 is the fifth of seven planned alpha releases.
DjangoCon US Call for Proposals
The CFP is now open until April 27th. The earlier you submit, the better!
DSF member of the month - Lily Foote
Lily is a long-time contributor to Django core, especially on the ORM, and is currently a member of the Django 6.x Steering Council.
I'm excited to join the Sovereign Tech Fellowship
Hugo van Kemenade is now a full-time open source developer, working on Python, with a focus on CPython, including as release manager for Python 3.14 and 3.15.
Updates to Django
Today 'Updates to Django' is presented by Abigail Afi Gbadago from the DSF Board!
Last week we had 13 pull requests merged into Django by 9 different contributors - including 3 first-time contributors! Congratulations to Andrew, Brian Nettleton and Arnaldo Govene for having their first commits merged into Django - welcome on board!🎊
This Week's Highlights:
- Support for MariaDB 10.5 has been dropped so MariaDB 10.6 minimum supported version for Django 6.0 (to be released December 2025).
- Support for GEOSHasM has been added for the GEOS API.
- Requesting a default value when migrating an auto field has been prevented. Special thanks for the long work on this PR 🥳
Django Newsletter
Sponsored Link 1
Hiring Jr. Web Services Engineer
This position is for someone who can bring their python software development experience to support Playdate, Game Publishing, and our Apps! You would be responsible for contributing to and maintaining our growing flock of Flask and Django web applications.
Additionally, Panic hires interns every summer via The Script, designed for college students with underrepresented backgrounds entering freshman through senior years.
Articles
Django in government - Thibaud's blog
DSF President Thibaud Colas focuses on almost 1,000 Django websites used in governments around the world.
Pytest, A Practical Guide
Andrew Mshar provides an introduction to key pytest
features, including fixtures, flags, markers, and Django-specific tools.
Things I'd Like to See in a DjangoCon US 2025 Talk
Former DjangoCon US program chair Drew Winstel has a detailed list of suggested topics for DjangoCon US talks this year. The CFP is now open.
Prefixed Parameters for Django querystring tag
An overview of Django 5.1's new querystring tag and how to add support for prefixed parameters.
Jump to dev
A clever Django middleware lets developers paste production URLs into their local server, automatically stripping out the domain for quick issue reproduction.
Events
DjangoCongress JP 2025
This online event is coming soon! Feb, 22, 2025.
Tutorials
Django MongoDB Backend Quickstart
Learn how to connect to a MongoDB deployment, ensure your deployment is hosted on MongoDB Atlas, and interact with the data using simple CRUD operations.
Videos
uv and Django - Managing Django Projects & Dependencies with uv!
This video dives into using uv and Django together for project and dependency management, including how to install packages into different groups and run Django commands.
Sponsored Link 2
Django & Wagtail Hosting for just $9/month
New year, new site! Finally put those domain names to use and launch that side-project, blog, or personal site in 2025. Lock in this limited time pricing by Feb 28.
Django News Jobs
Full-Stack engineer at Exoscale
⭐ Jr. Web Services Engineer at Panic (featured)
Senior Backend Engineer at BactoBio
Django Newsletter
Projects
safwanrahman/django-webpush
Web Push Notification Package for Django.
OmenApps/django-pint-field
Store, validate, and convert physical quantities in Django using Pint.
This RSS feed is published on https://django-news.com/. You can also subscribe via email.
14 Feb 2025 5:00pm GMT
13 Feb 2025
Django community aggregator: Community blog posts
Prefixed Parameters for Django querystring tag
An overview of Django 5.1's new querystring tag and how to add support for prefixed parameters.
13 Feb 2025 8:05pm GMT
TIL: Tools exist which do not lowercase domain names when requesting websites over HTTP(S)
TIL: Tools exist which do not lowercase domain names when requesting websites over HTTP(S)
About a week ago I received error mails for a surprising behavior (to me!) where some tool requested an URL from one of our websites using feincms3-language-sites (a Django library for multilingual websites) with a domain name containing uppercase characters.
I knew that the domain part of all sorts of URLs is case sensitive, but what surprised me was that our server actually got a request with such a domain name, I hadn't really seen that before.
After researching a bit I learned that for example curl intentionally preserves the casing of domain names, but browsers generally do lowercase domains because it's more consistent. It's interesting that the initial error was caused by a client with a proper Safari/macOS user agent, but further research showed that the request was probably sent by something called go-social-activity-parser
, whatever that is.
I fixed the bug in feincms3-language-sites and also in feincms3-sites by switching to case-insensitive matching of domain names. I have not yet added punycode or IDNA equivalence to the code because I haven't needed it yet and because I'm not 100% sure how to do it without breaking anything. Even though I often work on websites in languages with lots of accents and umlauts we don't use such domain names too often, so it hasn't been a problem yet. I'll cross that bridge when I get there.
13 Feb 2025 6:00pm GMT
12 Feb 2025
Django community aggregator: Community blog posts
Built with Django Newsletter - 2025 Week 7
Hey, Happy Wednesday!
Why are you getting this: *You signed up to receive this newsletter on Built with Django. I promised to send you the latest projects and jobs on the site as well as any other interesting Django content I encountered during the month. If you don't want to receive this newsletter, feel free to unsubscribe anytime.
News and Updates
- Added Pagination to the Projects page as well as project search.
- Want to experiment with the new section called "Django Updates". Last week I published a post with all of January's blog post updates. In addition to doing monthly posts I want to add a streamlined version here, on what got updated during the week. Would love to hear some feedback if any.
Sponsors
This issue is sponsored by SEO Blog Bot. Well, sponsor is a strong word. It is just another project of mine that I wanted to share with you 🙈. Fully free!
If you have a side project and are struggling with finding ideas for blog posts, this will help!
If you want to become a real sponsor, just reply to this email or check out available options here.
Projects
- Sombreros Olé - E-commerce - Handcrafted hats, bags and more.
Jobs
From the Community
- Looking at Django task runners and queues by Kevin Renskers
At Sound Radix, they use Django with a task queue for sending emails and running scheduled jobs, relying on packages like django-mailer and django-apscheduler. They are exploring options for handling background tasks, including adding django-tasks or switching to django-q2, but face limitations with both. The author prefers to keep django-apscheduler for scheduled tasks while considering adding django-tasks for one-off tasks, aiming for a future-proof solution.
- DSF member of the month - Lily Foote by Sarah Abderemane
- Django admin tip: Adding links to related objects in change forms by Matthias Kestenholz
- Better unit-tests for your emails with Django 5.2 by Ronny Vedrilla
- Rendering form fields as group in Django by Valentino Gagliardi
Top 3 links from last Issue
- SoundMadeSeen - SoundMadeSeen is a tool that allows podcasters to create videos from their audio content
- Bank Statement Analyzer - Analyze your spending patterns with AI
- Django WTF - Django Packages Index
Django Changes
Here is the list of changes that have been made to Django's codebase in the last week.
1. Overview
Focused work on:
- documentation updates
- shell command improvements
- database backend enhancements
- version management
There were 11 commits from 4 different contributors.
2. Key Changes and Features
Database Related:
- Removed MariaDB 10.5 support as part of Django 6.0 updates by Mariusz Felisiak)
- Fixed PostgreSQL index deletion SQL bug by Natalia)
- Enhanced database backend extensibility for Tuple compilation by Simon Charette)
Shell Command Improvements:
- Fixed verbose output formatting for auto-importing objects by Natalia)
- Refactored get_and_report_namespace function by Natalia)
- Added documentation for --no-imports flag by Natalia)
Documentation and Release Management:
- Added placeholder release notes for version 5.1.7 by Natalia)
- Updated release dates for versions 5.1.6, 5.0.12, and 4.2.19 by Natalia)
- Modified PyPI release documentation for multi-token support by Mariusz Felisiak)
Code Cleanup:
- Removed Python 2 compatibility code from test suite by Tim Graham)
- Improved documentation formatting for PEP 8 compliance by Natalia)
3. Development Patterns and Contributors
- Main contributors: Natalia (6 commits), Mariusz Felisiak (2 commits), Tim Graham (1 commit), Simon Charette (1 commit)
- Focus on code quality and maintenance
- Strong emphasis on documentation updates and version management
- Continued modernization of codebase by removing legacy support
4. Recommendations
- Users should prepare to migrate from MariaDB 10.5 as support is being dropped
- Database backend developers should review the new Tuple compilation changes for potential optimizations
- Projects using PostgreSQL should update to get the index deletion fix
- Teams should review their PyPI deployment configurations if using multiple tokens
Support
You can support this project by using one of the affiliate links below. These are always going to be projects I use and love! No "Bluehost" crap here!
- Buttondown - Email newsletter tool I use to send you this newsletter.
- Readwise - Best reading software company out there. I you want to up your e-reading game, this is definitely for you! It also so happens that I work for Readwise. Best company out there!
- Hetzner - IMHO the best place to buy a VPS or a server for your projects. I'll be doing a tutorial on how to use this in the future.
- SaaS Pegasus is one of the best (if not the best) ways to quickstart your Django Project. If you have a business idea but don't want to set up all the boring stuff (Auth, Payments, Workers, etc.) this is for you!
12 Feb 2025 8:15pm GMT
09 Feb 2025
Django community aggregator: Community blog posts
Jump to dev
At Dryft I have the luxury of a small production database, so I can mirror prod to my local dev machine in ~3 minutes. I use this a lot to get quick local reproduction of issues. I used to copy-paste the relevant URL part to my local dev and felt quite happy with it. Then I realized that I could just paste the entire URL after http://localhost:8000/
! My browser autocompleted that part anyway, and URLs like http://localhost:8000/https://[...]
are obviously invalid for normal uses cases, so can cleanly be made to just strip out the domain part and redirect.
This is the middleware I came up with to do this:
def domain_strip_middleware(get_response):
def domain_strip_middleware_inner(request):
if not settings.DEBUG:
return get_response(request)
m = re.match(r'/https?://(?P<domain>[^/]*)(?P<path>/.*)', request.get_full_path())
if m:
return HttpResponseRedirect(m.groupdict()['path'])
return get_response(request)
return domain_strip_middleware_inner
09 Feb 2025 6:00am GMT
08 Feb 2025
Django community aggregator: Community blog posts
Petites découvertes ou redécouvertes des derniers jours.
Le CSRF , mais pourquoi faire ?
Imaginons, juste comme ça hypothétiquement, que vous vouliez désactiver de manière globale la protection CSRF sur la totalité des urls d'un site django.
Vous pensez qu'il suffit de désactiver le middleware qui va bien (soit django.middleware.csrf.CsrfViewMiddleware ) pour que op c'est bon, la vérification CSRF n'est plus mise en place ?
Vous serez alors décontenancé de voir que non, cela ne suffit pas. Il faut aussi ajouter le décorateur csrf_exempt ( qui se trouve dans django.views.decorators.csrf ) sur chacune de vos urls. Un peu compliqué en vrai, surtout si vous avez beaucoup d'urls. _
Comment faire ?
Tout simplement coder un middleware qui va l'enlever pour vous. Vous n'aurez ensuite qu'à le déclarer dans les middleware actifs.
def __init__(self, get_response):
self.get_response = get_response
def __call__(self, request):
setattr(request, '_dont_enforce_csrf_checks', True)
response = self.get_response(request)
return response
Et voila ! Il suffit ensuite de le déclarer dans MIDDLEWARE et le tour est joué ( par exemple avec un BadIdeaApp.BadMiddleware.NOCSRFMiddleware
Groupons, Groupons, Groupons !!!
J'avais totalement oublié l'existence du templatetags regroup qui permet de regrouper des objets identique par un attribut commun. Comme regrouper une liste de dictionnaires par les valeurs de l'un des attributs. La documentation complète est disponible ici : https://docs.djangoproject.com/en/4.2/ref/templates/builtins/#regroup
Et redécouvrir ce templatetags m'a été bien utile. Surtout en le couplant avec un autre templatetags que j'avais également oublié, dicsort ( https://docs.djangoproject.com/fr/4.2/ref/templates/builtins/#std-templatefilter-dictsort) qui va trier une liste de dictionnaire par une des clés des dictionnaires.
The post Petites découvertes ou redécouvertes des derniers jours. first appeared on Le Mad Blog.
08 Feb 2025 5:41am GMT
07 Feb 2025
Django community aggregator: Community blog posts
Django News - Official MongoDB Backend Support - Feb 7th 2025
News
Django 5.1.6, 5.0.12, and 4.2.19 bugfix release
Two new bugfixes in the latest update.
MongoDB Django Backend Now Available in Public Preview
The Official Django MongoDB Backend is now available in public preview.
Python 3.13.2 and 3.12.9 now available!
Python 3.13.2 and 3.12.9 are maintenance releases.
Updates to Django
Boost Your Git DX second update out now
Adam Johnson's excellent book, Boost Your Git DX, now has a second update available!
Today 'Updates to Django' is presented by Velda Kiara from DEFNA and Djangonaut Space!
Last week we had 21 pull requests merged into Django by 13 different contributors - including 3 first-time contributors! Congratulations to Peter DeVita, Mohammadreza Eskandari, and Vinko Mlacic for having their first commits merged into Django - welcome on board 🎊 !
This Week's Django Highlights:
- Allowed customizing the
password_change_form
in the Django Admin for custom validation (Django 6.0). - Fixed a bug in
ArrayAgg()
which ensures it returns a default value when using an empty list filter(__in=[])
. - The Django Steering Council have started publishing their meeting minutes.
Django Newsletter
Wagtail CMS
Enjoy a smoother content experience with Wagtail 6.4
Our newest features help you create and organize quality content even faster
Sponsored Link 1
Buff your Monolith
Scout Monitoring delivers performance metrics, detailed traces and query stats for all your app routes with a five-minute setup. Add our Log Management and have everything you need to make your Django app shiny and fast. Get started for free at https://try.scoutapm.com/djangonews
Articles
Creating the MongoDB Database Backend for Django
Jib Adegunloye is the lead software developer on the official MongoDB database backend for Django. He writes here about the long process of brining official support to life.
First month on Django's Steering Council
Carlton Gibson shares some thoughts from the Django 6.x Steering Council.
(Re)naming things is hard
MP 133: Naming things is hard, but renaming things can be even harder.
I've been steadily working through the remaining issues that should be closed before the 1.0 release of django-simple-deploy. One of the last things to address involves reconsidering a name that's used throughout the project.
Renaming a
The Ultimate Guide to Django Templates
A very in-depth guide on everything related to Django templates, including the different types and how to use them.
Better unit-tests for your emails with Django 5.2
Django 5.2 introduces a new helper method, body_contains()
, that simplifies unit-testing email content, making it easier to assert text-based content across plain-text and HTML emails.
Events
Call for Proposals for DjangoCon Africa 2025 is now open!
The Call for Proposals is now open and will run from the 1st of February to the 31st of March 2025.
Speaking at DjangoCon Africa
A guide to the selection process, presentation types, proposal guidelines, and suggested topics for speaking at DjangoCon Africa.
Tutorials
Let's Switch Things Up: Using MongoDB in an Intro Django Project
A beginner-friendly tutorial on creating a new project with a MongoDB backend.
Sponsored Link 2
Hiring Web Services Engineer
This position is for someone who can bring their python software development experience to support Playdate, Game Publishing, and our Apps! You would be responsible for contributing to and maintaining our growing flock of Flask and Django web applications.
Podcasts
Django Chat #175: The Future of Django with Emma Delescolle
Emma is a longtime Django community member and newly elected member of the Django 6.x Steering Council. We discuss the future of Django, what it can learn from the Ember community, class-based views, django-ninja, and more.
Django News Jobs
⭐ Jr. Web Services Engineer at Panic 🆕 (featured)
Full-Stack engineer at Exoscale 🆕
Senior Backend Engineer at BactoBio
Senior Software Engineer at Spark
Django Newsletter
Projects
mongodb-labs/django-mongodb-backend
Official MongoDB Django Backend.
meeb/django-distill
Minimal configuration static site generator for Django.
This RSS feed is published on https://django-news.com/. You can also subscribe via email.
07 Feb 2025 5:00pm GMT
05 Feb 2025
Django community aggregator: Community blog posts
The Future of Django - Emma Delescolle
- Ember RFCs
- Emma has a blog
- LevIT
- Django: Looking Forward to the Next 20 Years
- drf-schema-adapter
- Django 6.x Steering Council Election Results
- django-distill
- PyScript
- Rewriting Django from almost scratch in 2021 - DjangoCon Europe
Sponsor
This episode was brought to you by Buttondown, the easiest way to start, send, and grow your email newsletter. New customers can save 50% off their first year with Buttondown using the coupon code DJANGO.
05 Feb 2025 6:00pm GMT
04 Feb 2025
Django community aggregator: Community blog posts
Built with Django Newsletter - 2025 Week 6
Hey, Happy Thursday!
Why are you getting this: *You signed up to receive this newsletter on Built with Django. I promised to send you the latest projects and jobs on the site as well as any other interesting Django content I encountered during the month. If you don't want to receive this newsletter, feel free to unsubscribe anytime.
News and Updates
- Last few weeks have been pretty good in terms of personal productivity, so I allowed myself some time to play around with LLMs. The results were quite good. If you are curious about my work and content I produce, you can subscribe to my personal newsletter.
- First thing that came out of it is the post about Django Updates in January 2025. I wrote some code that gets all the commit from the django repo from January, summarizes each one with AI and then creates a master summary with all the important details. I would love to hear your feedback about it, if any. I will keep iterating over it to improve. Even thinking about making a separate product out of it.
- I started dabbling in a new project which is top secret for now. Just kidding... I'm thinking of creating a web app that will help me come up with creative ways of sharing my projects, blog posts and other work on the internet (directories, link aggregators, social media, etc), using specific voice for each place. This means that
- I'm back to updating the django-saas-starter. If you ever end up using it, feel free telling me about your experience. I'm trying to make it as easy to use as possible. I'm probably going to make it paid at some point. Just as an FYI, though I'm not 100% sure about it.
- Anyway... Sorry for the rambling. Let's get into this week's issue.
Sponsors
This issue is sponsored by SEO Blog Bot. Well, sponsor is a strong word. It is just another project of mine that I wanted to share with you 🙈. Fully free!
If you have a side project and are struggling with finding ideas for blog posts, this will help!
If you want to become a real sponsor, just reply to this email or check out available options here.
Projects
- Design Studio Manager - Business management software for interior design studios. Handles the entire back of office workflow, including proposal, procurement, invoicing, reporting and managing work in progress.
- SoundMadeSeen - SoundMadeSeen is a tool that allows podcasters to create videos from their audio content
- Freelancer Dashboard - A CRM, assignment/to do list tracker, and automated invoicing platform for freelancers.
- No Nonsense Recipes - Just the recipes, no long storie
- Bank Statement Analyzer - Analyze your spending patterns with AI
- ShareMySnaps - Create and Share Stunning Digital Albums In Minute
- Online Convert Pro - Free Online Tools for Simple, Creative, Easy
- Django WTF - Django Packages Index
- FotoIA - Turn your selfies into professional photos or fantastic portraits with AI - in minutes!
Jobs
From the Community
- Managing Django's Queue by Carlton Gibson - Django's queue is overloaded and slowing everything down. The GitHub effect pushes too many extractive contributions onto a few core maintainers. A federated model would spread out the work and keep the community open and healthy.
- Avoiding Mocks: Testing LLM Applications with LangChain in Django - This article discusses a testing approach for Django projects that use large language models (LLMs) without relying on mocks. It suggests using a test-specific LLM backend to define responses and inspect requests, improving test reliability and maintainability. The approach allows for better isolation of tests and avoids common pitfalls associated with mocking.
- An Introduction to Django Views by Evgenia Verbina - Django views are essential for handling web requests and rendering templates in Django applications. There are two types of views: function-based views, which are simple and straightforward, and class-based views, which offer more structure and reusability. Understanding how to effectively use views will help you develop your Django projects more efficiently.
- (Re)naming things is hard by Eric Matthes - Renaming a widely used part of a project takes significant work. The author changed "simple_deploy" to "django_simple_deploy," which required thorough updates to code, documentation, and tests. They suggest prioritizing clear, consistent names early on and revisiting them if needed to help new users and contributors.
- What Changed? by Evan Rupert - The author uses a new project to refine workflows, switching from Make to Task, mandating an abstract base model for consistency, and focusing heavily on test coverage. He also reduces friction by integrating tests directly within the development environment. Yet he continues using Django Rest Framework and factoryboy, as they still provide rapid, reliable API and test development.
- What is OpenTelemetry and how to add it to your Django application by Jessica Garson - OpenTelemetry is an open-source framework that helps you monitor applications like Django in a standardized way. This blog post provides a guide on how to set up OpenTelemetry with a Django to-do list app and connect it to Elastic for observability. You can choose between automatic and manual instrumentation to customize your monitoring experience.
Top 3 links from last Issue
- Django and Postgres for the Busy Rails Developer by Andrew Atkinson
- TIL: Django relations are not cached in model instance by Enrique Soria
- CheckIN - All In One Software For Car Wash Companies.
Support
You can support this project by using one of the affiliate links below. These are always going to be projects I use and love! No "Bluehost" crap here!
- Buttondown - Email newsletter tool I use to send you this newsletter.
- Readwise - Best reading software company out there. I you want to up your e-reading game, this is definitely for you! It also so happens that I work for Readwise. Best company out there!
- Hetzner - IMHO the best place to buy a VPS or a server for your projects. I'll be doing a tutorial on how to use this in the future.
- SaaS Pegasus is one of the best (if not the best) ways to quickstart your Django Project. If you have a business idea but don't want to set up all the boring stuff (Auth, Payments, Workers, etc.) this is for you!
04 Feb 2025 8:30pm GMT
31 Jan 2025
Django community aggregator: Community blog posts
Django News - 400 DSF Members - Jan 31st 2025
News
PyPI Now Supports Project Archival
Projects on PyPI can now be marked as archived.
Django Software Foundation
400 individual members of the Django Software Foundation
The Django Software Foundation reached 400 individual members.
Updates to Django
Today 'Updates to Django' is presented by Abigail Afi Gbadago from Djangonaut Space!
Last week we had 21 pull requests merged into Django by 12 different contributors - including 2 first-time contributors! Congratulations to Gregory Mariani and Igor Scheller for having their first commits merged into Django - welcome on board!🎊
Highlights of the changes made:
- The
main
branch is now tracking development for Django 6.0. - You can now squash a squashed migration. This eases the squashing process (#19082).
- Support has been dropped for Python 3.10 & 3.11 (#19067)
Django Newsletter
Wagtail CMS
Our updated Accessibility Conformance Report
Wagtail has released a new Accessibility Conformance Report for version 6.3, showcasing improvements across WCAG 2.2 criteria, detailing compliance in the CMS, documentation, and websites, and inviting feedback for further accessibility enhancements.
Sponsored Link 1
Hiring Jr. Web Services Engineer
This position is for someone who can bring their python software development experience to support Playdate, Game Publishing, and our Apps! You would be responsible for contributing to and maintaining our growing flock of Flask and Django web applications.
Additionally, Panic hires interns every summer via The Script (https://thescript.org/internship-program/), designed for college students with underrepresented backgrounds entering freshman through senior years.
Articles
Database Indexing in Django
Explore the fundamentals of database indexing in Django-covering types, advantages, and practical examples-to help you significantly improve query performance and scalability in your projects.
An Introduction to Django Views
An overview of Django views, covering function-based vs. class-based approaches, best practices, and practical PyCharm tips for streamlined web development.
Django 5.2 simple_block_tag with HTMX
Django 5.2 introduces the new simple_block_tag()
, demonstrated here with HTMX to validate and test custom attributes for more robust and maintainable components.
Avoiding Mocks: Testing LLM Applications with LangChain in Django
A practical method for testing Django-based LLM apps with LangChain uses a custom fake backend to avoid mocks, enabling flexible refactoring and thorough validation of model interactions.
Add headings to HTML landmarks
Use visually hidden headings to make your website easier to navigate.
Rendering form fields as group in Django
A welcome addition in Django 5.0, the concept of field groups makes a lot easier to customize the layout of our Django forms.
Looking at Django task runners and queues
A look at different ways to combine scheduled and one-off background jobs in Django-comparing django-apscheduler, django-tasks, django-q2, Celery, and cron-to handle tasks like sending email and long-running processes efficiently.
Events
PyOhio 2025
PyOhio is a free annual Python community conference based in Ohio this July 26-27, 2025.
Tutorials
How to Use GraphQL in Django with Elasticsearch
A guide to combining Graphene-Django with Django Elasticsearch DSL to create high-performance GraphQL endpoints, complete with advanced search and filtering via Elasticsearch.
Sponsored Link 2
Django & Wagtail Hosting for just $9/month
New year, new site! Finally put those domain names to use and launch that side-project, blog, or personal site in 2025. Lock in this limited time pricing by Feb 28.
Podcasts
Real Python #236: Simon Willison: Using LLMs for Python Development
Simon talks about his LLM research and explores ways of writing Python code with these rapidly evolving tools.
Django News Jobs
⭐ Jr. Web Services Engineer at Panic 🆕 (featured)
Senior Backend Engineer at BactoBio 🆕
Senior Software Engineer at Spark
Front-end developer at cassandra.app
Lead Django Developer at cassandra.app
Développeur(se) back-end en CDI at Brief Media
Django Newsletter
Projects
drf-forms/drf-schema-adapter
Making using Django with frontend libraries and frameworks DRYer.
nanuxbe/django-classy-doc
django-classy-doc brings Classy Class-Based Views-style docs to your own code.
This RSS feed is published on https://django-news.com/. You can also subscribe via email.
31 Jan 2025 5:00pm GMT
Finishing Simple Signup - Building SaaS #213
In this episode, I completed the simplified sign up process for my JourneyInbox app. I finished off the final features that add account verification and initial engagement features to make sign up and nice and functional experience.
31 Jan 2025 6:00am GMT
29 Jan 2025
Django community aggregator: Community blog posts
Weeknotes (2025 week 05)
Weeknotes (2025 week 05)
Djangonaut Space
In December I wrote a few paragraphs about my decision to not run for the Django Steering Council, mentioning that I want to contribute in different ways.
I have offered to contribute to Djangonaut Space to do some mentoring. I'm already a bit stressed, but that's normal and to be expected. I'll probably have more to share about that in the close future!
Releases
- feincms-cookiecontrol 1.6: Removed the hardcoded dependency upon feincms3 and some additional code golfing. The cookie banner JavaScript is now back to <4KiB.
- django-curtains 0.7: Updated the CI job list and modernized the package somewhat, no code changes necessary. It's good to release updated versions though just to show that it's still actively maintained.
- django-prose-editor 0.10.3: Small CSS fixes and mainly updated TipTap/ProseMirror.
- django-imagefield 0.22: The updated version no longer autodeletes processed images; this wasn't really a problem before but I was a little bit fearful that images are still referenced elsewhere and this change let's me sleep better.
- feincms-oembed 2.0: Oembed support for FeinCMS 1 without actually depending upon the FeinCMS package itself. Still works.
- django-content-editor 7.2: The
Region
type is now hashable; this may be useful, or not. - feincms3 5.3.1: I undeprecated the
TemplateMixin
because even thoughPageTypeMixin
is nicer, sometimes all you need is a template selector.
29 Jan 2025 6:00pm GMT
28 Jan 2025
Django community aggregator: Community blog posts
Thinking About Risk: Sidebar #4: Quantitative Risk Revisited
In part 1 of this series, I briefly covered quantitive risk measuring - assigning a numeric value to risk, like "$3,500", rather than a qualitative label like "medium" - only to quickly recommend against trying it. In this final sidebar, I want to come back to this topic. I'll spend a bit more time explaining what I see as the pros and cons of quantitative risk measurement - why you might or might not want to use numeric values over more simple risk matrixes.
28 Jan 2025 6:00am GMT
27 Jan 2025
Django community aggregator: Community blog posts
Python Leiden (NL) meetup: python in applied mathematics - Tobias Datema
(One of my summaries of the first Python Leiden (NL) meetup in Leiden, NL).
Tobias studied applied mathematics at Delft University.
One of the fields he used python for was graph theory. A graph consists of points ("vertices") connected by lines ("edges"). It is a large field with many real world projects like social networks and logistics. He showed a demo he made with networkx, a python library that makes it real easy to do these kinds of graph calculations.
Graphs need to be shown. He used pyviz for that by converting the networkx graph to the format understood by pyviz.
Another field is machine learning. He did an experiment with a simulated self-driving car. He used a library that handles the basics like "reacting to a closed line on the road" and "measuring the distance to the dashed line on the road". The simulation is shown in a visual form, which makes it funny to look at.
In his study, python was also handy for statistics and numerical analysis.
27 Jan 2025 5:00am GMT
Python Leiden (NL) meetup: fawltydeps - Johan Herland
(One of my summaries of the Python Leiden (NL) meetup in Leiden, NL).
FawltyDeps is a python dependency checker. "Finding undeclared and unused dependencies in your notebooks and projects".
Note by Reinout: since 2009 I'm one of the maintainers of z3c.dependencychecker.... also a python dependency checker :-) So this talk interested me a lot, as I didn't know yet about fawltydeps.
A big problem in science is the "replication crisis". Lots of research cannot actually be reproduced when you try it... Data science is part of this problem. Reproducing your jupyter notebook for instance.
Someone looked at 22k+ jupyter notebooks. Only 70% had declared their dependencies, 46% could actually install the dependencies and only 5% actually could be run. ModuleNotFoundError and ImportError were the number 1 and 3 in the list of exceptions!
What is a dependency? For instance "numpy", if you have a import numpy as np in your file. Numpy isn't in the python standard library, you have to install it first.
You can specify dependencies in setup.py, pyproject.toml, requirements.txt and so. If you import something and don't specify it, it is an "undeclared dependency". When you later on remove an import and don't adjust your requirements.txt, you have an "unused dependency". That's not immediately fatal, but it might take up unnecessary space.
FawltyDeps was started to help with this problem: find undeclared and unused dependencies. It reports them. You can ask for a more detailed report with line numbers where the dependencies were found.
FawltyDeps supports most dependency declaration locations. requirements.txt, setup.py, pyproject, conda, etc. And it works with plain python files, notebooks, most python versions and most OSs. You can configure it on the commandline and in config files. There's even a handy command to add an example config to your pyproject.toml.
Handy: you can add it as a pre-commit hook (https://pre-commit.com). And: there's a ready-made github action for it, including good reporting.
Fawltydeps has to deal with several corner cases:
- Package names that don't match what you import. import sklearn and the dependency scikit-learn.
- Or setuptools that provides both setuptools and pkg_resources.
- For this it looks at various locations for installed packages to help figure out those mappings. It helps if you've installed FawltyDeps in your project's virtualenv.
- You can add your own custom mappings in your configuration to help FawltyDeps.
- You can exclude directories.
- There's a default list of "tool" packages that FawltyDeps doesn't complain about if you include them as dependency without importing them. Ruff, black, isort: those kinds of tools.
- Django projects can have dependencies that aren't actually imported. You can ignore those in the config to prevent them to be imported.
- At the moment, extra dependencies (like [test] or [dev] dependencies) are just handled as part of the whole set of dependencies.
27 Jan 2025 5:00am GMT