Commit f15ab7e7 authored by BO ZHANG's avatar BO ZHANG 🏀
Browse files

annotate type for Pipeline attributes

parent 0fc295bf
Loading
Loading
Loading
Loading
+12 −12
Original line number Diff line number Diff line
@@ -79,25 +79,25 @@ class Pipeline:
        **kwargs: Any,
    ):
        # get pipeline information from env vars
        self.pipeline_id = os.getenv("PIPELINE_ID", "-")
        self.build = os.getenv("BUILD", "-")
        self.created = os.getenv("CREATED", "-")
        self.verbose = os.getenv("VERBOSE", None)
        self.pipeline_id: str = os.getenv("PIPELINE_ID", "-")
        self.build: str = os.getenv("BUILD", "-")
        self.created: str = os.getenv("CREATED", "-")
        self.verbose: bool = bool(os.getenv("VERBOSE", ""))

        # set directory information
        self.dir_input = dir_input
        self.dir_output = dir_output
        self.dir_temp = dir_temp
        self.dir_aux = dir_aux
        self.dfs_root = dfs_root
        self.ccds_root = ccds_root
        self.ccds_cache = ccds_cache
        self.dir_input: str = dir_input
        self.dir_output: str = dir_output
        self.dir_temp: str = dir_temp
        self.dir_aux: str = dir_aux
        self.dfs_root: str = dfs_root
        self.ccds_root: str = ccds_root
        self.ccds_cache: str = ccds_cache

        if clean_output_before_run:
            self.clean_output()

        # additional parameters
        self.kwargs = kwargs
        self.kwargs: dict = kwargs

        # set logger
        self.pipeline_logger = get_logger(