diff --git a/.github/workflows/checks.yaml b/.github/workflows/checks.yaml index f570366..8ede01b 100644 --- a/.github/workflows/checks.yaml +++ b/.github/workflows/checks.yaml @@ -3,11 +3,7 @@ name: Checks on: push: - branches: - - master pull_request: - branches: - - master env: CACHE_VERSION: 1 @@ -43,9 +39,7 @@ jobs: id: generate-python-key run: >- echo "key=${{ env.KEY_PREFIX }}-${{ env.CACHE_VERSION }}-${{ - hashFiles('pyproject.toml', 'requirements_test.txt', - 'requirements_test_min.txt', 'requirements_test_pre_commit.txt') }}" >> - $GITHUB_OUTPUT + hashFiles('pyproject.toml', 'requirements/**.txt') }}" >> $GITHUB_OUTPUT - name: Restore Python virtual environment id: cache-venv uses: actions/cache@v4.0.0 @@ -66,7 +60,7 @@ jobs: path: ${{ env.PRE_COMMIT_CACHE }} key: >- ${{ runner.os }}-${{ steps.generate-pre-commit-key.outputs.key }} - - name: install dependencies + - name: Install Dependencies if: steps.cache-venv.outputs.cache-hit != 'true' run: make install diff --git a/.github/workflows/run-tests.yaml b/.github/workflows/tests.yaml similarity index 99% rename from .github/workflows/run-tests.yaml rename to .github/workflows/tests.yaml index db63fd6..a482b2b 100644 --- a/.github/workflows/run-tests.yaml +++ b/.github/workflows/tests.yaml @@ -1,5 +1,5 @@ --- -name: Testing +name: Tests on: push: diff --git a/Makefile b/Makefile index 9209c6e..341bff5 100644 --- a/Makefile +++ b/Makefile @@ -16,7 +16,7 @@ requirements/dev.txt: .venv requirements/dev.in pyproject.toml --quiet --generate-hashes --max-rounds=20 --strip-extras \ --resolver=backtracking \ --output-file requirements/dev.txt \ - requirements/dev.in pyproject.toml + requirements/dev.in # upgrades the dependencies to their latest/matching version .PHONY: upgrade @@ -26,14 +26,12 @@ upgrade: .venv --upgrade \ --resolver=backtracking \ --output-file requirements/dev.txt \ - requirements/dev.in pyproject.toml + requirements/dev.in # creates the venv if not present then install the dependencies, the package and pre-commit .PHONY: install install: .venv pip-sync requirements/dev.txt - # install pylint_pytest (deps are already handled by the line before) - pip install --no-deps -e . # install pre-commit hooks pre-commit install diff --git a/requirements/dev.in b/requirements/dev.in index 2926cab..fb819fa 100644 --- a/requirements/dev.in +++ b/requirements/dev.in @@ -1,3 +1,7 @@ +# Install pylint-pytest and its dependencies. +# tl;dr: Install pylint +-e file:.#egg=pylint-pytest + # to handle dependencies pip-tools wheel