{"action":"created","issue":{"url":"https://api.github.com/repos/littlecodersh/ItChat/issues/70","repository_url":"https://api.github.com/repos/littlecodersh/ItChat","labels_url":"https://api.github.com/repos/littlecodersh/ItChat/issues/70/labels{/name}","comments_url":"https://api.github.com/repos/littlecodersh/ItChat/issues/70/comments","events_url":"https://api.github.com/repos/littlecodersh/ItChat/issues/70/events","html_url":"https://github.com/littlecodersh/ItChat/issues/70","id":173132707,"number":70,"title":"如何保持itchat持续在线","user":{"login":"littlecodersh","id":13028340,"avatar_url":"https://avatars.githubusercontent.com/u/13028340?v=3","gravatar_id":"","url":"https://api.github.com/users/littlecodersh","html_url":"https://github.com/littlecodersh","followers_url":"https://api.github.com/users/littlecodersh/followers","following_url":"https://api.github.com/users/littlecodersh/following{/other_user}","gists_url":"https://api.github.com/users/littlecodersh/gists{/gist_id}","starred_url":"https://api.github.com/users/littlecodersh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/littlecodersh/subscriptions","organizations_url":"https://api.github.com/users/littlecodersh/orgs","repos_url":"https://api.github.com/users/littlecodersh/repos","events_url":"https://api.github.com/users/littlecodersh/events{/privacy}","received_events_url":"https://api.github.com/users/littlecodersh/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/littlecodersh/ItChat/labels/bug","name":"bug","color":"fc2929"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":14,"created_at":"2016-08-25T07:33:22Z","updated_at":"2016-08-31T08:22:18Z","closed_at":null,"body":"@featheraaa 在Issue中提出，确认为bug故新建issue\r\n\r\n## bug总览\r\n\r\n目前并不了解应该如何修复该bug，该Issue处于讨论阶段。\r\n\r\n思路与想法主要如下：\r\n1. 是否能够找到利用网页版微信协议并能保持长期稳定登陆的项目（不限语言与开源）\r\n2. 是否有可能的解决方法\r\n3. 程序是否能判断出是否出现了该种情况\r\n\r\n由于问题较为复杂，为了便于交流，我这里给出一个建议的回复模板：\r\n\r\n```\r\n2.1 是否有可能的解决方法（保持与公众号通信，保证活跃不被清理）\r\n\r\n经过尝试，仅通过该方法无法保持登陆。\r\n保持登陆时间为两天。\r\n```\r\n\r\n## 原文\r\n\r\n**featheraa**\r\n\r\n不知道是不是我人品不好，掉线率很高 ，我一台电脑登5.6个\r\n一个号最多一天半就要掉，有没有什么好一点的解决方案？\r\n请指教\r\n\r\n消息是发不出去也接收不到\r\n\r\n我是用tklinter和pyinstaller打包出来无dos窗口\r\n\r\n**brothertian**\r\n\r\n我这边程序也有类似问题，长时间运行后，收不到消息，发不出消息，send返回值为False，没有任何提示信息，阿里云windows运行环境\r\n\r\n**LittleCoder**\r\n\r\n我这里目前是阿里最基础的ubuntu服务器挂的机器人，没有做过特殊的优化。\r\npython 3.5.1, requests 2.11.0, itchat 1.1.3。\r\n上次重置时间为160813，目前可用。\r\n之前也出现过不满一周即无法接收消息的情况。\r\n使用程序见[这里][robot_main_script]。\r\n\r\n## 可能的解决方案\r\n1. 保持与公众号通信，保证活跃不被清理（不可行）\r\n2. 增加心跳包的频率（不可行）\r\n\r\n（有新想法之后我再增补）\r\n\r\n## 初步结果\r\n\r\n由于之前的讨论在Issue 1中，我这里就之前的内容做一个搬运\r\n\r\n### 保持与公众号通信，保证活跃不被清理\r\n\r\n**featheraa**\r\n\r\n用久了后会停在那里 对消息没有响应\r\n我至少半个钟内会发一次信息\r\n\r\n**brothertian**\r\n\r\n这两天做了测试，让机器人端自动每小时发一次消息，约半天左右就不能成功发出了，send返回值为false.\r\n期间机器人端无接收数据\r\n\r\n### 增加心跳包的频率\r\n\r\n**featheraa**\r\n\r\n运行两天了，修改刷新频率后 掉线似乎好了一点 六个掉两个\r\n\r\n[robot_main_script]: https://gist.github.com/littlecodersh/ec8ddab12364323c97d4e36459174f0d"},"comment":{"url":"https://api.github.com/repos/littlecodersh/ItChat/issues/comments/243693339","html_url":"https://github.com/littlecodersh/ItChat/issues/70#issuecomment-243693339","issue_url":"https://api.github.com/repos/littlecodersh/ItChat/issues/70","id":243693339,"user":{"login":"brothertian","id":20895529,"avatar_url":"https://avatars.githubusercontent.com/u/20895529?v=3","gravatar_id":"","url":"https://api.github.com/users/brothertian","html_url":"https://github.com/brothertian","followers_url":"https://api.github.com/users/brothertian/followers","following_url":"https://api.github.com/users/brothertian/following{/other_user}","gists_url":"https://api.github.com/users/brothertian/gists{/gist_id}","starred_url":"https://api.github.com/users/brothertian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brothertian/subscriptions","organizations_url":"https://api.github.com/users/brothertian/orgs","repos_url":"https://api.github.com/users/brothertian/repos","events_url":"https://api.github.com/users/brothertian/events{/privacy}","received_events_url":"https://api.github.com/users/brothertian/received_events","type":"User","site_admin":false},"created_at":"2016-08-31T08:22:18Z","updated_at":"2016-08-31T08:22:18Z","body":"@klausgao 安卓系统."}}
{"actor":{"display_login":"brothertian"}}