diff --git a/src/darker/files.py b/src/darker/files.py index 1b99a9ece..068d12c4b 100644 --- a/src/darker/files.py +++ b/src/darker/files.py @@ -3,7 +3,7 @@ from __future__ import annotations import inspect -from typing import TYPE_CHECKING, Collection, Optional, Tuple +from typing import TYPE_CHECKING, Collection from black import ( DEFAULT_EXCLUDES, @@ -23,7 +23,7 @@ from darker.formatters.base_formatter import BaseFormatter -def find_pyproject_toml(path_search_start: Tuple[str, ...]) -> Optional[str]: +def find_pyproject_toml(path_search_start: tuple[str, ...]) -> str | None: """Find the absolute filepath to a pyproject.toml if it exists""" path_project_root = find_project_root(path_search_start) path_pyproject_toml = path_project_root / "pyproject.toml"