From 9a201cf9a92cb3f8c427eaec6989b4b48cc5f6a7 Mon Sep 17 00:00:00 2001 From: sushi30 Date: Fri, 27 Sep 2024 09:38:28 +0200 Subject: [PATCH 1/3] trying to add job id to logs --- .github/workflows/py-cli-e2e-tests.yml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/py-cli-e2e-tests.yml b/.github/workflows/py-cli-e2e-tests.yml index 9a92c6923bd3..e87ce56e2f3a 100644 --- a/.github/workflows/py-cli-e2e-tests.yml +++ b/.github/workflows/py-cli-e2e-tests.yml @@ -188,14 +188,17 @@ jobs: cd ./docker/development docker compose down --remove-orphans sudo rm -rf ${PWD}/docker-volume - + + - uses: austenstone/job-id@v1 + id: job-id + - name: Slack on Failure if: steps.e2e-test.outcome != 'success' && steps.python-e2e-test.outcome != 'success' && env.DEBUG == 'false' uses: slackapi/slack-github-action@v1.23.0 with: payload: | { - "text": "🔥 Failed E2E Test for: ${{ matrix.e2e-test }} 🔥\nLogs: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}\nCommit: ${{ github.server_url }}/${{ github.repository }}/commit/${{ github.sha }}" + "text": "🔥 Failed E2E Test for: ${{ matrix.e2e-test }} 🔥\nLogs: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}/job/${{ steps.job-id.outputs.job-id }}" } env: SLACK_WEBHOOK_URL: ${{ secrets.E2E_SLACK_WEBHOOK }} From 6628fa8e79a425a935144d81cad9505db198dd9b Mon Sep 17 00:00:00 2001 From: sushi30 Date: Fri, 27 Sep 2024 09:47:21 +0200 Subject: [PATCH 2/3] set debug if branch is main --- .github/workflows/py-cli-e2e-tests.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/py-cli-e2e-tests.yml b/.github/workflows/py-cli-e2e-tests.yml index e87ce56e2f3a..2dd7dedc61ba 100644 --- a/.github/workflows/py-cli-e2e-tests.yml +++ b/.github/workflows/py-cli-e2e-tests.yml @@ -20,12 +20,12 @@ on: required: True default: '["bigquery", "dbt_redshift", "metabase", "mssql", "mysql", "redash", "snowflake", "tableau", "powerbi", "vertica", "python", "redshift", "quicksight", "datalake_s3", "postgres", "oracle", "athena", "bigquery_multiple_project"]' debug: - description: "If Debugging the Pipeline, Slack and Sonar events won't be triggered" + description: "If Debugging the Pipeline, Slack and Sonar events won't be triggered ["default", "true", "false"]" required: False - default: "false" + default: "default" env: - DEBUG: ${{ inputs.debug || 'false' }} + DEBUG: ${{ inputs.debug == 'true' || (inputs.debug == 'default' && github.ref != 'refs/heads/main') }}' }} permissions: id-token: write From 87ee9096f8d982bcb99419bc06ed6af74b7872e3 Mon Sep 17 00:00:00 2001 From: sushi30 Date: Mon, 30 Sep 2024 10:25:20 +0200 Subject: [PATCH 3/3] fixed yaml --- .github/workflows/py-cli-e2e-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/py-cli-e2e-tests.yml b/.github/workflows/py-cli-e2e-tests.yml index 2dd7dedc61ba..af0e8a79953e 100644 --- a/.github/workflows/py-cli-e2e-tests.yml +++ b/.github/workflows/py-cli-e2e-tests.yml @@ -20,7 +20,7 @@ on: required: True default: '["bigquery", "dbt_redshift", "metabase", "mssql", "mysql", "redash", "snowflake", "tableau", "powerbi", "vertica", "python", "redshift", "quicksight", "datalake_s3", "postgres", "oracle", "athena", "bigquery_multiple_project"]' debug: - description: "If Debugging the Pipeline, Slack and Sonar events won't be triggered ["default", "true", "false"]" + description: "If Debugging the Pipeline, Slack and Sonar events won't be triggered [default, true or false]" required: False default: "default"