Fix full build notification logic #3058
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
PR Overview
I noticed my full build
271ffc37d3e7a7253beb9bb74ec2ea6585b92e0a-rename-core-assets
passed all of the validation tests but thepudl-deployments
channel was received a failure notification. I think this happened because #3018 changed the script to catch any errors that happened during the data distribution and datasette publishing:pudl/docker/gcp_pudl_etl.sh
Lines 92 to 116 in 2493454
This logic does not work if we have a successful build that isn't kicked off from the
dev
branch. The first if statement will evaluate to true because the build succeeded, the inner two if statements will evaluate to false because the branch is not dev. The final if statement to determine if slack should be notified will also be false because the previous two if statements exit codes are non-zero.To resolve this issue, I created a
ETL_SUCCESS
variable to track failures during the distribution and publishing steps.PR Checklist
dev
).