Django community: RSS
This page, updated regularly, aggregates Community blog posts from the Django community.
-
Effective Organizations Value Autonomy
I believe that autonomy is one of the most important values of effective organizations. But I also think it’s a value that’s misunderstood and misapplied. In this post, I’ll (1) define what I mean by “autonomy”, (2) explain what autonomy isn’t, and (3) try to articulate why autonomy, as an organizational value, leads to higher effectiveness. -
Improve your Django experience with IPython
IPython is an improved Python shell for interactive use. It has many great features such as syntax highlighting, autocomplete, and powerful “magic commands”. I love it, use it on every project, and use the IPython prompt for examples on my blog. IPython has too much goodness to cover here. Check out its tutorial for an introduction. To use IPython with Django, simply install it: $ python -m pip install ipython (Or add to your project’s requirements file.) Now Django’s shell will automatically use IPython: $ ./manage.py shell Python 3.9.1 (default, Jan 21 2021, 09:04:53) Type 'copyright', 'credits' or 'license' for more information IPython 7.20.0 -- An enhanced Interactive Python. Type '?' for help. In [1]: from db_buddy.core.models import Server| Server ServerKind ServerManager In this example, I typed Server then pressed “Tab” and IPython opened a drop-down of possible names to import. IPython’s debugger IPython also comes with an improved version of Python’s pdb debugger, with colorization and other features. Inside the IPython shell, if you code raises an exception, you can open the IPython debugger with the %debug magic command: In [1]: def divide(x, y): ...: return x/y ...: In [2]: divide(1,0) --------------------------------------------------------------------------- ZeroDivisionError Traceback (most recent call last) <ipython-input-3-4fffc6193274> … -
Django’s release code words, up until 3.2
It’s now a long-running tradition that each Django release has an associated “code word”. This is used by the release manager in the announcement blog post to describe the list of features coming in the next version. I previously covered the code words used up until 2.2. This post is an update to expand the table up until Django 3.2, which had its first beta release yesterday. Each code word links to its Wiktionary entry so you can see the definition. The word frequency is the based on the data set provided by Peter Norvig based upon a Google 2012 corpus - higher means more occurrences of that word (in english). Version(Links to Announcement) Post Author Quote with Code Word Highlighted Word Frequency 1.7 James Bennett ...will bring several major new features to Django, along with a host of other improvements... 32,304,193 1.8 Tim Graham ...several major new features and a o cornucopia of other improvements... 330,288 1.9 Tim Graham ... myriad of goodies... 3,019,357 1.10 Tim Graham ... panoply of new features... 474,466 1.11 Tim Graham ... medley of new features... 963,448 2.0 Tim Graham ... assortment of new features... 2,252,068 2.1 Tim Graham ... smorgasbord of new features... … -
Django News - DjangoCon Europe is Virtual, Python, and Wagtail Releases - Feb 19th 2021
News DjangoCon Europe 2021 Announcement This year's DjangoCon Europe will be virtual only and held June 2-6. djangoproject.com Python 3.7.10 and 3.6.13 security updates now available Python 3.7.10 and 3.6.13, the latest security fix rollups for Python 3.7 and Python 3.6, are now available. blogspot.com Wagtail 2.12 and 2.11 Bugfixes Minor Wagtail versions 2.12.2, 2.12.1, 2.11.5, and 2.11.4 were released to address bug fixes. github.com Events PyCascades 2021 Remote is this weekend! Friday, February 19th, 2021, is the last day to purchase your PyCascades Remote 2021 tickets. Tickets range from $10 to $50. pretix.eu Articles New Testing Features in Django 3.2 Adam Johnson explores in-depth 5 new testing features in the forthcoming Django 3.2 release. adamj.eu Django and Stripe Payments Tutorial A video and text tutorial on adding Stripe Checkout to a Django website. justdjango.com Django and Pydantic How to integrate Pydantic with a Django application using the Pydantic-Django and Django Ninja packages. testdriven.io Quick and Dirty Django - Passing data to JavaScript without AJAX A clever quick & dirty way to proof of concept data without needing AJAX. hacksoft.io Why you really need to upgrade pip by Itamar Turner-Trauring In order to get the latest and greatest packages, without … -
Take Note of these Top Talks From DjangoCon EU
Photo by The Climate Reality Project on Unsplash Like many conferences in 2020, DjangoCon EU was held virtually. I'm glad I had the opportunity to attend because the sessions provided insight and information that I’m still applying. In light of the pandemic and the social changes it's caused, I've come to know that web development and the solutions it provides are at the heart of how we are navigating this challenging time. Here are three talks from DjangoCon EU that I believe will help you protect, maintain, and develop projects. Developing a Security Mindset: Practical Lessons for Pythonistas Hayley Denbraver Hayley used the great analogy of Sherlock Holmes and other detectives from fiction to help encourage the audience to take on a more security-oriented mindset in their Django projects. The talk touches upon a lot of topics in security, from how to think about third party dependencies and their security vulnerabilities, to mitigating the risk of SQL injection attacks and code execution from deserialized user content. All around, this talk was a great way to stay informed on the methodologies for protecting your application. C is for Cookie Russell Keith-Magee At Caktus many of our projects demand internationalization. As a … -
Django Forum - Ken Whitesell
2020 Malcolm Tredinnick Memorial Prize awarded to Ken WhitesellKen on Django ForumDjango Forum: Where to put business logic?Django models, encapsulation and data integrity by Tom ChristieDjango Hello, World 5 Different WaysSupport the ShowThis podcast is a labor of love and does not have any ads or sponsors. To support the show, please consider recommending a book from LearnDjango.com, signing up for the free weekly Django News newsletter, or learning more about Button a simpler deployment story for Django. -
Setup Webpack Project with Django
Setup a Webpack project with Django and run it in Watch mode. -
Setup Webpack Project with Django
Setup a Webpack project with Django and run it in Watch mode. -
Success With Static Files
Full show notes are available at https://www.mattlayman.com/django-riffs/12. -
Episode 12 - Success With Static Files
On this episode, our focus will be on static files. Static files are vital to your application, but they have little to do with Python code. We’ll see what they are and what they do. Listen at djangoriffs.com or with the player below. Last Episode On the last episode, we looked at Django middleware. We discussed why middleware is useful and how you can work with it. What Are Static Files? -
Interview Question Series Wrap Up
A summary and wrap-up of my Unpacking Interview Questions series, covering why I wrote this series in the first place, some advice on developing your own questions, and answers to a few questions. -
Django News - All About That Database - Feb 12th 2021
News Wagtail 2.12 released Changes include official Python 3.9 support, a new 'choose' permission, in-place StreamField updating (sounds niche but enables some cool features), admin colour themes, and performance improvements. wagtail.io PEP 634 -- Structural Pattern Matching: Specification Python is getting pattern matching in a future version which is similar to a switch statement in other languages. python.org Events ‘What’s New in Wagtail’, episode 3 The Wagtail team is hosting a free webinar to help get everyone up to speed on ‘What’s New in Wagtail’. Check out What's New in Wagtail (season 1, episode 2) too. wagtail.io Articles The Unexpected Find That Freed 20GB of Unused Index Space by Haki Benita How to free space without dropping indexes or deleting data. hakibenita.com Cleaning Up Your Postgres Database How do you know if your Postgres database is healthy? Craig Kerstiens shows us a few tips. crunchydata.com Database Constraints in Django Django's database constraints have evolved a lot since the Django 2.2 release, and Steven Pate walks through the various constraint options. laac.dev Elegant Database Migrations on ECS While this article is a few years old, Adam Stepinski shows us how to write a health check which checks Django's Migrations before signaling … -
The Weakness Question
The fifth and final part of my Unpacking Interview Questions series, where I share one of the questions I use when I interview for technical roles. Today’s question is the most difficult-to-ask of the series, but also one of the most valuable: asking a candidate to discuss one of their weaknesses. -
“Tell Me About a Disagreement…”
Part 4 of my Unpacking Interview Questions series, where I share one of the questions I use when I interview for technical roles. Today, an oldie-but-goodie: looking into a candidate’s ability to disagree and resolve conflict professionally. -
New Testing Features in Django 3.2
Django 3.2 had its first alpha release a couple of weeks ago and the final release will be out in April. It contains a mezcla of new features, which you can check out in the release notes. This post focuses on the changes to testing, a few of which you can get on earlier Django versions with backport packages. 1. setUpTestData() isolation The release note for this reads: “Objects assigned to class attributes in TestCase.setUpTestData() are now isolated for each test method.” setUpTestData() is a very useful hook for making your tests fast, and this change makes its use a lot easier. It’s common to use the TestCase.setUp() hook from unittest to create model instances that each test uses: from django.test import TestCase from example.core.models import Book class ExampleTests(TestCase): def setUp(cls): self.book = Book.objects.create(title="Meditations") The test runner calls setUp() before each test. This gives simple isolation, since the data is fresh for each test. The downside of this approach is that setUp() runs many times, which can get quite slow with large amounts of data or tests. setUpTestData() allows you to create the data at the class-level, so only once per TestCase. Its use is very similar to setUp(), only … -
Diversity, Equity, and Inclusion
Part 3 of my Unpacking Interview Questions series, where I share one of the questions I use when I interview for technical roles. Today: making sure candidates align with organizational values of diversity, equity, and inclusion. -
Sessions in Flask
This article looks at how sessions work in Flask. -
“Tell Me About a Project You Led…”
Part 2 of my Unpacking Interview Questions series, where I share one of the questions I use when I interview for technical roles. Today: measuring a manager’s ability to lead projects and manage them effectively. -
“Explain a Topic At Multiple Levels…”
Part 1 of my Unpacking Interview Questions series, where I share one of the questions I use when I interview for technical roles. Today: asking candidates to explain a topic at multiple levels. This is one of my favorite questions to ask for engineering roles; strong performance on this question correlates very highly with high job performance on my teams. -
How To Use Htmx In Django
This article show you how to use htmx in Django. What is htmx? According to the htmx website: htmx allows you to access AJAX, CSS Transitions, WebSockets and Server Sent Events directly in HTML, using attributes, so you can build modern user interfaces with the simplicity and power of hypertext. The example that we’ll craft is an ability to delete a task from a list of tasks without reloading the whole page. -
New Committers for Tastypie & Haystack
New Committers for Tastypie & Haystack -
Django Dash - Registration Soon! (And Sponsors Needed)
Django Dash - Registration Soon! (And Sponsors Needed) -
The State of Tastypie
The State of Tastypie -
Django Dash & WSGI Wrestle Cancelled
Django Dash & WSGI Wrestle Cancelled -
Haystack & Tastypie Orgs
Haystack & Tastypie Orgs