@@ -10,42 +10,17 @@ name: Python CI
1010on : {pull_request: {branches: ['*']}}
1111jobs :
1212
13-
14- single_commit :
15- name : Assert single commit
16- if : github.base_ref == 'main'
17- steps :
18- - name : Checkout
19- uses : actions/checkout@v3
20- with :
21- fetch-depth : 30
22- - name : Checkout main
23- run : git fetch origin main
24- - name : create local main branch
25- run : git branch main origin/main
26- - name : Commit Count Check
27- run : test `git log --oneline --no-merges HEAD ^main | wc -l ` = 1
13+ ready-to-ship :
2814 runs-on : ubuntu-latest
29-
30- lint :
31- runs-on : ubuntu-latest
32-
33-
3415 steps :
3516 - uses : actions/checkout@v3
3617 with :
37- # by default, it uses a depth of 1
38- # this fetches all history so that we can read each commit
3918 fetch-depth : 0
40-
4119 - uses : actions/setup-python@v3
4220 with :
4321 python-version : " 3.8"
44-
45- # lint_requirements contains tools needed for flake8, etc.
4622 - name : Install requirements
47- run : pip3 install -r lint_requirements.txt
48-
23+ run : pip3 install github
4924 - name : Check commit message
5025 if : github.event_name == 'pull_request'
5126 env :
5833 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
5934 GITHUB_CONTEXT : ${{ github.event.pull_request.commits_url }}
6035 run : sh .github/workflows/scripts/check_commit.sh
36+ - name : Verify requirements files
37+ run : python .ci/scripts/check_requirements.py
38+ single_commit :
39+ runs-on : ubuntu-latest
40+ name : Assert single commit
41+ if : github.base_ref == 'main'
42+ steps :
43+ - uses : actions/checkout@v3
44+ with :
45+ fetch-depth : 0
46+ - name : Checkout main
47+ run : git fetch origin main
48+ - name : create local main branch
49+ run : git branch main origin/main
50+ - name : Commit Count Check
51+ run : test `git log --oneline --no-merges HEAD ^main | wc -l ` = 1
52+
53+ lint :
54+ runs-on : ubuntu-latest
55+
56+ steps :
57+ - uses : actions/checkout@v3
58+ with :
59+ fetch-depth : 1
60+ - uses : actions/setup-python@v3
61+ with :
62+ python-version : " 3.8"
63+ # lint_requirements contains tools needed for flake8, etc.
64+ - name : Install requirements
65+ run : pip3 install -r lint_requirements.txt
6166
6267
6368
7883 - name : Check for gettext problems
7984 run : sh .ci/scripts/check_gettext.sh
8085
81- - name : Verify upper bound requirements
82- run : python .ci/scripts/upper_bound.py
83-
8486 test :
8587 runs-on : ubuntu-latest
8688 # run only after lint finishes
@@ -103,9 +105,7 @@ jobs:
103105 steps :
104106 - uses : actions/checkout@v3
105107 with :
106- # by default, it uses a depth of 1
107- # this fetches all history so that we can read each commit
108- fetch-depth : 0
108+ fetch-depth : 1
109109
110110 - uses : actions/setup-python@v3
111111 with :
@@ -123,7 +123,6 @@ jobs:
123123 echo "TEST=${{ matrix.env.TEST }}" >> $GITHUB_ENV
124124
125125 - name : Before Install
126-
127126 run : .github/workflows/scripts/before_install.sh
128127 shell : bash
129128 env :
@@ -137,7 +136,6 @@ jobs:
137136 GITHUB_CONTEXT : ${{ github.event.pull_request.commits_url }}
138137
139138 - name : Install
140-
141139 run : .github/workflows/scripts/install.sh
142140 shell : bash
143141 env :
@@ -150,13 +148,7 @@ jobs:
150148 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
151149 GITHUB_CONTEXT : ${{ github.event.pull_request.commits_url }}
152150
153- - name : Install Python client
154-
155- run : .github/workflows/scripts/install_python_client.sh
156- shell : bash
157-
158151 - name : Before Script
159-
160152 run : .github/workflows/scripts/before_script.sh
161153 shell : bash
162154 env :
@@ -177,7 +169,6 @@ jobs:
177169 SECRETS_CONTEXT : ${{ toJson(secrets) }}
178170
179171 - name : Script
180-
181172 run : .github/workflows/scripts/script.sh
182173 shell : bash
183174 env :
0 commit comments