Skip to content

Commit 9037f39

Browse files
committed
Merge branch 'refs/heads/main' into fix-auth-route-conflict
# Conflicts: # robyn/processpool.py
2 parents 691528d + 55e40d0 commit 9037f39

File tree

125 files changed

+6886
-1183
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

125 files changed

+6886
-1183
lines changed

.github/ISSUE_TEMPLATE/bug_report.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@ body:
4242
attributes:
4343
label: Your Python version (`python --version`)
4444
options:
45-
- 3.8
4645
- 3.9
4746
- 3.10
4847
- 3.11

.github/workflows/codspeed.yml

Lines changed: 15 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,31 +9,38 @@ on:
99
# performance analysis in order to generate initial data.
1010
workflow_dispatch:
1111

12+
env:
13+
UV_SYSTEM_PYTHON: 1
14+
1215
jobs:
1316
benchmarks:
1417
runs-on: ubuntu-22.04
1518
steps:
1619
- uses: actions/checkout@v4
20+
21+
- name: Install uv
22+
uses: astral-sh/setup-uv@v3
23+
1724
- uses: actions/setup-python@v5
1825
with:
19-
python-version: "3.8"
26+
python-version: "3.9"
2027

21-
- name: Install dependencies
28+
- name: Install dependencies with uv
2229
run: |
23-
python -m pip install --upgrade pip
24-
pip install poetry==1.3.0
25-
poetry export --with test --with dev --without-hashes --output requirements.txt
26-
pip install -r requirements.txt
27-
pip install -e .
30+
uv pip install poetry
31+
uv run poetry export --with test --with dev --without-hashes --output requirements.txt
32+
uv pip install -r requirements.txt
33+
uv pip install -e .
2834
- name: Add macos target
2935
if: matrix.os == 'macos'
3036
run: rustup target add aarch64-apple-darwin
3137
- name: Setup Rust part of the project
3238
run: |
3339
maturin build -i python --universal2 --out dist
34-
pip install --no-index --find-links=dist/ robyn
40+
uv pip install --no-index --find-links=dist/ robyn
3541
- name: Run benchmarks
3642
uses: CodSpeedHQ/action@v2
3743
with:
3844
token: ${{ secrets.CODSPEED_TOKEN }}
3945
run: pytest integration_tests --codspeed
46+

.github/workflows/lint-pr.yml

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,20 +4,26 @@ on:
44
pull_request:
55
branches: [main]
66

7+
8+
env:
9+
UV_SYSTEM_PYTHON: 1
10+
711
jobs:
812
lint:
913
runs-on: ubuntu-latest
1014
steps:
1115
- uses: actions/checkout@v4
12-
- name: Set up Python
13-
uses: actions/setup-python@v5
16+
- name: Install uv
17+
uses: astral-sh/setup-uv@v3
18+
19+
- uses: actions/setup-python@v5
1420
with:
15-
python-version: '3.x'
16-
- name: Install dependencies
21+
python-version: "3.11"
22+
23+
- name: Install dependencies with uv
1724
run: |
18-
python -m pip install --upgrade pip
19-
pip install ruff isort black
25+
uv pip install ruff isort black
2026
- name: Run linters
2127
run: |
22-
ruff check .
23-
isort --check-only --diff .
28+
uv run ruff check .
29+
uv run isort --check-only --diff .

.github/workflows/preview-deployments.yml

Lines changed: 17 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,19 @@ on:
1111
branches:
1212
- main
1313

