Why you should use Django
Inspired by Guido van Rossum’s plea to be taught web frameworks here are (in no particular order) ten reasons why he — and you — should use Django.
1. Django works — right now
Don’t be fooled by the fact that Django’s first release was in July. It’s been under heavy use for over two years, and I’m confident saying it has no show-stopping bugs.
I’m tired of hearing that that SomeAwesomeFramework™ will be “great when it’s finished”. Django is finished, now — all the changes we’re making in the run up to 1.0 involve stabilizing APIs and improving the cleanliness of the internal code.
2. Deployment is a breeze
The web framework world is full of sad tales of deployment woes. You can even read horror stories about deploying Rails, the leader of the dynamic web framework pack.
Not only is there a well-established way to deploy high-traffic Django sites, but Django sites are very stable. We do over 15 million hits to a day to about ten sites, and that’s a single Django installation (one web server, one database server).
3. Your site won’t go down
Django sites survive Slashdottings (chicagocrime.org), Farkings (ljworld.com), and rabid NCAA Basketball fans (kusports.com).
(Funny story about that: a few weeks ago the editor of ljworld.com asked me to look into why we had 3 million more daily hits than usually. Turns out we’d been Farked, and I hadn’t even noticed.)
4. Django is fast
Every bit of the framework is designed with efficiency in mind.
I’ve seen benchmarks that peg Django’s template language at four times faster than Kid and six times as fast as Cheetah. In fact, it’s SO fast that we’ve found that caching compiled templates is actually slower than re-rendering them on every request.
Django’s ORM is similarly extremely careful to perform as few database lookups as possible, and to always make it obvious when database hits are happening.
And if Django still isn’t fast enough, it’s stupidly easy to cache performance-intensive bits (or even the whole site). One of the available cache backends is memcached which drives LiveJournal and Slashdot itself.
5. Django scales
From personal sites running on shared hosting to small band sites to huge databases of public info to social networking sites with over 500,000 users, Django handles it all.
At the top end, you’re only limited by your hardware budget.
6. Django’s admin will blow your mind
The most boring part of writing content-heavy websites is developing admin interfaces. How many times have you written a form validation function?
Well, Django’s admin is the most amazing thing to happen to content-driven sites since the invention of the database itself.
Seriously — even if you don’t want to use Django for some reason you owe it to yourself to check out what a site administration interface should look like.
7. You don’t need to go whole-hog
As I said above, Django’s admin interface will blow your mind. Luckily, you don’t need to port your legacy sites to Django just to use the admin interface; in a few moments you can introspect your database and have a awesome admin interface to your old data.
I know quite a few people who have started major Django projects this way.
8. Django plays well with designers
Programmers have criticized Django’s template language for not being Pythonic enough. There’s a simple explanation for that: the template language isn’t meant for you. Our new designer Jeff Croft picked up Django’s template language in about a day, and moved on to getting real work done.
Sure, if you’re building a site all by yourself the overhead of learning a template language might seem dumb, but when you get bought by Yahoo you’ll be glad you can hand off the design to someone else so easily.
9. Django comes from the Real World
Every single feature in Django exists because it solves a real world problem. If you spend any time on django-dev you’ll see Adrian repeatedly ask “what real-world problem does this proposal solve?”
Django rose out of the insanely tight deadlines inherent to the news industry — our deadlines are mere days, if not hours — and it will let you build huge amazing sites far faster than you ever thought possible.
At work we’re about to launch the best local TV station site you’ve ever seen, but what you’ll miss when you see it is that it was built in just a few weeks.
If the Romans had used Django, they would have built Rome in a day.
10. We’re here to help
I’m very proud of the fact that Django’s community is lively and extremely friendly. Whether it’s on django-users, django-dev, or the IRC channel, you’ll find smart people to help you out.
It might seem trite to say it, but I think our community is our biggest asset.
That and a lead developer who speaks Ukrainian.