Write a script that takes IN a request like ‘1-request.txt’ (see ctb/meep, master branch, util/TinyHTTPProxy/add-msg) and OUTPUT a request like ‘1-response.txt’. Only worry about reading in & outputting the header components that you “know” how to do deal with (e.g. cookies).
Adhere to the HTTP protocol, please, but only worry about GET requests for now.
Call the script ‘miniapp.py’ and put it in the main directory, please.
For more info, see: http://www.jmarshall.com/easy/http/ and PEP-333.
Update your code to use Jinja2 templates (see ctb/meep, master). As much HTML as is possible should be in templates.
Update your tests to all be run (and pass) under ‘nose’, including the twill tests – you can modify test_app.py to do this, or create a new file ‘test_twill’ that uses the Python API to run twill.