Closed mwindowshz closed 5 years ago
Hey @mwindowshz
Thanks for reporting an issue. Unfortunately the autocomplete feature that you are using in VSCode is not coming from pylint
, I don't know exactly what it uses, but it's either using jedi
library or VSCode has its own autocompleter.
Regarding the other errors you are seeing, this time from pylint, it could help if you can try to add the following settings in your VSCode pylint configuration: --extension-pkg-whitelist=pytorch
. Unfortunately I don't use VSCode myself so I don't exactly how or where that flag looks like for VSCode itself. But if you have a pylintrc
configuration file and if you run pylint
from command line, adding that flag in the config file should make sure that pytorch
members can be found, if they are coming from a C extension, which I assume pytorch
actually is.
Let me know if this helps.
Hi
If you can explain the whitelist meaning.
when writing --extension-pkg-whitelist=pytorch
pylint would not check any errors for pytorch?
I would try this. (searching for the configuration placment of pylintrc file - on windows) Thanks
I am new to vscode, using for python. (tried fining answer but ...)
Autocoplete and pylint not working when editing code, but autocoplete works fine while debugging and writing in debug console.
Current behavior
autocomplete on file: does not recognise torch.rand()
Expected behavior
but in debug console it shows the correct autocomplete
problem with pylint : shoes many errors on basic typs such as torch.ones
I am using pythorch ver 1.0.0 VS Code version: Code 1.30.2 (61122f8, 2019-01-07T22:54:13.295Z) OS version: Windows_NT x64 10.0.17134 System Info Extensions (4)
Steps to reproduce
pylint --version output
pylint 2.2.2 astroid 2.1.0 Python 3.6.4 |Anaconda, Inc.| (default, Jan 16 2018, 10:22:32) [MSC v.1900 64 bit (AMD64)]