Refine code base on pylint