fix(server): load only due tasks during scheduler ticks - #9925
Conversation
|
This PR is too large for Bugbot to review. It changes 99,212 lines and 4,021,181 characters. Split the change into smaller pull requests to get a review. |
|
Macroscope has since reviewed this pull request. An earlier review was skipped by a cost limit; a review has now completed, so that notice no longer applies. |
b82facd to
2ac9bfe
Compare
ApprovabilityVerdict: Approved at Macroscope's review found this PR approvable — This is a focused scheduler optimization that moves existing due-task filtering into an indexed query while preserving lenient decoding and existing task behavior. Added tests cover the relevant task states, and no product defaults or production interfaces are changed. You can add or adjust custom eligibility rules. Learn more. |
aa837b8 to
f106115
Compare
Dismissing prior approval to re-evaluate d05a0ba
9242b91 to
3d81172
Compare
Dismissing prior approval to re-evaluate ebc4cd5
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
- Re-route steering that races completion into idempotent follow-up dispatches - Preserve scheduled-task attribution and provider ownership history across clients
Port main's pull-request discovery, active thread ordering, async question dismissal, settlement fixes, provider-session import, attachment context, and provider correctness changes into orchestration v2. Keep the branch's intentional composer and subagent behavior while adopting main's web and mobile fixes. Prevent headless setup terminals from hanging on the color probe, and move the v2 migration block to 050-061 after main claimed 048-049.
Restore the failed-before-start timer guard, align two server fixtures with the reconciled behavior, and remove dead files, exports, and dependencies surfaced by Knip. Drop the temporary branch push trigger now that the PR is mergeable, so each update runs the pull-request workflow once.
Keep main's batch machine-update banner and update action while preserving the v2 runtime-based environment lock used by draft load balancing.
Adopt TypeScript 7 and Effect rc.112 across orchestration v2, including the TaggedError API migration and updated Effect-aware tests. Restore main's composer-aware scroll-to-end clearance while retaining selected-model settings sync, preview recording transfer, image galleries, desktop context menus, and layout hit targets. Regenerate the lockfile on the upgraded dependency baseline.
efd9994 to
6102d00
Compare
Advertise bounded socket snapshots and authoritative dispatch validation, omit raw command output and inline file bodies at the wire boundary, and preserve compact status metadata across web and mobile. Add transport-budget coverage for snapshots, resume, commands, legacy import, and projection maintenance.
Restore pinned-thread shelf classification, server-owned unread state, hidden-subagent-safe project ordering, guarded jump hints, draft upload cleanup, and active-provider archive guards across the current and legacy sidebars. Bring the surrounding current-main sidebar work forward as well: canonical project favicons, stable row layout, thread file drops, account-aware mobile provider badges, and deferred desktop keyring loading.
ebc4cd5 to
f4b5f8a
Compare
8187b17 to
ada72ce
Compare
The five-second scheduler tick decoded every task, including disabled and future tasks. Query only enabled, due, non-running rows through the existing partial due-task index. Preserve task order and lenient handling of malformed due rows; API listing and one-time startup recovery retain their full reads.
Rebuilt head
f4b5f8a06targets V23aa47e294, with test-only prerequisite #10865 (merge first). Two-file topic, no schema changes.Validation: all seven focused scheduler/query tests pass, including index selection, malformed records, running/disabled/future rows. Server typecheck, targeted lint and formatting pass. No live state writes. New CI pending. Direct Claude Opus 5 high review remains unavailable because OAuth expired (latest launch exited 1 before inference).
Targets V2 #2829. Updated with GPT-6 in Codex/T3.