diff --git a/pdm.lock b/pdm.lock index d5f6848..0877b3e 100644 --- a/pdm.lock +++ b/pdm.lock @@ -5,10 +5,24 @@ groups = ["default", "dev"] strategy = ["inherit_metadata"] lock_version = "4.5.0" -content_hash = "sha256:b8c78f3679a91711144cac4d1d558cad80470ddb4c350d7409f419b3db462e22" +content_hash = "sha256:9760696434f3c5496929539bd0d968d60732150e34e59713be5e2e8d9b1be47c" [[metadata.targets]] -requires_python = ">=3.10" +requires_python = "~=3.10" + +[[package]] +name = "basedpyright" +version = "1.39.9" +requires_python = ">=3.8" +summary = "static type checking for Python (but based)" +groups = ["dev"] +dependencies = [ + "nodejs-wheel-binaries>=20.13.1", +] +files = [ + {file = "basedpyright-1.39.9-py3-none-any.whl", hash = "sha256:6b0837b9eba972c71895167ab9b127e6afdbc17abc92312e3f8d15ca82a5611c"}, + {file = "basedpyright-1.39.9.tar.gz", hash = "sha256:32cbea5fc8273e89df3db20daea56cb7286e419ccdfdc479c64759d2dc071901"}, +] [[package]] name = "colorama" @@ -149,6 +163,27 @@ files = [ {file = "markupsafe-3.0.3.tar.gz", hash = "sha256:722695808f4b6457b320fdc131280796bdceb04ab50fe1795cd540799ebe1698"}, ] +[[package]] +name = "nodejs-wheel-binaries" +version = "24.16.0" +requires_python = ">=3.7" +summary = "unoffical Node.js package" +groups = ["dev"] +dependencies = [ + "typing-extensions; python_version < \"3.8\"", +] +files = [ + {file = "nodejs_wheel_binaries-24.16.0-py2.py3-none-macosx_13_0_arm64.whl", hash = "sha256:d9f8f677dcf30e37ac244f07869726abe043f01eb0f45722b1df31cc2af7093c"}, + {file = "nodejs_wheel_binaries-24.16.0-py2.py3-none-macosx_13_0_x86_64.whl", hash = "sha256:3d0370fe7120ce9697a4f60d40480d2bd8808d9f30131458d5afc0040d4e5a51"}, + {file = "nodejs_wheel_binaries-24.16.0-py2.py3-none-manylinux_2_28_aarch64.whl", hash = "sha256:85dc92bbb79c851569c5925dcc2a4c915a034efab375f99e4e7e6bbe9cca8342"}, + {file = "nodejs_wheel_binaries-24.16.0-py2.py3-none-manylinux_2_28_x86_64.whl", hash = "sha256:2f3036292811514ba847b3708492644764f88a833ac425c5f55007014308ddfd"}, + {file = "nodejs_wheel_binaries-24.16.0-py2.py3-none-musllinux_1_2_aarch64.whl", hash = "sha256:db8a8a76ebd2b28ecbfc9ad464baa3707241b9e050a30e2efdf6f60c0f886502"}, + {file = "nodejs_wheel_binaries-24.16.0-py2.py3-none-musllinux_1_2_x86_64.whl", hash = "sha256:f1a3d8f7b4491cbbd023ba3fc4e901fcca2d9fb80d57f24ba3890de8b1dbac03"}, + {file = "nodejs_wheel_binaries-24.16.0-py2.py3-none-win_amd64.whl", hash = "sha256:bb136be9944f0662dcf1120f45193a6b75b13fac378971a95cc42c9f879a81aa"}, + {file = "nodejs_wheel_binaries-24.16.0-py2.py3-none-win_arm64.whl", hash = "sha256:8308940b5edd0a50dc5267ea36ba21c9f668e83fe0d9f293937174d3a7e31c36"}, + {file = "nodejs_wheel_binaries-24.16.0.tar.gz", hash = "sha256:c973cb69dc5fd16e6f6dc6e579e2c3d5534e2a1f57619dddf5ba070efa7dde37"}, +] + [[package]] name = "packaging" version = "26.2" diff --git a/pyproject.toml b/pyproject.toml index 3e11d0f..38f2b24 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -19,7 +19,8 @@ capnpc-py = "capnp_stubgen.plugin:main" [dependency-groups] dev = [ - "pytest>=8", + "pytest>=8", + "basedpyright>=1.39.9", ] [build-system] @@ -34,3 +35,16 @@ testpaths = ["tests"] [tool.setuptools.packages.find] where = ["src"] + +[tool.basedpyright] +typeCheckingMode = "recommended" +allowedUntypedLibraries = ["pycapnp"] +reportImportCycles = "hint" + +# Downgraded to hint for capnp to_dict() dynamic data patterns +reportUnknownVariableType = "hint" +reportUnknownArgumentType = "hint" +reportUnknownMemberType = "hint" +reportUnknownParameterType = "hint" +reportAny = "hint" +reportExplicitAny = "hint"