Simon Willison’s Weblog

Subscribe
Atom feed for django

565 items tagged “django”

The Django web framework.

2008

GeoDjango Documentation. Merged to Django trunk a few hours ago. The tutorial isn’t there yet, but the rest of the docs are worth exploring.

# 5th August 2008, 11:06 pm / geodjango, documentation, django, python

Changeset 8162. “Implemented a secure password reset form that uses a token and prompts user for new password”—also sneaks base36 encoding and decoding in to Django.

# 31st July 2008, 10:54 pm / django, python, lukeplant, changeset, security, base36, passwords

Super User Conditional Page Exception Reporting. The name is almost as long as the code snippet: this serves Django’s debug page to logged in super-users, falling back to the default 500 template for everyone else.

# 31st July 2008, 9:06 pm / django, python, debugging, exceptions, middleware

Spawning + Django. The latest version of Spawning (a fast Python web server built on top of the Eventlet non-blocking coroutine networking library) can run Django applications out of the box, using threads and processes to work around the blocking nature of the ORM’s database drivers. Eric Florenzano reports better performance than Apache and mod_wsgi, and is now hosting his site on it.

# 31st July 2008, 10:56 am / eric-florenzano, django, python, comet, eventlet, spawning

DjangoCon & Django 1.0 updates. DjangoCon tickets will be released in two batches of 100. The first set will be available at 12 noon UTC on Thursday July 31st; the second set will be released at 6pm UTC on Friday August 1st.

# 30th July 2008, 10:25 am / tickets, djangocon, events, django, python

Extra fields on many-to-many relationships (via) Checked in just over an hour ago, Django now lets you specify a custom “through” table for a ManyToManyField. Great work by Eric Florenzano.

# 29th July 2008, 1:58 pm / manytomany, eric-florenzano, django, python, through

FLOSS Weekly 34: Django. Randal Schwartz interviewed Jacob Kaplan-Moss at OSCON for the consistently excellent FLOSS Weekly podcast.

# 27th July 2008, 9:47 am / flossweekly, open-source, randalschwartz, jacob-kaplan-moss, django, python, podcasts

Dojango version 0.3 released. A reusable Django application that provides Dojo, helper functions (dojo.data integration) and tools for switching between Dojo versions.

# 24th July 2008, 12:47 am / dojango, dojo, django, python, javascript

Python BoF and Django Drinkup (via) At OSCON? Come along to the Jax Bar tonight (Tuesday 22nd) from 7pm to 10pm to hang out with fellow Pythoneers and Djangonaughts.

# 22nd July 2008, 6:48 pm / python, django, oscon, social, bof

Replacing Django’s Template Language With Jinja2. Part of Will Larson’s series on taking advantage of Django’s loose coupling.

# 22nd July 2008, 5:18 pm / django, loosecoupling, jinja, python, will-larson

ComicVine.com. Also powered by Django, Whiskey Media’s comic book encyclopedia and community. 43,000 characters and 94,000 issues and counting.

# 22nd July 2008, 7:12 am / whiskeymedia, comics, django

GiantBomb.com. Launched today, powered by Django—a combination of (mostly ex-Gamespot) quality editorial content and a massive structured wiki of every computer game ever released. This is going to be a lot of fun—all of the crazy detailed content that Wikipedia tends to reject.

# 22nd July 2008, 7:09 am / django, giantbomb, games, wikipedia, wiki

Django 1.0 alpha release notes. The big features are newforms-admin, unicode everywhere, the queryset-refactor ORM improvements and auto-escaping in templates.

# 22nd July 2008, 6:04 am / orm, django, alpha, python, newformsadmin, unicode, querysetrefactor, autoescaping

Django 1.0 alpha released! Not meant for production use, but a pretty solid preview of what’s coming in 1.0 proper. The beta is scheduled for August 5th.

# 22nd July 2008, 6:01 am / django, alpha, python

newforms-admin branch has been merged into trunk. Congrats to Brian Rosner for the merge. django.newforms has been renamed to django.forms as well—1.0 grows ever closer.

# 20th July 2008, 11:17 pm / django, newformsadmin, merge, brian-rosner, forms

DjangoCon 2008. The official DjangoCon site is up, along with a mostly complete schedule.

# 20th July 2008, 8:49 pm / djangocon, django, python

