Skip to content

Commit dd595e8

Browse files
committed
#497 bump senzing-factory/github-action-install-senzing-sdk to @v5
1 parent 7479158 commit dd595e8

11 files changed

Lines changed: 83 additions & 97 deletions

.github/workflows/add-labels-standardized.yaml

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,7 @@ jobs:
1515
secrets:
1616
ORG_MEMBERSHIP_TOKEN: ${{ secrets.ORG_MEMBERSHIP_TOKEN }}
1717
MEMBERS: ${{ secrets.SENZING_MEMBERS }}
18-
uses: senzing-factory/build-resources/.github/workflows/add-labels-to-issue.yaml@v4
19-
20-
slack-notification:
21-
needs: [add-issue-labels]
22-
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.add-issue-labels.result) }}
23-
secrets:
2418
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
2519
SLACK_CHANNEL: ${{ secrets.SLACK_CHANNEL }}
26-
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v4
27-
with:
28-
job-status: ${{ needs.add-issue-labels.result }}
20+
uses: senzing-factory/build-resources/.github/workflows/add-labels-to-issue.yaml@v4
21+

.github/workflows/add-to-project-garage-dependabot.yaml

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -12,16 +12,9 @@ jobs:
1212
repository-projects: write
1313
secrets:
1414
PROJECT_RW_TOKEN: ${{ secrets.SENZING_GITHUB_PROJECT_RW_TOKEN }}
15+
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
16+
SLACK_CHANNEL: ${{ secrets.SLACK_CHANNEL }}
1517
uses: senzing-factory/build-resources/.github/workflows/add-to-project-dependabot.yaml@v4
1618
with:
1719
project: ${{ vars.SENZING_PROJECT_GARAGE }}
1820

19-
slack-notification:
20-
needs: [add-to-project-dependabot]
21-
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.add-to-project-dependabot.result) }}
22-
secrets:
23-
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
24-
SLACK_CHANNEL: ${{ secrets.SLACK_CHANNEL }}
25-
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v4
26-
with:
27-
job-status: ${{ needs.add-to-project-dependabot.result }}

.github/workflows/add-to-project-garage.yaml

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14,17 +14,10 @@ jobs:
1414
repository-projects: write
1515
secrets:
1616
PROJECT_RW_TOKEN: ${{ secrets.SENZING_GITHUB_PROJECT_RW_TOKEN }}
17+
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
18+
SLACK_CHANNEL: ${{ secrets.SLACK_CHANNEL }}
1719
uses: senzing-factory/build-resources/.github/workflows/add-to-project.yaml@v4
1820
with:
1921
project-number: ${{ vars.SENZING_PROJECT_GARAGE }}
2022
org: ${{ vars.SENZING_GITHUB_ACCOUNT_NAME }}
2123

22-
slack-notification:
23-
needs: [add-to-project]
24-
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.add-to-project.result) }}
25-
secrets:
26-
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
27-
SLACK_CHANNEL: ${{ secrets.SLACK_CHANNEL }}
28-
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v4
29-
with:
30-
job-status: ${{ needs.add-to-project.result }}

.github/workflows/build-distribution.yaml

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@ name: Build distribution
22

33
on: [push]
44

5+
concurrency:
6+
group: ${{ github.workflow }}-${{ github.head_ref || github.ref_name }}
7+
cancel-in-progress: true
8+
59
permissions:
610
contents: read
711

@@ -47,12 +51,11 @@ jobs:
4751
name: python-package-distributions
4852
path: dist/
4953

50-
slack-notification:
51-
needs: [build-distribution]
52-
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.build-distribution.result ) && github.ref_name == github.event.repository.default_branch }}
53-
secrets:
54-
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
55-
SLACK_CHANNEL: ${{ secrets.SLACK_CHANNEL }}
56-
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v4
57-
with:
58-
job-status: ${{ needs.build-distribution.result }}
54+
- name: Notify Slack on failure
55+
if: (failure() || cancelled()) && github.ref_name == github.event.repository.default_branch
56+
uses: senzing-factory/build-resources/slack-failure-notification@v4
57+
with:
58+
job-status: ${{ job.status }}
59+
slack-channel: ${{ secrets.SLACK_CHANNEL }}
60+
slack-bot-token: ${{ secrets.SLACK_BOT_TOKEN }}
61+

