From 733670817bb5df5efb5da77b89c1ec39b853a9ee Mon Sep 17 00:00:00 2001 From: Shunsuke Shimizu Date: Wed, 6 Apr 2022 23:24:20 +0900 Subject: [PATCH] Sort files to make output more readable (#11) * sort files to make output more readable * drop import of Set, not yet used --- pysen/lint_command.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/pysen/lint_command.py b/pysen/lint_command.py index b629dbf..efd767f 100644 --- a/pysen/lint_command.py +++ b/pysen/lint_command.py @@ -2,7 +2,7 @@ import logging import pathlib from abc import abstractmethod -from typing import Iterable, List, Optional, Sequence, Set +from typing import Iterable, List, Optional, Sequence from . import git_utils from .command import CommandBase @@ -18,13 +18,14 @@ def __init__(self, base_dir: pathlib.Path, source: Source) -> None: def _get_sources( self, reporter: Reporter, filter_predicate: FilePredicateType - ) -> Set[pathlib.Path]: - return self.source.resolve_files( + ) -> List[pathlib.Path]: + sources = self.source.resolve_files( self.base_dir, filter_predicate, self.git_enabled(), reporter, ) + return sorted(sources) def _get_covered_files( self,