Some pylint-inspired clean-up. Also added pylint test to Travis.