8
8
- main
9
9
- v1.51
10
10
11
+ env :
12
+ UV_LOCKED : 1
13
+
11
14
jobs :
12
15
validate :
13
16
runs-on : ubuntu-latest
@@ -41,21 +44,14 @@ jobs:
41
44
python-version : " 3.8"
42
45
allow-prereleases : true
43
46
44
- - uses : pdm-project/setup-pdm@v4
45
- name : Set up PDM
47
+ - name : Install uv
48
+ uses : astral-sh/setup-uv@v4
46
49
with :
47
- python-version : " 3.8"
48
- version : " 2.20.1"
49
- allow-python-prereleases : false
50
- cache : true
51
- cache-dependency-path : |
52
- ./pdm.lock
53
-
54
- - name : Install dependencies
55
- run : pdm install -G:all
50
+ version : " 0.5.4"
51
+ enable-cache : true
56
52
57
53
- name : Run mypy
58
- run : pdm run mypy
54
+ run : uv run mypy
59
55
60
56
pyright :
61
57
runs-on : ubuntu-latest
@@ -67,21 +63,14 @@ jobs:
67
63
python-version : " 3.8"
68
64
allow-prereleases : true
69
65
70
- - uses : pdm-project/setup-pdm@v4
71
- name : Set up PDM
66
+ - name : Install uv
67
+ uses : astral-sh/setup-uv@v4
72
68
with :
73
- python-version : " 3.8"
74
- version : " 2.20.1"
75
- allow-python-prereleases : false
76
- cache : true
77
- cache-dependency-path : |
78
- ./pdm.lock
79
-
80
- - name : Install dependencies
81
- run : pdm install -G:all
69
+ version : " 0.5.4"
70
+ enable-cache : true
82
71
83
72
- name : Run pyright
84
- run : pdm run pyright
73
+ run : uv run pyright
85
74
86
75
slotscheck :
87
76
runs-on : ubuntu-latest
@@ -93,21 +82,14 @@ jobs:
93
82
python-version : " 3.8"
94
83
allow-prereleases : false
95
84
96
- - uses : pdm-project/setup-pdm@v4
97
- name : Set up PDM
85
+ - name : Install uv
86
+ uses : astral-sh/setup-uv@v4
98
87
with :
99
- python-version : " 3.8"
100
- version : " 2.20.1"
101
- allow-python-prereleases : false
102
- cache : true
103
- cache-dependency-path : |
104
- ./pdm.lock
105
-
106
- - name : Install dependencies
107
- run : pdm install -G:all
88
+ version : " 0.5.4"
89
+ enable-cache : true
108
90
109
91
- name : Run slotscheck
110
- run : pdm run slotscheck litestar
92
+ run : uv run slotscheck litestar
111
93
112
94
test :
113
95
name : " test (${{ matrix.python-version }})"
@@ -135,25 +117,22 @@ jobs:
135
117
with :
136
118
python-version : 3.11
137
119
138
- - uses : pdm-project/setup-pdm@v4
139
- name : Set up PDM
120
+ - name : Install uv
121
+ uses : astral-sh/setup-uv@v4
140
122
with :
141
- python-version : 3.11
142
- allow-python-prereleases : false
143
- cache : true
144
- cache-dependency-path : |
145
- ./pdm.lock
123
+ version : " 0.5.4"
124
+ enable-cache : true
146
125
147
126
- name : Install dependencies
148
127
run : |
149
- pdm install -G:all
150
- pip install -U "${{ matrix.uvicorn-version }}"
128
+ uv sync
129
+ uv pip install -U "${{ matrix.uvicorn-version }}"
151
130
152
131
- name : Set PYTHONPATH
153
132
run : echo "PYTHONPATH=$PWD" >> $GITHUB_ENV
154
133
155
134
- name : Test
156
- run : pdm run pytest tests -m server_integration
135
+ run : uv run --no-sync pytest tests -m server_integration
157
136
158
137
test-platform-compat :
159
138
if : github.event_name == 'push' || contains(github.event.pull_request.labels.*.name, 'test platform compat')
@@ -217,25 +196,19 @@ jobs:
217
196
python-version : " 3.12"
218
197
allow-prereleases : true
219
198
220
- - uses : pdm-project/setup-pdm@v4
221
- name : Set up PDM
199
+ - name : Install uv
200
+ uses : astral-sh/setup-uv@v4
222
201
with :
223
- python-version : " 3.12"
224
- allow-python-prereleases : false
225
- cache : true
226
- cache-dependency-path : |
227
- ./pdm.lock
228
-
229
- - name : Install dependencies
230
- run : pdm install -G:all
202
+ version : " 0.5.4"
203
+ enable-cache : true
231
204
232
205
- name : Build docs
233
- run : pdm run make docs
206
+ run : uv run make docs
234
207
235
208
- name : Check docs links
236
209
env :
237
210
LITESTAR_DOCS_IGNORE_MISSING_EXAMPLE_OUTPUT : 1
238
- run : pdm run make docs-linkcheck
211
+ run : uv run make docs-linkcheck
239
212
240
213
- name : Save PR number
241
214
run : |
@@ -264,23 +237,19 @@ jobs:
264
237
with :
265
238
python-version : " 3.12"
266
239
267
- - uses : pdm-project/setup-pdm@v4
268
- name : Set up PDM
240
+ - name : Install uv
241
+ uses : astral-sh/setup-uv@v4
269
242
with :
270
- python-version : " 3.12"
271
- allow-python-prereleases : false
272
- cache : true
273
- cache-dependency-path : |
274
- ./pdm.lock
275
-
276
- - name : Install dependencies
277
- run : pdm install
243
+ version : " 0.5.4"
244
+ enable-cache : true
278
245
279
246
- name : Set pythonpath
280
247
run : echo "PYTHONPATH=$PWD" >> $GITHUB_ENV
281
248
282
249
- name : Test
283
- run : mv tests/examples/test_hello_world.py test_hello_world.py && pdm run pytest test_hello_world.py
250
+ run : |
251
+ mv tests/examples/test_hello_world.py test_hello_world.py
252
+ uv run pytest test_hello_world.py
284
253
285
254
test_pydantic_1_app :
286
255
name : Test Minimal Pydantic 1 application
@@ -296,26 +265,22 @@ jobs:
296
265
with :
297
266
python-version : " 3.12"
298
267
299
- - uses : pdm-project/setup-pdm@v4
300
- name : Set up PDM
268
+ - name : Install uv
269
+ uses : astral-sh/setup-uv@v4
301
270
with :
302
- python-version : " 3.12"
303
- allow-python-prereleases : false
304
- cache : true
305
- cache-dependency-path : |
306
- ./pdm.lock
271
+ version : " 0.5.4"
272
+ enable-cache : true
307
273
308
274
- name : Install dependencies
309
275
run : |
310
- pdm install
311
- pdm run python -m ensurepip
312
- pdm run python -m pip install "pydantic==1.*"
276
+ uv sync
277
+ uv pip install "pydantic==1.*"
313
278
314
279
- name : Set pythonpath
315
280
run : echo "PYTHONPATH=$PWD" >> $GITHUB_ENV
316
281
317
282
- name : Test
318
- run : pdm run coverage run --branch -m unittest test_apps/pydantic_1_app.py
283
+ run : uv run --no-sync coverage run --branch -m unittest test_apps/pydantic_1_app.py
319
284
320
285
- name : Rename coverage file
321
286
run : mv .coverage* .coverage.pydantic_v1
0 commit comments