From 9f7fb48923ad1ced8265ba2051fcbd9ba7cef440 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 23 Oct 2023 18:16:34 +0000 Subject: [PATCH 1/3] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/psf/black: 23.9.1 → 23.10.0](https://github.com/psf/black/compare/23.9.1...23.10.0) - [github.com/astral-sh/ruff-pre-commit: v0.0.292 → v0.1.1](https://github.com/astral-sh/ruff-pre-commit/compare/v0.0.292...v0.1.1) - [github.com/dosisod/refurb: v1.21.0 → v1.22.1](https://github.com/dosisod/refurb/compare/v1.21.0...v1.22.1) - [github.com/pre-commit/mirrors-mypy: v1.6.0 → v1.6.1](https://github.com/pre-commit/mirrors-mypy/compare/v1.6.0...v1.6.1) --- .pre-commit-config.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index e6598bf7..91362ac1 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -44,15 +44,15 @@ repos: hooks: - id: sort-all - repo: https://github.com/psf/black - rev: 23.9.1 + rev: 23.10.0 hooks: - id: black - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.0.292 + rev: v0.1.1 hooks: - id: ruff - repo: https://github.com/dosisod/refurb - rev: v1.21.0 + rev: v1.22.1 hooks: - id: refurb args: [--ignore, FURB126] @@ -63,7 +63,7 @@ repos: args: [-v, --fail-under=75] exclude: ^(tests/|docs/|scripts/|docs_src/) - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.6.0 + rev: v1.6.1 hooks: - id: mypy additional_dependencies: [ From 9524943a2a32274f5d076a3060d12642ef74a960 Mon Sep 17 00:00:00 2001 From: Tobias Raabe Date: Tue, 24 Oct 2023 11:30:58 +0200 Subject: [PATCH 2/3] Fix. --- src/_pytask/dag.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/_pytask/dag.py b/src/_pytask/dag.py index 758a7f1c..f3f1b81e 100644 --- a/src/_pytask/dag.py +++ b/src/_pytask/dag.py @@ -204,7 +204,7 @@ def _check_if_dag_has_cycles(dag: nx.DiGraph) -> None: def _format_cycles(cycles: list[tuple[str, ...]]) -> str: """Format cycles as a paths connected by arrows.""" - chain = [x for i, x in enumerate(itertools.chain(*cycles)) if i % 2 == 0] + chain = [x for i, x in enumerate(itertools.chain.from_iterable(cycles)) if i % 2 == 0] chain += [cycles[-1][1]] lines = chain[:1] From 653e2155013fd0e14f6a4b3f9b5e56b00e643980 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Tue, 24 Oct 2023 09:32:22 +0000 Subject: [PATCH 3/3] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- src/_pytask/dag.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/_pytask/dag.py b/src/_pytask/dag.py index f3f1b81e..07953838 100644 --- a/src/_pytask/dag.py +++ b/src/_pytask/dag.py @@ -204,7 +204,9 @@ def _check_if_dag_has_cycles(dag: nx.DiGraph) -> None: def _format_cycles(cycles: list[tuple[str, ...]]) -> str: """Format cycles as a paths connected by arrows.""" - chain = [x for i, x in enumerate(itertools.chain.from_iterable(cycles)) if i % 2 == 0] + chain = [ + x for i, x in enumerate(itertools.chain.from_iterable(cycles)) if i % 2 == 0 + ] chain += [cycles[-1][1]] lines = chain[:1]