测试
全部博文(931)
分类: 架构设计与优化
2019-12-08 17:39:18
使用如下的命令行安装:
pip install wxpy
Collecting wxpy
Downloading
c4561551489f36/wxpy-0.3.9.8.tar.gz (45kB)
100% | 51kB 98kB/s
Collecting itchat==1.2.32 (from wxpy)
Downloading
3fec62ed7bb343/itchat-1.2.32-py2.py3-none-any.whl
Requirement already satisfied: requests in c:\myapp\py20180816
Requirement already satisfied: future in c:\myapp\py20180816\l
om wxpy) (0.16.0)
Collecting pyqrcode (from itchat==1.2.32->wxpy)
Downloading
884ac68d979316/PyQRCode-1.2.1.tar.gz
Collecting pypng (from itchat==1.2.32->wxpy)
Downloading
017663467f5147/pypng-0.0.20.tar.gz (649kB)
Requirement already satisfied: certifi>=2017.4.17 in c:\myapp\
wxpy) (2018.8.13)
Requirement already satisfied: chardet<3.1.0,>=3.0.2 in c:\mya
ts->wxpy) (3.0.4)
Requirement already satisfied: urllib3<1.24,>=1.21.1 in c:\mya
ts->wxpy) (1.23)
在python文件wechat.py里使用这个库的时候,如果遇到如下的错误消息:ModuleNotFoundError: No module named PIL
解决方法是安装pillow这个库:
pip install pillow
如果遇到下面这个超时的错误:
Retrying (Retry(total-1, connect=None, read=None, redirect=None, status-None)) aftery 'ReadTimeoutError("HTTPSConnection Pool(host='pypi.org', port=443): Read timed out./simple/pillow/
可以使用国内镜像代替:
因为wxpy这个库背后其实使用的是微信网页版的功能,所以如果你的python程序在使用wxpy不能正常工作时,先检查你的微信账号是否能够成功登录微信网页版,如果遇到下列这种提示,说明你的微信账号无法使用wxpy库。
要获取更多Jerry的原创文章,请关注公众号"汪子熙":