Open azbh111 opened 2 years ago
操作系统: MacOS 11.6.1 NodeJS: v16.13.1 设置环境变量 export WECHATY_LOG=verbose export WECHATY_PUPPET=wechaty-puppet-wechat 启动 npm start 报错日志
11:37:44 VERB PuppetWeChatEvent onScan({code: 201, url: https://login.weixin.qq.com/qrcode/odsv5ChIGQ==}) 11:37:44 VERB StateSwitch <WechatyReady> inactive(true) <- (true) 11:37:44 INFO StarterBot onScan: Scanned(3) 11:37:48 VERB PuppetWeChatBridge onLoad() page.url=https://wx2.qq.com/cgi-bin/mmwebwx-bin/webwxnewloginpage?ticket=Azgh72H3h7wI7cdoHmPzM_9K@qrticket_0&uuid=odsv5ChIGQ==&lang=en_US&scan=1641267463 11:37:48 VERB PuppetWeChatBridge readyAngular() 11:38:18 VERB PuppetWeChatBridge readyAngular() exception: TimeoutError: waiting for function failed: timeout 30000ms exceeded 11:38:18 VERB PuppetWeChatBridge testBlockedMessage(<pre style="word-wrap: break-word; white-space: pr) 11:38:18 VERB PuppetWeChatBridge preHtmlToXml() 11:38:18 WARN PuppetWeChatBridge testBlockedMessage() error.ret=1203 11:38:18 INFO PuppetWeChatBridge Please see: Account Login Issue <https://github.com/wechaty/wechaty/issues/872> 11:38:18 ERR PuppetWeChatBridge onLoad() exception: Error: 登录失败。 11:38:18 ERR Config ########################### 11:38:18 ERR Config Wechaty unhandledRejection: Error: 登录失败。 at Bridge.readyAngular (file:///Users/admin/project/github/wechaty-getting-started/node_modules/wechaty-puppet-wechat/src/bridge.ts:324:15) at processTicksAndRejections (node:internal/process/task_queues:96:5) at async Bridge.onLoad (file:///Users/admin/project/github/wechaty-getting-started/node_modules/wechaty-puppet-wechat/src/bridge.ts:212:7) [object Promise] 11:38:18 ERR Config ########################### 11:38:18 ERR Config process.on(unhandledRejection) promise.catch(登录失败。) Config GError: 登录失败。 at Bridge.readyAngular (file:///Users/admin/project/github/wechaty-getting-started/node_modules/wechaty-puppet-wechat/src/bridge.ts:324:15) at processTicksAndRejections (node:internal/process/task_queues:96:5) at async Bridge.onLoad (file:///Users/admin/project/github/wechaty-getting-started/node_modules/wechaty-puppet-wechat/src/bridge.ts:212:7) { code: 2, details: 'Error: 登录失败。\n' + ' at Bridge.readyAngular (file:///Users/admin/project/github/wechaty-getting-started/node_modules/wechaty-puppet-wechat/src/bridge.ts:324:15)\n' + ' at processTicksAndRejections (node:internal/process/task_queues:96:5)\n' + ' at async Bridge.onLoad (file:///Users/admin/project/github/wechaty-getting-started/node_modules/wechaty-puppet-wechat/src/bridge.ts:212:7)' } 11:38:44 WARN PuppetWatchdogAgent start() reset() reason: {"data":{"code":201,"url":"https://login.weixin.qq.com/qrcode/odsv5ChIGQ=="},"type":"scan","timeoutMilliseconds":60000} 11:38:44 ERR Config ########################### 11:38:44 ERR Config Wechaty uncaughtException: Error: WatchdogAgent reset: lastFood: "{"data":{"code":201,"url":"https://login.weixin.qq.com/qrcode/odsv5ChIGQ=="},"type":"scan","timeoutMilliseconds":60000}" at Watchdog.reset (file:///Users/admin/project/github/wechaty-getting-started/node_modules/wechaty-puppet/src/agents/watchdog-agent.ts:65:33) at Watchdog.emit (node:events:390:28) at Watchdog.emit (node:domain:475:12) at Timeout._onTimeout (file:///Users/admin/project/github/wechaty-getting-started/node_modules/watchdog/src/watchdog.ts:115:12) at listOnTimeout (node:internal/timers:557:17) at processTimers (node:internal/timers:500:7) uncaughtException 11:38:44 ERR Config ########################### 11:39:44 WARN PuppetWeChat initScanWatchdog() on(reset) lastFood: [object Object], timePast: 120000 11:39:44 VERB PuppetWeChatBridge reload() 11:39:44 ERR PuppetWeChat initScanWatchdog() on(reset) exception: Error: Protocol error (Page.reload): Session closed. Most likely the page has been closed. 11:39:44 ERR PuppetWeChat initScanWatchdog() on(reset) try to recover by bridge.{quit,init}() 11:39:44 VERB PuppetWeChatBridge stop() 11:39:44 VERB StateSwitch <PuppetWeChatBridge> inactive(pending) <- (false) 11:39:44 WARN PuppetWeChatBridge stop() page.close() exception: Error: Protocol error: Connection closed. Most likely the page has been closed. 11:39:44 VERB StateSwitch <PuppetWeChatBridge> inactive(true) <- (pending) 11:39:44 VERB PuppetWeChatBridge start() 11:39:44 VERB StateSwitch <PuppetWeChatBridge> active(pending) <- (false) 11:39:44 VERB PuppetWeChatBridge initBrowser() 11:39:44 VERB PuppetWeChatBridge initBrowser() with options={"args":["--audio-output-channels=0","--disable-default-apps","--disable-translate","--disable-gpu","--disable-setuid-sandbox","--disable-sync","--hide-scrollbars","--mute-audio","--no-sandbox"],"headless":true} 11:39:44 VERB PuppetWeChatBridge initBrowser() version: HeadlessChrome/93.0.4577.0 11:39:44 VERB PuppetWeChatBridge start() initBrowser() done 11:39:44 VERB PuppetWeChatBridge initPage() 11:39:45 VERB PuppetWeChatBridge cookieDomain([object Object],[object Object],[object Object]) 11:39:45 VERB PuppetWeChatBridge initPage() before page.goto(url) 11:39:47 VERB PuppetWeChatBridge initPage() after page.goto(url) 11:39:48 VERB PuppetWeChatBridge onLoad() page.url=https://wx.qq.com/?target=t 11:39:48 VERB PuppetWeChatBridge onLoad() page.url=https://wx.qq.com/?target=t 11:39:48 ERR PuppetWeChatBridge onLoad() exception: Error: Failed to add page binding with name wechatyPuppetBridgeEmit: window['wechatyPuppetBridgeEmit'] already exists! 11:39:48 ERR PuppetWeChatBridge onLoad() exception: ProtocolError: Protocol error (Page.addScriptToEvaluateOnNewDocument): Target closed. 11:39:48 ERR Config ########################### 11:39:48 ERR Config Wechaty unhandledRejection: Error: Protocol error: Connection closed. Most likely the page has been closed. at assert (/Users/admin/project/github/wechaty-getting-started/node_modules/puppeteer/src/common/assert.ts:23:21) at Page.close (/Users/admin/project/github/wechaty-getting-started/node_modules/puppeteer/src/common/Page.ts:2922:11) at Bridge.onLoad (file:///Users/admin/project/github/wechaty-getting-started/node_modules/wechaty-puppet-wechat/src/bridge.ts:220:18) at processTicksAndRejections (node:internal/process/task_queues:96:5) [object Promise] 11:39:48 ERR Config ########################### 11:39:48 ERR Config process.on(unhandledRejection) promise.catch(Protocol error: Connection closed. Most likely the page has been closed.) Config GError: Protocol error: Connection closed. Most likely the page has been closed. at assert (/Users/admin/project/github/wechaty-getting-started/node_modules/puppeteer/src/common/assert.ts:23:21) at Page.close (/Users/admin/project/github/wechaty-getting-started/node_modules/puppeteer/src/common/Page.ts:2922:11) at Bridge.onLoad (file:///Users/admin/project/github/wechaty-getting-started/node_modules/wechaty-puppet-wechat/src/bridge.ts:220:18) at processTicksAndRejections (node:internal/process/task_queues:96:5) { code: 2, details: 'Error: Protocol error: Connection closed. Most likely the page has been closed.\n' + ' at assert (/Users/admin/project/github/wechaty-getting-started/node_modules/puppeteer/src/common/assert.ts:23:21)\n' + ' at Page.close (/Users/admin/project/github/wechaty-getting-started/node_modules/puppeteer/src/common/Page.ts:2922:11)\n' + ' at Bridge.onLoad (file:///Users/admin/project/github/wechaty-getting-started/node_modules/wechaty-puppet-wechat/src/bridge.ts:220:18)\n' + ' at processTicksAndRejections (node:internal/process/task_queues:96:5)' } 11:39:48 ERR Config ########################### 11:39:48 ERR Config Wechaty unhandledRejection: Error: Failed to add page binding with name wechatyPuppetBridgeEmit: window['wechatyPuppetBridgeEmit'] already exists! at Page.exposeFunction (/Users/admin/project/github/wechaty-getting-started/node_modules/puppeteer/src/common/Page.ts:1393:13) at Bridge.onLoad (file:///Users/admin/project/github/wechaty-getting-started/node_modules/wechaty-puppet-wechat/src/bridge.ts:209:20) at processTicksAndRejections (node:internal/process/task_queues:96:5) [object Promise] 11:39:48 ERR Config ########################### 11:39:48 ERR Config process.on(unhandledRejection) promise.catch(Failed to add page binding with name wechatyPuppetBridgeEmit: window['wechatyPuppetBridgeEmit'] already exists!) Config GError: Failed to add page binding with name wechatyPuppetBridgeEmit: window['wechatyPuppetBridgeEmit'] already exists! at Page.exposeFunction (/Users/admin/project/github/wechaty-getting-started/node_modules/puppeteer/src/common/Page.ts:1393:13) at Bridge.onLoad (file:///Users/admin/project/github/wechaty-getting-started/node_modules/wechaty-puppet-wechat/src/bridge.ts:209:20) at processTicksAndRejections (node:internal/process/task_queues:96:5) { code: 2, details: "Error: Failed to add page binding with name wechatyPuppetBridgeEmit: window['wechatyPuppetBridgeEmit'] already exists!\n" + ' at Page.exposeFunction (/Users/admin/project/github/wechaty-getting-started/node_modules/puppeteer/src/common/Page.ts:1393:13)\n' + ' at Bridge.onLoad (file:///Users/admin/project/github/wechaty-getting-started/node_modules/wechaty-puppet-wechat/src/bridge.ts:209:20)\n' + ' at processTicksAndRejections (node:internal/process/task_queues:96:5)' }
Looks like it's the same issue here: https://github.com/wechaty/puppet-wechat/issues/192
操作系统: MacOS 11.6.1 NodeJS: v16.13.1 设置环境变量 export WECHATY_LOG=verbose export WECHATY_PUPPET=wechaty-puppet-wechat 启动 npm start 报错日志