File tree Expand file tree Collapse file tree 2 files changed +8
-4
lines changed
tests/containers/pydantic_schemas Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -147,6 +147,13 @@ ignore = [
147147# Allow unused variables when underscore-prefixed.
148148dummy-variable-rgx = " ^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
149149
150+ # Don't suggest moving types used in Pydantic models into `if TYPE_CHECKING` import blocks
151+ # https://docs.astral.sh/ruff/settings/#lint_flake8-type-checking_runtime-evaluated-base-classes
152+ flake8-type-checking.runtime-evaluated-base-classes = [" pydantic.BaseModel" ]
153+
154+ # https://docs.astral.sh/ruff/settings/#lint_pep8-naming_classmethod-decorators
155+ pep8-naming.classmethod-decorators = [" pydantic.validator" ]
156+
150157# https://docs.astral.sh/ruff/formatter
151158[tool .ruff .format ]
152159line-ending = " lf"
Original file line number Diff line number Diff line change 11from __future__ import annotations
22
33import json
4- from typing import TYPE_CHECKING
4+ from datetime import datetime
55
66from pydantic import BaseModel
77
8- if TYPE_CHECKING :
9- from datetime import datetime
10-
118
129class ConfigDir (BaseModel ):
1310 Path : str
You can’t perform that action at this time.
0 commit comments