You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request. Searching for pre-existing feature requests helps us consolidate datapoints for identical requirements into a single place, thank you!
Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request.
If you are interested in working on this issue or have submitted a pull request, please leave a comment.
Overview of the Issue
If a pre or post workflow hook script errors with a non zero exit code, any output from the script is not logged.
{"level":"info","ts":"2023-05-20T12:06:43.863+0100","caller":"runtime/pre_workflow_hook_runner.go:77","msg":"successfully ran \"echo \\\"test line 1\\\" && exit 0\" in \"atlantis-test\\\\1\\\\default\"","json":{"repo":"X-Guardian/atlantis-test","pull":"1"}}
{"level":"error","ts":"2023-05-20T12:06:44.831+0100","caller":"events/command_runner.go:293","msg":"Error running pre-workflow hooks exit status 1: running \"echo \\\"test line 2\\\" && exit 1\" in \"atlantis-test\\\\1\\\\default\": \ntest line 2\n. Proceeding with plan command.","json":{"repo":"X-Guardian/atlantis-test","pull":"1"},"stacktrace":"github.com/runatlantis/atlantis/server/events.(*DefaultCommandRunner).RunCommentCommand\n\tC:/Users/Simon/Documents/GitHub/X-Guardian/atlantis/server/events/command_runner.go:293"}
Output Screenshot
Environment details
Atlantis version: 0.23.5
Deployment method: local
If not running the latest Atlantis version have you tried to reproduce this issue on the latest version: n/a
Atlantis flags: none
Atlantis server-side config file: none
Additional Context
The OutputHandler.SendWorkFlowHook calls in these functions should be before the error handling blocks:
Community Note
Overview of the Issue
If a pre or post workflow hook script errors with a non zero exit code, any output from the script is not logged.
Reproduction Steps
repos.yaml:
Logs
Logs
Output Screenshot
Environment details
0.23.5
Additional Context
OutputHandler.SendWorkFlowHook
calls in these functions should be before the error handling blocks:atlantis/server/core/runtime/pre_workflow_hook_runner.go
Lines 53 to 75 in f740d62
atlantis/server/core/runtime/post_workflow_hook_runner.go
Lines 53 to 75 in f740d62
The text was updated successfully, but these errors were encountered: