juzibot / donut-tester

40 stars 4 forks source link

message的函数触发非常慢,达到10多秒 #46

Closed xuwancheng closed 3 years ago

xuwancheng commented 3 years ago

Important:Please file the issue follow the template, or we won't help you to solve the problem.

0. Report Issue Guide

  1. Please run the following command and check whether the problem has been fixed:

    rm -rf package-lock.json
    rm -rf node_modules
    npm install
  2. Please search in FAQ List first, and make sure your problem has not been solved before.

  3. Please search in the issue first, and make sure your problem had not been reported before

1. Versions

2. Describe the bug

发送图片的时候,message的回调特别慢,达到10多秒(基本没有10秒以内),而PadPlus的协议的只需要1-2秒就可以触发,我用的就是Example里面的代码。 .on('message', async message => { console.log(message: ${JSON.stringify(message)}) })

3. To Reproduce

我用的就是Example里面的代码,也做了对比视频,已经发给Juzi.BOT。

4. Expected behavior

希望跟PadPlus的速度差不多

5. Actual behavior

现在的反应时间是10-15秒

6. Full Output Logs

程序没有出错,没有设置Log

Show Logs ```shell $ WECHATY_LOG=silly node yourbot.js Question: Paste your FULL(DO NOT ONLY PROVIDE FRAGMENTS) log messages Answer: ```

7. Additional context

Add any other context about the problem here.

[bug]

su-chang commented 3 years ago

升级hostie版本 0.11.5

提供所发图片的原图,接收图片的时间和图片大小有关。

xuwancheng commented 3 years ago

先把图片发给您 微信图片_20201113151306

su-chang commented 3 years ago

这边测试基本1秒左右就能收到。

xuwancheng commented 3 years ago

问题可能还是发生在wechaty-puppet-hostie的版本问题,我这边用的是NodeJS,这边就只运行了npm install wechaty@next, 我在package.json里面并没有发现有wechaty-puppet-hostie这个配置,然后我就手动执行了npm install wechaty-puppet-hostie, 然后看到"wechaty-puppet-hostie": "^0.10.8" 这一行,请问如何将版本升级到0.11.5?

xuwancheng commented 3 years ago

贴一下我这边的代码: const { Wechaty } = require('wechaty'); const { ScanStatus } = require('wechaty-puppet'); const QrcodeTerminal = require('qrcode-terminal');

const token = 'XXXX'

const bot = new Wechaty({ puppet: 'wechaty-puppet-hostie', puppetOptions: { token, } });

bot .on('scan', (qrcode, status) => { if (status === ScanStatus.Waiting) { QrcodeTerminal.generate(qrcode, { small: true }) } }) .on('login', async user => { console.log(user: ${JSON.stringify(user)}) }) .on('message', async message => { console.log(message: ${JSON.stringify(message)}) }) .start()

su-chang commented 3 years ago

重新安装下wechaty即可

xuwancheng commented 3 years ago

我删除了所有的Module,然后执行npm install wechaty, 只有wechaty的版本,应该是最新的,但是并没有看到wechaty-puppet-hostie的包,还需要执行什么命令吗?怎么知道wechaty-puppet-hostie的版本号? 111

su-chang commented 3 years ago

npm ls wechaty-puppet-hostie

xuwancheng commented 3 years ago

运行了命令,查看到版本号是最新的,但是我测试过后问题依旧,还是需要等待10多秒才会进入函数,我有一个猜想:会不会是因为你那边在内部环境,而我这边是在外部环境造成的? PS D:\P-WeRobot\SourceCode_V2.1\WeRobotClientDonut1> npm ls wechaty-puppet-hostie Debugger attached. werobotdonut@0.0.1 D:\P-WeRobot\SourceCode_V2.1\WeRobotClientDonut1 -- wechaty@0.49.8 -- wechaty-puppet-hostie@0.11.5

xuwancheng commented 3 years ago

或者是恰巧分配给我的那台主机性能比较差,对图片处理速度慢?

xuwancheng commented 3 years ago

