The register_exit_trap_cmd function allows to register multiple commands to execute at EXIT, with a priority order.
As a consequence, whenever a run exits (succeeds or fail) the GitHub log shows logs that are related to the registered trapped commands.
This is also valid when the run fails, and it means that after the failure and error message, the GitHub log shows other logs related to the trapped commands that might succeed without issues (usually cleanup operations).
This makes the error more difficult to identify at fist glance.
Add text to the trapped commands to indicate the start of the trapped commands log.
Something like:
=================================
BEGINNING OF EXIT TRAPPED COMMANDS
=================================
The
register_exit_trap_cmdfunction allows to register multiple commands to execute at EXIT, with a priority order.As a consequence, whenever a run exits (succeeds or fail) the GitHub log shows logs that are related to the registered trapped commands.
This is also valid when the run fails, and it means that after the failure and error message, the GitHub log shows other logs related to the trapped commands that might succeed without issues (usually cleanup operations).
This makes the error more difficult to identify at fist glance.
Add text to the trapped commands to indicate the start of the trapped commands log.
Something like: