Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions docs/config_reference.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1321,6 +1321,8 @@ General Configuration

Trap command errors in the generated job scripts and let them exit immediately.

.. versionadded:: 3.2


.. js:attribute:: .general[].keep_stage_files

Expand Down
4 changes: 3 additions & 1 deletion docs/manpage.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1113,7 +1113,7 @@ Here is an alphabetical list of the environment variables recognized by ReFrame:

.. envvar:: RFM_TRAP_JOB_ERRORS

Ignore job exit code
Trap job errors in submitted scripts and fail tests automatically.

.. table::
:align: left
Expand All @@ -1122,6 +1122,8 @@ Here is an alphabetical list of the environment variables recognized by ReFrame:
Associated configuration parameter :js:attr:`trap_job_errors` general configuration parameter
================================== ==================

.. versionadded:: 3.9.0


.. envvar:: RFM_UNLOAD_MODULES

Expand Down
7 changes: 7 additions & 0 deletions reframe/frontend/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -530,6 +530,13 @@ def main():
configvar='logging/handlers_perflog/syslog_address',
help='Syslog server address'
)
argparser.add_argument(
dest='trap_job_errors',
envvar='RFM_TRAP_JOB_ERRORS',
configvar='general/trap_job_errors',
action='store_true',
help='Trap job errors in job scripts and fail tests automatically'
)
argparser.add_argument(
dest='use_login_shell',
envvar='RFM_USE_LOGIN_SHELL',
Expand Down