Skip to content
Snippets Groups Projects
Commit 258a66b5 authored by Ian's avatar Ian Committed by Ian
Browse files

fix: propagate KeyboardInterrupt in Job and JobManager.submit()

parent 227157db
No related branches found
No related tags found
No related merge requests found
......@@ -31,6 +31,8 @@ class Job:
"""Call a MAAP function, catch and log exceptions."""
try:
return fn(*args, **kwargs)
except KeyboardInterrupt:
raise
except Exception as e:
logging.error(f"MAAP API error in {fn.__name__}: {e}")
return None
......
......@@ -54,6 +54,8 @@ class JobManager:
job.submit()
self.ledger.add_job(job)
job_batch_counter += 1
except KeyboardInterrupt:
raise
except Exception as e:
logging.error(f"Error submitting job: {e}")
continue
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment