diff --git a/.github/actions/setup-python-env/action.yml b/.github/actions/setup-python-env/action.yml index 3ce30fd..c17ee1c 100644 --- a/.github/actions/setup-python-env/action.yml +++ b/.github/actions/setup-python-env/action.yml @@ -6,6 +6,10 @@ inputs: description: "Python version to use" required: true default: "3.10" + resolution: + description: "Resolution strategy" + required: true + default: "highest" uv-version: description: "uv version to use" required: true @@ -25,10 +29,19 @@ runs: enable-cache: "true" cache-suffix: ${{ inputs.python-version }} + # - name: Install Python dependencies + # # Install eo-tides and all required dependencies. + # # --all-extras will install all optional dependencies. + # # resolution method will install either "highest"" + # # versions of dependencies, or "lowest-direct" versions + # run: uv sync --all-extras --resolution lowest-direct + # shell: bash + - name: Install Python dependencies - # Install eo-tides and all required dependencies. - # --all-extras will install all optional dependencies. - # resolution method will install either "highest"" - # versions of dependencies, or "lowest-direct" versions - run: uv sync --all-extras --resolution lowest-direct + run: | + if [ "${{ inputs.resolution }}" == "lowest-direct" ]; then + uv sync --frozen --all-extras --resolution lowest-direct + else + uv sync --frozen --all-extras + fi shell: bash diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 63d7858..e48f7f3 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -51,6 +51,7 @@ jobs: uses: ./.github/actions/setup-python-env with: python-version: ${{ matrix.python-version }} + resolution: "highest" - name: Run Python unit tests run: uv run python -m pytest tests --cov --cov-config=pyproject.toml --cov-report=xml --verbose