Getting Python to run on Windows 10
I am using Atom (1.0.4) on Windows 10. I have a couple of Python packages installed, seeing as I'm new to Python and still learning.
- autocomplete-python
- linter-flake8
- script
- language-python (core)
I installed Python here: C:\Users\bramv\AppData\Local\Programs\Python\Python35\python.exe (default). I put this path in the settings of autocomplete-python, which requires the path to Python. However, when I try to execute a script with ctrl+shift+b, I get the following error:
Unable to run
python
Is it in your PATH?
PATH: C:\Users\bramv\AppData\Local\Programs\Python\Python35;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files (x86)\Skype\Phone\;C:\Users\bramv\AppData\Local\atom\bin;/usr/local/bin;/usr/bin;/bin;/usr/sbin;/sbin
I also get this error when I launch atom from command prompt with start atom.
As I said, I'm quite new to Python so maybe there's something with my code, but for now even trying to print a string doesn't work, for instance print "I like bananas".
I have the same issue with windows 7.
There was no issue two days ago.
@yuxianggu Do you have any of the packages installed that I mentioned? I ask so because then maybe it's easier to debug.
@BramVanroy
Thanks for the prompt reply.
A bit more information about the bug. Basically I cannot run anything, not just python. e.g. "Unable to run node" when trying to run a js file.
I just reinstalled Atom with only 'script' installed and the problem was still there.
And then I installed "atom-terminal" and everything can be called.
Hopefully the above information can give you some idea of debugging. Thanks.
I can confirm that installing atom-terminal solves this issue. I have been looking for a "why" but I can't find it. Any help is appreciated.
EDIT: when atom-terminal is installed, you also don't need to run Atom from the command line. It will work even if you launch it from a desktop icon.
That's probably because atom-terminal uses the fix-path package. I was against using it since it would make virtualenvs not work (it overrides the PATH).
I am on Win 10 as well though atom-script is still unable to find python path even after trying atom-terminal and fix-path (separately). Any thoughts?
Maybe this happened because you installed python without check the option ADD PYTHON X.X TO PATH... I had problems with that when running python for the first time. Did you check this option when installing python?
I have this problem and Python34 (and the Script folder too), NodeJs, Atom are in my path. All solution that I found was to add into the path variable, but nothing this fix this error.
humm, i tried everything and currently not working, i am on win 8.1 anaconda. etc. quite interestingly. next pc is same, win 8.1 and install atom and it just works with script run................this is strange
@lalamax3d Compare the PATH variable of both systems. Are they the same, or at least similar?
yes path variablewere same, quite interestingly. i removed almost all of extension packages and then install atom-terminal. restart 2-3 times and it started working in first pc. ..........thanks again..
Try doing what it says here: http://cardiffmathematicscodeclub.github.io/blog/2015/10/03/adding-python-to-the-path-windows.html. This was written by a friend of mine who solved this for Windows machines
I had the same problem: Atom, Windows 10, Python, Script, and the error "Is it in your PATH?". Installing the terminal-package did not have any effect.
I managed to fix the problem by running Atom in developer mode (View -> Developer -> Open in dev mode), hopefully it fixes it for you too.
@Asjenw Thanks! It works
@Asjenw thanks~ you slove my question
@Asjenw thanks!
@Asjenw it works. Thanks!
On my Windows7, I found it easy and straight and i hope this might help you. In Python Executable Path type C:\Python27\python.exe