Skip to content

Commit 097aa56

Browse files
committed
feat: move from poetry to uv
1 parent bd684f5 commit 097aa56

File tree

24 files changed

+518
-8189
lines changed

24 files changed

+518
-8189
lines changed

.devcontainer/Dockerfile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
ARG VARIANT=3.13
22
FROM mcr.microsoft.com/devcontainers/python:${VARIANT}
33

4-
RUN pip3 install poetry pre-commit
5-
RUN poetry config virtualenvs.in-project true
4+
RUN pip3 install uv pre-commit

.devcontainer/post-install.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
poetry install --with dev,integrations
1+
uv sync
22
pre-commit install --install-hooks

.github/bot-action/Dockerfile

Lines changed: 0 additions & 8 deletions
This file was deleted.

.github/bot-action/action.yml

Lines changed: 0 additions & 17 deletions
This file was deleted.

.github/bot-action/main.py

Lines changed: 0 additions & 51 deletions
This file was deleted.

.github/workflows/codeflash.yaml

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -26,16 +26,12 @@ jobs:
2626
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6
2727
with:
2828
fetch-depth: 0
29-
- name: Set up Python
30-
uses: actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v5
29+
- name: Install uv
30+
uses: astral-sh/setup-uv@61cb8a9741eeb8a550a1b8544337180c0fc8476b # v7.2.0
3131
with:
32+
enable-cache: true
3233
python-version: "3.11"
3334
- name: Install Project Dependencies
34-
run: |
35-
python -m pip install --upgrade pip
36-
pip install poetry
37-
poetry install --all-extras
35+
run: uv sync --all-extras
3836
- name: Run Codeflash to optimize code
39-
run: |
40-
poetry env use python
41-
poetry run codeflash --benchmark --benchmarks-root tests/benchmarks
37+
run: uvx codeflash --benchmark --benchmarks-root tests/benchmarks

.github/workflows/e2e-tests.yml

Lines changed: 8 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -30,27 +30,22 @@ jobs:
3030
cd e2e
3131
bunx playwright install --with-deps
3232
33-
- name: Setup Python
34-
uses: actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v5
33+
- name: Install uv
34+
uses: astral-sh/setup-uv@61cb8a9741eeb8a550a1b8544337180c0fc8476b # v7.2.0
3535
with:
36-
python-version: "3.12"
37-
38-
- name: Install Poetry
39-
uses: snok/install-poetry@76e04a911780d5b312d89783f7b1cd627778900a # v1
40-
with:
41-
version: latest
42-
virtualenvs-create: true
43-
virtualenvs-in-project: true
36+
enable-cache: true
37+
python-version: "3.13"
4438

4539
- name: Install Python dependencies
4640
run: |
47-
poetry install --extras cli
48-
poetry run pip install graphql-core==3.3.0a9
41+
uv sync --extra cli
42+
uv pip install graphql-core==3.3.0a9
4943
5044
- name: Start Strawberry server
5145
run: |
5246
cd e2e
53-
poetry run strawberry dev app:schema --port 8000 &
47+
# --no-sync prevents uv from reverting graphql-core to lockfile version
48+
uv run --no-sync strawberry dev app:schema --port 8000 &
5449
echo $! > server.pid
5550
sleep 5 # Wait for server to start
5651

.github/workflows/federation-compatibility.yml

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ on:
1414
- "strawberry/printer/**"
1515
- "federation-compatibility/**"
1616
- "pyproject.toml"
17-
- "poetry.lock"
17+
- "uv.lock"
1818
- ".github/workflows/federation-compatibility.yml"
1919

2020
jobs:
@@ -25,17 +25,15 @@ jobs:
2525
steps:
2626
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6
2727

28-
- run: pipx install poetry
29-
- uses: actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v4
30-
id: setup-python
28+
- name: Install uv
29+
uses: astral-sh/setup-uv@61cb8a9741eeb8a550a1b8544337180c0fc8476b # v7.2.0
3130
with:
32-
python-version: "3.12"
33-
cache: "poetry"
34-
- run: poetry env use python3.12
35-
- run: poetry install
31+
enable-cache: true
32+
python-version: "3.13"
33+
- run: uv sync
3634

3735
- name: export schema
38-
run: poetry run strawberry export-schema schema:schema > schema.graphql
36+
run: uv run strawberry export-schema schema:schema > schema.graphql
3937
working-directory: federation-compatibility
4038

4139
- uses: apollographql/federation-subgraph-compatibility@b6981fd83d24450a7cbd2d7727196e0ba57614e0 # v2

.github/workflows/pre-release-pr.yml

Lines changed: 0 additions & 84 deletions
This file was deleted.

0 commit comments

Comments
 (0)