shoving .encode() on the end seems to make stuff appear as a bytestring in the console output under py3k. Removing it fixes it.