Skip to content

Commit ed55b18

Browse files
committed
add mypy to precommit
1 parent 7f85dfb commit ed55b18

File tree

4 files changed

+117
-6
lines changed

4 files changed

+117
-6
lines changed

.pre-commit-config.yaml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,10 @@ repos:
1616
# Run the linter.
1717
- id: ruff
1818
# Run the formatter.
19-
- id: ruff-format
19+
- id: ruff-format
20+
21+
- repo: https://github.com/pre-commit/mirrors-mypy
22+
rev: v1.11.2
23+
hooks:
24+
- id: mypy
25+
name: mypy

poetry.lock

Lines changed: 100 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,17 @@ ydb = "^3.18.1"
1313
[tool.poetry.group.dev.dependencies]
1414
pre-commit = "^4.0.1"
1515
ruff = "^0.6.9"
16+
mypy = "^1.11.2"
17+
poethepoet = "^0.29.0"
1618

1719
[build-system]
1820
requires = ["poetry-core"]
1921
build-backend = "poetry.core.masonry.api"
22+
23+
[tool.poe.tasks]
24+
mypy = "mypy"
25+
ruff-fix = "ruff check --fix"
26+
ruff = "ruff check"
27+
lint = ["mypy", "ruff"]
28+
format-check = "ruff format --check"
29+
format = "ruff format"

ydb_dbapi/__init__.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +0,0 @@
1-
import ydb
2-
3-
a = 5
4-
b = 10

0 commit comments

Comments
 (0)