Skip to content

Commit 7124dd6

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 6621053 commit 7124dd6

6 files changed

Lines changed: 7 additions & 7 deletions

File tree

src/_pytask/capture.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -328,7 +328,7 @@ def repr(self, class_name: str) -> str:
328328
return "<{} {} _old={} _state={!r} tmpfile={!r}>".format(
329329
class_name,
330330
self.name,
331-
hasattr(self, "_old") and repr(self._old) or "<UNSET>",
331+
(hasattr(self, "_old") and repr(self._old)) or "<UNSET>",
332332
self._state,
333333
self.tmpfile,
334334
)
@@ -337,7 +337,7 @@ def __repr__(self) -> str:
337337
return "<{} {} _old={} _state={!r} tmpfile={!r}>".format(
338338
self.__class__.__name__,
339339
self.name,
340-
hasattr(self, "_old") and repr(self._old) or "<UNSET>",
340+
(hasattr(self, "_old") and repr(self._old)) or "<UNSET>",
341341
self._state,
342342
self.tmpfile,
343343
)

src/_pytask/mark/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@
3636

3737

3838
__all__ = [
39-
"Expression",
4039
"MARK_GEN",
40+
"Expression",
4141
"Mark",
4242
"MarkDecorator",
4343
"MarkGenerator",

src/_pytask/mark/expression.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ def __str__(self) -> str:
8181

8282

8383
class Scanner:
84-
__slots__ = ("tokens", "current")
84+
__slots__ = ("current", "tokens")
8585

8686
def __init__(self, input_: str) -> None:
8787
self.tokens = self.lex(input_)

src/_pytask/nodes.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
import pickle
88
from contextlib import suppress
99
from os import stat_result
10-
from pathlib import Path # noqa: TCH003
10+
from pathlib import Path # noqa: TC003
1111
from typing import TYPE_CHECKING
1212
from typing import Any
1313
from typing import Callable

src/_pytask/tree_util.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@
1414
from optree import tree_structure as _optree_tree_structure
1515

1616
__all__ = [
17-
"PyTree",
1817
"TREE_UTIL_LIB_DIRECTORY",
18+
"PyTree",
1919
"tree_flatten_with_path",
2020
"tree_leaves",
2121
"tree_map",

tests/test_collect_utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
import pytest
66

77
from _pytask.collect_utils import _find_args_with_product_annotation
8-
from pytask import Product # noqa: TCH001
8+
from pytask import Product
99

1010

1111
@pytest.mark.unit

0 commit comments

Comments
 (0)