use modern Exception "as" for python3 support
change 0750 to 0o750 for python3 support
update doc for python 3 support