Skip to content

Commit

Permalink
move already post-processed check to post_process_all
Browse files Browse the repository at this point in the history
  • Loading branch information
diitaz93 committed Oct 11, 2024
1 parent 6a1cf61 commit a880b6f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
3 changes: 3 additions & 0 deletions cg/services/run_devices/abstract_classes.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,9 @@ def post_process_all(self, run_directory_names: list[str], dry_run: bool = False
LOG.info("Starting post-processing for all runs")
is_post_processing_successful = True
for run_name in run_directory_names:
if self._is_run_post_processed(run_name):
LOG.info(f"Run {run_name} has already been post-processed")
continue
try:
self.post_process(run_name=run_name, dry_run=dry_run)
except Exception as error:
Expand Down
3 changes: 0 additions & 3 deletions cg/services/run_devices/pacbio/post_processing_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,6 @@ def __init__(
to_raise=PostProcessingError,
)
def post_process(self, run_name: str, dry_run: bool = False) -> None:
if self._is_run_post_processed(run_name):
LOG.info(f"Run {run_name} has already been post-processed")
return
LOG.info(f"Starting Pacbio post-processing for run: {run_name}")
run_data: PacBioRunData = self.run_data_generator.get_run_data(
run_name=run_name, sequencing_dir=self.sequencing_dir
Expand Down

0 comments on commit a880b6f

Please sign in to comment.