coldnight / pual_bot

一个使用多路复用I/O模型的高效的WebQQ机器人, 其主要功能有 Python shell, 执行Python代码, 贴代码, 英汉互译
Other
74 stars 42 forks source link

群消息响应失败 #18

Closed Chichele closed 10 years ago

Chichele commented 10 years ago

我在群里发送指令后,控制台日志里面显示机器人回复成功了,但是我在QQ里却没有收到。 下面是部分日志记录(我设置“大雄”为机器人的nickname了):

[I 140829 11:26:48 requests:440] 获取消息: {u'retcode': 0, u'result': [{u'poll_type': u'group_message', u'value': {u'reply_ip': 180064301, u'group_code': 1494019774, u'seq': 26019, u'msg_type': 43, u'send_uin': 581530372, u'info_seq': 79614930, u'msg_id': 29092, u'content': [[u'font', {u'color': u'0080ff', u'style': [1, 0, 0], u'name': u'Tahoma', u'size': 10}], u'\u5927\u96c4 '], u'msg_id2': 843024, u'from_uin': 2976486328, u'time': 1409282808, u'to_uin': 1213380834}}]}
[I 140829 11:26:48 hub:571] 获取消息: [{u'poll_type': u'group_message', u'value': {u'reply_ip': 180064301, u'group_code': 1494019774, u'seq': 26019, u'msg_type': 43, u'send_uin': 581530372, u'info_seq': 79614930, u'msg_id': 29092, u'content': [[u'font', {u'color': u'0080ff', u'style': [1, 0, 0], u'name': u'Tahoma', u'size': 10}], u'\u5927\u96c4 '], u'msg_id2': 843024, u'from_uin': 2976486328, u'time': 1409282808, u'to_uin': 1213380834}}]
[I 140829 11:26:48 __init__:89] Plugin SimSimiPlugin handled message 大雄
[I 140829 11:26:48 client:68] [群消息] 1494019774: 夸客 ==> 大雄 
* Hostname was found in DNS cache
*   Trying 112.95.242.171...
* Rebuilt URL to: http://www.simsimi.com/?
* Found bundle for host www.simsimi.com: 0x327fa10
* Re-using existing connection! (#16) with host www.simsimi.com
* Connected to www.simsimi.com (54.236.144.23) port 80 (#16)
> GET /? HTTP/1.1
User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/28.0.1500.71 Chrome/28.0.1500.71 Safari/537.36
Host: www.simsimi.com
Accept: */*
Accept-Encoding: gzip,deflate
Cookie: AWSELB=B9551BF112497261E578B202D2B846B8A14A9E16497C786DB8922E1E6A69C0E9D6C41B7353F357B9385B46EBC3D8C20423580E4174B0C3EF4724DB56B6C005AE715398E96A; Filtering=0.0; sid=s%3AH5K5iv8VYHlooUXNtamg9Oqs.ZbqSeNMpsTGj%2BiRkiZ0L90p2n%2BUSCcShKLYX3a3V0Fk; Filtering=0.0
Accept-Charset: UTF-8,*;q=0.5
Connection: keep-alive

* Found bundle for host d.web2.qq.com: 0x2d99980
* Hostname was found in DNS cache
*   Trying 112.95.242.171...
* Connected to d.web2.qq.com (112.95.242.171) port 80 (#19)
> POST /channel/poll2 HTTP/1.1
User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/28.0.1500.71 Chrome/28.0.1500.71 Safari/537.36
Host: d.web2.qq.com
Accept: */*
Accept-Encoding: gzip,deflate
Cookie: p_skey=blA*GBmO3nx7jOeAG*KA5Fo23QArYzZhOUGOG1BTpXE_; p_uin=o1213380834; pt4_token=hGuwt-6cSSJAxNZuyau87Q__; RK=Mg8eyfwQYb; pt2gguin=o1213380834; ptcz=2a476ed1d4f27da07a6d31f28a5a88a8f5920922722e54233006d18b38f2bef9; ptisp=cm; ptwebqq=874c503d346b9df201ee7b5319e2fd9c8d6546212fec2a15123f8499e1f86877; skey=@Hf2QFaNzE; uin=o1213380834; verifysession=h02ZrmQ6ZkYlcSsqpz3gM4tbkYfAhnfATKAgNjUltdWONR7NMFJnQCpGaUVUn5i9yDuQLpLb2oWgImXxFuWQSXIQw**
Origin: http://d.web2.qq.com
Accept-Charset: UTF-8,*;q=0.5
Connection: keep-alive
Referer: https://d.web2.qq.com/cfproxy.html?v=20110331002&callback=1
Content-Length: 583
Content-Type: application/x-www-form-urlencoded

* Connected to d.web2.qq.com (112.95.242.171) port 80 (#18)
> POST /channel/send_qun_msg2 HTTP/1.1
User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/28.0.1500.71 Chrome/28.0.1500.71 Safari/537.36
Host: d.web2.qq.com
Accept: */*
Accept-Encoding: gzip,deflate
Cookie: p_skey=blA*GBmO3nx7jOeAG*KA5Fo23QArYzZhOUGOG1BTpXE_; p_uin=o1213380834; pt4_token=hGuwt-6cSSJAxNZuyau87Q__; RK=Mg8eyfwQYb; pt2gguin=o1213380834; ptcz=2a476ed1d4f27da07a6d31f28a5a88a8f5920922722e54233006d18b38f2bef9; ptisp=cm; ptwebqq=874c503d346b9df201ee7b5319e2fd9c8d6546212fec2a15123f8499e1f86877; skey=@Hf2QFaNzE; uin=o1213380834; verifysession=h02ZrmQ6ZkYlcSsqpz3gM4tbkYfAhnfATKAgNjUltdWONR7NMFJnQCpGaUVUn5i9yDuQLpLb2oWgImXxFuWQSXIQw**
Origin: http://d.web2.qq.com
Accept-Charset: UTF-8,*;q=0.5
Connection: keep-alive
Referer: https://d.web2.qq.com/cfproxy.html?v=20110331002&callback=1
Content-Length: 895
Content-Type: application/x-www-form-urlencoded

< HTTP/1.1 302 Moved Temporarily
< Access-Control-Allow-Headers: Content-Type, Authorization, Content-Length, X-Requested-With
< Access-Control-Allow-Methods: GET,PUT,POST,DELETE,OPTIONS
< Access-Control-Allow-Origin: *
< Content-Type: text/plain; charset=UTF-8
< Date: Fri, 29 Aug 2014 03:26:48 GMT
< Location: /talk.htm
< Vary: Accept, Accept-Encoding
< X-Powered-By: Express
< Content-Length: 43
< Connection: keep-alive
< 
* Ignoring the response-body
* Connection #16 to host www.simsimi.com left intact
* Issue another request to this URL: 'http://www.simsimi.com/talk.htm'
* Found bundle for host www.simsimi.com: 0x327fa10
* Re-using existing connection! (#16) with host www.simsimi.com
* Connected to www.simsimi.com (54.236.144.23) port 80 (#16)
> GET /talk.htm HTTP/1.1
User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/28.0.1500.71 Chrome/28.0.1500.71 Safari/537.36
Host: www.simsimi.com
Accept: */*
Accept-Encoding: gzip,deflate
Cookie: AWSELB=B9551BF112497261E578B202D2B846B8A14A9E16497C786DB8922E1E6A69C0E9D6C41B7353F357B9385B46EBC3D8C20423580E4174B0C3EF4724DB56B6C005AE715398E96A; Filtering=0.0; sid=s%3AH5K5iv8VYHlooUXNtamg9Oqs.ZbqSeNMpsTGj%2BiRkiZ0L90p2n%2BUSCcShKLYX3a3V0Fk; Filtering=0.0
Accept-Charset: UTF-8,*;q=0.5
Connection: keep-alive

< HTTP/1.1 200 OK
< Date: Fri, 29 Aug 2014 03:26:48 GMT
< Content-Type: text/plain; charset=utf-8
< Content-Length: 29
< Cache-Control: no-cache
< Connection: close
< 
* Closing connection 18
[I 140829 11:26:48 requests:45] [群消息] 夸客: 小的在 ==> 1494019774 成功
< HTTP/1.1 302 Moved Temporarily
< Access-Control-Allow-Headers: Content-Type, Authorization, Content-Length, X-Requested-With
< Access-Control-Allow-Methods: GET,PUT,POST,DELETE,OPTIONS
< Access-Control-Allow-Origin: *
< Content-Type: text/plain; charset=UTF-8
< Date: Fri, 29 Aug 2014 03:26:48 GMT
< Location: /language.htm
< Vary: Accept, Accept-Encoding
< X-Powered-By: Express
< Content-Length: 47
< Connection: keep-alive
< 
* Ignoring the response-body
* Connection #16 to host www.simsimi.com left intact
* Issue another request to this URL: 'http://www.simsimi.com/language.htm'
* Found bundle for host www.simsimi.com: 0x327fa10
* Re-using existing connection! (#16) with host www.simsimi.com
* Connected to www.simsimi.com (54.236.144.23) port 80 (#16)
> GET /language.htm HTTP/1.1
User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/28.0.1500.71 Chrome/28.0.1500.71 Safari/537.36
Host: www.simsimi.com
Accept: */*
Accept-Encoding: gzip,deflate
Cookie: AWSELB=B9551BF112497261E578B202D2B846B8A14A9E16497C786DB8922E1E6A69C0E9D6C41B7353F357B9385B46EBC3D8C20423580E4174B0C3EF4724DB56B6C005AE715398E96A; Filtering=0.0; sid=s%3AH5K5iv8VYHlooUXNtamg9Oqs.ZbqSeNMpsTGj%2BiRkiZ0L90p2n%2BUSCcShKLYX3a3V0Fk; Filtering=0.0
Accept-Charset: UTF-8,*;q=0.5
Connection: keep-alive

< HTTP/1.1 200 OK
< Access-Control-Allow-Headers: Content-Type, Authorization, Content-Length, X-Requested-With
< Access-Control-Allow-Methods: GET,PUT,POST,DELETE,OPTIONS
< Access-Control-Allow-Origin: *
< Content-Encoding: gzip
< Content-Type: text/html; charset=utf-8
< Date: Fri, 29 Aug 2014 03:26:49 GMT
< ETag: "991066145"
< Vary: Accept-Encoding
< X-Powered-By: Express
< transfer-encoding: chunked
< Connection: keep-alive
< 
* Connection #16 to host www.simsimi.com left intact
* Found bundle for host www.simsimi.com: 0x327fa10
* Re-using existing connection! (#16) with host www.simsimi.com
* Connected to www.simsimi.com (54.236.144.23) port 80 (#16)
> POST /func/setProfile HTTP/1.1
User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/28.0.1500.71 Chrome/28.0.1500.71 Safari/537.36
Host: www.simsimi.com
Accept-Encoding: gzip,deflate
Cookie: AWSELB=B9551BF112497261E578B202D2B846B8A14A9E16497C786DB8922E1E6A69C0E9D6C41B7353F357B9385B46EBC3D8C20423580E4174B0C3EF4724DB56B6C005AE715398E96A; Filtering=0.0; sid=s%3AH5K5iv8VYHlooUXNtamg9Oqs.ZbqSeNMpsTGj%2BiRkiZ0L90p2n%2BUSCcShKLYX3a3V0Fk; Filtering=0.0
Accept-Language: zh-cn,en_us;q=0.7,en;q=0.3
Accept: application/json, text/javascript, */*; q=0.01
Referer: http://www.simsimi.com/set_profile_frameview.htm
Accept-Charset: UTF-8,*;q=0.5
Connection: keep-alive
Cookie: simsimi_uid=52125598
X-Requested-With: XMLHttpRequest
Content-Type: application/json; charset=utf-8
Content-Length: 22

< HTTP/1.1 400 Bad Request
< Access-Control-Allow-Headers: Content-Type, Authorization, Content-Length, X-Requested-With
< Access-Control-Allow-Methods: GET,PUT,POST,DELETE,OPTIONS
< Access-Control-Allow-Origin: *
< Content-Type: text/html
< Date: Fri, 29 Aug 2014 03:26:49 GMT
< Vary: Accept-Encoding
< X-Powered-By: Express
< Content-Length: 11
< Connection: keep-alive
* HTTP error before end of send, stop sending
< 
* Closing connection 16
* Hostname was NOT found in DNS cache
* Resolving timed out after 501 milliseconds
* Closing connection 20
[I 140829 11:27:33 requests:408] 心跳...
coldnight commented 10 years ago

这个很正常, 一些新的 QQ 在跑得时候群消息开始会有点不正常, 发几个链接让它解析一下, 过一会应该就好了