mirror of https://github.com/openclaw/openclaw.git
fix(cron): notify user when cron job is auto-disabled after repeated errors (openclaw#29098) thanks @ningding97
Verified: - pnpm install --frozen-lockfile - pnpm check - pnpm test -- --run src/cron/service.runs-one-shot-main-job-disables-it.test.ts Co-authored-by: ningding97 <17723822+ningding97@users.noreply.github.com> Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
This commit is contained in:
parent
504c1f3607
commit
5b49cc4129
|
|
@ -77,6 +77,8 @@ Docs: https://docs.openclaw.ai
|
|||
|
||||
### Fixes
|
||||
|
||||
- Cron/Schedule errors: notify users when a job is auto-disabled after repeated schedule computation failures. (#29098) Thanks .
|
||||
- Cron/Schedule errors: notify users when a job is auto-disabled after repeated schedule computation failures. (#29098) Thanks .
|
||||
- Onboarding/Custom providers: raise default custom-provider model context window to the runtime hard minimum (16k) and auto-heal existing custom model entries below that threshold during reconfiguration, preventing immediate `Model context window too small (4096 tokens)` failures. (#21653) Thanks @r4jiv007.
|
||||
- Web UI/Assistant text: strip internal `<relevant-memories>...</relevant-memories>` scaffolding from rendered assistant messages (while preserving code-fence literals), preventing memory-context leakage in chat output for models that echo internal blocks. (#29851) Thanks @Valkster70.
|
||||
- Dashboard/Sessions: allow authenticated Control UI clients to delete and patch sessions while still blocking regular webchat clients from session mutation RPCs, fixing Dashboard session delete failures. (#21264) Thanks @jskoiz.
|
||||
|
|
|
|||
|
|
@ -208,6 +208,19 @@ function recordScheduleComputeError(params: {
|
|||
{ jobId: job.id, name: job.name, errorCount, err: errText },
|
||||
"cron: auto-disabled job after repeated schedule errors",
|
||||
);
|
||||
|
||||
// Notify the user so the auto-disable is not silent (#28861).
|
||||
const notifyText = `⚠️ Cron job "${job.name}" has been auto-disabled after ${errorCount} consecutive schedule errors. Last error: ${errText}`;
|
||||
state.deps.enqueueSystemEvent(notifyText, {
|
||||
agentId: job.agentId,
|
||||
sessionKey: job.sessionKey,
|
||||
contextKey: `cron:${job.id}:auto-disabled`,
|
||||
});
|
||||
state.deps.requestHeartbeatNow({
|
||||
reason: `cron:${job.id}:auto-disabled`,
|
||||
agentId: job.agentId,
|
||||
sessionKey: job.sessionKey,
|
||||
});
|
||||
} else {
|
||||
state.deps.log.warn(
|
||||
{ jobId: job.id, name: job.name, errorCount, err: errText },
|
||||
|
|
|
|||
Loading…
Reference in New Issue