1414 - " tests/**"
1515 - " noxfile.py"
1616 - " pyproject.toml"
17- - " poetry .lock"
17+ - " uv .lock"
1818 - " .github/workflows/test.yml"
1919
2020jobs :
@@ -26,15 +26,13 @@ jobs:
2626 steps :
2727 - uses : actions/checkout@v4
2828 - name : Install uv
29- uses : astral-sh/setup-uv@v3
30- - run : uv venv
31- - run : uv pip install poetry nox nox-poetry
29+ uses : astral-sh/setup-uv@v5
30+ - run : uv sync
3231 - id : set-matrix
3332 shell : bash
3433 run : |
35- . .venv/bin/activate
3634 echo sessions=$(
37- nox --json -t tests -l |
35+ uv run nox --json -t tests -l |
3836 jq 'map(
3937 {
4038 session,
5452
5553 steps :
5654 - uses : actions/checkout@v4
55+ - name : Install uv
56+ uses : astral-sh/setup-uv@v5
57+ with :
58+ enable-cache : true
59+ cache-dependency-glob : " uv.lock"
5760 - uses : actions/setup-python@v5
5861 with :
5962 python-version : |
6366 3.13
6467 3.14
6568
66- - run : pip install poetry nox nox-poetry uv
67- - run : nox -r -t tests -s "${{ matrix.session.session }}"
69+ - run : uv sync
70+ - run : uv run nox -r -t tests -s "${{ matrix.session.session }}"
6871 - uses : actions/upload-artifact@v4
6972 if : ${{ always() }}
7073 with :
@@ -96,73 +99,76 @@ jobs:
9699
97100 steps :
98101 - uses : actions/checkout@v4
99- - run : pipx install poetry
102+ - name : Install uv
103+ uses : astral-sh/setup-uv@v5
104+ with :
105+ enable-cache : true
106+ cache-dependency-glob : " uv.lock"
100107 - uses : actions/setup-python@v5
101108 id : setup-python
102109 with :
103110 python-version : " 3.12"
104111 architecture : x64
105- cache : " poetry"
106112
107- - run : poetry env use 3.12
108- - run : poetry install
109- if : steps.setup-python.outputs.cache-hit != 'true'
113+ - run : uv sync
110114
111115 - name : Run benchmarks
112116 uses : CodSpeedHQ/action@v4
113117 with :
114118 mode : simulation
115- run : poetry run pytest tests/benchmarks --codspeed -p no:codeflash-benchmark
119+ run : uv run pytest tests/benchmarks --codspeed -p no:codeflash-benchmark
116120
117121 lint :
118122 name : ✨ Lint
119123 runs-on : ubuntu-latest
120124
121125 steps :
122126 - uses : actions/checkout@v4
123- - run : pipx install poetry
124- - run : pipx install coverage
127+ - name : Install uv
128+ uses : astral-sh/setup-uv@v5
129+ with :
130+ enable-cache : true
131+ cache-dependency-glob : " uv.lock"
125132 - uses : actions/setup-python@v5
126133 id : setup-python
127134 with :
128135 python-version : " 3.12"
129- cache : " poetry"
130136
131- - run : poetry install --with integrations
132- if : steps.setup-python.outputs.cache-hit != 'true'
137+ - run : uv sync
133138
134139 - run : |
135- mkdir .mypy_cache
140+ mkdir -p .mypy_cache
136141
137- poetry run mypy --install-types --non-interactive --cache-dir=.mypy_cache/ --config-file mypy.ini
142+ uv run mypy --install-types --non-interactive --cache-dir=.mypy_cache/ --config-file mypy.ini
138143
139144 unit-tests-on-windows :
140145 name : 🪟 Tests on Windows
141146 runs-on : windows-latest
142147
143148 steps :
144149 - uses : actions/checkout@v4
145- - run : pipx install poetry
146- - run : pipx install coverage
150+ - name : Install uv
151+ uses : astral-sh/setup-uv@v5
152+ with :
153+ enable-cache : true
154+ cache-dependency-glob : " uv.lock"
147155 - uses : actions/setup-python@v5
148156 id : setup-python
149157 with :
150158 python-version : " 3.11"
151- cache : " poetry"
152159
153- - run : poetry install --with integrations
154- if : steps.setup-python.outputs.cache-hit != 'true'
160+ - run : uv sync
155161 # Since we are running all the integrations at once, we can't use
156162 # pydantic v2. It is not compatible with starlette yet
157- - run : poetry run pip install pydantic==1.10
163+ - run : uv pip install pydantic==1.10
158164
159- # we use poetry directly instead of nox since we want to
165+ # we use uv directly instead of nox since we want to
160166 # test all integrations at once on windows
161167 # but we want to exclude tests/mypy since we are using an old version of pydantic
162168 - run : |
163- poetry run pytest --cov=. --cov-append --cov-report=xml -n auto --showlocals --ignore tests/mypy -vv
169+ uv run pytest --cov=. --cov-append --cov-report=xml -n auto --showlocals --ignore tests/mypy -vv
164170 - name : coverage xml
165- run : coverage xml -i
171+ run : uv run coverage xml -i
166172 if : ${{ always() }}
167173
168174 - uses : codecov/codecov-action@v4
0 commit comments