4

I want to disable hover hint for python keyword (for example import), but preserve linter message. How can I do this? enter image description here

UPDATE: settings.json

{
  "python.pythonPath": "venv/bin/python",
  "python.formatting.provider": "black",
  "python.linting.enabled": true,
  "python.linting.pylintEnabled": false,
  "python.jediEnabled": false,
  "python.linting.flake8Enabled": true,
  "python.languageServer": "Jedi",
}
IgorNikolaev
  • 1,053
  • 1
  • 12
  • 28
  • Sorry, but it's a little weird, I can not get the hint of `import`. Have you configured something in the settings.json and which python interpreter have you selected? – Steven-MSFT Jan 10 '22 at 03:08
  • @Steven-MSFT it appears by default. I now have version 1.61.2 (downloaded from github assets). Previously I had latest 1.63 (pylint messages don't appear in 1.63). – IgorNikolaev Jan 10 '22 at 09:01

2 Answers2

5

It's provided by the Jedi Language Server, You can take Pylance instead of it:

"python.languageServer": "Pylance",
Steven-MSFT
  • 7,438
  • 1
  • 5
  • 13
  • it works, but now vscode asks to install `pylance` on every start, but i guess it's a separate issue – IgorNikolaev Jan 10 '22 at 11:40
  • Great answer, I wasn't aware since I've been using Pylance as default for ages, but it had switched to Jedi while debugging inside a Docker container! – dtasev Aug 03 '22 at 14:35
0

quick solution for Mac OS: Go to

Settings of VS code --> type 'Hover" in search settings box --> Uncheck box of Editor > Hover: Enabled This is also preserve linter message if any syntax error.

There is already solution provided, please refer below URL

Disable tooltip hint in Visual Studio Code

Please have a look for screenshot: enter image description here

user8811698
  • 118
  • 1
  • 7