These are the articles I’ve written about technical, programming-related topics in order to share some of the experience I’ve had with Python, web development, and various other topics.
More than once I've had to take a list of items and group them into tuples. Here's the code.
XSLT can be used to expand a simple <youtube> XML element into a full, XHTML-compliant <object> element that embeds a YouTube video.
What's fast, easy to set up, and good for running web applications? Lighttpd and Pylons!
Sometimes it's useful to be able to determine your external WAN IP address from a script. Here's a simple Lua/Lighttpd approach.
How to run more than one Pylons app, on different domains, in the same Python process.
This will show you how to get a Pylons web app running on Google App Engine in about 15 minutes, assuming you already have a GAE account and a passing familiarity with Pylons and virtualenv.
Supervisor is a well-documented, convenient process manager that can help you wrangle multiple long-running processes like Pylons apps and lighttpd.
Creating by hand what code generation would ordinarily do for you helps you understand Pylons and port existing apps to the Pylons deployment scheme.
Using Pylons (or Paste Deploy), filters are a configurable way to apply WSGI middleware to your application without code changes.
Eventually, you realize that the name you gave your Pylons app conflicts with another package, or just needs to be changed. Here's what to do.
Sample code for n-choose-k in Python, C using Python bignums, and C using GMP. Guess which one is fastest?
Some custom Python code makes it easy to embed YouTube videos in reStructuredText documents that are converted to HTML.
How and why Python's self argument makes it tricky, and possibly not a good idea, to mix function decorators and WSGI
Quick tip on how to dynamically add bound methods to objects in Python, which is distinct from dynamically adding new methods to classes.
Here's a useful Python snippet that shows the basics of using formencode to validate form submissions inside a typical web application controller.
Python Imaging Library may need an extra command-line option to install on Intel Macs (as may similar libraries)