在Python中安装Requests库(安装成功)和xlwings库(安装失败)

Requests库:处理URL资源。

xlwings库:处理大量Excel数据生成一系列的报表,实现一些Excel中的一些函数功能。

第一步:在搜索栏上,输入“cmd”,点击“以管理员身份运行”,如下:

第二步:在命令提示符,输入命令行:“pip install requests”,需要一些时间下载,如下:

第三步:下载完成,如下:

 第四步:输入命令行:“pip install xlwings”,如下:

第五步: 下载失败,如下:

 第六步:输入命令行:“conda install xlwings”,仍然失败了,只能暂时放一边。如下:

第七步:打开Python IDLE。

 第八步:打开后,输入代码,测试一下Requests库是否成功。

第九步:确定Requests库安装成功。 

关于安装xlwings很头疼,只能暂时放弃。

Microsoft Windows [Version 10.0.22000.613]
(c) Microsoft Corporation. All rights reserved.

C:\windows\system32>pip install xlwings
WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x000001A90DEA1FC0>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')': /simple/xlwings/
WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x000001A90DEA22F0>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')': /simple/xlwings/
WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x000001A90DEA2650>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')': /simple/xlwings/
WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x000001A90DEA28C0>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')': /simple/xlwings/
WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x000001A90DEA2B30>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')': /simple/xlwings/
ERROR: Could not find a version that satisfies the requirement xlwings (from versions: none)
ERROR: No matching distribution found for xlwings

C:\windows\system32>

第一步:登陆一个网站,如下:

 

第二步:按一下“Download files”,如下:

第三步:在Built Distribution的下面,直接点击一下:后缀whl格式的蓝色文件,下载很花时间。

 第四步:下载完成后,把下载的文件拖到C盘根目录,然后打开cmd,输入命令行pip install,如下:

 

  • 3
    点赞
  • 8
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值