14+
env:
15+
UV_SYSTEM_PYTHON: 1
16+
1417
jobs:
1518
macos:
16-
runs-on: macos-12
19+
runs-on: macos-13
1720
strategy:
1821
matrix:
19-
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
22+
python-version: ["3.9", "3.10", "3.11", "3.12"]
2023
steps:
2124
- uses: actions/checkout@v4
25+
- name: Install uv
26+
uses: astral-sh/setup-uv@v3
2227
- uses: actions/setup-python@v5
2328
with:
2429
python-version: ${{ matrix.python-version }}
@@ -32,25 +37,27 @@ jobs:
3237
args: -i python --release --out dist --no-sdist
3338
- name: Install build wheel - x86_64
3439
run: |
35-
pip install --force-reinstall dist/robyn*.whl
40+
uv pip install --force-reinstall dist/robyn*.whl
3641
cd ~ && python -c 'import robyn'
3742
- name: Build wheels - universal2
3843
uses: PyO3/maturin-action@v1
3944
with:
4045
args: -i python --release --universal2 --out dist --no-sdist
4146
- name: Install build wheel - universal2
4247
run: |
43-
pip install --force-reinstall dist/robyn*_universal2.whl
48+
uv pip install --force-reinstall dist/robyn*_universal2.whl
4449
cd ~ && python -c 'import robyn'
4550
4651
windows:
4752
runs-on: windows-latest
4853
strategy:
4954
matrix:
50-
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
55+
python-version: ["3.9", "3.10", "3.11", "3.12"]
5156
target: [x64, x86]
5257
steps:
5358
- uses: actions/checkout@v4
59+
- name: Install uv
60+
uses: astral-sh/setup-uv@v3
5461
- uses: actions/setup-python@v5
5562
with:
5663
python-version: ${{ matrix.python-version }}
@@ -64,18 +71,20 @@ jobs:
6471
- name: Install build wheel
6572
shell: bash
6673
run: |
67-
pip install --force-reinstall dist/robyn*.whl
74+
uv pip install --force-reinstall dist/robyn*.whl
6875
cd ~ && python -c 'import robyn'
6976
7077
linux:
7178
runs-on: ubuntu-latest
7279
strategy:
7380
matrix:
74-
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
81+
python-version: ["3.9", "3.10", "3.11", "3.12"]
7582
target: [x86_64, i686]
7683
steps:
7784
- uses: actions/checkout@v4
7885
- uses: dtolnay/rust-toolchain@stable
86+
- name: Install uv
87+
uses: astral-sh/setup-uv@v3
7988
- uses: actions/setup-python@v5
8089
with:
8190
python-version: ${{ matrix.python-version }}
@@ -88,7 +97,7 @@ jobs:
8897
- name: Install build wheel
8998
if: matrix.target == 'x86_64'
9099
run: |
91-
pip install --force-reinstall dist/robyn*.whl
100+
uv pip install --force-reinstall dist/robyn*.whl
92101
cd ~ && python -c 'import robyn'
93102
94103
linux-cross:
@@ -98,7 +107,6 @@ jobs:
98107
matrix:
99108
python:
100109
[
101-
{ version: "3.8", abi: "cp38-cp38" },
102110
{ version: "3.9", abi: "cp39-cp39" },
103111
{ version: "3.10", abi: "cp310-cp310" },
104112
{ version: "3.11", abi: "cp311-cp311" },

.github/workflows/python-CI.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
fail-fast: false
1111
matrix:
1212
os: ["windows", "ubuntu", "macos"]
13-
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
13+
python-version: ["3.9", "3.10", "3.11", "3.12"]
1414
name: ${{ matrix.os }} tests with python ${{ matrix.python-version }}
1515
runs-on: ${{ matrix.os }}-latest
1616
steps:

.github/workflows/release-CI.yml

Lines changed: 62 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,21 @@ on:
44
push:
55
tags:
66
- v*
7+
workflow_dispatch:
8+
9+
env:
10+
UV_SYSTEM_PYTHON: 1
711
jobs:
812
macos:
9-
runs-on: macos-12
13+
runs-on: macos-13
1014
strategy:
1115
matrix:
12-
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
16+
python-version: ["3.9", "3.10", "3.11", "3.12"]
1317
steps:
1418
- uses: actions/checkout@v3
15-
- uses: actions/setup-python@v4
19+
- name: Install uv
20+
uses: astral-sh/setup-uv@v3
21+
- uses: actions/setup-python@v5
1622
with:
1723
python-version: ${{ matrix.python-version }}
1824
- uses: dtolnay/rust-toolchain@stable
@@ -25,30 +31,32 @@ jobs:
2531
args: -i python --release --out dist
2632
- name: Install build wheel - x86_64
2733
run: |
28-
pip install --force-reinstall dist/robyn*.whl
34+
uv pip install --force-reinstall dist/robyn*.whl
2935
cd ~ && python -c 'import robyn'
3036
- name: Build wheels - universal2
3137
uses: PyO3/maturin-action@v1
3238
with:
3339
args: -i python --release --universal2 --out dist
3440
- name: Install build wheel - universal2
3541
run: |
36-
pip install --force-reinstall dist/robyn*_universal2.whl
42+
uv pip install --force-reinstall dist/robyn*_universal2.whl
3743
cd ~ && python -c 'import robyn'
3844
- name: Upload wheels
39-
uses: actions/upload-artifact@v3
45+
uses: actions/upload-artifact@v4
4046
with:
41-
name: wheels
47+
name: wheels-${{ github.job }}-universal-${{ matrix.python-version }}
4248
path: dist
4349
windows:
4450
runs-on: windows-latest
4551
strategy:
4652
matrix:
47-
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
53+
python-version: ["3.9", "3.10", "3.11", "3.12"]
4854
target: [x64, x86]
4955
steps:
5056
- uses: actions/checkout@v3
51-
- uses: actions/setup-python@v4
57+
- name: Install uv
58+
uses: astral-sh/setup-uv@v3
59+
- uses: actions/setup-python@v5
5260
with:
5361
python-version: ${{ matrix.python-version }}
5462
architecture: ${{ matrix.target }}
@@ -61,23 +69,25 @@ jobs:
6169
- name: Install build wheel
6270
shell: bash
6371
run: |
64-
pip install --force-reinstall dist/robyn*.whl
72+
uv pip install --force-reinstall dist/robyn*.whl
6573
cd ~ && python -c 'import robyn'
6674
- name: Upload wheels
67-
uses: actions/upload-artifact@v3
75+
uses: actions/upload-artifact@v4
6876
with:
69-
name: wheels
77+
name: wheels-${{ github.job }}-${{ matrix.target }}-${{ matrix.python-version }}
7078
path: dist
7179
linux:
7280
runs-on: ubuntu-latest
7381
strategy:
7482
matrix:
75-
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
83+
python-version: ["3.9", "3.10", "3.11", "3.12"]
7684
target: [x86_64, i686]
7785
steps:
7886
- uses: actions/checkout@v3
7987
- uses: dtolnay/rust-toolchain@stable
80-
- uses: actions/setup-python@v4
88+
- name: Install uv
89+
uses: astral-sh/setup-uv@v3
90+
- uses: actions/setup-python@v5
8191
with:
8292
python-version: ${{ matrix.python-version }}
8393
- name: Build Wheels
@@ -89,20 +99,19 @@ jobs:
8999
- name: Install build wheel
90100
if: matrix.target == 'x86_64'
91101
run: |
92-
pip install --force-reinstall dist/robyn*.whl
102+
uv pip install --force-reinstall dist/robyn*.whl
93103
cd ~ && python -c 'import robyn'
94104
- name: Upload wheels
95-
uses: actions/upload-artifact@v3
105+
uses: actions/upload-artifact@v4
96106
with:
97-
name: wheels
107+
name: wheels-${{ github.job }}-${{ matrix.target }}-${{ matrix.python-version }}
98108
path: dist
99109
linux-cross:
100110
runs-on: ubuntu-latest
101111
strategy:
102112
matrix:
103113
python:
104114
[
105-
{ version: "3.8", abi: "cp38-cp38" },
106115
{ version: "3.9", abi: "cp39-cp39" },
107116
{ version: "3.10", abi: "cp310-cp310" },
108117
{ version: "3.11", abi: "cp311-cp311" },
@@ -123,48 +132,66 @@ jobs:
123132
name: Install build wheel
124133
with:
125134
arch: ${{ matrix.target }}
126-
distro: ubuntu20.04
135+
distro: ubuntu22.04
127136
githubToken: ${{ github.token }}
128137
# Mount the dist directory as /artifacts in the container
129138
dockerRunArgs: |
130139
--volume "${PWD}/dist:/artifacts"
131140
install: |
132141
apt update -y
133-
apt install -y gcc musl-dev python3-dev # this is needed for psutil
134-
apt install -y --no-install-recommends software-properties-common
135-
add-apt-repository ppa:deadsnakes/ppa
142+
apt install -y software-properties-common
143+
add-apt-repository -y ppa:deadsnakes/ppa
136144
apt update -y
137-
PYTHON=python${{ matrix.python.version }}
138-
apt install -y $PYTHON $PYTHON-distutils $PYTHON-venv
145+
apt install -y gcc musl-dev python3-dev python${{ matrix.python.version }} python${{ matrix.python.version }}-venv
139146
run: |
140147
ls -lrth /artifacts
141-
PYTHON=python${{ matrix.python.version }}
142-
$PYTHON --version
143-
$PYTHON -m venv venv
148+
python${{ matrix.python.version }} -m venv venv
144149
source venv/bin/activate
145-
pip install --upgrade pip setuptools wheel
146-
pip install --force-reinstall dist/robyn*.whl
150+
python -m pip install --upgrade pip setuptools wheel
151+
python -m pip install --force-reinstall /artifacts/robyn*.whl
147152
cd ~ && python -c 'import robyn'
148153
- name: Upload wheels
149-
uses: actions/upload-artifact@v3
154+
uses: actions/upload-artifact@v4
150155
with:
151-
name: wheels
156+
name: wheels-${{ github.job }}-${{ matrix.target }}-${{ matrix.python.version }}-${{ matrix.python.abi }}
152157
path: dist
158+
merge:
159+
name: Building Single Artifact
160+
runs-on: ubuntu-latest
161+
needs: [macos, windows, linux, linux-cross]
162+
steps:
163+
- name: Downloading all Artifacts
164+
uses: actions/download-artifact@v4
165+
with:
166+
path: artifacts
167+
pattern: wheels-*
168+
merge-multiple: true
169+
- run: |
170+
echo "Listing directories"
171+
ls -R
172+
- name: Uploading Artifact's Bundle
173+
uses: actions/upload-artifact@v4
174+
with:
175+
name: wheels
176+
path: artifacts
177+
153178
release:
154179
name: Release
155180
runs-on: ubuntu-latest
156-
needs: [macos, windows, linux, linux-cross]
181+
needs: [macos, windows, linux, linux-cross, merge]
157182
steps:
158-
- uses: actions/download-artifact@v3
183+
- uses: actions/download-artifact@v4
159184
with:
160185
name: wheels
161-
- uses: actions/setup-python@v4
186+
- name: Install uv
187+
uses: astral-sh/setup-uv@v3
188+
- uses: actions/setup-python@v5
162189
with:
163190
python-version: 3.x
164191
- name: Publish to PyPi
165192
env:
166193
TWINE_USERNAME: __token__
167194
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
168195
run: |
169-
pip install --upgrade twine
196+
uv pip install --upgrade twine
170197
twine upload --skip-existing *

0 commit comments

Comments
 (0)