Skip to content

Commit

Permalink
docs(api): add a comment to explain why the monitoring loop must not …
Browse files Browse the repository at this point in the history
…raise exception
  • Loading branch information
laurent-laporte-pro committed May 2, 2023
1 parent f999c23 commit 31a61bb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions antarest/launcher/adapters/slurm_launcher/slurm_launcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,9 +148,12 @@ def _retrieve_running_jobs(self) -> None:

def _loop(self) -> None:
while self.check_state:
# noinspection PyBroadException
try:
self._check_studies_state()
except Exception:
# To keep the SLURM processing monitoring loop active, exceptions
# are caught and a message is simply displayed in the logs.
logger.error(
"An uncaught exception occurred in slurm_launcher loop",
exc_info=True,
Expand Down

0 comments on commit 31a61bb

Please sign in to comment.