Repository navigation
feat(server): run scheduled tasks until their checks pass - #132
Conversation
Settings → Scheduled tasks lists each task's health (last run, pinned check version and verdict, failure streak, last error, chosen minute and neighbours) and manages tasks: create with a required check and reason, edit, pause and resume, run now, delete, and revert check versions with a reason. A finished turn with a failing check is shown as continuing, never as done. Adds a user guide. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…ou rules The Scheduled tasks page now requires one selected environment and asks for one otherwise, instead of listing a stand-in environment's tasks. Search uses the environment scope. Only a verified run counts as settled: on a task that needs you, Run now resumes the same run and Delete is left to the server's quiescence check, while work in progress blocks both. Guide updated. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
|
What: Independent review of candidate Review evidence
Elon recordRequirements and who asked: User requested read-only independent exact-head review and explicitly instructed not to post success while the root startup blocker remains active. |
Thread transfer impact✅ Thread transfer remains within every enforced ceiling.
Baseline: Scenario and decoded snapshot size10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.
Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed. |
|
What: Candidate Finding: stopped provider sessions are incorrectly treated as retiredLocation: When an existing scheduled thread's provider session transitions to This is reachable without retirement: the provider runtime marks sessions stopped on session closure and stop operations, while the orchestration model stores retirement separately. The existing Review scope and evidence
Elon recordRequirements and who asked: #123 requires same-thread continuation after work and failures; the user explicitly requires retired-thread recovery only for actually retired threads. |
Agent work on this PREstimated cost $0.00 · 0 responses · 54 sessions · 4.6 h wall time
Flags: 6 human corrections · 110 large tool outputs · 54 repeated commands · 15 repeated failures · 36 repeated reads · 11 repeated skill loads · 54 sessions with usage bound to no task Details: snapshot, prices, coverage, counters
Token counters by model (native counter semantics; never added across semantics): Selected rates (USD per million tokens). These rates value the report at the selected schedule date; they do not establish historical prices or subscription spending.
Other output and reasoning are priced without double counting inclusive native output. Missing rates remain unknown. Local measurement from native records; usage totals are not billing. Updated in place by |
|
What: Candidate Finding: done runs can lose their pinned judge and verified resultLocation: When a Startup investigation updateCoordinator evidence now shows Review evidence and Elon recordRequirements and who asked: #123 requires only a passing immutable pinned check to settle a run; the user requires cumulative exact-head review and prohibits success until startup is cleared. |
|
Measurement gap: Agent Observer publication succeeded, but its task lookup exited 3 and the published report attributes zero responses while flagging 54 sessions with usage bound to no task. The displayed $0.00 is not a measured total cost for #123. No missing usage has been treated as zero; task cost remains unknown pending attribution repair. |
|
Clarification to the stopped-session finding on this exact candidate:
No runtime or test was run by this reviewer. Candidate remains |
|
What: Candidate Finding: list tool schema aborts MCP/routes startupLocation: When Elon recordRequirements and who asked: #123 exposes scheduler tools through MCP; the user requires the actual startup cause be verified and fixed in the narrow server phase. |
|
What: Independent exact-head review found no code-blocking findings at ReviewReviewed the full cumulative diff from base The three prior findings are closed:
Proof reviewedThe exact-head combined manifest is The root's integrated client pass verified All scope, missing-check validation, refusal when the check exits 0, creation/pause with exit 1, Run Now disabled state, and authored version 2 check history. Revert submission then failed because the T3 preview host disconnected with Requirements and who asked: #123 check-gated scheduled work and the user's exact-head independent review; the coordinator requires one draft PR and final client evidence before changing draft state. |
Knip reported five exports used only inside ScheduledTasksSettings.logic.ts. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
|
What: Independent exact-head review found no code-blocking findings at ReviewReviewed the complete cumulative candidate against base The earlier findings remain closed: scheduler MCP list registration uses an object-shaped empty schema; provider Proof reviewedThe exact-head manifests are Root's Requirements and who asked: #123's check-gated, recoverable scheduled tasks and the user's exact-head independent review. |
|
Merged by the coordinator as 86d3269 (squash) at verified head ca9e537: diff read (scheduler state lives in the orchestration log, no numbered migration; the startup scan takes about 0.1 s on the maintainer's 255k-event database), CI green on that head, |
What: Chromeria gains scheduled tasks that continue until a pinned server outcome check passes.
Why: Starting a turn or finishing it does not prove recurring or timed work is complete.
So what: This PR remains draft until the native preview host returns and root completes client acceptance; installed-build provider proof remains user-owned after merge.
Durable blocked-draft handoff.
Closes #123. Targets main including Spectrum #118 and people #121. No merge, installation or real-provider live proof performed. No versioning by design.
The fork-owned scheduler uses the existing append-only orchestration log, serialized atomic claims and durable send receipts. Required checks must fail at creation. Each run pins its check version, definition, working directory and creator owner; other authors' check edits and reverts apply only to future runs. A passing check waits for pending parent work, Drafters and queued reports. Recovery walks the Prism Colors, continues the same thread after work or ambiguous restart, and resumes the same pinned run after ladder exhaustion. Retired threads require explicit recovery.
Settings and agent tools provide creation, health, history, editing, pause, deletion and run now. Fixed times default to a symmetric ±30-minute window; 0 pins the exact minute, with chosen minutes and neighbours returned. Settings requires one named environment. Quiescent exhausted tasks can be tombstoned without declaring their unfinished work done.
Exact-head proof and independent review
Final head:
ca9e5375da9ca4600c57985b6017cc9902e6a695; base:7f0a8ff68a429202d89619aecdd8b64289fd3934(Spectrum #118 and people #121 included). Clean task branch equals its pushed head. No migration-list edits./opt/homebrew/opt/node@24/bin: 493 server tests and 93 UI tests passed. All 14 targeted commands exited 0: tests, server/contracts/web typechecks, targeted lint, scoped server/web knip exports, fork registry, fork check and diff checks. No repository-wide local gate is claimed./tmp/promachos-coord/evidence/123/final-proof.json,final-ci-server-proof.json, andfinal-ci-ui-proof.json. Existing unrelated lint warnings remain; no knip ignores were added.review/independentis success on this exact head, created bylukemaj. Reviewer: visible T3 threadsub.sub.sub.46b03420-8643-4703-8756-8602f14b39fb.dispatcher-2274c9005036.dispatcher-50e6f2dd4945.reviewer-145b3d1ce0f8, GPT-6-Luna via Codex. This is a code verdict, not readiness approval.Blocked isolated client acceptance
Root's sanitized partial record is
/tmp/promachos-coord/evidence/123/root-client-proof.json. Actual runtime atfdc7e2f9ea7436b695380d6222efa8d64d5ccaa1started successfully on Node 24; discovery returned HTTP 200 in 0.31 seconds. Later commits add three test mock methods and remove six unused export modifiers only. Root and coordinator inspected that exact delta; function bodies/rendering are unchanged, but source is not byte-identical and the browser pass was not rerun at the final head.Passed in the native client: All-environments notice with no task management, named environment management, missing-check validation, passing-check creation refusal, failing-check creation, pause disabling Run now, and authored future-check v2 history retaining v1.
External blocker:
PreviewAutomationNoAvailableHostError: no connected desktop host. Root stopped browser verification when the host disappeared during revert submission. Revert/v3 author and reason, default/exact fixed-time windows and neighbours, task health/history screenshot, Settings search, and fixture deletion remain unverified. Revert may have reached the server: inspect history before retrying. These are unfinished dev-client checks, separate from deferred installed-provider proof below.Before image:
/tmp/promachos-coord/evidence/123/settings-before.png. Captured All-environments notice:/tmp/promachos-coord/evidence/123/settings-all-environments.png. No task-health after image is claimed; GitHub upload was unavailable, so permitted local evidence paths are retained.Root owns retained isolated dev session
71083, ports 13832/5792, and paused fixtureScheduler proof: interval(1440 minutes; no provider run requested). Retain the task worktree and isolated state for resumption. Only a read-only database VACUUM snapshot was copied; no settings or secret store was copied. Generated isolated credentials had zero nonempty live-secret matches, settings had no populated relay/cloud fields, and startup had no relay registration. No alternate browser was used. Root resumes these checks when the native host returns; do not mark ready, merge or install now.Agent cost
Agent Observer publication was republished for this final candidate. Attribution gap: ownership remains unbound, so displayed
$0.00is not a measured task total; total cost remains unknown. No bookkeeping capture or unrelated observer repair was introduced.Assumptions and limits
Installed-build proof, user after merge
/Users/lukaszmaj/Downloads/chromeria-scheduler-proof/repeatingand/Users/lukaszmaj/Downloads/chromeria-scheduler-proof/once. Use a Prism role with an available provider. Do not reuse existing marker files./Users/lukaszmaj/Downloads/chromeria-scheduler-proof/repeating/<run_id>.done. Check whether it already exists before writing; continue existing work without repeating it.” Check command:test -f '/Users/lukaszmaj/Downloads/chromeria-scheduler-proof/repeating/{run_id}.done'. Reason: “The run-specific marker proves this run completed.” Creation must succeed because its creation marker is absent.oncedirectory. Verify the selected minute equals the requested minute, the check begins failing and then passes, and exactly one run/marker is recorded. Subsequent reconciliation must not create another one-shot run.allow-passfile. Let the agent finish its marker while that file is absent: it must remain unfinished and continue the same thread/run/check. Createallow-pass, then verify done and one marker. Do not edit the active check to force success.Elon record
Requirements and who asked: #123's settled user outcome/check/recovery/history/window requirements, explicit sequential server and Opus UI routing, root's Spectrum/people/retirement/lease safeguards, one PR against main and no merge.
Deleted: V2 service backport, duplicate turn sender, hash chain, new scheduler tables/numbered migrations, unbounded live history, fresh worked-run retries, notification endpoint, mobile screen, cancel state, version-policy adoption and extra PRs.
Bottleneck: Code proof, independent review and CI are complete; the missing native preview host blocks the remaining isolated client acceptance.
Checked myself: Whole live #123 and comments plus parent #113, current rules, actual main auth/people mapping, preserved rebases, exact final source delta, 14 command manifests/logs, live main/PR head, authenticated exact-head review status and completed CI. Root client evidence inspected and explicitly partial.
Implemented through visible T3 threads: GPT-6.1-Sol on Codex for server work and coordination; Claude Opus 5.5 on Claude Code for every UI write. Independent review used GPT-6-Luna via Codex; Agent Observer publication has the explicit attribution gap above.