Getting error 'SyntaxError: invalid syntax' when trying to install Jupyter Notebook using pip on Windows 10
9,180
Those are not the same commands I found on their website: This is what I found: If Python 3 is installed:
python3 -m pip install --upgrade pip
python3 -m pip install jupyter
For Python 2:
python -m pip install --upgrade pip
python -m pip install jupyter
Hope this helps.
Related videos on Youtube
![jack.py](https://i.stack.imgur.com/3wxwd.jpg?s=256&g=1)
Comments
-
jack.py almost 2 years
I am using the command on the Jupyter website,
pip3 install jupyter
but I get the error:
File "<stdin>", line 1 pip3 install jupyter ^ SyntaxError: invalid syntax
I've tried many different commands, and they all produce the same error. I'm reluctant to install Anaconda, as I already have python installed on my computer.
-
jack.py almost 5 yearsI did use these commands at first (still returns an error), but then on their help page and official documentation it tells you to use the commands I stated,
-
rtyocum almost 5 yearsAre you able to run Python at all from CMD. If not you may have to change your system’s PATH variable to the python install directory
-
jack.py almost 5 yearsyeah, I can run python. I figured out that I didn't have pip in my PATH environment variable. I fixed it now.
-
Ting Yi Shih over 3 yearsYou saved me! It turns out that I'm installing the python3 version of jupyter with python2. Installing it with python3 makes it work!