fix: schedule nextWakeAtMs for isolated sessionTarget cron jobs#19541
Merged
Takhoffman merged 2 commits intoopenclaw:mainfrom Feb 28, 2026
Merged
Conversation
|
This pull request has been automatically marked as stale due to inactivity. |
b3c64cf to
492397d
Compare
Contributor
|
Merged via squash after rebase + verification. Merge commit: e1c8094
|
vincentkoc
pushed a commit
to Sid-Qin/openclaw
that referenced
this pull request
Feb 28, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
vincentkoc
pushed a commit
to rylena/rylen-openclaw
that referenced
this pull request
Feb 28, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
mrosmarin
added a commit
to mrosmarin/openclaw
that referenced
this pull request
Feb 28, 2026
* main: (31 commits) fix(browser): resolve correct targetId in navigate response after renderer swap (openclaw#25326) fix: sed escaping and UID mismatch in Podman Quadlet setup (openclaw#26414) fix(cron): pass heartbeat target=last for main-session cron jobs (openclaw#28508) (openclaw#28583) fix(cron): disable messaging tool when delivery.mode is none (openclaw#21808) (openclaw#21896) fix: clear delivery routing state when creating isolated cron sessions (openclaw#27778) fix(cron): avoid marking queued announce paths as delivered (openclaw#29716) fix(cron): enable completion direct send for text-only announce delivery (openclaw#29151) fix(cron): force main-target system events onto main session (openclaw#28898) fix(cron): condition requireExplicitMessageTarget on resolved delivery (openclaw#28017) feat(cron): add --account flag for multi-account delivery routing (openclaw#26284) fix: schedule nextWakeAtMs for isolated sessionTarget cron jobs (openclaw#19541) fix: sandbox browser docker no-sandbox rollout (openclaw#29879) (thanks @Lukavyi) GitHub: add regression bug issue template and routing (openclaw#29864) thanks @Takhoffman feat(feishu): add chat info/member tool (openclaw#14674) feat(feishu): add markdown tables, positional insert, color_text, and table ops (openclaw#29411) feat(feishu): add parent/root inbound context for quote support (openclaw#18529) fix: land android onboarding and voice reliability updates (openclaw#29796) fix(android-voice): rotate playback token per assistant reply fix(android-voice): retry talk config after transient failures fix(android-voice): cancel in-flight speech when speaker muted ...
newtontech
pushed a commit
to newtontech/openclaw-fork
that referenced
this pull request
Feb 28, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
nsd97
pushed a commit
to nsd97/openclaw
that referenced
this pull request
Feb 28, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
wanjizheng
pushed a commit
to wanjizheng/openclaw
that referenced
this pull request
Mar 1, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
wanjizheng
pushed a commit
to wanjizheng/openclaw
that referenced
this pull request
Mar 1, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
6 tasks
hughdidit
pushed a commit
to hughdidit/DAISy-Agency
that referenced
this pull request
Mar 1, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com> (cherry picked from commit e1c8094) # Conflicts: # CHANGELOG.md # src/cron/service/jobs.ts # src/cron/service/timer.ts
zooqueen
added a commit
to hanzoai/bot
that referenced
this pull request
Mar 1, 2026
…claw#19541) Cherry-pick from upstream openclaw/openclaw e1c8094. Adds isFiniteTimestamp guards throughout cron scheduler to handle NaN/Infinity nextRunAtMs from legacy isolated jobs. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
ansh
pushed a commit
to vibecode/openclaw
that referenced
this pull request
Mar 2, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
steipete
pushed a commit
to Sid-Qin/openclaw
that referenced
this pull request
Mar 2, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
safzanpirani
pushed a commit
to safzanpirani/clawdbot
that referenced
this pull request
Mar 2, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
steipete
pushed a commit
to Sid-Qin/openclaw
that referenced
this pull request
Mar 2, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
robertchang-ga
pushed a commit
to robertchang-ga/openclaw
that referenced
this pull request
Mar 2, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
execute008
pushed a commit
to execute008/openclaw
that referenced
this pull request
Mar 2, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
hughdidit
pushed a commit
to hughdidit/DAISy-Agency
that referenced
this pull request
Mar 3, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com> (cherry picked from commit e1c8094) # Conflicts: # CHANGELOG.md # src/cron/service/jobs.ts # src/cron/service/timer.ts
dorgonman
pushed a commit
to kanohorizonia/openclaw
that referenced
this pull request
Mar 3, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
sachinkundu
pushed a commit
to sachinkundu/openclaw
that referenced
this pull request
Mar 6, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
zooqueen
added a commit
to hanzoai/bot
that referenced
this pull request
Mar 6, 2026
…claw#19541) Cherry-pick from upstream openclaw/openclaw e1c8094. Adds isFiniteTimestamp guards throughout cron scheduler to handle NaN/Infinity nextRunAtMs from legacy isolated jobs.
zooqueen
pushed a commit
to hanzoai/bot
that referenced
this pull request
Mar 6, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
Mateljan1
pushed a commit
to Mateljan1/openclaw
that referenced
this pull request
Mar 7, 2026
…claw#19541) * fix(cron): repair isolated next wake scheduling * cron: harden isolated next-wake timestamp guards --------- Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
nextRunAtMsvalues so the timer can arm andnextWakeAtMsis populatedeveryschedule anchor fallback to usenowMswhen external registrations omitcreatedAtMsnextRunAtMsas missing during maintenance recompute so isolated jobs self-heal instead of silently stallingeveryjobs loaded withoutcreatedAtMsTesting
pnpm vitest run src/cron/service.issue-regressions.test.ts src/cron/service.every-jobs-fire.test.ts src/cron/service.issue-16156-list-skips-cron.test.ts src/cron/service.rearm-timer-when-running.test.ts src/cron/service.prevents-duplicate-timers.test.ts --config vitest.unit.config.tspnpm vitest run src/cron/service/jobs.schedule-error-isolation.test.ts --config vitest.unit.config.tspnpm vitest run --config vitest.e2e.config.ts src/gateway/server.cron.e2e.test.tsFixes #19469
Greptile Summary
Fixed cron scheduling for isolated jobs with non-finite timestamp values
This PR addresses an issue where isolated
sessionTargetcron jobs could have invalid (non-finite)nextRunAtMsvalues, preventing the timer from arming properly and causing jobs to stall silently.Key Changes:
isFiniteTimestamp()type guard for consistent finite number validation across the cron serviceresolveEveryAnchorMs()to fall back to0when bothanchorMsandfallbackAnchorMsare non-finite, ensuringeveryschedules can always compute a valid anchorcomputeJobNextRunAtMs()to validate all return paths and only return finite timestamps orundefinednormalizeJobTickState()to treat non-finitenextRunAtMsas missing during maintenance passesnextWakeAtMs()andarmTimer()to filter out jobs with non-finite timestampscreatedAtMsthat validates self-healing behaviorThe fix ensures legacy jobs with invalid timestamps self-heal on next service start and prevents future invalid values from propagating through the scheduling system.
Confidence Score: 5/5
Number.isFinite()checks across all relevant code paths.Last reviewed commit: 052b306
(4/5) You can add custom instructions or style guidelines for the agent here!