0

I'm using VS Code on Macbook. I have Python, Python for VSCode, Python Extension Pack and Python Extended packs installed on VSCode. Right now my code is totally runnable. I'm 100% it works perfectly fine. However, VSCode still falsely gives me so many unnecessary underlines.

In the first picture, it thinks my indentations are wrong; in the second one, it underlines cv2 and numpy, because it doesn't know the existence of these libraries. Seeing the editor like this is just annoying. Any ways to make these underlines disappear?

  • Image for Indentation underlined:

image

  • Image for Imported libraries underlined:

image

1
  • In VSCode press Ctrl+Shift+P

  • Type python linting

  • Select Python: Enable Linting

  • Choose Off

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.