Fixed errors reported by pylint