Fix mistakes pointed out by pylint in 3 previous commits