From 89365e274399438654021498a6a4ed81292124ad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ond=C5=99ej=20Gajdu=C5=A1ek?= Date: Thu, 19 Dec 2024 13:28:19 +0100 Subject: [PATCH] Switch Airgun CI/CQ to uv --- .github/workflows/pull_request.yml | 26 ++++++++++++++++++++++---- 1 file changed, 22 insertions(+), 4 deletions(-) diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml index e62b210df..787d29de9 100644 --- a/.github/workflows/pull_request.yml +++ b/.github/workflows/pull_request.yml @@ -7,6 +7,7 @@ on: env: PYCURL_SSL_LIBRARY: openssl + UV_SYSTEM_PYTHON: 1 jobs: codechecks: @@ -24,11 +25,19 @@ jobs: with: python-version: ${{ matrix.python-version }} + - name: Install the latest version of uv and set the Python version + uses: astral-sh/setup-uv@v4 + with: + python-version: ${{ matrix.python-version }} + enable-cache: true + cache-dependency-glob: | + **/requirements*.txt + **/setup.py + - name: Install Dependencies run: | sudo apt update - pip install -U pip - pip install -U -r requirements.txt -r requirements-optional.txt + uv pip install -U -r requirements.txt -r requirements-optional.txt - name: Analysis (git diff) if: failure() @@ -41,6 +50,7 @@ jobs: robottelo-cross-check: name: Robottelo installation cross-check runs-on: ubuntu-latest + needs: codechecks steps: - name: Checkout Airgun uses: actions/checkout@v4 @@ -50,6 +60,15 @@ jobs: with: python-version: '3.12' + - name: Install the latest version of uv and set the Python version + uses: astral-sh/setup-uv@v4 + with: + python-version: '3.12' + enable-cache: true + cache-dependency-glob: | + **/requirements*.txt + **/setup.py + - name: Download robottelo's requirements.txt run: | curl -s https://raw.githubusercontent.com/SatelliteQE/robottelo/$GITHUB_BASE_REF/requirements.txt -o requirements-robottelo.txt @@ -60,5 +79,4 @@ jobs: - name: Robottelo Installability run: | - pip install -U pip - pip install -U -r requirements-robottelo.txt -r requirements.txt -r requirements-optional.txt + uv pip install -U -r requirements-robottelo.txt -r requirements.txt -r requirements-optional.txt