我发现package-lock.json里面的版本为什么是0.11.0呢,我删除了重新安装的 "wechaty": { "version": "0.49.8", "resolved": "https://registry.npmjs.org/wechaty/-/wechaty-0.49.8.tgz", "integrity": "sha512-MQSuwbp32zgyZjxAzWRa8RrPf0jnPpttXnrq42M6P7LmE15gUPB7e+1jMg3MxbsxXsMwXMQqYG182sIo2Ens4w==", "requires": { "brolog": "^1.12.4", "clone-class": "^0.7.3", "cuid": "^2.1.8", "dotenv": "^8.2.0", "in-gfw": "^1.2.0", "json-rpc-peer": "^0.17.0", "npm-programmatic": "0.0.12", "open-graph": "^0.2.4", "opencollective": "^1.0.3", "opencollective-postinstall": "^2.0.3", "pkg-dir": "^5.0.0", "portfinder": "^1.0.28", "promise-retry": "^2.0.1", "raven": "^2.6.4", "read-pkg-up": "^7.0.1", "state-switch": "^0.9.9", "typed-emitter": "^1.3.1", "watchdog": "^0.8.17", "wechaty-puppet": "^0.33.3", "wechaty-puppet-hostie": "^0.11.0", "ws": "^7.3.1" }

su-chang commented 3 years ago

这边给你开了一个临时测试的token: puppet_donut_b8819e4a46f6605c

你用这个测试下看看

su-chang commented 3 years ago

"wechaty-puppet-hostie": "^0.11.0",

你需要理解下 ^的含义

xuwancheng commented 3 years ago

谢谢你的提醒关于^的含义,我刚才用你提供的测试的token测试,发现问题依旧,文字消息是秒到的,图片消息还是10秒以上,问题没有得到解决,您那边如果方便,我这边可以开远程桌面给你看下,方便问题的寻找,我的电话18662591312,如果您需要语音了解的话

su-chang commented 3 years ago

你可以把接收到的图片消息的详细日志打印一下,列到comment中。

message payload中有对应的timestamp 看下详细日志再说吧。

WECHATY_LOG=silly ts-node index.ts

xuwancheng commented 3 years ago

我这边收到的消息JSON格式化是这样的,那个WECHATY_LOG=silly ts-node index.ts我这边不是typescript的,我研究下怎么加上去 { "_events": {}, "_eventsCount": 0, "id": "5099372405356501864", "payload": { "filename": "", "fromId": "q34539890", "id": "5099372405356501864", "mentionIdList": [], "roomId": "", "text": "<?xml version=\"1.0\"?>\n\n\t<img aeskey=\"f379ca028eb8bf07e0c602c4e554d97a\" encryver=\"0\" cdnthumbaeskey=\"f379ca028eb8bf07e0c602c4e554d97a\" cdnthumburl=\"3058020100044c304a0201000204eb95de7402032f55f902042a0260b402045fae284a0425617570696d675f613665306438363866643462336536345f31363035323439303937393035020401050a020201000405004c54a100\" cdnthumblength=\"5214\" cdnthumbheight=\"90\" cdnthumbwidth=\"120\" cdnmidheight=\"0\" cdnmidwidth=\"0\" cdnhdheight=\"0\" cdnhdwidth=\"0\" cdnmidimgurl=\"3058020100044c304a0201000204eb95de7402032f55f902042a0260b402045fae284a0425617570696d675f613665306438363866643462336536345f31363035323439303937393035020401050a020201000405004c54a100\" length=\"61722\" md5=\"fe622b1056a7895bb111b3ac224ef7f1\" hevc_mid_size=\"61722\" />\n\n", "timestamp": 1605256506000, "toId": "filehelper", "type": 6 } }

su-chang commented 3 years ago

请提供相对完整的日志,局部日志难以排查问题,至少接收消息日志的对应时间要有。

xuwancheng commented 3 years ago

cross-env WECHATY_LOG=SILLY node test/index.js

Debugger attached. Debugger attached. 16:53:13 SILL Puppet Config: WECHATY_LOG set level to SILLY 16:53:16 INFO Config registering process.on("unhandledRejection") for development/debug 16:53:16 VERB Config constructor() 16:53:24 VERB Wechaty constructor() 16:53:24 VERB StateSwitch constructor(Wechaty, "{"log":{"enableTimestamp":true,"logLevel":5,"prefixFilter":{}}}") 16:53:24 VERB StateSwitch constructor(WechatyReady, "{"log":{"enableTimestamp":true,"logLevel":5,"prefixFilter":{}}}") 16:53:24 VERB Wechaty on(scan, listener) registering... listenerCount: 0 16:53:24 VERB Wechaty on(login, listener) registering... listenerCount: 0 16:53:24 VERB Wechaty on(message, listener) registering... listenerCount: 0 16:53:24 VERB Wechaty () start() v0.49.8 is starting... 16:53:24 VERB Wechaty id: ckhg0xinw0000hwhj7ux954ox 16:53:24 SILL StateSwitch on() is false 16:53:24 SILL StateSwitch off() is true 16:53:24 VERB StateSwitch off(true) <- (true) 16:53:24 SILL StateSwitch on() is false 16:53:24 VERB StateSwitch on(pending) <- (false) 16:53:24 VERB MemoryCard constructor(undefined) 16:53:24 VERB MemoryCard getStorage() for storage type: N/A 16:53:24 VERB MemoryCard load() from storage: N/A 16:53:24 VERB MemoryCard load() no storage 16:53:24 VERB Wechaty initPuppet() wechaty-puppet-hostie 16:53:24 VERB MemoryCard multiplex(puppet) 16:53:24 VERB MemoryCard static multiplex(MemoryCard<>, puppet) 16:53:24 VERB MemoryCard constructor({"multiplex":{"name":"puppet","parent":{"payload":{},"multiplexNameList":[]}}}) 16:53:24 VERB PuppetManager resolve({puppet: wechaty-puppet-hostie, puppetOptions: {"token":"puppet_donut_1fb3edf2e7ba0ffb"}}) 16:53:24 VERB PuppetManager resolveName(wechaty-puppet-hostie) 16:53:24 VERB PuppetManager checkModule(wechaty-puppet-hostie) 16:53:24 SILL PuppetManager checkModule() wechaty-puppet-hostie installed version 0.11.5 satisfied range * 16:53:24 VERB Puppet constructor({"token":"puppet_donut_1fb3edf2e7ba0ffb"}) #0 16:53:24 VERB StateSwitch constructor(PuppetHostie, "{"log":{"enableTimestamp":true,"logLevel":5,"prefixFilter":{}}}") 16:53:24 VERB MemoryCard constructor(undefined) 16:53:24 VERB MemoryCard getStorage() for storage type: N/A 16:53:24 VERB MemoryCard load() from storage: N/A 16:53:24 VERB MemoryCard load() no storage 16:53:24 VERB Puppet constructor() watchdog timeout set to 60 seconds 16:53:24 VERB HotImport callerResolve(., D:\P-WeRobot\SourceCode_V2.1\WeRobotClientDonut1\node_modules\wechaty-puppet\dist\src\puppet.js) 16:53:24 SILL HotImport callerResolve() callsites() file=D:\P-WeRobot\SourceCode_V2.1\WeRobotClientDonut1\node_modules\hot-import\dist\src\hot-import.js, type=Object 16:53:24 SILL HotImport callerResolve() callsites() file=D:\P-WeRobot\SourceCode_V2.1\WeRobotClientDonut1\node_modules\wechaty-puppet\dist\src\puppet.js, type=null 16:53:24 SILL HotImport callerResolve() callsites() file=D:\P-WeRobot\SourceCode_V2.1\WeRobotClientDonut1\node_modules\wechaty-puppet-hostie\dist\src\client\puppet-hostie.js, type=null 16:53:24 SILL HotImport callerResolve() callerFile=D:\P-WeRobot\SourceCode_V2.1\WeRobotClientDonut1\node_modules\wechaty-puppet-hostie\dist\src\client\puppet-hostie.js 16:53:24 VERB Puppet constructor() childClassPath=D:\P-WeRobot\SourceCode_V2.1\WeRobotClientDonut1\node_modules\wechaty-puppet-hostie\dist\src\client 16:53:24 VERB Puppet setMemory() 16:53:24 VERB Wechaty initPuppetEventBridge(Puppet#0()) 16:53:24 VERB Wechaty initPuppetEventBridge() puppet.on(friendship) (listenerCount:0) registering... 16:53:24 VERB Wechaty initPuppetEventBridge() puppet.on(login) (listenerCount:0) registering... 16:53:24 VERB Wechaty initPuppetEventBridge() puppet.on(logout) (listenerCount:0) registering... 16:53:24 VERB Wechaty initPuppetEventBridge() puppet.on(message) (listenerCount:0) registering... 16:53:24 VERB Wechaty initPuppetEventBridge() puppet.on(room-invite) (listenerCount:0) registering... 16:53:24 VERB Wechaty initPuppetEventBridge() puppet.on(room-join) (listenerCount:0) registering... 16:53:24 VERB Wechaty initPuppetEventBridge() puppet.on(room-leave) (listenerCount:0) registering... 16:53:24 VERB Wechaty initPuppetEventBridge() puppet.on(room-topic) (listenerCount:0) registering... 16:53:24 VERB Wechaty initPuppetEventBridge() puppet.on(scan) (listenerCount:0) registering... 16:53:24 VERB Wechaty initPuppetEventBridge() puppet.on(dirty) (listenerCount:0) registering... 16:53:24 VERB Wechaty initPuppetEventBridge() puppet.on(dong) (listenerCount:0) registering... 16:53:24 VERB Wechaty initPuppetEventBridge() puppet.on(error) (listenerCount:0) registering... 16:53:24 VERB Wechaty initPuppetEventBridge() puppet.on(heartbeat) (listenerCount:0) registering... 16:53:24 VERB Wechaty initPuppetEventBridge() puppet.on(ready) (listenerCount:0) registering... 16:53:24 VERB Wechaty initPuppetEventBridge() puppet.on(reset) (listenerCount:0) registering... 16:53:24 VERB Wechaty wechatifyUserModules(Puppet#0()) 16:53:24 VERB PuppetHostie start() 16:53:24 SILL StateSwitch on() is false 16:53:24 SILL StateSwitch on() is false 16:53:24 VERB StateSwitch on(pending) <- (false) 16:53:24 VERB PuppetHostie startGrpcClient() 16:53:24 VERB PuppetHostie discoverHostieIp(puppet_donut_1fb3edf2e7ba0ffb) 16:53:25 VERB PuppetHostie startGrpcStream() 16:53:25 VERB PuppetHostie onGrpcStreamEvent({type:EVENT_TYPE_LOGIN(25), payload:"{"contactId":"q34539890"}"}) 16:53:25 VERB Contact load(q34539890) init pool 16:53:26 SILL Contact constructor(q34539890) 16:53:26 SILL Contact ready() @ Puppet#0() with id="q34539890" 16:53:26 SILL Puppet contactPayload(q34539890) cache MISS 16:53:26 VERB PuppetHostie contactRawPayload(q34539890) 16:53:26 SILL StateSwitch on() is pending 16:53:26 VERB StateSwitch on(true) <- (pending) 16:53:26 VERB Wechaty on(heartbeat, listener) registering... listenerCount: 0 16:53:26 SILL StateSwitch on() is pending 16:53:26 VERB StateSwitch on(true) <- (pending) 16:53:26 SILL Puppet contactPayload(q34539890) cache SET user: {"_events":{},"_eventsCount":0,"id":"q34539890","payload":{"address":" ","alias":"","avatar":"http://wx.qlogo.cn/mmhead/ver_1/oy29R9vbpiaxOdccISyJC046gRRLjVOr5DXKAcIjicgd4rlI1QSxnDhKYnLxrEVpcrZIZc1zqFK8MB2icJXIZrkpQ/0","city":"","corporation":"","coworker":false,"description":"","friend":true,"gender":1,"id":"q34539890","name":"徐万成--软件服务","phone":[],"province":"","signature":"","star":false,"title":"","type":1,"weixin":""}} 16:53:48 VERB PuppetHostie onGrpcStreamEvent({type:EVENT_TYPE_MESSAGE(2), payload:"{"messageId":"4951262135378079760"}"}) 16:53:48 SILL Wechaty memoryCheck() free: 2123 MB, require: 4 MB 16:53:48 VERB Message static load(4951262135378079760) 16:53:48 VERB Message constructor(4951262135378079760) for class WechatifiedMessage 16:53:48 VERB Message ready() 16:53:48 VERB Puppet messagePayload(4951262135378079760) 16:53:48 SILL Puppet messagePayloadCache(4951262135378079760) cache MISS 16:53:48 VERB PuppetHostie messageRawPayload(4951262135378079760) 16:53:49 SILL Puppet messagePayload(4951262135378079760) cache SET 16:53:49 VERB Contact load(q34539890) init pool 16:53:49 SILL Contact constructor(q34539890) 16:53:49 SILL Contact ready() @ Puppet#0() with id="q34539890" 16:53:49 SILL Contact constructor(filehelper) 16:53:49 SILL Contact ready() @ Puppet#0() with id="filehelper" 16:53:49 SILL Puppet contactPayload(filehelper) cache MISS 16:53:49 VERB PuppetHostie contactRawPayload(filehelper) 16:53:49 SILL Puppet contactPayload(filehelper) cache SET message: {"_events":{},"_eventsCount":0,"id":"4951262135378079760","payload":{"filename":"","fromId":"q34539890","id":"4951262135378079760","mentionIdList":[],"roomId":"","text":"<?xml version=\"1.0\"?>\n\n\t<img aeskey=\"f379ca028eb8bf07e0c602c4e554d97a\" encryver=\"0\" cdnthumbaeskey=\"f379ca028eb8bf07e0c602c4e554d97a\" cdnthumburl=\"3058020100044c304a0201000204eb95de7402032f55f902042a0260b402045fae284a0425617570696d675f613665306438363866643462336536345f31363035323439303937393035020401050a020201000405004c54a100\" cdnthumblength=\"5214\" cdnthumbheight=\"90\" cdnthumbwidth=\"120\" cdnmidheight=\"0\" cdnmidwidth=\"0\" cdnhdheight=\"0\" cdnhdwidth=\"0\" cdnmidimgurl=\"3058020100044c304a0201000204eb95de7402032f55f902042a0260b402045fae284a0425617570696d675f613665306438363866643462336536345f31363035323439303937393035020401050a020201000405004c54a100\" length=\"61722\" md5=\"fe622b1056a7895bb111b3ac224ef7f1\" hevc_mid_size=\"61722\" />\n\n","timestamp":1605257624000,"toId":"filehelper","type":6}} 16:53:49 VERB Puppet selfId() 16:53:52 VERB PuppetHostie onGrpcStreamEvent({type:EVENT_TYPE_HEARTBEAT(1), payload:"{"data":"[object Object]"}"}) 16:53:52 SILL Wechaty memoryCheck() free: 2082 MB, require: 4 MB

su-chang commented 3 years ago

接收消息的日志时间:16:53:49 消息实际发送时间:2020-11-13 16:53:44

这个时间差是5s

你这个是用文件助手发的图片,你可以尝试接收联系人发的图片试试。

xuwancheng commented 3 years ago

我这边试了,用另外一个联系人发给我,问题是一样的,下面的Logo前后有一点点是其他的干扰消息,你看中间主要的 17:04:50 SILL Contact ready() @ Puppet#0() with id="nickyau0" message: {"_events":{},"_eventsCount":0,"id":"7081046718916237353","payload":{"filename":"","fromId":"nickyau0","id":"7081046718916237353","mentionIdList":[],"roomId":"8191420627@chatroom","text":"你这个还能打照片吧","timestamp":1605258293000,"toId":"","type":7}} 17:05:02 VERB PuppetHostie onGrpcStreamEvent({type:EVENT_TYPE_HEARTBEAT(1), payload:"{"data":"[object Object]"}"}) 17:05:02 SILL Wechaty memoryCheck() free: 2222 MB, require: 4 MB 17:05:42 VERB PuppetHostie onGrpcStreamEvent({type:EVENT_TYPE_MESSAGE(2), payload:"{"messageId":"4540013635554292165"}"}) 17:05:42 SILL Wechaty memoryCheck() free: 2229 MB, require: 4 MB 17:05:42 VERB Message static load(4540013635554292165) 17:05:42 VERB Message constructor(4540013635554292165) for class WechatifiedMessage 17:05:42 VERB Message ready() 17:05:42 VERB Puppet messagePayload(4540013635554292165) 17:05:42 SILL Puppet messagePayloadCache(4540013635554292165) cache MISS 17:05:42 VERB PuppetHostie messageRawPayload(4540013635554292165) 17:05:42 SILL Puppet messagePayload(4540013635554292165) cache SET 17:05:42 SILL Contact ready() @ Puppet#0() with id="wxid_ftek8r3ozbj421" 17:05:42 SILL Contact ready() isReady() true 17:05:42 SILL Contact ready() @ Puppet#0() with id="q34539890" 17:05:42 SILL Contact ready() isReady() true message: {"_events":{},"_eventsCount":0,"id":"4540013635554292165","payload":{"filename":"","fromId":"wxid_ftek8r3ozbj421","id":"4540013635554292165","mentionIdList":[],"roomId":"","text":"<?xml version=\"1.0\"?>\n\n\t<img aeskey=\"f379ca028eb8bf07e0c602c4e554d97a\" encryver=\"0\" cdnthumbaeskey=\"f379ca028eb8bf07e0c602c4e554d97a\" cdnthumburl=\"3058020100044c304a0201000204eb95de7402032f55f902042a0260b402045fae284a0425617570696d675f613665306438363866643462336536345f31363035323439303937393035020401050a020201000405004c54a100\" cdnthumblength=\"5186\" cdnthumbheight=\"90\" cdnthumbwidth=\"120\" cdnmidheight=\"0\" cdnmidwidth=\"0\" cdnhdheight=\"0\" cdnhdwidth=\"0\" cdnmidimgurl=\"3058020100044c304a0201000204eb95de7402032f55f902042a0260b402045fae284a0425617570696d675f613665306438363866643462336536345f31363035323439303937393035020401050a020201000405004c54a100\" length=\"61722\" md5=\"fe622b1056a7895bb111b3ac224ef7f1\" hevc_mid_size=\"61722\" />\n\n","timestamp":1605258338000,"toId":"q34539890","type":6}} 17:05:43 VERB Puppet selfId() 17:05:46 VERB PuppetHostie onGrpcStreamEvent({type:EVENT_TYPE_HEARTBEAT(1), payload:"{"data":"[object Object]"}"}) 17:05:46 SILL Wechaty memoryCheck() free: 2215 MB, require: 4 MB 17:05:53 VERB PuppetHostie onGrpcStreamEvent({type:EVENT_TYPE_MESSAGE(2), payload:"{"messageId":"982705075622391824"}"}) 17:05:53 SILL Wechaty memoryCheck() free: 2226 MB, require: 4 MB 17:05:53 VERB Message static load(982705075622391824) 17:05:53 VERB Message constructor(982705075622391824) for class WechatifiedMessage 17:05:53 VERB Message ready() 17:05:53 VERB Puppet messagePayload(982705075622391824) 17:05:53 SILL Puppet messagePayloadCache(982705075622391824) cache MISS 17:05:53 VERB PuppetHostie messageRawPayload(982705075622391824) 17:05:53 SILL Puppet messagePayload(982705075622391824) cache SET 17:05:53 VERB Room ready() 17:05:53 SILL Contact ready() @ Puppet#0() with id="wxid_6y3n8qqe3dqz12" message: {"_events":{},"_eventsCount":0,"id":"982705075622391824","payload":{"filename":"","fromId":"wxid_6y3n8qqe3dqz12","id":"982705075622391824","mentionIdList":[],"roomId":"8191420627@chatroom","text":"是滴","timestamp":1605258358000,"toId":"","type":7}}

xuwancheng commented 3 years ago

你上面说的是5秒,但是我这边从转发出去开始到断点被触发,我自己数了一下,有10秒左右

su-chang commented 3 years ago

17:05:42 "timestamp":1605258338000 => 2020-11-13 17:05:38 你自行这样排查下吧。目前来看没有你说的10秒以上的情况

xuwancheng commented 3 years ago

我跟踪了一下Logo,我从17:16:00左右转发图片出去,一直等待到17:16:13才开始打印,单后图片的时间戳时间是17:16:8,从0秒到13才开始打印Logo,从0秒到图片的时间戳0秒之间,不知道系统在做什么?

17:15:59 VERB PuppetHostie onGrpcStreamEvent({type:EVENT_TYPE_HEARTBEAT(1), payload:"{"data":"[object Object]"}"}) 17:15:59 SILL Wechaty memoryCheck() free: 2191 MB, require: 4 MB 17:16:13 VERB PuppetHostie onGrpcStreamEvent({type:EVENT_TYPE_MESSAGE(2), payload:"{"messageId":"3810917686360629709"}"}) 17:16:13 SILL Wechaty memoryCheck() free: 2199 MB, require: 4 MB 17:16:13 VERB Message static load(3810917686360629709) 17:16:13 VERB Message constructor(3810917686360629709) for class WechatifiedMessage 17:16:13 VERB Message ready() 17:16:13 VERB Puppet messagePayload(3810917686360629709) 17:16:13 SILL Puppet messagePayloadCache(3810917686360629709) cache MISS 17:16:13 VERB PuppetHostie messageRawPayload(3810917686360629709) 17:16:14 SILL Puppet messagePayload(3810917686360629709) cache SET 17:16:14 VERB Room ready() 17:16:14 SILL Contact ready() @ Puppet#0() with id="wxid_uh3cmu5lr6d812" 17:16:14 SILL Contact ready() isReady() true message: {"_events":{},"_eventsCount":0,"id":"3810917686360629709","payload":{"filename":"","fromId":"wxid_uh3cmu5lr6d812","id":"3810917686360629709","mentionIdList":[],"roomId":"19426220478@chatroom","text":"<?xml version=\"1.0\"?>\n\n\t<img aeskey=\"f379ca028eb8bf07e0c602c4e554d97a\" encryver=\"0\" cdnthumbaeskey=\"f379ca028eb8bf07e0c602c4e554d97a\" cdnthumburl=\"3058020100044c304a0201000204eb95de7402032f55f902042a0260b402045fae284a0425617570696d675f613665306438363866643462336536345f31363035323439303937393035020401050a020201000405004c54a100\" cdnthumblength=\"5214\" cdnthumbheight=\"90\" cdnthumbwidth=\"120\" cdnmidheight=\"0\" cdnmidwidth=\"0\" cdnhdheight=\"0\" cdnhdwidth=\"0\" cdnmidimgurl=\"3058020100044c304a0201000204eb95de7402032f55f902042a0260b402045fae284a0425617570696d675f613665306438363866643462336536345f31363035323439303937393035020401050a020201000405004c54a100\" length=\"61722\" md5=\"d9c7cde5d8443219de68297445b0a2ad\" hevc_mid_size=\"61722\" />\n\n","timestamp":1605258968000,"toId":"","type":6}} 17:16:32 VERB PuppetHostie onGrpcStreamEvent({type:EVENT_TYPE_HEARTBEAT(1), payload:"{"data":"[object Object]"}"}) 17:16:32 SILL Wechaty memoryCheck() free: 2199 MB, require: 4 MB

xuwancheng commented 3 years ago

日志没有显示出0-10秒的行为,时间应该就是在这里被浪费的

10

su-chang commented 3 years ago

/>\n\n","timestamp":1605258968000,"toId":"","type":6}}

这个是你发送图片的实际时间 2020-11-13 17:16:08

我从17:16:00左右转发图片出去

与你说的有较大差异。

17:16:14 接收到该条消息

17:16:14 - 17:16:08 = 6