Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use UV as a faster pip implementation #2556

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 19 additions & 23 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,15 +65,14 @@ jobs:
gdb --batch --quiet --nx --nh --ex 'py import rpyc; print(rpyc.version.version)'

- name: Set up Python ${{ matrix.python_version }}
uses: actions/setup-python@v5
uses: astral-sh/setup-uv@v5
with:
python-version: ${{ matrix.python_version }}
cache: 'pip'
cache-dependency-path: |
enable-cache: true
cache-dependency-glob: |
**/pyproject.toml
**/requirements*.txt


- name: Verify tag against version
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags')
env:
Expand Down Expand Up @@ -122,16 +121,13 @@ jobs:

- name: Install dependencies
run: |
pip install --upgrade pip
pip install --upgrade wheel build
pip install --upgrade flake8 appdirs
pip install --upgrade --editable .
uv pip install --upgrade --editable .

- name: Sanity checks
run: PWNLIB_NOTERM=1 python -bb -c 'from pwn import *; print(pwnlib.term.term_mode)'

- name: Install documentation dependencies
run: pip install -r docs/requirements.txt
run: uv pip install -r docs/requirements.txt

- name: Disable yama ptrace_scope
run: |
Expand Down Expand Up @@ -219,7 +215,7 @@ jobs:

- name: Build source and wheel distributions
run: |
python -m build
uv build

- uses: actions/upload-artifact@v4
if: matrix.python_version == '3.10'
Expand Down Expand Up @@ -248,11 +244,11 @@ jobs:
- uses: actions/checkout@v4

- name: Set up Python 3.12
uses: actions/setup-python@v5
uses: astral-sh/setup-uv@v5
with:
python-version: '3.12'
cache: 'pip'
cache-dependency-path: |
enable-cache: true
cache-dependency-glob: |
**/pyproject.toml
**/requirements*.txt

Expand Down Expand Up @@ -288,21 +284,18 @@ jobs:

- name: Install dependencies
run: |
pip install --upgrade pip
pip install --upgrade wheel build
pip install --upgrade flake8 appdirs
pip install --upgrade --editable .
uv pip install --upgrade --editable .

- name: Sanity checks
run: PWNLIB_NOTERM=1 python -c 'from pwn import *; print(pwnlib.term.term_mode)'

- name: Install documentation dependencies
run: pip install -r docs/requirements.txt
run: uv pip install -r docs/requirements.txt

- name: Coverage Doctests (Android Only)
run: |
source .android.env
PWNLIB_NOTERM=1 coverage run -m sphinx -b doctest docs/source docs/build/doctest docs/source/adb.rst
PWNLIB_NOTERM=1 python -bb -m coverage run -m sphinx -b doctest docs/source docs/build/doctest docs/source/adb.rst

- uses: actions/upload-artifact@v4
with:
Expand All @@ -318,17 +311,20 @@ jobs:
- uses: actions/checkout@v4

- name: Set up Python 3.12
uses: actions/setup-python@v5
uses: astral-sh/setup-uv@v5
with:
python-version: '3.12'
enable-cache: true
cache-dependency-glob: |
**/pyproject.toml
**/requirements*.txt

- name: Install dependencies
run: |
pip install --upgrade pip
pip install --upgrade --editable .
uv pip install --upgrade --editable .

- name: Install documentation dependencies
run: pip install -r docs/requirements.txt
run: uv pip install -r docs/requirements.txt

- name: Sanity checks
run: |
Expand Down
Loading