tensorstore icon indicating copy to clipboard operation
tensorstore copied to clipboard

Generate `.pyi` files for type inference compatibility

Open timblakely opened this issue 1 year ago • 1 comments

Currently Pylance - the language server used by the VSCode python extension - doesn't play nice with the cpython compiled shared object files:

image

However, if you use mypy's stubgen program you can automatically generate .pyi files that allow the internal types to be exposed:

cd $(dirname $(python3 -c "import tensorstore; print(tensorstore.__file__)")) && stubgen -p tensorstore -o ../

image

Would be nice to ship these inside the pypi package.

timblakely avatar Apr 05 '23 21:04 timblakely

+1

stillwalker1234 avatar Dec 12 '23 14:12 stillwalker1234