1

I have been running Visual Studio code on the Mac for about 2 years now and I'm running into issues that I haven't seen before. I have not personally run any updates for Code for quite a while. lets say late November.

1) A message at the lower right of my Work space that says

The macOS system install of Python is not recommended,
some functionality in the extension will be limited. 
Install another version of Python for the best
experience.

Unfortunately I can't update to Python 3.x and it shouldn't be up to Code to force me to update. Is there a way to turn this message off?

2) Related to above is that some classes or language keywords (JSONUtils, @unittest, requests, def) are no longer being recognized. Some constants that I have created and a variable defined to store a class.

sc = SomeClass()

This will be recognized at definition but later during usage it will not be recognized.

sc.SomeMethod( 1, 2, 3 )

sc won't be recognized. None of this is making sense to me as it is not a pure pattern. Everything is probably the same issue. Need to point Code to python 2.7.

Keith
  • 4,129
  • 3
  • 13
  • 25

2 Answers2

1

This is a bug in VS Code. A new future version will have an ignore button.

VS Code Issue 4448

Community
  • 1
  • 1
Keith
  • 4,129
  • 3
  • 13
  • 25
0

I still can't comment, so here it is an an answer instead...

This looks like a duplicate of How can I change python version in Visual Studio Code?

The short version that worked for me:

  1. CTRL+SHIFT+P to open command palette
  2. Choose "Python: Select Interpreter"
  3. Point VS Code to the Python interpreter you wish to use.
Mr. Snrub
  • 322
  • 2
  • 13
  • Interesting... this did not fix anything. I still get the MacOS system install message and my code is scattered with invalid/incorrect red squiggles. – Keith Mar 03 '19 at 04:49
  • @Keith Hmm perplexing. Did you try any of the tweaks in the linked post? I think we're beyond my depth now; the above worked great for me, but I'm on Windows and you're on MacOS so it's quite possible that Your Mileage May Vary. – Mr. Snrub Mar 03 '19 at 05:47