9
votes

In VS Code, I tried importing a module called foo.py that has a type hinting stub file foo.pyi. I want to get code autocompletion based on the type hints in the .pyi file, as PyCharm does. However, the .pyi file does not seem to have any effect. Does anyone know if this feature is supported?

1

1 Answers

2
votes

It should be supported if you use the Pylance language server which will set "python.languageServer": "Pylance" as a side-effect of installing it.