Emulating nested optgroups in Django Forms

Some motivation Django has a field called ChoiceField which lets you very easily create a <select> dropdown in your forms. A great feature is the ability to transform nested choices into appropriate <optgroup> groups. For instance, the following code: …creates a field that when rendered looks something like this:   The HTML that Django produced looks […]

A basic “man-in-the-middle” proxy with Twisted

[OUTDATED – It has been a while since I looked at this, so it’s probably very outdated. Please check the comments.] I came across a nice example of a Twisted “man-in-the-middle” style proxy on Stack Overflow. This style of proxy is great for logging traffic between two endpoints, as well as modifying the requests and […]

Hack a Guitar Hero drumset to use it with any computer over USB, Part 5

< < Part 4   BitBucket repository is live: https://bitbucket.org/MostThingsWeb/usbdrumming/src In the final post in this five part series, I’ll develop a client side application in Python to communicate with our drumset which was modified in part 4. The final result will be a simple command line interface (for now) that looks like this:   […]