diff --git a/.github/workflows/pyright.yml b/.github/workflows/pyright.yml index d8e60b0a5..0c6cc7af6 100644 --- a/.github/workflows/pyright.yml +++ b/.github/workflows/pyright.yml @@ -26,24 +26,10 @@ jobs: uses: actions/setup-python@v4 with: python-version: ${{ matrix.python-version }} - - - name: Cache Poetry virtualenv - uses: actions/cache@v2 - with: - path: ~/.cache/pypoetry/virtualenvs - key: ${{ runner.os }}-poetry-${{ hashFiles('**/poetry.lock') }} - restore-keys: | - ${{ runner.os }}-poetry- - - - name: Install Poetry - uses: snok/install-poetry@v1.3.1 - - - name: Install dependencies - run: poetry install --with dev,anthropic - - - name: Add poetry to PATH - run: echo "$(poetry env info --path)/bin" >> $GITHUB_PATH - + - name: Install uv + uses: astral-sh/setup-uv@v4 + - name: Install the project + run: uv sync --all-extras - uses: jakebailey/pyright-action@v2 with: version: 1.1.373 diff --git a/.github/workflows/python-publish.yml b/.github/workflows/python-publish.yml index 1bea74f84..db0162bb3 100644 --- a/.github/workflows/python-publish.yml +++ b/.github/workflows/python-publish.yml @@ -25,17 +25,17 @@ jobs: - name: Set up Python 3.10 uses: actions/setup-python@v4 with: - python-version: '3.10' + python-version: "3.10" - - name: Install Poetry - uses: snok/install-poetry@v1.3.1 - env: - ACTIONS_ALLOW_UNSECURE_COMMANDS: 'true' + - name: Install uv + uses: astral-sh/setup-uv@v4 + - name: Install the project + run: uv sync --all-extras - name: Get release version run: echo "RELEASE_VERSION=$(poetry version | awk '{print $2}')" >> $GITHUB_ENV - name: Build and publish Python package - run: poetry publish --build + run: uv publish env: POETRY_PYPI_TOKEN_PYPI: ${{ secrets.PYPI_TOKEN }} diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index f325a570f..2e710bce9 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -20,21 +20,10 @@ jobs: uses: actions/setup-python@v4 with: python-version: ${{ matrix.python-version }} - - - name: Cache Poetry virtualenv - uses: actions/cache@v2 - with: - path: ~/.cache/pypoetry/virtualenvs - key: ${{ runner.os }}-poetry-${{ hashFiles('**/poetry.lock') }} - restore-keys: | - ${{ runner.os }}-poetry- - - - name: Install Poetry - uses: snok/install-poetry@v1.3.1 - - - name: Install dependencies - run: poetry install --with dev,anthropic - + - name: Install uv + uses: astral-sh/setup-uv@v4 + - name: Install the project + run: uv sync --all-extras - name: Run tests if: matrix.python-version != '3.11' run: poetry run pytest tests/ -k 'not llm and not openai and not gemini and not anthropic and not cohere and not vertexai' && poetry run pytest tests/llm/test_cohere diff --git a/.github/workflows/test_docs.yml b/.github/workflows/test_docs.yml index ab264130d..212144964 100644 --- a/.github/workflows/test_docs.yml +++ b/.github/workflows/test_docs.yml @@ -28,18 +28,10 @@ jobs: with: python-version: ${{ matrix.python-version }} cache: "poetry" - - - name: Cache Poetry virtualenv - uses: actions/cache@v2 - with: - path: ~/.cache/pypoetry/virtualenvs - key: ${{ runner.os }}-poetry-${{ hashFiles('**/poetry.lock') }} - restore-keys: | - ${{ runner.os }}-poetry- - - - name: Install dependencies - run: poetry install --with dev,docs,test-docs,anthropic,google-generativeai - + - name: Install uv + uses: astral-sh/setup-uv@v4 + - name: Install the project + run: uv sync --all-extras - name: Run tests run: poetry run pytest tests/llm/test_openai/docs env: