diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml index e62b210df..641b22aff 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: @@ -19,16 +20,22 @@ jobs: - name: Checkout Airgun uses: actions/checkout@v4 - - name: Set Up Python-${{ matrix.python-version }} - uses: actions/setup-python@v5 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v4 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' + - 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,14 +48,22 @@ jobs: robottelo-cross-check: name: Robottelo installation cross-check runs-on: ubuntu-latest + needs: codechecks steps: - name: Checkout Airgun uses: actions/checkout@v4 - - name: Set Up Python - uses: actions/setup-python@v5 + - name: Set up Python 3.12 + uses: actions/setup-python@v4 + 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' - name: Download robottelo's requirements.txt run: | @@ -60,5 +75,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