Fix some python3 errors.  Tests pass in python3, but no testing
in a python 3 app yet.