import itchat
itchat.auto_login(hotReload=True)
itchat.send('Hello, filehelper', toUserName='filehelper')
运行提示:
Log in time out, reloading QR code.
Please press confirm on your phone.
Log in time out, reloading QR code.
Getting uuid of QR code.
Downloading QR code.
Please scan the QR code to log in.
原因是因为ichat微信要安全验证 5s之后才能按确认 然后二维码5秒内正好就过期了
所以需要修改源代码。
修改过程 利用 ctrl
core.py内出现receivingRetryCount参数,搜到此参数默认为5 ,延长修改为10或者更长即可。