---
source: crates/ruff_linter/src/rules/flake8_type_checking/mod.rs
---
TC003 [*] Move standard library import `pathlib.Path` into a type-checking block
 --> singledispatchmethod.py:4:21
  |
3 | from collections.abc import MutableMapping, Mapping
4 | from pathlib import Path
  |                     ^^^^
5 | from functools import singledispatchmethod
6 | from typing import Union
  |
help: Move into type-checking block
  |
3 | from collections.abc import MutableMapping, Mapping
  - from pathlib import Path
4 | from functools import singledispatchmethod
  - from typing import Union
5 + from typing import Union, TYPE_CHECKING
6 +
7 + if TYPE_CHECKING:
8 +     from pathlib import Path
9 |
  |
note: This is an unsafe fix and may change runtime behavior