.github/workflows/create-sphinx-documentation.yaml

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -48,12 +48,11 @@ jobs:
4848
publish_dir: _build/
4949
force_orphan: true
5050

51-
slack-notification:
52-
needs: [docs]
53-
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.docs.result ) }}
54-
secrets:
55-
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
56-
SLACK_CHANNEL: ${{ secrets.SLACK_CHANNEL }}
57-
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v4
58-
with:
59-
job-status: ${{ needs.docs.result }}
51+
- name: Notify Slack on failure
52+
if: failure() || cancelled()
53+
uses: senzing-factory/build-resources/slack-failure-notification@v4
54+
with:
55+
job-status: ${{ job.status }}
56+
slack-channel: ${{ secrets.SLACK_CHANNEL }}
57+
slack-bot-token: ${{ secrets.SLACK_BOT_TOKEN }}
58+

.github/workflows/dependabot-approve-and-merge.yaml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,6 @@ on:
44
pull_request:
55
branches: [main]
66

7-
concurrency:
8-
group: ${{ github.workflow }}-${{ github.head_ref || github.ref_name }}
9-
cancel-in-progress: true
10-
117
permissions: {}
128

139
jobs:

.github/workflows/publish-to-pypi.yaml

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,14 @@ jobs:
4444
name: python-package-distributions
4545
path: dist/
4646