Jinja2 Final aka Jinjavitus Released. The Jinja template engine now has auto-escaping as an optional feature, disabled by default. Worth considering as an almost drop-in replacement for Django’s template language if features such as macros and compilation to Python code appeal to you.

# 19th July 2008, 11:52 pm / jinja, python, autoescaping, django

DjangoCon 2008. Venue: Gooleplex, San Francisco Bay Area. Dates: 6th and 7th Sept. Official post will be on djangoproject.com soon.

Robert Lofthouse

# 13th July 2008, 4:50 pm / robert-lofthouse, djangocon, django, python, events, google, googleplex, san-francisco

It looks like the first ever Django conference will take place in early September in the San Francisco bay area.

Me, on Twitter

# 7th July 2008, 5:14 pm / django, events, djangocon, conferences, san-francisco, twitter

Django Unit Tests and Transactions. If you’re using a transactional database engine (MySQL with InnoDB, Postgres or SQLite) you can speed things up by running each of your unit tests inside a transaction and rolling back in tearDown().

# 7th July 2008, 2:14 pm / unittesting, unittest, python, django, transactions, innodb, mysql, sqlite, postgresql

Django File Uploads (via) Nearly two years in the making, Django’s file upload capacity has received a major (and backwards incompatible) upgrade. Previously, files were uploaded by default in to RAM—now, files larger than 2.5MB are streamed to a temporary file and extensive hooks are provided to customise where they end up—streaming to S3, for example.

# 1st July 2008, 5 pm / django, fileuploads, s3, uploads

Graphite. Real-time graphing package for server monitoring, similar to RRDTool. Created by the team at Orbitz, using Django and ExtJS for the frontend and Cairo to generate the graphs.

# 28th June 2008, 11:53 pm / graphite, cairo, orbitz, rrdtool, monitoring, graphing, django, python, extjs

CookBookNewFormsFieldOrdering. Handy tip—change the order of fields in a Django newforms instance by over-riding form.fields.keyOrder (since fields is a SortedDict).

# 27th June 2008, 1:02 am / newforms, django, python, tip

mod_rpaf for Apache. A more secure alternative to Django’s equivalent middleware: sets the REMOTE_ADDR of incoming requests from whitelisted load balancers to the X-Forwarded-For header, without any risk that if the load balancers are missing attackers could abuse it to spoof their IP addresses.

# 24th June 2008, 5:02 pm / django, middleware, apache, rpaf, modrpaf, security, xforwardedfor, http, load-balancing

Django snippets: Command to dump data as a python script. Extremely useful—dumps the data for an application as an executable Python script which will re-import it in to another database without any risk of colliding with existing IDs, sorting out foreign keys along the way.

# 24th June 2008, 12:07 pm / django, python, import, django-snippets

The basics of creating a tumblelog with Django (via) Ryan Berg suggests having a StreamItem model that links uses a GenericForeignKey to link to other content types, then using signals to cause a StreamItem to be created for every other model type. I should switch to doing that on this blog: at the moment I have to query three separate tables to build the tumblelog part which results in messy code for ordering and pagination.

# 24th June 2008, 11:09 am / ryan-berg, django, python, tumblelog, genericforeignkey, contenttypes

What is it like to write a technical book? Plenty of food for thought from the lead author of the new edition of High Performance MySQL. It’s amazing how Word is still an integral part of most technical book projects despite its obvious inadequacies compared to a toolchain based on plain text files and Subversion (the Django Book used ReST and Subversion to great effect).

# 20th June 2008, 8:18 am / writing, word, subversion, django, rest, plaintext, baron-schwartz

PortingDjangoTo3k. Martin von Loewis has started assembling a patch. His write-up illustrates some key differences between Python 2.X and Python 3—it looks like Django’s unicode handling is going to require the most work.

# 19th June 2008, 5:53 pm / python3k, python, martinvonloewis, django, unicode

New foundation for Django. Django now has its own nonprofit software foundation (courtesy of a bunch of tough paperwork by Jacob Kaplan-Moss), and fittingly the Lawrence-Journal World get the exclusive.

# 17th June 2008, 5:16 pm / ljworld, django, python, jacob-kaplan-moss, dsf

DebugFooter middleware with Pygments sql syntax highlighting. Andreas Marr has enhanced my Django DebugFooter middleware with proper syntax highlighting for the logged SQL.

# 14th June 2008, 10:04 am / django, middleware, andreas-marr, debugfooter, python