diff --git a/src/cplus_plugin/api/scenario_task_api_client.py b/src/cplus_plugin/api/scenario_task_api_client.py index edf3ad7c..bc16662f 100644 --- a/src/cplus_plugin/api/scenario_task_api_client.py +++ b/src/cplus_plugin/api/scenario_task_api_client.py @@ -319,6 +319,13 @@ def upload_layers(self) -> typing.Union[bool, None]: {"progress_text": "Checking layers to be uploaded", "progress": 0} ) masking_layers = self.get_masking_layers() + masking_layers.extend( + [ + mask_path + for activity in self.analysis_activities + for mask_path in activity.mask_paths + ] + ) # 2 comes from sieve_mask_layer and snap layer check_counts = len(self.analysis_activities) + 2 + len(masking_layers) @@ -404,7 +411,6 @@ def upload_layers(self) -> typing.Union[bool, None]: ) files_to_upload.update(self.check_layer_uploaded(items_to_check)) - if self.processing_cancelled: return False diff --git a/src/cplus_plugin/tasks.py b/src/cplus_plugin/tasks.py index a8bd802b..d891fafe 100644 --- a/src/cplus_plugin/tasks.py +++ b/src/cplus_plugin/tasks.py @@ -160,13 +160,6 @@ def get_masking_layers(self) -> typing.List: ) masking_layers = masking_layers_paths.split(",") if masking_layers_paths else [] masking_layers.remove("") if "" in masking_layers else None - masking_layers.extend( - [ - mask_path - for activity in self.analysis_activities - for mask_path in activity.mask_paths - ] - ) return masking_layers def cancel_task(self, exception=None):