Summary
When a script decorated with @stx.session raises an exception, the output shows:
SUCC: Congratulations! The script completed: .../FINISHED_ERROR/...
The directory is correctly named FINISHED_ERROR, but the prefix SUCC: Congratulations! is misleading — it implies success when the script actually errored.
Expected Behavior
On error, the message should reflect the failure:
ERRO: Script failed: .../FINISHED_ERROR/...
Or at minimum, not use SUCC: prefix or "Congratulations" when the exit status is error.
Reproduction
@stx.session
def main(CONFIG=stx.session.INJECTED):
raise ValueError("something went wrong")
return 0
Output:
ERRO: Error in main: something went wrong
SUCC: Congratulations! The script completed: .../FINISHED_ERROR/...
Location
Likely in src/scitex/session/_decorator.py around the session cleanup/finalization logic.
Summary
When a script decorated with
@stx.sessionraises an exception, the output shows:The directory is correctly named
FINISHED_ERROR, but the prefixSUCC: Congratulations!is misleading — it implies success when the script actually errored.Expected Behavior
On error, the message should reflect the failure:
Or at minimum, not use
SUCC:prefix or "Congratulations" when the exit status is error.Reproduction
Output:
Location
Likely in
src/scitex/session/_decorator.pyaround the session cleanup/finalization logic.