Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions .github/workflows/add-labels-standardized.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,12 @@ jobs:
ORG_MEMBERSHIP_TOKEN: ${{ secrets.ORG_MEMBERSHIP_TOKEN }}
SENZING_MEMBERS: ${{ secrets.SENZING_MEMBERS }}
uses: senzing-factory/build-resources/.github/workflows/add-labels-to-issue.yaml@v2

slack-notification:
needs: [add-issue-labels]
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.add-issue-labels.outputs.job-status) }}
secrets:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v2
with:
job-status: ${{ needs.add-issue-labels.outputs.job-status }}
9 changes: 9 additions & 0 deletions .github/workflows/add-to-project-garage-dependabot.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,12 @@ jobs:
uses: senzing-factory/build-resources/.github/workflows/add-to-project-dependabot.yaml@v2
with:
project: ${{ vars.SENZING_PROJECT_GARAGE }}

slack-notification:
needs: [add-to-project-dependabot]
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.add-to-project-dependabot.outputs.job-status) }}
secrets:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v2
with:
job-status: ${{ needs.add-to-project-dependabot.outputs.job-status }}
9 changes: 9 additions & 0 deletions .github/workflows/add-to-project-garage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,12 @@ jobs:
classic: false
project-number: ${{ vars.SENZING_PROJECT_GARAGE }}
org: ${{ vars.SENZING_GITHUB_ACCOUNT_NAME }}

slack-notification:
needs: [add-to-project]
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.add-to-project.outputs.job-status) }}
secrets:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v2
with:
job-status: ${{ needs.add-to-project.outputs.job-status }}
2 changes: 2 additions & 0 deletions .github/workflows/bandit.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
name: bandit

on:
push:
branches-ignore: [main]
pull_request:
branches: [main]

Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/black.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
name: black

on: [push, pull_request]
on:
push:
branches-ignore: [main]
pull_request:
branches: [main]

permissions:
contents: read
Expand Down
11 changes: 11 additions & 0 deletions .github/workflows/build-distribution.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ permissions:
jobs:
build-distribution:
name: Build distribution
outputs:
status: ${{ job.status }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
Expand Down Expand Up @@ -42,3 +44,12 @@ jobs:
with:
name: python-package-distributions
path: dist/

slack-notification:
needs: [build-distribution]
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.build-distribution.outputs.status ) && github.ref_name == github.event.repository.default_branch }}
secrets:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v2
with:
job-status: ${{ needs.build-distribution.outputs.status }}
4 changes: 3 additions & 1 deletion .github/workflows/check-development-dependencies.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
name: Check development dependencies

on: [pull_request]
on:
pull_request:
branches: [main]

permissions:
contents: read
Expand Down
11 changes: 11 additions & 0 deletions .github/workflows/create-sphinx-documentation.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ permissions:

jobs:
docs:
outputs:
status: ${{ job.status }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
Expand Down Expand Up @@ -43,3 +45,12 @@ jobs:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: _build/
force_orphan: true

slack-notification:
needs: [docs]
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.docs.outputs.status ) }}
secrets:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v2
with:
job-status: ${{ needs.docs.outputs.status }}
6 changes: 5 additions & 1 deletion .github/workflows/flake8.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
name: flake8

on: [push, pull_request]
on:
push:
branches-ignore: [main]
pull_request:
branches: [main]

permissions:
contents: read
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/isort.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
name: isort

on: [push, pull_request]
on:
push:
branches-ignore: [main]
pull_request:
branches: [main]

permissions:
contents: read
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/mypy.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
name: mypy

on: [push, pull_request]
on:
push:
branches-ignore: [main]
pull_request:
branches: [main]

permissions:
contents: read
Expand Down
23 changes: 19 additions & 4 deletions .github/workflows/publish-to-pypi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ permissions:
jobs:
build-distribution:
name: Build distribution
outputs:
status: ${{ job.status }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
Expand Down Expand Up @@ -42,13 +44,15 @@ jobs:
path: dist/

publish-to-pypi:
name: Publish Python distribution to PyPI
if: startsWith(github.ref, 'refs/tags/') # only publish to PyPI on tag pushes
needs:
- build-distribution
environment:
name: pypi
url: https://pypi.org/p/senzing
if: startsWith(github.ref, 'refs/tags/') # only publish to PyPI on tag pushes
name: Publish Python distribution to PyPI
needs:
- build-distribution
outputs:
status: ${{ job.status }}
permissions:
id-token: write
runs-on: ubuntu-latest
Expand All @@ -67,6 +71,8 @@ jobs:
name: Sign the Python distribution with Sigstore and upload them to GitHub Release
needs:
- publish-to-pypi
outputs:
status: ${{ job.status }}
permissions:
contents: write # IMPORTANT: mandatory for making GitHub Releases
id-token: write # IMPORTANT: mandatory for sigstore
Expand All @@ -93,3 +99,12 @@ jobs:
# `dist/` contains the built packages, and the
# sigstore-produced signatures and certificates.
run: gh release upload '${{ github.ref_name }}' dist/** --repo '${{ github.repository }}'

slack-notification:
needs: [build-distribution, publish-to-pypi, github-release]
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.build-distribution.outputs.status ) && contains(fromJSON('["failure", "cancelled"]'), needs.publish-to-pypi.outputs.status ) && contains(fromJSON('["failure", "cancelled"]'), needs.github-release.outputs.status ) && github.ref_name == github.event.repository.default_branch }}
secrets:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v2
with:
job-status: ${{ needs.build-distribution.outputs.status && needs.publish-to-pypi.outputs.status && needs.github-release.outputs.status }}
11 changes: 11 additions & 0 deletions .github/workflows/pylint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ permissions:

jobs:
pylint:
outputs:
status: ${{ job.status }}
runs-on: ubuntu-latest
strategy:
matrix:
Expand Down Expand Up @@ -35,3 +37,12 @@ jobs:
run: |
# shellcheck disable=SC2046
pylint $(git ls-files '*.py' ':!:docs/source/*')

slack-notification:
needs: [pylint]
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.pylint.outputs.status ) && github.ref_name == github.event.repository.default_branch }}
secrets:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v2
with:
job-status: ${{ needs.pylint.outputs.status }}
11 changes: 11 additions & 0 deletions .github/workflows/pytest-linux.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ permissions:
jobs:
pytest-linux:
name: "pytest with Senzing: ${{ matrix.senzingsdk-version }}; OS: ${{ matrix.os }}; Python ${{ matrix.python-version }}"
outputs:
status: ${{ job.status }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
Expand Down Expand Up @@ -123,3 +125,12 @@ jobs:
pull-requests: write
contents: write
uses: senzing-factory/build-resources/.github/workflows/python-coverage-comment.yaml@v2

slack-notification:
needs: [pytest-linux, coverage]
if: ${{ always() && contains(fromJSON('["failure", "cancelled"]'), needs.pytest-linux.outputs.status ) && contains(fromJSON('["failure", "cancelled"]'), needs.coverage.outputs.job-status ) && github.ref_name == github.event.repository.default_branch }}
secrets:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
uses: senzing-factory/build-resources/.github/workflows/build-failure-slack-notification.yaml@v2
with:
job-status: ${{ needs.pytest-linux.outputs.status && needs.coverage.outputs.job-status }}
Loading