line-length = 120
indent-width = 4
target-version = "py313"

exclude = [
    ".venv",
    ".devenv",
    ".git",
    ".vscode",
    "build",
    "site",
    "__pycache__",
]

[lint]
preview = true

extend-select = [
    "ARG",      # https://docs.astral.sh/ruff/rules/#flake8-unused-arguments-arg
	"B",        # https://docs.astral.sh/ruff/rules/#flake8-bugbear-b
	"C4",       # https://docs.astral.sh/ruff/rules/#flake8-comprehensions-c4
    "DOC102",   # https://docs.astral.sh/ruff/rules/docstring-extraneous-parameter/
    "DOC202",   # https://docs.astral.sh/ruff/rules/docstring-extraneous-returns/
    "DOC403",   # https://docs.astral.sh/ruff/rules/docstring-extraneous-yields/
    "DOC502",   # https://docs.astral.sh/ruff/rules/docstring-extraneous-exception/
	"E", "W",   # https://docs.astral.sh/ruff/rules/#pycodestyle-e-w
	"F",        # https://docs.astral.sh/ruff/rules/#pyflakes-f
    "FURB",     # https://docs.astral.sh/ruff/rules/#refurb-furb
	"I",        # https://docs.astral.sh/ruff/rules/#isort-i
    "N",        # https://docs.astral.sh/ruff/rules/#pep8-naming-n
    "PD",       # https://docs.astral.sh/ruff/rules/#pandas-vet-pd
    "PTH",      # https://docs.astral.sh/ruff/rules/#flake8-use-pathlib-pth
	"UP",       # https://docs.astral.sh/ruff/rules/#pyupgrade-up
	"SIM",      # https://docs.astral.sh/ruff/rules/#flake8-simplify-sim
    "PLR0202",  # https://docs.astral.sh/ruff/rules/no-classmethod-decorator/
    "PLR0203",  # https://docs.astral.sh/ruff/rules/no-staticmethod-decorator/
    "PLR0206",  # https://docs.astral.sh/ruff/rules/property-with-parameters/
    "PLR0915",  # https://docs.astral.sh/ruff/rules/too-many-statements/
    "PLR1702",  # https://docs.astral.sh/ruff/rules/too-many-nested-blocks/
    "TRY002",
]
extend-fixable = ["ALL"]
ignore = [
    "UP046",
    "UP047",
]

[lint.extend-per-file-ignores]
"*.ipynb" = [
    "F401", # unused imports
    "F841", # unused local variable
    "F821", # undefined name in exploratory notebook cells
]

[lint.isort]
force-single-line = true

[format]
quote-style = "double"
indent-style = "space"
skip-magic-trailing-comma = false
line-ending = "auto"
