Vs code Python intellisense for manually installed package

Viewed 30

I have built a python extension using SWIG and the following setup.py file:

from setuptools import setup, Extension

ext = Extension('_MyModule',
                           sources=['MyModule_wrap.cxx'],
                           libraries= ["someLibs"]
                           )

setup (name = 'MyModule',
       version = '1.0',
       author      = "XXX ",
       description = """SWIG wrapper for my module""",
       ext_modules = [ext],
       py_modules = ["MyModule"],
       data_files=[("", ["someDll.dll"])]
       )

Then I ran python setup.py install. I see the package installed in my virtual environment and I can import it from the VS code command prompt. However, in my script, the package is not recognized. There is not auto-completion available.

I have the correct interpreter defined for the text editor.

What did I do wrong?

0 Answers
Related