Skip to content

Commit 8e6a2eb

Browse files
committed
Switch from mypy to ty
1 parent e0c83a1 commit 8e6a2eb

File tree

3 files changed

+4
-12
lines changed

3 files changed

+4
-12
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ rufftest:
1616

1717
.PHONY: typingtest
1818
typingtest:
19-
mypy .
19+
ty check
2020

2121
.PHONY: unittest
2222
unittest:

pyproject.toml

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ dependencies = [
3535

3636
[project.optional-dependencies]
3737
dev = [
38-
'mypy==1.17.0',
38+
'ty==0.0.1a22',
3939
]
4040

4141
[project.urls]
@@ -45,14 +45,6 @@ Repository = 'https://github.com/153957/153957-theme/'
4545
module-name = 'theme_153957'
4646
module-root = ''
4747

48-
[tool.mypy]
49-
ignore_missing_imports = true
50-
show_column_numbers = true
51-
show_error_codes = true
52-
strict = true
53-
warn_return_any = true
54-
warn_unused_configs = true
55-
5648
[tool.ruff]
5749
line-length = 120
5850
target-version = 'py311'

theme_153957/full_menu.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,13 @@ def path_to_root(album: Album) -> None:
1717
else:
1818
path_to_root += '/'
1919

20-
album.path_to_root = path_to_root
20+
album.path_to_root = path_to_root # ty: ignore[unresolved-attribute]
2121

2222

2323
def path_from_root(album: Album) -> None:
2424
"""url from gallery root"""
2525

26-
album.path_from_root = album.path
26+
album.path_from_root = album.path # ty: ignore[unresolved-attribute]
2727

2828

2929
def register(settings: dict[str, Any]) -> None:

0 commit comments

Comments
 (0)