mirror of
https://github.com/TagStudioDev/TagStudio.git
synced 2026-01-31 15:19:10 +00:00
* ci: update ruff linter config - Set line length to 100 - Enforce Google-style docstrings - Lint docstrings and imports * ci(ruff): exclude missing docstring warnings * ci(ruff): exclude docstring checks from tests dir * fix(ruff): change top level linter setting Fix Ruff warning: `warning: The top-level linter settings are deprecated in favour of their counterparts in the `lint` section. Please update the following options in `pyproject.toml`: - 'per-file-ignores' -> 'lint.per-file-ignores'`. * chore: format with ruff * add `.git-blame-ignore-revs` * ci(ruff): add E402 and F541 checks * ci(ruff): add FBT003 check (#500) * ci(ruff): add T20 check * ci(ruff)!: add N check, refactor method names * ci(ruff): add E501 check, refactor strings Much commented-out code is removed in this commit. * update `.git-blame-ignore.revs` --------- Co-authored-by: yed <yedpodtrzitko@users.noreply.github.com>
61 lines
960 B
TOML
61 lines
960 B
TOML
[tool.ruff]
|
|
exclude = ["main_window.py", "home_ui.py", "resources.py", "resources_rc.py"]
|
|
line-length = 100
|
|
|
|
[tool.ruff.lint.per-file-ignores]
|
|
"tagstudio/tests/**" = ["D", "E402"]
|
|
|
|
[tool.ruff.lint.pydocstyle]
|
|
convention = "google"
|
|
|
|
[tool.ruff.lint]
|
|
select = [
|
|
"B",
|
|
"D",
|
|
"E",
|
|
"F",
|
|
"FBT003",
|
|
"I",
|
|
"N",
|
|
"SIM",
|
|
"T20",
|
|
"UP",
|
|
]
|
|
ignore = [
|
|
"D100",
|
|
"D101",
|
|
"D102",
|
|
"D103",
|
|
"D104",
|
|
"D105",
|
|
"D106",
|
|
"D107",
|
|
]
|
|
|
|
[tool.mypy]
|
|
strict_optional = false
|
|
disable_error_code = ["func-returns-value", "import-untyped"]
|
|
explicit_package_bases = true
|
|
warn_unused_ignores = true
|
|
check_untyped_defs = true
|
|
|
|
[[tool.mypy.overrides]]
|
|
module = "tests.*"
|
|
ignore_errors = true
|
|
|
|
[[tool.mypy.overrides]]
|
|
module = "src.qt.main_window"
|
|
ignore_errors = true
|
|
|
|
[[tool.mypy.overrides]]
|
|
module = "src.qt.ui.home_ui"
|
|
ignore_errors = true
|
|
|
|
[[tool.mypy.overrides]]
|
|
module = "src.core.ts_core"
|
|
ignore_errors = true
|
|
|
|
[tool.pytest.ini_options]
|
|
#addopts = "-m 'not qt'"
|
|
qt_api = "pyside6"
|