From 3fe51b951e54dbe3149735d6a73cff1ccee12818 Mon Sep 17 00:00:00 2001 From: maxi297 Date: Wed, 11 Jan 2023 09:27:30 -0500 Subject: [PATCH 1/6] [ISSUE #19981] adding slack notification to airbyte cdk release --- .../publish-cdk-command-manually.yml | 112 ++++++++++++++++++ 1 file changed, 112 insertions(+) diff --git a/.github/workflows/publish-cdk-command-manually.yml b/.github/workflows/publish-cdk-command-manually.yml index 7fae6ce9e4dc..8d1b0238b474 100644 --- a/.github/workflows/publish-cdk-command-manually.yml +++ b/.github/workflows/publish-cdk-command-manually.yml @@ -58,6 +58,34 @@ jobs: commit_message: 🤖 Bump ${{ github.event.inputs.release-type }} version of Airbyte CDK commit_user_name: Octavia Squidington III commit_user_email: octavia-squidington-iii@users.noreply.github.com + - name: Post failure to Slack channel dev-connectors-extensibility + if: !success() + uses: slackapi/slack-github-action@v1.23.0 + continue-on-error: true + with: + channel-id: C02TL38U5L7 + payload: | + { + "text": "Error while publishing Airbyte CDK!" + "blocks": [ + { + "type": "section", + "text": { + "type": "mrkdwn", + "text": "Error while publishing Airbyte CDK!" + } + }, + { + "type": "section", + "text": { + "type": "mrkdwn", + "text": "See details on \n" + } + } + ] + } + env: + SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN_AIRBYTE_TEAM }} build-cdk: needs: bump-version @@ -77,6 +105,34 @@ jobs: ref: ${{ github.event.inputs.gitref }} - name: Build CDK Package run: SUB_BUILD=CONNECTORS_BASE ./gradlew --no-daemon --no-build-cache :airbyte-cdk:python:build + - name: Post failure to Slack channel dev-connectors-extensibility + if: !success() + uses: slackapi/slack-github-action@v1.23.0 + continue-on-error: true + with: + channel-id: C02TL38U5L7 + payload: | + { + "text": "Error while publishing Airbyte CDK!" + "blocks": [ + { + "type": "section", + "text": { + "type": "mrkdwn", + "text": "Error while publishing Airbyte CDK!" + } + }, + { + "type": "section", + "text": { + "type": "mrkdwn", + "text": "See details on \n" + } + } + ] + } + env: + SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN_AIRBYTE_TEAM }} publish-cdk: needs: build-cdk @@ -109,3 +165,59 @@ jobs: env: TWINE_PASSWORD: ${{ secrets.TWINE_PASSWORD }} TWINE_USERNAME: ${{ secrets.TWINE_USERNAME }} + - name: Post success to Slack channel dev-connectors-extensibility + if: success() + uses: slackapi/slack-github-action@v1.23.0 + continue-on-error: true + with: + channel-id: C02TL38U5L7 + payload: | + { + "text": "A new version of Airbyte CDK has been released!" + "blocks": [ + { + "type": "section", + "text": { + "type": "mrkdwn", + "text": "A new version of Airbyte CDK has been released!\n\n" + } + }, + { + "type": "section", + "text": { + "type": "mrkdwn", + "text": "See details on and \n" + } + } + ] + } + env: + SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN_AIRBYTE_TEAM }} + - name: Post failure to Slack channel dev-connectors-extensibility + if: !success() + uses: slackapi/slack-github-action@v1.23.0 + continue-on-error: true + with: + channel-id: C02TL38U5L7 + payload: | + { + "text": "Error while publishing Airbyte CDK!" + "blocks": [ + { + "type": "section", + "text": { + "type": "mrkdwn", + "text": "Error while publishing Airbyte CDK!" + } + }, + { + "type": "section", + "text": { + "type": "mrkdwn", + "text": "See details on \n" + } + } + ] + } + env: + SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN_AIRBYTE_TEAM }} From 45424fa2872fd2fa390ad381ac132a14fcdaee39 Mon Sep 17 00:00:00 2001 From: maxi297 Date: Fri, 13 Jan 2023 14:22:54 -0500 Subject: [PATCH 2/6] [ISSUE #19981] change default release-type and change slack channel --- .github/workflows/publish-cdk-command-manually.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/publish-cdk-command-manually.yml b/.github/workflows/publish-cdk-command-manually.yml index 8d1b0238b474..f017113f2dff 100644 --- a/.github/workflows/publish-cdk-command-manually.yml +++ b/.github/workflows/publish-cdk-command-manually.yml @@ -14,10 +14,10 @@ on: type: choice description: "Choose the type of version upgrade : major|minor|patch" options: + - none - major - minor - patch - - none required: true skip-publish-test: description: 'By default, the job publishes to Test PyPi. Use "true" to only publish to actual PyPi servers.' @@ -63,7 +63,7 @@ jobs: uses: slackapi/slack-github-action@v1.23.0 continue-on-error: true with: - channel-id: C02TL38U5L7 + channel-id: C04J1M66D8B payload: | { "text": "Error while publishing Airbyte CDK!" @@ -110,7 +110,7 @@ jobs: uses: slackapi/slack-github-action@v1.23.0 continue-on-error: true with: - channel-id: C02TL38U5L7 + channel-id: C04J1M66D8B payload: | { "text": "Error while publishing Airbyte CDK!" @@ -170,7 +170,7 @@ jobs: uses: slackapi/slack-github-action@v1.23.0 continue-on-error: true with: - channel-id: C02TL38U5L7 + channel-id: C04J1M66D8B payload: | { "text": "A new version of Airbyte CDK has been released!" @@ -198,7 +198,7 @@ jobs: uses: slackapi/slack-github-action@v1.23.0 continue-on-error: true with: - channel-id: C02TL38U5L7 + channel-id: C04J1M66D8B payload: | { "text": "Error while publishing Airbyte CDK!" From 91ebc2327e2ffe29d38c075db6b1acba954741e3 Mon Sep 17 00:00:00 2001 From: maxi297 Date: Mon, 16 Jan 2023 08:53:24 -0500 Subject: [PATCH 3/6] [ISSUE #19981] code review - precising error messages --- .github/workflows/publish-cdk-command-manually.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/publish-cdk-command-manually.yml b/.github/workflows/publish-cdk-command-manually.yml index f017113f2dff..6a62862f4a22 100644 --- a/.github/workflows/publish-cdk-command-manually.yml +++ b/.github/workflows/publish-cdk-command-manually.yml @@ -66,7 +66,7 @@ jobs: channel-id: C04J1M66D8B payload: | { - "text": "Error while publishing Airbyte CDK!" + "text": "Error during `bump-version` while publishing Airbyte CDK!" "blocks": [ { "type": "section", @@ -113,7 +113,7 @@ jobs: channel-id: C04J1M66D8B payload: | { - "text": "Error while publishing Airbyte CDK!" + "text": "Error during `build-cdk` while publishing Airbyte CDK!" "blocks": [ { "type": "section", @@ -201,7 +201,7 @@ jobs: channel-id: C04J1M66D8B payload: | { - "text": "Error while publishing Airbyte CDK!" + "text": "Error during `publish-cdk` while publishing Airbyte CDK!" "blocks": [ { "type": "section", From deb49cbc60de6e79d6e514d7927cedbaed3f0bf8 Mon Sep 17 00:00:00 2001 From: maxi297 Date: Tue, 17 Jan 2023 08:24:23 -0500 Subject: [PATCH 4/6] commit for CI From 243227d3db54d057477fba6410cd6758f04a4112 Mon Sep 17 00:00:00 2001 From: maxi297 Date: Tue, 17 Jan 2023 10:27:32 -0500 Subject: [PATCH 5/6] commit for CI From 845642114888a9d3748232a0e38f6f516e34e1a4 Mon Sep 17 00:00:00 2001 From: maxi297 Date: Tue, 17 Jan 2023 13:47:55 -0500 Subject: [PATCH 6/6] commit for CI