support py3k
halfway through
more fixes
nearly finished