Ask HN: Structured approach to learning Python/Django

11 points by naithemilkman ↗ HN
Can anyone recommend a sequential order of books and resources to read and learn to learn Python and Django?

Suppose my objective is to create a simple webapp and host it on Google App Engine, what should I be reading when?

I've started with Learning Python the Hardway and I'm currently going through Head First Python. Next up on my reading list is The Definitive Guide to Django Web Development Done Right.

10 comments

[ 4.2 ms ] story [ 27.8 ms ] thread
If you're looking to host on App Engine, I strongly recommend http://oreilly.com/catalog/9780596522735

It is a great intro to App Engine & the datastore generally but also puts a bit more emphasis on Python/Django than on Java development, so it is well suited for Python devs.

Django's own documentation is extremely good. You can work through its tutorials to get going.

But start with a python tutorial. I don't know which is the best, but other people should be able to help you.

I would suggest this order of learning though:

1. Python 2. Django 3. App Engine

Each introduces its own elements, so you're better proceeding step by step. Obviously you don't have to master python to get going with django, but you want to be comfortable.

The first step is to learn python. If you already know how to program this should be quick (< 72 hrs) following the official tutorial:

http://docs.python.org/tutorial/

The second thing, go through the django tutorial which should take < 48 hrs:

http://docs.djangoproject.com/en/1.2/intro/tutorial01/

Third, come up with a project for yourself and start trying to make it happen using the django docs and stackoverflow as references. This is the most important step. Don't worry too much about the right way to do things or efficiency, just get something working.

Also, don't worry about deploying your app (i.e. getting it running behind nginx, etc). Just use a sqlite3 database and the django dev server until you're comfortable with the different pieces of django.

Take a look at how the generic views, the contrib apps, and the popular 3rd party apps are written to get some feel for what are good practices in writing apps.

So you reckon dump google app engine and get going first?
Just launched my first webapp, built to teach myself Python and Django. Don't get too wrapped up in books and just think of a webapp to build... and then do it. I know infinitely more now because I would think, "I need so and so" and through Googling/Stack Overflow/friends, I'd figure out how to launch it.

I did Learn Python the Hard Way to start, then the main Django tutorial as well as Kenneth Love's blog tutorial at http://gigantuan.net/ (as well as lots of random tutorials/blog posts). Otherwise, I haven't read any books.

The app launched last night: http://www.weddinginvitelove.com

tl;dr: Make sure you're learning by doing. Make a random web app, it'll help things "stick" way faster.

how long did you take to launch that? did you do all the graphics/html/css as well? it looks really impressive! good job!
I started in early December, I think? Graphics/html/css were my specialty before, so that wasn't the hard part... took me quite a few weeks to wrap the concept of Django around my head.

Thanks!

I've been through Django's docs several times and also bought the book from Kaplan Moss (don't recall the name, for v. 0.96). I read most of the book a couple of times. It took me more than a year to actually do something that worked, most of the stuff was just experimenting. Now that I have something that works I find myself learning more stuff about Python and Django itself.

So what I'd say is try to do something very simple that you would actually use. Perhaps a to-do list or some sort of notepad? In my case it was just some sort of a video bookmarking app (actually I spent more time on the design/front-end than the backend).

Yeah, exactly what I was trying to say — WIL was an app I've wanted to build for a long time and I used it to learn Django too.

I wouldn't worry about whether you're copying an existing app as well — just make something that interests you.