---
source: crates/ruff_linter/src/rules/flake8_type_checking/mod.rs
---
TC002 [*] Move third-party import `geopandas` into a type-checking block
 --> runtime_evaluated_base_classes_2.py:3:21
  |
1 | from __future__ import annotations
2 |
3 | import geopandas as gpd  # TC002
  |                     ^^^
4 | import pydantic
5 | import pyproj  # TC002
  |
help: Move into type-checking block
   |
2  |
   - import geopandas as gpd  # TC002
3  | import pydantic
--------------------------------------------------------------------------------
7  | import numpy
8  + from typing import TYPE_CHECKING
9  +
10 + if TYPE_CHECKING:
11 +     import geopandas as gpd
12 |
   |
note: This is an unsafe fix and may change runtime behavior

TC002 [*] Move third-party import `pyproj` into a type-checking block
 --> runtime_evaluated_base_classes_2.py:5:8
  |
3 | import geopandas as gpd  # TC002
4 | import pydantic
5 | import pyproj  # TC002
  |        ^^^^^^
6 | from pydantic import BaseModel
  |
help: Move into type-checking block
   |
4  | import pydantic
   - import pyproj  # TC002
5  | from pydantic import BaseModel
6  |
7  | import numpy
8  + from typing import TYPE_CHECKING
9  +
10 + if TYPE_CHECKING:
11 +     import pyproj
12 |
   |
note: This is an unsafe fix and may change runtime behavior
