微信登录不起了吗
Traceback (most recent call last):
File "f:\wps同步\python练习\微信机器人\321.py", line 197, in <module>
itchat.auto_login(hotReload=True,loginCallback=login, exitCallback=out)
File "F:\anaconda\lib\site-packages\itchat\components\register.py", line 31, in auto_login
self.login(enableCmdQR=enableCmdQR, picDir=picDir, qrCallback=qrCallback,
File "F:\anaconda\lib\site-packages\itchat\components\login.py", line 55, in login
status = self.check_login()
File "F:\anaconda\lib\site-packages\itchat\components\login.py", line 141, in check_login
if process_login_info(self, r.text):
File "F:\anaconda\lib\site-packages\itchat\components\login.py", line 183, in process_login_info
core.loginInfo['wxsid'] = core.loginInfo['BaseRequest']['Sid'] = cookies["wxsid"]
KeyError: 'wxsid'
我重启了一下电脑,然后就登录不起了,换电脑了也不行
我也无法登录, itchat.auto_login() File "D:\ProgramData\Anaconda3\lib\site-packages\itchat\components\register.py", line 36, in auto_login loginCallback=loginCallback, exitCallback=exitCallback) File "D:\ProgramData\Anaconda3\lib\site-packages\itchat\components\login.py", line 53, in login status = self.check_login() File "D:\ProgramData\Anaconda3\lib\site-packages\itchat\components\login.py", line 137, in check_login if process_login_info(self, r.text): File "D:\ProgramData\Anaconda3\lib\site-packages\itchat\components\login.py", line 172, in process_login_info for node in xml.dom.minidom.parseString(r.text).documentElement.childNodes: File "D:\ProgramData\Anaconda3\lib\xml\dom\minidom.py", line 1968, in parseString return expatbuilder.parseString(string) File "D:\ProgramData\Anaconda3\lib\xml\dom\expatbuilder.py", line 925, in parseString return builder.parseString(string) File "D:\ProgramData\Anaconda3\lib\xml\dom\expatbuilder.py", line 223, in parseString parser.Parse(string, True) xml.parsers.expat.ExpatError: mismatched tag: line 63, column 4
试试微信网页版能登录不
试试微信网页版能登录不
登不上就g了吗
这是来自QQ邮箱的假期自动回复邮件。 您好,我最近正在休假中,无法亲自回复您的邮件。我将在假期结束后,尽快给您回复。
█Getting uuid of QR code. Downloading QR code. Please scan the QR code to log in. Please press confirm on your phone. Traceback (most recent call last): File "C:\Users\yanbi\Desktop\test (2).py", line 3, in
itchat.auto_login() File "C:\Python\Python39\lib\site-packages\itchat\components\register.py", line 35, in auto_login self.login(enableCmdQR=enableCmdQR, picDir=picDir, qrCallback=qrCallback, File "C:\Python\Python39\lib\site-packages\itchat\components\login.py", line 53, in login status = self.check_login() File "C:\Python\Python39\lib\site-packages\itchat\components\login.py", line 137, in check_login if process_login_info(self, r.text): File "C:\Python\Python39\lib\site-packages\itchat\components\login.py", line 172, in process_login_info for node in xml.dom.minidom.parseString(r.text).documentElement.childNodes: File "C:\Python\Python39\lib\xml\dom\minidom.py", line 1998, in parseString return expatbuilder.parseString(string) File "C:\Python\Python39\lib\xml\dom\expatbuilder.py", line 925, in parseString return builder.parseString(string) File "C:\Python\Python39\lib\xml\dom\expatbuilder.py", line 223, in parseString parser.Parse(string, True) xml.parsers.expat.ExpatError: mismatched tag: line 63, column 4
这个如何解决的呢?
█Getting uuid of QR code. Downloading QR code. Please scan the QR code to log in. Please press confirm on your phone. Traceback (most recent call last): File "C:\Users\yanbi\Desktop\test (2).py", line 3, in itchat.auto_login() File "C:\Python\Python39\lib\site-packages\itchat\components\register.py", line 35, in auto_login self.login(enableCmdQR=enableCmdQR, picDir=picDir, qrCallback=qrCallback, File "C:\Python\Python39\lib\site-packages\itchat\components\login.py", line 53, in login status = self.check_login() File "C:\Python\Python39\lib\site-packages\itchat\components\login.py", line 137, in check_login if process_login_info(self, r.text): File "C:\Python\Python39\lib\site-packages\itchat\components\login.py", line 172, in process_login_info for node in xml.dom.minidom.parseString(r.text).documentElement.childNodes: File "C:\Python\Python39\lib\xml\dom\minidom.py", line 1998, in parseString return expatbuilder.parseString(string) File "C:\Python\Python39\lib\xml\dom\expatbuilder.py", line 925, in parseString return builder.parseString(string) File "C:\Python\Python39\lib\xml\dom\expatbuilder.py", line 223, in parseString parser.Parse(string, True) xml.parsers.expat.ExpatError: mismatched tag: line 63, column 4
这个如何解决的呢?
同遇到这样问题,您解决了吗
出现这个问题是因为被拒绝了登录网页版,返回的是一个html页面, 而不是XML数据
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta id="viewport" name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0, viewport-fit=cover" />
<meta name="color-scheme" content="light dark">
<title>微信网页版</title>
<style>
* {
margin: 0;
padding: 0;
}
body {
font-family: Microsoft YaHei,-apple-system-font,Helvetica Neue,Helvetica,sans-serif;
font-size: 14px;
line-height: 1.6;
}
.msg {
width: 400px;
margin: 0 auto;
text-align: center;
position: absolute;
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
}
.msg-title {
font-size: 24px;
font-weight: 400;
color: #191919;
}
@media (prefers-color-scheme: dark) {
.msg-title {
color: rgba(255, 255, 255, 0.9);
}
}
.msg-desc {
margin-top: 10px;
font-weight: 400;
color: #999999;
}
.msg-button-area {
margin-top: 72px;
}
.msg-button {
width: 228px;
height: 32px;
background-color: #07C160;
border: 0;
color: #fff;
border-radius: 3px;
cursor: pointer;
display: inline-block;
vertical-align: middle;
line-height: 32px;
text-decoration: none;
}
.msg-button:hover {
background-color: #06ad56;
}
</style>
</head>
<body>
<div class="msg">
<div class="msg-text-area">
<h2 class="msg-title">提示</h2>
<p class="msg-desc">由于安全原因,此微信号不能使用网页版微信。你可以前往微信官网 https://weixin.qq.com/ 下载客户端登录。</p>
</div>
</div>
<script src="//res.wx.qq.com/t/wx_fed/webwx/res/static/vendor/vendor_bb4e225.js"></script><script>webpackJsonp([0],[function(n,exports){n.exports=""}]);/* vhtml-webpack-plugin version: 0.1.38 */</script></body>
</html>
这是来自QQ邮箱的假期自动回复邮件。 您好,我最近正在休假中,无法亲自回复您的邮件。我将在假期结束后,尽快给您回复。
替代itchat项目, ntchat来了, https://github.com/smallevilbeast/ntchat
什么情况。。。又可以登录啦?有需求,请问有办法访问嘛或者邮件联络
------------------ 原始邮件 ------------------ 发件人: @.>; 发送时间: 2023年3月5日(星期天) 下午5:45 收件人: @.>; 抄送: @.>; @.>; 主题: Re: [littlecodersh/ItChat] 微信登录不起了吗 (Issue #960)
替代itchat项目, ntchat来了, smallevilbeast/ntchat
好一个 404。
— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you are subscribed to this thread.Message ID: @.***>
出现这个问题是因为被拒绝了登录网页版,返回的是一个html页面, 而不是XML数据
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta id="viewport" name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0, viewport-fit=cover" /> <meta name="color-scheme" content="light dark"> <title>微信网页版</title> <style> * { margin: 0; padding: 0; } body { font-family: Microsoft YaHei,-apple-system-font,Helvetica Neue,Helvetica,sans-serif; font-size: 14px; line-height: 1.6; } .msg { width: 400px; margin: 0 auto; text-align: center; position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); } .msg-title { font-size: 24px; font-weight: 400; color: #191919; } @media (prefers-color-scheme: dark) { .msg-title { color: rgba(255, 255, 255, 0.9); } } .msg-desc { margin-top: 10px; font-weight: 400; color: #999999; } .msg-button-area { margin-top: 72px; } .msg-button { width: 228px; height: 32px; background-color: #07C160; border: 0; color: #fff; border-radius: 3px; cursor: pointer; display: inline-block; vertical-align: middle; line-height: 32px; text-decoration: none; } .msg-button:hover { background-color: #06ad56; } </style> </head> <body> <div class="msg"> <div class="msg-text-area"> <h2 class="msg-title">提示</h2> <p class="msg-desc">由于安全原因,此微信号不能使用网页版微信。你可以前往微信官网 https://weixin.qq.com/ 下载客户端登录。</p> </div> </div> <script src="//res.wx.qq.com/t/wx_fed/webwx/res/static/vendor/vendor_bb4e225.js"></script><script>webpackJsonp([0],[function(n,exports){n.exports=""}]);/* vhtml-webpack-plugin version: 0.1.38 */</script></body> </html>
问下具体解决方案是什么?
网页版登录可以通过这个插件绕开,不过不知道怎么整合到这个里面来 https://github.com/adamyi/wechrome