Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

reset heartbeat error #2685

Open
DW1992 opened this issue May 2, 2024 · 3 comments
Open

reset heartbeat error #2685

DW1992 opened this issue May 2, 2024 · 3 comments

Comments

@DW1992
Copy link

DW1992 commented May 2, 2024

14:51:36 WARN PuppetWatchdogAgent start() reset() reason: {"data":"heartbeat@browserbridge ding","timeoutMilliseconds":60000}
node:events:491
throw er; // Unhandled 'error' event
^

/home/myshare/shilim/shilim-bot/node_modules/wechaty-puppet/src/agents/watchdog-agent.ts:65
this.puppet.emit('error', new Error(
^

Error: WatchdogAgent reset: lastFood: "{"data":"heartbeat@browserbridge ding","timeoutMilliseconds":60000}"
at Watchdog.reset (/home/myshare/shilim/shilim-bot/node_modules/wechaty-puppet/src/agents/watchdog-agent.ts:65:33)
at Watchdog.emit (node:events:513:28)
at Watchdog.emit (node:domain:489:12)
at Timeout._onTimeout (/home/myshare/shilim/shilim-bot/node_modules/watchdog/src/watchdog.ts:115:12)
at listOnTimeout (node:internal/timers:559:17)
at processTimers (node:internal/timers:502:7)
Emitted 'error' event on WechatyImpl instance at:
return super.emit('error', gerror)
^

Error
at WechatyImpl.emit (/home/myshare/shilim/shilim-bot/node_modules/wechaty/src/wechaty-mixins/gerror-mixin.ts:60:20)
at PuppetWeChat. (/home/myshare/shilim/shilim-bot/node_modules/wechaty/src/wechaty-mixins/puppet-mixin.ts:212:20)
at PuppetWeChat.emit (node:events:513:28)
at PuppetWeChat.emit (node:domain:489:12)
at PuppetWeChat.emit (/home/myshare/shilim/shilim-bot/node_modules/wechaty-puppet/src/puppet/puppet-skeleton.ts:142:18)
at Watchdog.reset (/home/myshare/shilim/shilim-bot/node_modules/wechaty-puppet/src/agents/watchdog-agent.ts:65:19)
at Watchdog.emit (node:events:513:28)
[... lines matching original stack trace ...]
at processTimers (node:internal/timers:502:7) {
code: 2,
details: '/home/myshare/shilim/shilim-bot/node_modules/wechaty-puppet/src/agents/watchdog-agent.ts:65\n' +
" this.puppet.emit('error', new Error(\n" +
' ^\n' +
'\n' +
'Error: WatchdogAgent reset: lastFood: "{"data":"heartbeat@browserbridge ding","timeoutMilliseconds":60000}"\n' +
' at Watchdog.reset (/home/myshare/shilim/shilim-bot/node_modules/wechaty-puppet/src/agents/watchdog-agent.ts:65:33)\n' +
' at Watchdog.emit (node:events:513:28)\n' +
' at Watchdog.emit (node:domain:489:12)\n' +
' at Timeout._onTimeout (/home/myshare/shilim/shilim-bot/node_modules/watchdog/src/watchdog.ts:115:12)\n' +
' at listOnTimeout (node:internal/timers:559:17)\n' +
' at processTimers (node:internal/timers:502:7)'
}

Copy link

dosubot bot commented May 2, 2024

Hey there, @DW1992! 👋 I'm Dosu, a bot here to lend a hand with bugs, answer your queries, and guide you through becoming a contributor, all while you're waiting for a human maintainer to jump in. Excited to help you out! I'm taking a glance at your issue and will get back to you with a full answer shortly.

@liangzhicheng0423
Copy link

liangzhicheng0423 commented May 15, 2024

Has this problem been resolved? I also encountered the same problem

Copy link

dosubot bot commented May 15, 2024

The error you're encountering with the WatchdogAgent resetting due to a heartbeat timeout in wechaty-puppet suggests that the system is not receiving a heartbeat signal within the expected 60-second interval. This issue could be related to several factors, including network latency, performance bottlenecks, or issues with the puppet's operation.

To address this issue, consider the following steps:

  1. Adjust the Timeout Value: If operations are taking longer than expected, increasing the timeout value might help.
  2. Improve Error Handling: Implementing a robust error handling strategy could help manage timeouts more effectively. This might include retry logic or more detailed logging.
  3. Heartbeat Throttling: Managing the frequency of heartbeat signals could prevent potential overloads that might lead to timeouts.
  4. Optimize Puppet Event Handling: Ensure that event handling is efficient and does not unnecessarily block the event loop.
  5. Investigate Underlying Causes: Look into any underlying issues that might be causing the heartbeat timeout, such as network problems or external factors affecting the puppet's operation.

If you're still facing issues after trying these steps, providing more details about your setup, including the Wechaty version, the specific puppet implementation, and any relevant configuration settings, could help in identifying a more specific solution.

Details

Sources


About Dosu
This response is meant to be useful and save you time. It is not meant to be a precise solution, but rather a starting point for your own research.

Help me be more useful! Please leave a 👍 if this is helpful and 👎 if it is irrelevant.

To continue the conversation, mention @dosu.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants