Fatal error in launcher: Unable to create process

2019-01-03 00:35发布

Searching the net this seems to be a problem caused by spaces in the Python installation path.

How do I get pip to work without having to reinstall everything in a path without spaces ?

标签: python pip
22条回答
可以哭但决不认输i
2楼-- · 2019-01-03 01:29

For me this problem appeared when I changed the environment path to point to v2.7 which was initially pointing to v3.6. After that, to run pip or virtualenv commands, I had to python -m pip install XXX as mentioned in the answers below.

So, in order to get rid of this, I ran the v2.7 installer again, chose change option and made sure that, add to path option was enabled, and let the installer run. After that everything works as it should.

查看更多
Explosion°爆炸
3楼-- · 2019-01-03 01:31

I have chosen to install Python for Windows (64bit) not for all users, but just for me.

Reinstalling Python-x64 and checking the advanced option "for all users" solved the pip problem for me.

查看更多
我命由我不由天
4楼-- · 2019-01-03 01:31

Please add this address :

C:\Program Files (x86)\Python33

in Windows PATH Variable

Though first make sure this is the folder where Python exe file resides, then only add this path to the PATH variable.

To append addresses in PATH variable, Please go to

Control Panel -> Systems -> Advanced System Settings -> Environment Variables -> System Variables -> Path -> Edit ->

Then append the above mentioned path & click Save

查看更多
\"骚年 ilove
5楼-- · 2019-01-03 01:32

On Windows at least, pip stores the execution path in the executable pip.exe when it is installed.

Edit this file using a hex editor or WordPad (you have to save it as plain text then to retain binary data), change the path to Python with quotes and spaces like this:

#!"C:\Program Files (x86)\Python33\python.exe"

to an escaped path without spaces and quotes and pad with spaces (dots at the end should be spaces):

#!C:\Progra~2\Python33\python.exe.............

For "C:\Program Files", this path would probably be "C:\Progra~1" (shortened path names in DOS / Windows 3.x notation use tilde and numbers). Windows provides this alternative notation for backwards compatibility with DOS / Windows 3.x apps.

Note that as this is a binary file, you should not change the file size which may break the executable, hence the padding.

Save with administrator privileges, make sure it is actually saved at the target location and try again.

You might also need to set the PATH variable to use the ~ notation for the path to pip.

查看更多
贪生不怕死
6楼-- · 2019-01-03 01:32

I had a similar issue and upgrading pip fixed it for me.

python -m pip install --upgrade pip 

This was on Windows and the path to python inside pip.exe was incorrect. See Archimedix answer for more information about the path.

查看更多
做个烂人
7楼-- · 2019-01-03 01:32

On windows I solved this problem a little complex way :

1) Uninstalled Python

2) went to C:\Users\MyName\AppData\Local\Programs(your should turn on hidden files visibility Show hidden files instruction)

3)deleted 'Python' folder

4) installed Python

查看更多
登录 后发表回答