openclaw - 💡(How to fix) Fix Feature Request: Agent Heartbeat Queue During Active Turn [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#84138Fetched 2026-05-20 03:43:37
View on GitHub
Comments
1
Participants
2
Timeline
4
Reactions
1
Timeline (top)
labeled ×2closed ×1commented ×1

Feature Request: Add configuration option to queue heartbeat polls during an active agent turn instead of interrupting the turn.

Root Cause

Feature Request: Add configuration option to queue heartbeat polls during an active agent turn instead of interrupting the turn.

Fix Action

Fix / Workaround

Alternative Considered

  • Lowering cron frequency (done as a workaround)
  • Modifying gateway code (not recommended - would be overwritten on updates)

Code Example

{
  "agents": {
    "defaults": {
      "heartbeat": {
        "queueDuringActiveTurn": true
      }
    }
  }
}
RAW_BUFFERClick to expand / collapse

Description

Feature Request: Add configuration option to queue heartbeat polls during an active agent turn instead of interrupting the turn.

Problem

Currently, when an agent is in the middle of a multi-step task (e.g., building a system), heartbeat polls from the gateway interrupt the agent's turn, ending it prematurely. This breaks the workflow for long-running tasks.

The current behavior is defined in HEARTBEAT.md:

  • Active Hours: 08:00–23:00 ET
  • If current time is outside active hours → reply HEARTBEAT_OK immediately, no checks

During active hours, heartbeat polls interrupt the agent mid-turn, which:

  • Breaks context for multi-step tasks
  • Makes it impossible to complete longer workflows
  • Forces the agent to constantly restart from checkpoints

Proposed Solution

Add a config option in openclaw.json, for example:

{
  "agents": {
    "defaults": {
      "heartbeat": {
        "queueDuringActiveTurn": true
      }
    }
  }
}

When enabled, heartbeat events would be queued and delivered when the agent finishes its current turn rather than interrupting mid-turn.

Alternative Considered

  • Lowering cron frequency (done as a workaround)
  • Modifying gateway code (not recommended - would be overwritten on updates)

Priority

Medium - improves agent workflow for multi-step tasks

Additional Notes

  • The schema already has agents.defaults.heartbeat and agents.list[].heartbeat defined as empty objects, suggesting this was a planned but not implemented feature
  • The schema also has web.heartbeatSeconds which is also empty

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

openclaw - 💡(How to fix) Fix Feature Request: Agent Heartbeat Queue During Active Turn [1 comments, 2 participants]