@@ -17,18 +17,28 @@ jobs:
1717 permissions :
1818 contents : write
1919 if : (github.ref == 'refs/heads/master' && github.event_name == 'push') || github.event_name == 'release'
20- runs-on : ubuntu-latest
20+ runs-on : ${{ matrix.os }}
21+ strategy :
22+ max-parallel : 10
23+ fail-fast : false
24+ matrix :
25+ os : ["ubuntu-latest"]
26+ python-version : ["3.10"]
2127 steps :
2228 - uses : actions/checkout@v4
23- - uses : actions /setup-python@v5
29+ - uses : astral-sh /setup-uv@v6
2430 with :
25- python-version : " 3.10"
31+ version : " latest"
32+ python-version : " ${{ matrix.python-version }}"
33+ activate-environment : true
34+ enable-cache : true
35+ cache-suffix : " ${{ hashFiles('requirements-dev.txt') }}-${{ hashFiles('docs/requirements.txt') }}"
36+ cache-dependency-glob : |
37+ **/docs/requirements.txt
38+ **/requirements-dev.txt
39+ **/pyproject.toml
2640
2741 - run : sudo npm install katex -g
28- - uses : actions/cache@v4
29- with :
30- path : ~/.cache/pip
31- key : pip-${{ hashFiles('requirements-dev.txt') }}-${{ hashFiles('docs/requirements.txt') }}
3242
3343 - name : Install docs deps
3444 run : bash .github/workflows/install_docs_deps.sh
@@ -47,18 +57,27 @@ jobs:
4757
4858 linkcheck :
4959 if : github.event_name == 'pull_request' || github.event_name == 'push'
50- runs-on : ubuntu-latest
60+ runs-on : ${{ matrix.os }}
5161 timeout-minutes : 10
62+ strategy :
63+ max-parallel : 10
64+ fail-fast : false
65+ matrix :
66+ os : ["ubuntu-latest"]
67+ python-version : ["3.10"]
5268 steps :
5369 - uses : actions/checkout@v4
54- - uses : actions/setup-python@v5
55- with :
56- python-version : " 3.10"
57-
58- - uses : actions/cache@v4
70+ - uses : astral-sh/setup-uv@v6
5971 with :
60- path : ~/.cache/pip
61- key : pip-${{ hashFiles('requirements-dev.txt') }}-${{ hashFiles('docs/requirements.txt') }}
72+ version : " latest"
73+ python-version : ${{ matrix.python-version }}
74+ activate-environment : true
75+ enable-cache : true
76+ cache-suffix : " ${{ hashFiles('requirements-dev.txt') }}-${{ hashFiles('docs/requirements.txt') }}"
77+ cache-dependency-glob : |
78+ **/docs/requirements.txt
79+ **/requirements-dev.txt
80+ **/pyproject.toml
6281
6382 - name : Install docs deps
6483 run : bash .github/workflows/install_docs_deps.sh
@@ -69,18 +88,28 @@ jobs:
6988
7089 doctest :
7190 if : github.event_name == 'pull_request' || github.event_name == 'push'
72- runs-on : ubuntu-latest
91+ runs-on : ${{ matrix.os }}
92+ strategy :
93+ max-parallel : 10
94+ fail-fast : false
95+ matrix :
96+ os : ["ubuntu-latest"]
97+ python-version : ["3.10"]
7398 steps :
7499 - uses : actions/checkout@v4
75- - uses : actions /setup-python@v5
100+ - uses : astral-sh /setup-uv@v6
76101 with :
77- python-version : " 3.10"
102+ version : " latest"
103+ python-version : " ${{ matrix.python-version }}"
104+ activate-environment : true
105+ enable-cache : true
106+ cache-suffix : " ${{ hashFiles('requirements-dev.txt') }}-${{ hashFiles('docs/requirements.txt') }}"
107+ cache-dependency-glob : |
108+ **/docs/requirements.txt
109+ **/requirements-dev.txt
110+ **/pyproject.toml
78111
79112 - run : sudo npm install katex -g
80- - uses : actions/cache@v4
81- with :
82- path : ~/.cache/pip
83- key : pip-${{ hashFiles('requirements-dev.txt') }}-${{ hashFiles('docs/requirements.txt') }}
84113
85114 - name : Install docs deps
86115 run : bash .github/workflows/install_docs_deps.sh
0 commit comments