Doug Hellmann, a Python developer, writes Python Module of the Week, a series of tutorials on the standard library, plus performance notes.
HN commenters often recommend PyMOTW and his book 'The Python Standard Library by Example' as the best way to learn the standard library.
I'm a guy from a C/C++ background who did linux kernel development, and picked up python along the way and used it to do desktop tools. I used python (without knowing any of it) to write a disassembler for a project I was doing in 2003 on a non-x86 processor. It took me 5 days to learn the language enough to do so and to write the entire tool, at which point I "got it".
First off, Java isn't a toy language. You've characterized it improperly. Java is a bureaucratic language. You have to cross your t's dot your i's, fill out your requests in triplicate at the FactoryFactoryFactory to get the objectOfYourDesire. Why is this so?
This comes back to how C++ works on projects, especially large projects and midsize projects with a couple mediocre programmers thrown in (because, in commercial software development, you rarely get control of your team). C++ does not work well for large team development unless 1> You have very capable people 2> and you can fire everyone who steps outside the "defined okay subset" of C++ you use on the project. The language is too big, certain parts make it too uncertain, etc, for people to just willy nilly use all the language features. So Java, is basically Sun's "redoing" of C++ where they took its wild west nature, and made a BureauDisney version where you can't do a dozen things that happens in C++ all the time when good programmers go off the reservation or bad programmers enter the equation at all.
C++ has uses, but it's the sulfuric acid of…
I'm surprised nobody has mentioned Doug Hellman's great resources. His book "The Python Standard Library by Example" is basically a print version of his PyMOTW project (http://www.doughellmann.com/PyMOTW/). While not an end to end "learn Python" the examples, at least in my case, have led me to ask quite a few questions that open other doors into Python that I haven't been exposed to.
I like what Zed has put out, but the books Lutz has out are great as well. Hetland's book is OK and Paul Barry's "Head First Python" is a great read if you're a true beginner to get your feet wet with a fun book. It's an easy read, but I would think that the transition to "Learning Python" would feel like a slight step backwards - however "Programming Python" by Lutz may be a better logical step (instead of going back through a lot of the basics).
I think you missed my point.
I agree that for trivial regex it's useless. For instance (directly taken from Python doc) in this case:
a = re.compile(r"""\d + # the integral part
\. # the decimal point
\d * # some fractional digits""", re.X)
b = re.compile(r"\d+\.\d*")
that's useless. But for more complex problems it may be useful (e.g. http://www.doughellmann.com/PyMOTW/re/ I know email matching regexes are not really complex or even a good example of use of regexes but that's the first example I found).
Another point is that even if I can read/write (that's the case) regexes other people may have to deal with my code and it's a well known fact that many people doesn't understand/like regex, so splitting them in small "chunks" may help them.
I usually deploy it is nginx => Django FastCGI via flup. Make sure to use prefork instead of threaded method. On top of that I run each Django project inside individual virtualenv's [1], where virtualenvwrapper [2] simplifies the process. Since all my servers are Debian-based, I use my own creation called flint [3] to automatically start/stop the FastCGI processes on boot/shutdown. For deploying code I use fabric [4] and then simply $ flint restart_all or $ flint restart myproject to reload the code.
[1] virtualenv - http://virtualenv.openplans.org/
[2] virtualenvwrapper - http://www.doughellmann.com/projects/virtualenvwrapper/
[3] flint - http://igorpartola.com/projects/flint
[4] fabric - http://docs.fabfile.org/0.9.2/
I would definitely recommend sync'ing the python subversion tree and picking a few modules and reading through them. Doing so taught me some of the less obvious things within the language, and also taught me a lot about the various dunder (__foo__) methods for objects.
Additionally, I'd recommend reading through the PEP documents (http://python.org/dev/peps/) - there's a lot of great examples and rationales contained in those.
Finally, Doug hellmann has done an excellent job with his Python Module of the Week series (http://www.doughellmann.com/PyMOTW/) and a new project "The hazel tree" (http://www.thehazeltree.org/) is doing a great job at compiling the various examples, docs/etc together in one place.
The Python standard has some pure Python modules may be worth looking at. Doug Hellmann's Python Module of the Week, http://www.doughellmann.com/PyMOTW/contents.html, is good place to start.
I'd recommend looking at code that interests you. It will make reading the code more interesting and perhaps more useful. Here are some popular projects arrange by interest:
Web framework: Django, Pylons
TCP/IP networking: the official Bittorrent client, Mercurial, Tornado
Database: SQLAlchemy, SQLObject
Past HN submissions are generally a good place to find interesting projects too: http://searchyc.com/submissions/python?sort=by_points