Skip to content

Commit 132028f

Browse files
[pre-commit.ci] pre-commit autoupdate (#526)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Tobias Raabe <[email protected]>
1 parent e7786ec commit 132028f

15 files changed

+18
-18
lines changed

.pre-commit-config.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -45,13 +45,13 @@ repos:
4545
hooks:
4646
- id: sort-all
4747
- repo: https://github.com/astral-sh/ruff-pre-commit
48-
rev: v0.1.6
48+
rev: v0.1.7
4949
hooks:
5050
- id: ruff-format
5151
- id: ruff
5252
args: [--unsafe-fixes]
5353
- repo: https://github.com/dosisod/refurb
54-
rev: v1.24.0
54+
rev: v1.25.0
5555
hooks:
5656
- id: refurb
5757
args: [--ignore, FURB126]

docs_src/how_to_guides/bp_scaling_tasks_4.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111

1212
def _create_parametrization(
13-
estimations: dict[str, dict[str, str]]
13+
estimations: dict[str, dict[str, str]],
1414
) -> dict[str, str | Path]:
1515
id_to_kwargs = {}
1616
for name, config in estimations.items():

docs_src/how_to_guides/interfaces/products_annotation_with_pnode.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,6 @@
66

77

88
def task_write_file(
9-
path: Annotated[Path, PathNode(path=Path("file.txt")), Product]
9+
path: Annotated[Path, PathNode(path=Path("file.txt")), Product],
1010
) -> None:
1111
path.touch()

docs_src/how_to_guides/writing_custom_nodes_example_2_py310_return.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@ class PickleNode:
1313

1414

1515
def task_example(
16-
df: Annotated[pd.DataFrame, in_node]
16+
df: Annotated[pd.DataFrame, in_node],
1717
) -> Annotated[pd.DataFrame, out_node]:
1818
return df.apply(...)

docs_src/how_to_guides/writing_custom_nodes_example_2_py38_return.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@ class PickleNode:
1313

1414

1515
def task_example(
16-
df: Annotated[pd.DataFrame, in_node]
16+
df: Annotated[pd.DataFrame, in_node],
1717
) -> Annotated[pd.DataFrame, out_node]:
1818
return df.apply(...)

docs_src/tutorials/defining_dependencies_products_products_py310.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99

1010
def task_create_random_data(
11-
path_to_data: Annotated[Path, Product] = BLD / "data.pkl"
11+
path_to_data: Annotated[Path, Product] = BLD / "data.pkl",
1212
) -> None:
1313
rng = np.random.default_rng(0)
1414
beta = 2

docs_src/tutorials/defining_dependencies_products_products_py38.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99

1010
def task_create_random_data(
11-
path_to_data: Annotated[Path, Product] = BLD / "data.pkl"
11+
path_to_data: Annotated[Path, Product] = BLD / "data.pkl",
1212
) -> None:
1313
rng = np.random.default_rng(0)
1414
beta = 2

docs_src/tutorials/defining_dependencies_products_relative_py310.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,6 @@
55

66

77
def task_create_random_data(
8-
path_to_data: Annotated[Path, Product] = Path("../bld/data.pkl")
8+
path_to_data: Annotated[Path, Product] = Path("../bld/data.pkl"),
99
) -> None:
1010
...

docs_src/tutorials/defining_dependencies_products_relative_py38.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,6 @@
55

66

77
def task_create_random_data(
8-
path_to_data: Annotated[Path, Product] = Path("../bld/data.pkl")
8+
path_to_data: Annotated[Path, Product] = Path("../bld/data.pkl"),
99
) -> None:
1010
...

docs_src/tutorials/skipping_tasks_example_1.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,6 @@
77

88
@pytask.mark.skip()
99
def task_long_running(
10-
path: Annotated[Path, Product] = Path("time_intensive_product.pkl")
10+
path: Annotated[Path, Product] = Path("time_intensive_product.pkl"),
1111
) -> None:
1212
...

docs_src/tutorials/using_a_data_catalog_2_py310.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99

1010
def task_create_random_data(
11-
node: Annotated[PickleNode, Product] = data_catalog["data"]
11+
node: Annotated[PickleNode, Product] = data_catalog["data"],
1212
) -> None:
1313
rng = np.random.default_rng(0)
1414
beta = 2

docs_src/tutorials/using_a_data_catalog_2_py38.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88

99
def task_create_random_data(
10-
node: Annotated[PickleNode, Product] = data_catalog["data"]
10+
node: Annotated[PickleNode, Product] = data_catalog["data"],
1111
) -> None:
1212
rng = np.random.default_rng(0)
1313
beta = 2

src/_pytask/logging.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ def pytask_log_session_header(session: Session) -> None:
9292

9393

9494
def _format_plugin_names_and_versions(
95-
plugininfo: list[tuple[str, DistFacade]]
95+
plugininfo: list[tuple[str, DistFacade]],
9696
) -> list[str]:
9797
"""Format name and version of loaded plugins."""
9898
values: list[str] = []

src/_pytask/task.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ def pytask_collect_file(
5757

5858

5959
def _raise_error_when_task_functions_are_duplicated(
60-
tasks: list[Callable[..., Any]]
60+
tasks: list[Callable[..., Any]],
6161
) -> None:
6262
"""Raise error when task functions are duplicated.
6363

src/_pytask/task_utils.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ def wrapper(func: Callable[..., Any]) -> Callable[..., Any]:
149149

150150

151151
def _parse_after(
152-
after: str | Callable[..., Any] | list[Callable[..., Any]] | None
152+
after: str | Callable[..., Any] | list[Callable[..., Any]] | None,
153153
) -> str | list[Callable[..., Any]]:
154154
if not after:
155155
return []
@@ -246,7 +246,7 @@ def _parse_task_kwargs(kwargs: Any) -> dict[str, Any]:
246246

247247

248248
def parse_keyword_arguments_from_signature_defaults(
249-
task: Callable[..., Any]
249+
task: Callable[..., Any],
250250
) -> dict[str, Any]:
251251
"""Parse keyword arguments from signature defaults."""
252252
parameters = inspect.signature(task).parameters
@@ -258,7 +258,7 @@ def parse_keyword_arguments_from_signature_defaults(
258258

259259

260260
def _generate_ids_for_tasks(
261-
tasks: list[tuple[str, Callable[..., Any]]]
261+
tasks: list[tuple[str, Callable[..., Any]]],
262262
) -> dict[str, Callable[..., Any]]:
263263
"""Generate unique ids for parametrized tasks."""
264264
parameters = inspect.signature(tasks[0][1]).parameters

0 commit comments

Comments
 (0)