python3 support, pep8 and quotes, small fixes