2016-03-22 52 views
1

我看了很多关于此的帖子,没有任何东西可以解决它。我初步开始使用Python 3.5,听说有几个未解决的问题与点,所以我卸载并重新安装Python 3.4.4 -PIP - 升级不起作用Python3.4.4

我想使用pyautogui工作任务,但是当我尝试直接安装pyautogui在Python3.4.4安装后,它告诉我找不到PIL模块。我读过另一篇文章来安装3.4.4并更新pip,然后安装pyautogui。酷,所以我安装了3.4.4,我需要升级点子。所以我输入了

Scripts\pip.exe install --upgrade pip 

从根文件夹中的命令行。每次我得到这个

Exception: 
Traceback (most recent call last): 
    File "h:\python34\lib\shutil.py", line 527, in move 
    os.rename(src, real_dst) 
PermissionError: [WinError 32] The process cannot access the file because it is 
being used by another process: 'h:\\python34\\scripts\\pip.exe' -> 'C:\\Users\\z 
jf\\AppData\\Local\\Temp\\pip-qo75adq9-uninstall\\python34\\scripts\\pip.exe' 

During handling of the above exception, another exception occurred: 

Traceback (most recent call last): 
    File "h:\python34\lib\site-packages\pip\basecommand.py", line 211, in main 
    File "h:\python34\lib\site-packages\pip\commands\install.py", line 311, in run 

    File "h:\python34\lib\site-packages\pip\req\req_set.py", line 640, in install 
    File "h:\python34\lib\site-packages\pip\req\req_install.py", line 716, in unin 
stall 
    File "h:\python34\lib\site-packages\pip\req\req_uninstall.py", line 125, in re 
move 
    File "h:\python34\lib\site-packages\pip\utils\__init__.py", line 315, in renam 
es 
    File "h:\python34\lib\shutil.py", line 540, in move 
    os.unlink(src) 
PermissionError: [WinError 32] The process cannot access the file because it is 
being used by another process: 'h:\\python34\\scripts\\pip.exe' 

事情是,没有什么在该文件夹中运行。我没有开放的Windows资源管理器,我没有任何访问任何文件的内容,而且我显然使用命令行从上层目录运行它。所以我不知道为什么它说pip.exe正在被另一个进程使用。它正在运行的唯一过程就是它本身,如果这是问题,那么你应该如何在这个世界上升级它?

**编辑:**每接受的答案,为了得到PIP更新我用命令

python -m pip install -U pip

一旦工作,我试图再次安装pyautogui。它仍然表示无法找到PIL模块。 PIL是Python图像库。我安装了它使用

python -m pip install image

而且一旦工作,我再装pyautogui像这样

python -m pip install pyautogui

+0

我想Guido会害怕他是否知道你尝试过Python 4. – Goyo

+0

@Goyo大声笑,耶稣。我的意思是3.5。我会改变它。 Brain lapse – zfrisch

+0

当然,你以管理员身份执行“cmd.exe”? –

回答

5

在Windows升级PIP谷歌“在Windows上升级点子”或交替在运行此命令提示符:

python -m pip install -U pip 

这是Windows上的一个已知问题,其中可执行文件不能被覆盖十个运行中。对不起没有链接,但应该很容易找到更多的细节。

+0

我会试试看,并回复给你。每次点突破时我都需要一分钟,我不得不重新安装它。手指交叉和所有。 – zfrisch

+0

工作就像一个魅力! – zfrisch