diff --git a/MANIFEST.in b/MANIFEST.in index 2aa1e1d..6ac08ff 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,4 +1,5 @@ include *.md +global-include py.typed *.pyi recursive-include doc *.py *.rst recursive-include examples *.html *.js *.png *.py recursive-include tests *.dcm *.png *.py *.svs *.tiff diff --git a/pyproject.toml b/pyproject.toml index 6bb05bb..6394f6f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -38,11 +38,15 @@ Documentation = "https://openslide.org/api/python/" Repository = "https://github.com/openslide/openslide-python" [tool.setuptools] +include-package-data = false packages = ["openslide"] [tool.setuptools.dynamic] version = {attr = "openslide._version.__version__"} +[tool.setuptools.package-data] +openslide = ["py.typed", "*.pyi"] + [tool.black] skip-string-normalization = true target-version = ["py38", "py39", "py310", "py311", "py312", "py313"] diff --git a/setup.py b/setup.py index 4a5e532..a4702e7 100644 --- a/setup.py +++ b/setup.py @@ -21,7 +21,4 @@ # tag wheel for Limited API 'bdist_wheel': {'py_limited_api': 'cp311'} if _abi3 else {}, }, - package_data={ - 'openslide': ['py.typed'], - }, )