diff --git a/.github/workflows/lint.yaml b/.github/workflows/lint.yaml index 8bde27db68e..5522e0ef051 100644 --- a/.github/workflows/lint.yaml +++ b/.github/workflows/lint.yaml @@ -56,7 +56,5 @@ jobs: run: tox -e lint_docstring_include_list - name: Run mypy checks run: tox -e mypy - - uses: psf/black@stable - with: - version: ">=25.1.0" - - uses: isort/isort-action@v1 + - name: Run format checks + run: tox -e format diff --git a/tox.ini b/tox.ini index ab1153917d2..65dcdce1c8d 100644 --- a/tox.ini +++ b/tox.ini @@ -3,6 +3,7 @@ # hyphens in an environment name are used to delimit factors envlist = first_startup + format lint lint_docstring_include_list mypy @@ -16,6 +17,8 @@ skipsdist = True [testenv] commands = first_startup: bash .ci/first_startup.sh + format: isort --check --diff . + format: black --check --diff . lint: ruff check . # Once we are happy to replace flake8 with ruff, we can replace the next line with `black --check --diff` # (since ruff delegates to black for checking/fixing many rules). @@ -31,6 +34,8 @@ commands = test_galaxy_packages_for_pulsar: bash packages/test.sh --for-pulsar allowlist_externals = bash + black + isort make passenv = CI @@ -52,6 +57,7 @@ setenv = unit: marker=not external_dependency_management deps = coverage: coverage + format: -rlib/galaxy/dependencies/dev-requirements.txt lint,lint_docstring,lint_docstring_include_list: -rlib/galaxy/dependencies/pinned-lint-requirements.txt mypy: -rlib/galaxy/dependencies/pinned-typecheck-requirements.txt mypy: -rlib/galaxy/dependencies/pinned-requirements.txt