47+
- name: Notify Slack on failure
48+
if: failure() || cancelled()
49+
uses: senzing-factory/build-resources/slack-failure-notification@v4
50+
with:
51+
job-status: ${{ job.status }}
52+
slack-channel: ${{ secrets.SLACK_CHANNEL }}
53+
slack-bot-token: ${{ secrets.SLACK_BOT_TOKEN }}
54+
4755
publish-to-pypi:
4856
environment:
4957
name: pypi
@@ -97,12 +105,3 @@ jobs:
97105
# sigstore-produced signatures and certificates.
98106
run: gh release upload "${GITHUB_REF_NAME}" dist/** --repo "${{ github.repository }}"
99107

100-
slack-notification:
101-
needs: [build-distribution, publish-to-pypi, github-release]
102-
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.build-distribution.result ) && contains(fromJSON('["failure", "cancelled"]'), needs.publish-to-pypi.result ) && contains(fromJSON('["failure", "cancelled"]'), needs.github-release.result ) && github.ref_name == github.event.repository.default_branch }}
103-
secrets:
104-
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
105-
SLACK_CHANNEL: ${{ secrets.SLACK_CHANNEL }}
106-
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v4
107-
with:
108-
job-status: ${{ needs.build-distribution.result && needs.publish-to-pypi.result && needs.github-release.result }}

.github/workflows/pylint.yaml

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -45,12 +45,3 @@ jobs:
4545
# shellcheck disable=SC2046
4646
pylint $(git ls-files '*.py' ':!:docs/source/*')
4747
48-
slack-notification:
49-
needs: [pylint]
50-
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.pylint.result ) && github.ref_name == github.event.repository.default_branch }}
51-
secrets:
52-
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
53-
SLACK_CHANNEL: ${{ secrets.SLACK_CHANNEL }}
54-
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v4
55-
with:
56-
job-status: ${{ needs.pylint.result }}

.github/workflows/pytest-darwin.yaml

Lines changed: 20 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,14 @@ jobs:
2626
- id: cfg
2727
uses: senzing-factory/build-resources/sdk-versions@v4
2828

29+
- name: Notify Slack on failure
30+
if: (failure() || cancelled()) && (github.ref_name == github.event.repository.default_branch || github.event_name == 'schedule')
31+
uses: senzing-factory/build-resources/slack-failure-notification@v4
32+
with:
33+
job-status: ${{ job.status }}
34+
slack-channel: ${{ secrets.SLACK_CHANNEL }}
35+
slack-bot-token: ${{ secrets.SLACK_BOT_TOKEN }}
36+
2937
pytest-darwin:
3038
name: "Pytest with Senzing: ${{ matrix.senzingsdk-version }}; OS: ${{ matrix.os }}; Python ${{ matrix.python-version }}"
3139
needs: sdk-versions
@@ -65,10 +73,21 @@ jobs:
6573
source ./venv/bin/activate
6674
python -m pip install typing_extensions
6775
76+
- name: Mint staging tap token
77+
if: matrix.senzingsdk-version != 'production-v4'
78+
id: staging-token
79+
uses: actions/create-github-app-token@v3.1.1
80+
with:
81+
client-id: ${{ secrets.SENZINGSDK_STAGING_CLIENT_ID }}
82+
private-key: ${{ secrets.SENZINGSDK_STAGING_APP_KEY }}
83+
owner: senzing-factory
84+
repositories: homebrew-senzingsdk-staging
85+
6886
- name: Install Senzing SDK
69-
uses: senzing-factory/github-action-install-senzing-sdk@v4
87+
uses: senzing-factory/github-action-install-senzing-sdk@v5
7088
with:
7189
senzingsdk-version: ${{ matrix.senzingsdk-version }}
90+
senzingsdk-token: ${{ steps.staging-token.outputs.token || github.token }}
7291

7392
- name: Set environment variables
7493
run: |
@@ -115,12 +134,3 @@ jobs:
115134
contents: write
116135
uses: senzing-factory/build-resources/.github/workflows/python-coverage-comment.yaml@v4
117136

118-
slack-notification:
119-
needs: [pytest-darwin]
120-
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.pytest-darwin.result ) && github.event_name == 'schedule' }}
121-
secrets:
122-
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
123-
SLACK_CHANNEL: ${{ secrets.SLACK_CHANNEL }}
124-
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v4
125-
with:
126-
job-status: ${{ needs.pytest-darwin.result }}

.github/workflows/pytest-linux.yaml

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,14 @@ jobs:
2828
- id: cfg
2929
uses: senzing-factory/build-resources/sdk-versions@v4
3030

31+
- name: Notify Slack on failure
32+
if: (failure() || cancelled()) && (github.ref_name == github.event.repository.default_branch || github.event_name == 'schedule')
33+
uses: senzing-factory/build-resources/slack-failure-notification@v4
34+
with:
35+
job-status: ${{ job.status }}
36+
slack-channel: ${{ secrets.SLACK_CHANNEL }}
37+
slack-bot-token: ${{ secrets.SLACK_BOT_TOKEN }}
38+
3139
pytest-linux:
3240
name: "Pytest with Senzing: ${{ matrix.senzingsdk-version }}; OS: ${{ matrix.os }}; Python ${{ matrix.python-version }}"
3341
needs: sdk-versions
@@ -84,7 +92,7 @@ jobs:
8492
python -m pip install typing_extensions
8593
8694
- name: Install Senzing SDK
87-
uses: senzing-factory/github-action-install-senzing-sdk@v4
95+
uses: senzing-factory/github-action-install-senzing-sdk@v5
8896
with:
8997
senzingsdk-version: ${{ matrix.senzingsdk-version }}
9098

@@ -162,12 +170,3 @@ jobs:
162170
contents: write
163171
uses: senzing-factory/build-resources/.github/workflows/python-coverage-comment.yaml@v4
164172

165-
slack-notification:
166-
needs: [pytest-linux]
167-
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.pytest-linux.result ) && (github.ref_name == github.event.repository.default_branch || github.event_name == 'schedule') }}
168-
secrets:
169-
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
170-
SLACK_CHANNEL: ${{ secrets.SLACK_CHANNEL }}
171-
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v4
172-
with:
173-
job-status: ${{ needs.pytest-linux.result }}

0 commit comments

Comments
 (0)