I am trying to use the newer version of Python but when I type:
import sys
print sys.version_info
I get back:
sys.version_info(major=2, minor=7, micro=1, releaselevel='final', serial=0)
In the terminal when I enter python
I get:
Python 2.7.1 (r271:86832, Jun 16 2011, 16:59:05)
[GCC 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2335.15.00)] on darwin
When I enter python3
I get:
Python 3.3.2 (v3.3.2:d047928ae3f6, May 13 2013, 13:52:24)
[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin
As you see, I have installed Python 3.3 but no matter what I do I can't seem to actually use it in CodeRunner.
On your VS code press Ctrl + Shift + P, to open the command palette. Type and select “Python: Select Linter”. Choose PyLint from the list.
To do so, open the Command Palette (Ctrl+Shift+P) and enter Preferences: Open User Settings. Then set python.defaultInterpreterPath , which is in the Python extension section of User Settings, with the appropriate interpreter.
For the latest version of VS Code, you need to open settings (shift+command+p) and override the python interpreter value.
CodeRunner->Preferences->Languages->Run Command
edit "python $filename" to "python3 $filename"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With