Skip to content

Commit

Permalink
Revert "Annotate re-raised exception instead of logging it."
Browse files Browse the repository at this point in the history
This reverts commit 7b1fce0.

This logging was duplicative when seen from STDERR, which also gets
exception tracebacks that propagate up, but we need error messages and
tracebacks to appear in the saved logs, too, and this is the only
place we can do that.
  • Loading branch information
TallJimbo committed Aug 26, 2024
1 parent ed11321 commit 2015b74
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion python/lsst/ctrl/mpexec/singleQuantumExecutor.py
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,13 @@ def _execute(self, task_node: TaskNode, /, quantum: Quantum) -> Quantum:
try:
self.runQuantum(task, quantum, task_node, limited_butler)
except Exception as e:
e.add_note(f"Execution of task {task_node.label!r} on quantum {quantum.dataId} failed.")
_LOG.error(
"Execution of task '%s' on quantum %s failed. Exception %s: %s",
task_node.label,
quantum.dataId,
e.__class__.__name__,
str(e),
)
raise
logInfo(None, "end", metadata=quantumMetadata) # type: ignore[arg-type]
fullMetadata = task.getFullMetadata()
Expand Down

0 comments on commit 2015b74

Please sign in to comment.