-
Notifications
You must be signed in to change notification settings - Fork 39
46 lines (43 loc) · 1.19 KB
/
python-cron.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
name: Python Canary Cron
on:
schedule:
- cron: "0 18 * * 1-5"
workflow_dispatch:
defaults:
run:
working-directory: ./python
jobs:
canary:
runs-on: oss-4-core-runner
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: |
3.8
3.9
3.10
3.11
3.12
- run: pip install tox-uv==1.11.2
- run: >-
tox run-parallel --parallel-no-spinner
-e $(tox -l | egrep -e '-latest$' | paste -sd, -)
--result-json=${{ runner.temp }}/.tox-result.json
- run: >-
echo "testenvs=$(cat ${{ runner.temp }}/.tox-result.json
| jq -r '.testenvs | with_entries(select(.value|.result.success==false)) | keys | .[]'
| sort
| paste -sd, -)"
>> "$GITHUB_OUTPUT"
id: failed
if: failure()
- uses: slackapi/slack-github-action@v1
if: failure()
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
with:
payload: |
{
"text": "CI Failures for Python Packages: ${{ steps.failed.outputs.testenvs }}"
}