WIP: Better py3k support

ping @warrd, feel free to send me PRs so we can work in parallel