Django, the Python-based Web development framework, is one of the hottest topics in Web development today. Its creator (and co-author of this book) Adrian Holovaty has built a compelling array of Web applications using Django, including Django creator Adrian Holovaty and lead developer Jacob Kaplan-Moss have created this book as the definitive guide to the technology. Beginning with fundamentals such as installation and configuration, the book tackles sophisticated features of Django, such as outputting non-HTML content such as RSS feeds and PDFs, caching, and user management. Also includes a detailed reference to Django’s many configuration options and commands.
Django is a framework I’ve long (in web years) held in some esteem, despite never having used it before the past few weeks. The framework’s creators� many well reasoned contributions on all manner of debates about the web suggested a thoughtful approach, and the range of high quality sites powered by Django has kept growing, with the recent launch of EveryBlock being a prime example of its capabilities. So I was delighted to receive a copy of The Definitive Guide to django: Web Development Done Right for review.
Authored by two of the creators of Django: Adrian Holovaty and Jacob Kaplan-Moss, the book is carefully structured, initially placing django in context by exploring various approaches to web development, and then stepping through initial project creation, templates, models, url configuration, django’s famed admin interface, and so on. After eight chapters it changes tack and switches from basic tutorial to more in-depth exploration of areas like the ORM, session handling, caching and deployment. Several appendices provide supplementary material.
The first few chapters do a good job of laying out the foci of the framework’s architecture and it’s Model Template View (MTV) approach. Its pace is measured and while I wonder if it might be a little too much too soon for those totally new to full stack web frameworks, it would work well for those coming from a background building web apps with PHP, Java, or for those of us who are used to working with Rails. There are new techniques to learn and I found the book particularly useful for grasping the deeply pythonic approach, favouring flexibility over convention.
A clear example of that comes in the use of Context objects for passing values between Views and Templates. The authors initially show us the most verbose and rudimentary way to do it and gradually develop that to show how they’ve provided for various common cases. By going through those steps there’s a good chance the reader will be well equipped to work out ways to simplify their own workflow and/or create new subclasses to promote reuse in their code.
Where the book is lacking is in the examples. The introductory material, and much of the reference content is excellent, but as a newcomer to the framework I felt a little lost in how I should structure my code and how different components relate; it’s clear how models relate to the database, but how do I pass them around when building associations?
I recognise that django deliberately avoids the strong conventions of the Rails community (though even there you frequently find newcomers unsure where in the directory structure to place certain components) and there’s no need for lengthy tutorials on building a shop or how a magazine cms could work, but when I come to a book like this I’m looking for a guide to best practices at the project architecture level, not just the component level, and I was sorry not to find it. The authors clearly have a lot of experience of structuring django sites of all shapes and sizes and it would be good to learn more about how they keep those sites organised.
That said, this is a solid introduction to django for web developers; a solid contribution in a so-far underserved market and it’s likely to come in handy for a number of people. Just be prepared to supplement it with a fair amount of time in search engines working out good strategies for connecting the pieces.
Disclaimer: I was sent a copy of this book for review by the publisher.
I've dabbled with what I consider to be all the major web frameworks: TurboGears, Pylons, Rails, and Django. Religion and other biases aside, what really made me finally settle on Django was the documentation (though community/all-in-one-ness/robustness aspects are also nice factors). What's notable out about Django documentation? Precision, attention to detail, comprehensiveness, and general emphasis on polish.
To many people, a book is what makes a new technology both accessible and credible. A couple years ago when I thought TurboGears was the framework I wanted, I got the book, and it was crap. Subsequently, other things about the framework started to feel lacking. Then with Pylons, there is no book, which reflects the constant state of flux of the component mix. Cool framework, admirable ideals, but no book. Now with Django, there is *the* book, and it's beautifully done, and you discover that the framework is, too.
I see this book as a true community resource. Its examples directly extend *the* tutorial. Being available in its up-to-date entirety as a living document, anyone can simply answer a question by consulting a link to a book section. I applaud the authors opening this book up to be accessible to everyone, both in ease of reading, and in being free for download. It is always reassuring to find a book about a tool being written by the authors of a tool, and that should contribute to making it the canonical Django resource.
I needed to come up to speed on Django for a new job and I was able to read through this book and get a good sense of the framework. The book not only explains the mechanics but also the philosophy that guides the design. As an experienced developer who is new to Django it was at the perfect level for me. I wouldn't recommend this book to a beginner developer - you should have experience with both Python and web development before picking it up.
Having python and C++ experience, I was able to learn and get several Django examples working with this book, but not without the help of googling the internet and help from colleagues to get started. The reason is that there are some details that have changed in later versions of django. Once I got over the initial hurdles, I got a great deal out of the book and got many of the examples to work.
This book gives you that same transcendant feeling you get when you first start to understand Python. I found myself audibly saying "Aw yeah!" several times while reading it. Plus, it's very accessible: the gentle learning curve allows even an MVC newb like me to actually get what's going on. I'll never have to use PHP again!
I felt like I understand django quite a bit more now, and got some general tips for python web programming. I don't actually use django very much at the moment, so I can't fully assess it, but I'm confident it will shave some time off the next time I am called to get a python website up and running quickly.
I actually read the free online version of this book (in which all of the image links were broken - a fate that the print book surely does not share). Although I've been programming in Django for a few years now, this book was a great quick read to learn some of the philosophy behind Django and a few useful features I had been too afraid to use
Before you buy this book you may want to start by reading the django documentation online (). If your new to Django or just need a solid reference then i recommend this is the book for you.
Extremely helpful for someone learning the Django web development framework. But also out of date by 6 years, which is an eternity in the computer software genre.