chore: set up mypy strict checking and ship py.typed

This commit is contained in:
Tiara Rodney 2026-06-17 14:03:46 +02:00
parent ee2a729438
commit e60495b2ce
Signed by: tiara
GPG key ID: 5CD8EC1D46106723
3 changed files with 14 additions and 0 deletions

View file

@ -12,6 +12,7 @@ name = "pypi"
[dev-packages] [dev-packages]
tox = "*" tox = "*"
pytest = "*" pytest = "*"
mypy = "*"
build = "*" build = "*"
twine = "*" twine = "*"
setuptools-scm = "~=8.2.0" setuptools-scm = "~=8.2.0"

View file

@ -59,6 +59,9 @@ Git = "https://git.code.tiararodney.com/tiararodney/sekft"
where = ["src"] where = ["src"]
namespaces = true namespaces = true
[tool.setuptools.package-data]
"tiararodney.sekft" = ["py.typed"]
[tool.pytest.ini_options] [tool.pytest.ini_options]
pythonpath = ["src", "../posix-sdc/src"] pythonpath = ["src", "../posix-sdc/src"]
testpaths = ["tests"] testpaths = ["tests"]
@ -70,6 +73,16 @@ markers = [
[tool.mypy] [tool.mypy]
strict = true strict = true
mypy_path = "src"
explicit_package_bases = true
namespace_packages = true
[[tool.mypy.overrides]]
module = [
"torch.*", "transformers.*", "peft.*", "datasets.*", "bitsandbytes.*",
"tiararodney.posix_sdc.*",
]
ignore_missing_imports = true
[tool.autopep8] [tool.autopep8]
max_line_length = 80 max_line_length = 80

View file