Skip to content

feat(task-lanes): operator-configured lane boards over read-only taskLanes.list - #135890

Closed
TheArchitectit wants to merge 27 commits into
openclaw:mainfrom
TheArchitectit:feat/automation-task-lanes
Closed

TheArchitectit wants to merge 27 commits into
openclaw:mainfrom
TheArchitectit:feat/automation-task-lanes

Conversation

@TheArchitectit

@TheArchitectit TheArchitectit commented Sep 2, 2026 •

Copy link
Copy Markdown
Contributor

STACKED ON #135889. Diff shows PR-1 commits until it merges.

PR-2 — feat(task-lanes): operator-configured lane boards over taskLanes.list

What Problem This Solves

Cron already runs the work, but there is no read-side surface that groups runs/runs-outputs into operator-defined boards: "the board this team watches", "the lanes this gateway is responsible for". Operators configure such boards out-of-band today (spreadsheets, chats) with no typed, containable way to surface them next to the Automations UI they already live in.

Why This Change Was Made

Adds task lanes: named boards of work items from pluggable providers, read over a new read-only gateway RPC taskLanes.list, rendered as a read-only panel in the Control UI.

Framing: read-side observability over existing cron, deliberately. Lanes observe runs; nothing here schedules, multiplexes, or steers concurrent execution. Concurrent-run groundwork (state-lease multiplexing, GPU cap coordination, mid-run steering) was evaluated 2026-09-02 and deferred as cost > benefit — recorded in the spec so it is not re-litigated here.

Registration route (updated after review): the shipped route is operator config — a taskLanes.providers block in openclaw.json registers json-file providers at gateway start (1d681de65cd). The earlier taskLaneProviders manifest-capability route was evaluated and omitted (4e82e38f14e): with config-driven registration in place, no plugin could ever populate the capability, so declaring it was an unreachable contract that implied a registration path that does not exist. A provider-registration handler for third-party plugins remains the offered follow-up; if/when that lands it can declare the manifest capability for real. This is a product-surface call — maintainer confirmation on the omission (vs. holding the contract slot open) is welcome before merge.

User Impact

Operators who configure a taskLanes block get their lane boards in the gateways they already run, visible in the Control UI. Zero cost with no config: absent the block, the RPC behaves as if the subsystem doesn't exist (B1/G1 battery probes). Everyone else: nothing changes.

Evidence

Live Control-UI proof on the current head (2026-09-02, isolated dev gateway — own OPENCLAW_STATE_DIR, own port): with a config block whose provider rootDir is deliberately relative ("rootDir": "lanes"), the gateway resolves it against the state directory (f764a4c6624) and taskLanes.list returns the two configured lanes with items and ok diagnostics; the Automations run-history tab renders the TASK LANES panel from that RPC (screenshot). Sanitized RPC output (paths redacted):

{"lanes":[{"id":"ingest","label":"Ingest","items":[…3 items with titles/states]},{"id":"review","label":"Review","items":[…1 item]}],"diagnostics":[{"providerId":"demo-board","ok":true,"laneCount":2,"itemCount":4}]}

The battery found a real bug, fixed inside this PR stack. Battery D3 caught the missing-provider diagnostic echoing an absolute resolved path (and parse errors able to echo file content) onto the wire. 25a48ae4d0e narrows all provider diagnostics to node errno codes only, with regression tests asserting absence of path/content sentinels. This PR is stronger because the battery ran before merge — the evidence trail accompanies it.

Review-fix commits (this round), each failing-repro-first:

  • 7d090cb22f4 — a malformed board's schemaVersion diagnostic no longer echoes the file's attacker-controlled value; a fixed sentinel is emitted instead, with a regression test pinning the sentinel.
  • f764a4c6624 — relative provider rootDirs resolve against the state directory, not the process cwd; cwd-dependent lane registration was a silent-miss failure class. Regression test: same config + stateDir tmp root, lane visible only with state-dir anchoring. Proven live with a relative rootDir (above).
  • 234a6886cf0 — lane identity is scoped per provider: two providers may both expose a lane with the same id; snapshot assembly previously merged them into one lane, cross-assigning items. Regression test: alpha/beta providers both lane "work" → two lanes, one item each.
  • 4e82e38f14e — omit the unreachable taskLaneProviders manifest contract (see framing).

Land-time suites (per commit, openspec §2.2):

Commit What Verification
f8005b0fca2 neutral task-lane registry + path-safe providers (CR-1) 25/25 unit-src (13 json-file + 6 cron-backed + 6 registry)
590ccb35401 taskLanes.list schema + compiled validator (CR-2) 4/4 gateway-client schema shard
28a8facc058 taskLanes.list RPC + descriptor + context wiring (CR-3) 3/3 handler, gateway-core 175/175, tsgo:core exit 0
dab544d6ec8 taskLaneProviders manifest capability (CR-4; later omitted by 4e82e38f14e) manifest-registry 115/115 at the time
f483be91138 Control UI task lanes panel, read-only (CR-5) view-task-lanes 7/7, 70 cron-page tests, tsgo:ui + UI build green
1d681de65cd config-driven json-file lane registration (CR-3b) zod 7/7, config-registration tests, task-lanes 28/28, runtime-config 256/256, server-request-context 20/20, tsgo:core exit 0
afe132dc328 / f338303a9d8 sweep fallout: section-docs decision, request-context fixture, cursor policy token, docs-URL registry entry, typed tokenBudget test params covered under CR-7 full re-sweep
25a48ae4d0e provider diagnostics → errno codes only (battery D3 fix) 30/30 task-lane tests incl. 2 regressions, tsgo green
7d090cb22f4 schemaVersion diagnostics never echo the file's value failing-first regression green
f764a4c6624 relative provider rootDir anchored to the state directory failing-first regression green + live proof above
234a6886cf0 provider-scoped lane identity in snapshot assembly failing-first regression green
4e82e38f14e omit unreachable taskLaneProviders contract route manifest-registry/capability-summary suites adjusted, green

Screenshot (isolated dev gateway, current head):

TASK LANES panel from live taskLanes.list above the runs pane — typed origin labels on every run row

Safety posture (asserted by the battery, not aspirational):

  • Containment is real: the json-file provider realpaths rootDir and every filePath; unit tests stub resolveRealpath, so battery group C exercises the unstubbed real-fs path (traversal, symlink-to-/etc/hostname, oversize).

  • Hostile producers can't take the gateway down: bounded reads (256 KiB), bounded counts (20 lanes / 200 items), per-provider diagnostics instead of thrown errors.

  • UI never renders unsafe text: artifactUrl dropped (not sanitized) unless http(s) without traversal/control chars; titles/outcomes truncated.

  • Tree: this leg 94 files, +4154/−20 over merge-base; rebased onto current main 2026-09-02 (final head 507266661c6), tsgo core+ui green, task-lanes 33/33. pnpm-lock: clean; zero trailers; audits as PR-1.

Test plan

  • Per-commit land-time suites — table above, all green
  • CR-7 full sweep (see PR-1), post-rebase affected shards re-run 2026-09-02
  • Live battery A + D + partial E: 8 PASS, 2 pass-with-erratum, 1 FAIL (D3) → fixed + regression-covered; D1 blocked (needs low-priv token), E3 blocked (browser tooling), D4 skipped
  • Live Control-UI proof on current head: taskLanes.list RPC + lanes panel (this round)
  • Battery B/C (config surface + provider matrix) — scheduled
  • Battery F5 (final shard counts incl. tsgo) — scheduled
  • Battery G (lifecycle, restart-gated, operator-approved restarts) — scheduled

Round-6 update (2026-09-04, rebased onto PR-1 head 7daa73aa1e8 / upstream 8e23a5324f5, head 180b741e1d1):

  • Round-6 review fixes: (1) lane identity stays provider-scoped — lanes are unique only within a provider, so snapshot assembly now keeps each lane's providerId in the registry result, the wire schema (TaskLaneSchema.providerId), and the UI (sort order provider-then-id; lane headers render provider · label); (2) fail-closed capability gate — cron-page sends taskLanes.list only when cron.status explicitly reports taskLanesConfigured: true; an absent signal (unconfigured install or legacy/unresolved status) is no longer read as permission, including while an operator refresh races a slow cron.status (new gate test holds cron.status pending past the 150 ms debounce and asserts zero lane requests).

  • Verification at the new head: tsgo core + UI clean, all 5 core lint stripes + core:ui pass, task-lanes suites 42/42, cron-page gate tests green, protocol registry check passed, Kotlin + Swift protocol models regenerate unchanged.

  • Real-Gateway proof re-run at the exact new head (180b741e1d1) — isolated gateway (loopback, throwaway token, own state dir), real taskLanes.list RPCs and real headless-Chromium Control UI: configured install returns provider-scoped lanes (providerId on every lane, ENOENT diagnostic without path echo, timestamp contract enforced); unconfigured install returns taskLanesConfigured: false + empty lanes; the UI renders the provider-scoped panel (demo-board · Ingest queue) and no panel at all when unconfigured.

  • Config-surface ratchet: the taskLanes section adds +6 config keys (taskLanes, providers[], per-provider id/rootDir/filePath/schemaVersion) — intentional new config surface; baseline regenerated with pnpm config:docs:gen and committed (ab48c5c68fe). All other config surface is untouched.

Round-7 update (2026-09-04, head c04137faf5d): addressed the CR-7 task-lane truncation finding. The registry sliced the flat item list at the default page limit but returned every lane with no total or continuation indicator, so a lane whose items fell outside the slice rendered as an empty queue — indistinguishable from a genuinely empty lane. Snapshot assembly now records each lane's unpaged item total + omitted count and a snapshot-level paging block ({offset, limit, totalItems, returnedItems}), exposed as optional wire-schema fields (TaskLaneSchema.totalItems/omittedItems, TaskLaneSnapshotSchema.paging) so older snapshots stay valid. The Control UI renders "shown of total" on partially-off-page lanes, a panel-level truncation notice when the page omits items, and requests the bounded maximum page (200, the schema cap) so the snapshot is as complete as the registry will serve. Failing-first regressions: registry.test.ts "reports per-lane totals so an off-page lane is distinguishable from an empty lane" (red → green) and view-task-lanes.test.ts "marks an off-page lane as omitted instead of reading as an empty queue" (red → green). Verification at c04137faf5d: tsc --noEmit core+UI exit 0, oxlint clean on touched files, repo-wide oxfmt --check clean, task-lanes registry 7/7 + view 7/7 + cron-page gate 5/5 green, protocol registry check passed, Kotlin/Swift models regenerate unchanged. (Toolchain note: tsgo:ui and the type-aware tsgolint shard segfault on this box — environmental, reproduces in a sibling worktree on untouched files; tsc --noEmit is the authoritative UI typecheck here.)

Round-8 update (2026-09-05, head e5ec3a231d5): addressed the P2 count-cap omission finding from the 02:57 UTC review. The json-file provider capped at 20 lanes and 200 items per lane but only returned the retained slices; the registry then reported totalItems=200, omittedItems=0 for a 205-item lane, and the UI showed no truncation notice — a silently-cropped snapshot masqueraded as complete. Count input lanes and raw item count before each cap fires in loadJsonFileProviderLanes; return omittedLanes/omittedItems alongside the retained lanes. The registry propagates the counts into the ok-variant TaskLaneProviderDiagnostic (optional, omitted when zero so older providers stay valid). The gateway-protocol schema carries the same optional fields (omittedLanes, omittedItems) in the closed TaskLaneProviderDiagnosticSchema. The Control UI renders a distinct warn-styled chip (cron-task-lanes__chip--warn: "big: 20 lanes · 219 items (dropped 1 lanes, 5 items at provider cap)") instead of the bare ok chip when omissions exist. Failing-first coverage: each cap test now asserts both the retained length and the omission count, a combined test exercises both caps simultaneously (21-lane source: lane 0 has 205 items, lane cap drops lane 20 → omittedLanes=1, per-lane cap drops 5 from lane 0 → omittedItems=5), the registry test asserts the diagnostic carries the omission fields, the schema test accepts the optional fields and rejects negative counts, and the UI test asserts the warn chip renders with the dropped counts. Verification at e5ec3a231d5: tsc --noEmit -p tsconfig.core.json zero errors in touched files, 48/48 task-lanes + UI + schema tests, 695/695 gateway-protocol tests, 159/159 cron page tests; oxfmt + oxlint clean. Live proof (proof-pr2-cap.mts, fork release pr-proof-2026-09-05-tasklanes-cap): loadJsonFileProviderLanes → omittedLanes=1, omittedItems=5; registry snapshot → diagnostic.omittedLanes=1, omittedItems=5; TaskLaneSnapshotSchema validates the diagnostic → true.

Inline proof trace (taskLanes.list, redacted — inlined because the review sandbox cannot fetch release assets; full evidence at the release links above):

# live gateway capture at runtime head 180b741e1d1 (banner "OpenClaw 2026.8.1 (180b741)");
# isolated loopback gateway, own state dir, throwaway token — operator gateway never touched
cron.status (configured):     {"taskLanesConfigured": true, ...}
taskLanes.list (configured):
  lanes:[ {"providerId":"demo-board","id":"ingest","label":"Ingest queue",
           "items":[ /* item-1: both ms timestamps kept;
                       item-2: startedAtMs=-5 dropped, heartbeatAtMs kept;
                       item-3: heartbeatAtMs=1.5 dropped, startedAtMs kept */ ]},
          {"providerId":"demo-board","id":"review","label":"Review queue","items":[...]} ]
  diagnostics:[ {"providerId":"demo-board","ok":true,"laneCount":2,"itemCount":3},
                {"providerId":"ghost-board","ok":false,"error":"task lane file is unavailable (ENOENT)"} ]
  # providerId on every lane (round-6); errno-only diagnostic, no path echo
cron.status (unconfigured):   {"taskLanesConfigured": false, ...}
taskLanes.list (unconfigured):{"lanes":[],"diagnostics":[]}
UI (headless Chromium):       configured  -> panel renders "demo-board · Ingest queue" (provider · label)
                              unconfigured-> no panel rendered (verified programmatically)
# ── Round-7 live re-capture at EXACT head c04137faf5d (banner "OpenClaw 2026.8.1 (c04137f)") ──
# Isolated loopback gateway (port 18993), own state dir + OPENCLAW_CONFIG_PATH, throwaway
# token — operator gateway never touched. Config: one demo-board provider, two lanes —
# ingest (200 items, the per-lane cap) and review (5 items); flat total = 205 > the 200
# page bound, so the review lane's items fall outside the slice.
taskLanes.list (limit:200, the UI page size):
  lanes:[ {"providerId":"demo-board","id":"ingest","label":"Ingest queue",
           "items":[ /* 200 */ ], "totalItems":200, "omittedItems":0},
          {"providerId":"demo-board","id":"review","label":"Review queue",
           "items":[], "totalItems":5, "omittedItems":5} ]   # <- off-page, NOT empty
  diagnostics:[ {"providerId":"demo-board","ok":true,"laneCount":2,"itemCount":205} ]
  paging:{"offset":0,"limit":50,"totalItems":205,"returnedItems":50}   # default call; UI sends 200
UI (headless Chromium, Activity tab):
  panel notice: "Showing 200 of 205 items (snapshot page limit). Lane counts include
                 off-page items."  (role="status", visible to operators)
  ingest lane count:  "200"
  review lane count:  "0 of 5"   # renderLaneCount "shown of total" — omitted>0, not a bare "0"
# This is the round-7 paging/omission behavior live at the exact PR head, not a re-stamped
# earlier capture. Full evidence (fork release assets, no repo-branch artifacts):
#   pr2-trunc-evidence.md · rpc-tasklanes-trunc.json · rpc-cronstatus-trunc.json · screenshot-trunc-lanes.png
#   release 383104927 — https://github.com/TheArchitectit/openclaw/releases/tag/pr-proof-2026-09-05-tasklanes-trunc

Out of scope: generic lane writes (read-only this PR), provider auth/signing (in-process providers), cross-plugin lane composition, provider-registration handler for third-party plugins (offered follow-up; manifest capability deliberately omitted until it exists), concurrent-run scheduling machinery (see framing).

Fixes #135876 (part 2 of 2).

@clawsweeper

clawsweeper Bot commented Sep 2, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added app: web-ui App: web-ui gateway Gateway runtime size: XL labels Sep 2, 2026
@TheArchitectit

Copy link
Copy Markdown
Contributor Author

Post-rebase re-verification (head 4b70b920529, stack rebased 2026-09-02 onto 8fe71d40ff1; 4 file conflicts resolved: cron payload builders moved to cron-shared.ts, core-descriptors.ts, server-methods-list.test.ts, schema.tiers.ts):

Green: task-lanes 30/30 · gateway-client protocol 648/648 · gateway-server descriptors+context ✓ · ui-cron 308/308 · tsgo:core ✓ · tsgo:ui ✓ · gateway-methods 4236/4237 · runtime-config 4040/4046 · plugins 4529/4530.

Flagged lanes, all diagnosed as not-from-this-stack (verbose re-runs, twice-deterministic):

  • gateway-methods models.test.ts ×1 — ambient Anthropic auth on the dev box makes a fixture model report available; the test file itself changed upstream inside the rebased window (84e81339c2c). Environment-dependent.
  • runtime-config io.write-config.test.ts ×5 + validation.policy.test.ts ×1 — this stack touches none of those files; the write-config tests changed upstream during the window (717c78cc6cf). Upstream-drift/environment candidates.
  • plugins whatsapp external repair-hint ×1 — untouched by this stack; catalog/environment-dependent.
  • cron full shard — vitest worker crash (Worker exited unexpectedly, infra), no assertion failure; cron subsets green at land time (54/54/95).

Exact-head fork CI is the arbiter for the flagged lanes; will fold results in when CI reports.

Stack map: PR-1 #135889 (single-pane, 9 commits) → PR-2 #135890 (task-lanes, 9 commits). Draft until the live battery groups B/C/F5/G close (restart-gated on the operator's box).

@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. labels Sep 2, 2026
@clawsweeper

clawsweeper Bot commented Sep 2, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs real behavior proof before merge.

What this changes

Adds operator-configured JSON task boards, a read-only Gateway RPC, and an Automations panel.

Example: Provider demo-board reads lanes/board.json containing an Ingest queue with three items.

  • Before: Automations cannot display that external board.
  • After: Run history displays demo-board · Ingest queue with item states and provider diagnostics.

Review scores

Measure Result What it means
Overall readiness 🦪 silver shellfish (2/6) Useful behavior evidence supports the lane concept, but upgrade validation is incomplete and unchanged type errors, untranslated presentation, and stale-response publication block readiness.
Proof confidence 🦐 gold shrimp (3/6) Real behavior proof is necessary before merge. See Before merge.
Patch quality 🦪 silver shellfish (2/6) 4 actionable review findings remain.

Product

Kind: Feature · Worth it: Needs a maintainer decision · Fix scope: Partial
User problem: Operators want external work queues visible beside their automation history.
Reason: New core configuration and board ownership need an owner decision; the linked umbrella also includes cron capabilities left to the companion PR.

Merge readiness

⛔ Blocked before merge - 9 items remain

Keep open: this PR contains distinct work paired with open submissions, but four previously reported defects remain and its core-versus-plugin direction is unresolved.

Priority: P2
Reviewed head: 9f4ffdb391099613e100af5d8c9651581222e510
Owner decision: Required. See Decision needed.

Decision needed

  • Question: Should external task-lane snapshots extend Workboard, ship as a separate plugin, or introduce this new core configuration and RPC?
  • Recommendation: Extend Workboard: Place external snapshot providers under the existing board owner and add only a demonstrated missing extension seam.
  • Why: The contributor explicitly leaves ownership unresolved; existing Workboard covers related board presentation, but no human approval settles the external-provider boundary or new core surface.

Before merge

  • Add real behavior proof - Contributor Gateway traces and inspected Chromium screenshots exercise configured and unconfigured installs, provider-scoped rendering, timestamp normalization, diagnostics, refresh, and paging; the new configuration/protocol surface lacks a latest-stable upgrade capture preserving existing settings and data. After adding proof, update the PR body, then request a new review with @clawsweeper re-review. The PR author or someone with repository write access can request it.
  • Align the restored run helper with the actual protocol (P1) - CronRunLogEntry is re-exported from the protocol, whose closed run-entry schema has no completionCause or trigger property. This Pick therefore violates its key constraint, and the added entry.trigger and entry.completionCause accesses in view-runs.ts also fail typechecking. Remove this companion-only presentation from the lane branch, or land its approved producer and protocol contracts together; do not widen the type to conceal the mismatch. This previously reported blocker remains unchanged.
  • Remove the obsolete payload kind from the typed label map (P1) - CronJobKind comes from the protocol-derived reported payload union, which permits agentTurn, command, systemEvent, script, and heartbeat but not skillCollectionReview. Adding this property to Record<CronJobKind, string> produces an excess-property error and blocks UI typechecking. Remove the obsolete entry rather than expanding the public type. This previously reported blocker remains unchanged.
  • Supply English strings for the restored presentation (P2) - An enabled scheduled job now renders cron.upcoming.title, opening an agentTurn job renders cron.jobKind.agentTurn, and a recent failed run renders cron.runs.failureLabel.active. None of these keys exists in the English catalog; t() returns the key itself when English lookup fails, exposing internal identifiers to users. Add the strings for every retained presenter or remove the companion presentation. This previously reported blocker remains unchanged.
  • Guard lane publication against superseded requests (P2) - If an initial lane read is slow and Refresh starts another read on the same page state, the newer response can display the updated board before the older response overwrites it here. An older rejection can likewise replace the current success with an error. The debounce does not retire requests already in flight, and runCronTask only controls rendering. Give lane reads current-request ownership like the neighboring status/history loaders and guard both success and error publication. This previously reported blocker remains unchanged.
  • Complete next step - Resolve the reported merge conflicts against current main, adapting any retained Automations integration to its current Solid page and state owners.
  • Resolve maintainer decision - Resolve the maintainer decision shown above before merge.
  • Add data-model compatibility proof - The review found that existing stored data may not work after upgrade. Show that existing data still loads and works with this change.
  • Explain or restore the original intent of Automation refresh and response ownership - 407a8f4: Coalesce event bursts while keeping successful reads visible and preventing retired page responses from publishing.

Findings

  • [P1] Align the restored run helper with the actual protocol — ui/src/lib/cron/completion-cause.ts:43
  • [P1] Remove the obsolete payload kind from the typed label map — ui/src/pages/cron/job-kind.ts:21
  • [P2] Supply English strings for the restored presentation — ui/src/pages/cron/view.ts:768-771

Provenance

  • Automation refresh and response ownership changes intended behavior without addressing why it exists (407a8f4: Coalesce event bursts while keeping successful reads visible and preventing retired page responses from publishing.)

Tests

  • Low-value test ui/src/pages/cron/cron-page.test.ts: Remove the two duplicated configured/unconfigured lane-gate cases; cron-page.task-lanes-gate.test.ts already exercises the same setup and assertions alongside the distinct timing and refresh scenarios.
  • Missing end-to-end proof: The supplied captures do not show an upgrade from the latest stable release preserving existing configuration and data while enabling task lanes.
Agent review details

How this fits together

Gateway startup registers configured file providers; taskLanes.list reads bounded board snapshots and returns lanes, paging information, and diagnostics to the Control UI.

flowchart LR
  A[Operator configuration] --> B[Gateway lane service]
  C[JSON board files] --> D[Bounded file provider]
  B --> D
  D --> E[Snapshot registry]
  E --> F[Read-only Gateway RPC]
  F --> G[Automations panel]
Loading

Technical review

Best possible solution:

Prefer a Workboard-owned provider extension, keeping cron authoritative for run facts and removing companion-only presentation from this branch.

Do we have a high-confidence way to reproduce the issue?

Source inspection establishes the type-contract failures, missing translation fallbacks, and response-order race; no target code was executed.

Is this the best way to solve the issue?

The bounded read-only provider is coherent, but a parallel core board owner needs product approval and the restored cron presentation lacks its producer contracts.

Full review comments:

  • [P1] Align the restored run helper with the actual protocol — ui/src/lib/cron/completion-cause.ts:43
    CronRunLogEntry is re-exported from the protocol, whose closed run-entry schema has no completionCause or trigger property. This Pick therefore violates its key constraint, and the added entry.trigger and entry.completionCause accesses in view-runs.ts also fail typechecking. Remove this companion-only presentation from the lane branch, or land its approved producer and protocol contracts together; do not widen the type to conceal the mismatch. This previously reported blocker remains unchanged.
    Confidence: 1
  • [P1] Remove the obsolete payload kind from the typed label map — ui/src/pages/cron/job-kind.ts:21
    CronJobKind comes from the protocol-derived reported payload union, which permits agentTurn, command, systemEvent, script, and heartbeat but not skillCollectionReview. Adding this property to Record<CronJobKind, string> produces an excess-property error and blocks UI typechecking. Remove the obsolete entry rather than expanding the public type. This previously reported blocker remains unchanged.
    Confidence: 1
  • [P2] Supply English strings for the restored presentation — ui/src/pages/cron/view.ts:768-771
    An enabled scheduled job now renders cron.upcoming.title, opening an agentTurn job renders cron.jobKind.agentTurn, and a recent failed run renders cron.runs.failureLabel.active. None of these keys exists in the English catalog; t() returns the key itself when English lookup fails, exposing internal identifiers to users. Add the strings for every retained presenter or remove the companion presentation. This previously reported blocker remains unchanged.
    Confidence: 0.99
  • [P2] Guard lane publication against superseded requests — ui/src/lib/cron/index.ts:445-453
    If an initial lane read is slow and Refresh starts another read on the same page state, the newer response can display the updated board before the older response overwrites it here. An older rejection can likewise replace the current success with an error. The debounce does not retire requests already in flight, and runCronTask only controls rendering. Give lane reads current-request ownership like the neighboring status/history loaders and guard both success and error publication. This previously reported blocker remains unchanged.
    Confidence: 0.99

Overall correctness: patch is incorrect
Overall confidence: 0.98

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 19d311e00246.

Provenance checked

  • Control UI page lifecycle keeps the original intent (deb7faf: Make obsolete async completions inert across source replacement, reconnect, route changes, and detach.)
  • Existing Automations layout changes intended behavior with a stated reason (17a533c: Provide an owner-requested stats, table, and full-page-detail layout; the PR explains adding read-side boards but leaves acceptance of that direction open.)
  • Read-only Cron access keeps the original intent (2a94aa5: Keep browsing available while hiding administrator-only mutations and rechecking scope at dispatch.)

Testing

Proof path: shipped entry point.

Security

None.

Evidence

What I checked:

PR surface

Source +1617, Tests +1471, Generated 0, Other 0. Total +3088 across 53 files. Added test files: 8.

View PR surface stats
Area Files Added Removed Net
Source 35 1624 7 +1617
Tests 15 1480 9 +1471
Docs 0 0 0 0
Config 0 0 0 0
Generated 2 4 4 0
Other 1 2 2 0
Total 53 3110 22 +3088

Review metrics

Metric Value Why it matters
New configuration surface 1 root section; 3 per-provider inputs taskLanes.providers introduces id, rootDir, and filePath; the current schema has no per-provider schemaVersion option despite the older body description.

Root-cause cluster

Relationship: partial_overlap
Canonical: #135876
Summary: This PR implements the lane-observability portion of the umbrella request; its companion owns the cron contracts referenced by restored presentation.

Members:

Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything.

Labels

Label changes:

  • add proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence.
  • add status: 📣 needs proof: The PR needs real behavior proof before ClawSweeper can clear the contributor ask.
  • remove proof: sufficient: Current real behavior proof status is insufficient, not sufficient.
  • remove status: ⏳ waiting on author: Current PR status label is status: 📣 needs proof.
  • remove merge-risk: 🚨 other: Current PR review selected no merge-risk labels.

Label justifications:

  • P2: This is an operator-observability improvement with concrete implementation work, without an established urgent existing-user regression.
  • rating: 🦪 silver shellfish: Overall readiness is 🦪 silver shellfish; proof is 🦐 gold shrimp and patch quality is 🦪 silver shellfish.
  • status: 📣 needs proof: The PR needs real behavior proof before ClawSweeper can clear the contributor ask.
  • proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

History

Review history (40 earlier review cycles; latest 8 shown)
  • reviewed 2026-09-04T13:19:22.567Z sha c04137faf5da08381d3cad43ac1a0bb8ffa0bdfb :: needs real behavior proof before merge. :: [P1] Reuse Workboard rather than add a parallel lane board
  • reviewed 2026-09-05T02:57:02.196Z sha c04137faf5da08381d3cad43ac1a0bb8ffa0bdfb :: blocked before merge. :: [P2] [P2] Expose omissions caused by the provider's count caps | [P2] [P2] Preserve the typed budget cause through the run boundary
  • reviewed 2026-09-05T05:04:04.786Z sha e5ec3a231d537ca1aa65d96fe611168027f78856 :: blocked before merge. :: [P2] [P2] Preserve the typed budget cause through the run boundary | [P2] [P2] Describe the token budget as an observed-use threshold
  • reviewed 2026-09-05T20:58:48.662Z sha 06e8566 :: blocked before merge. :: [P1] [P1] Remove the extra brace from the cron status loader | [P1] [P1] Remove or complete the orphaned Automations view imports | [P1] [P1] Remove the token-budget control until its data path exists | [P2] [P2] Keep the jobs-table grid aligned with its added columns | [P1] [P1] Remove the restored unreachable task-lane manifest capability
  • reviewed 2026-09-05T21:41:41.930Z sha 9f4ffdb :: blocked before merge. :: [P1] [P1] Align the restored run helper with the actual protocol | [P1] [P1] Remove the obsolete payload kind from the typed label map | [P2] [P2] Supply English strings for the restored presentation helpers | [P2] [P2] Guard lane publication against superseded requests
  • reviewed 2026-09-07T15:11:48.585Z sha 9f4ffdb :: blocked before merge. :: [P1] [P1] Align the restored run helper with the actual protocol | [P1] [P1] Remove the obsolete payload kind from the typed label map | [P2] [P2] Supply English strings for the restored presentation helpers | [P2] [P2] Guard lane publication against superseded requests
  • reviewed 2026-09-22T21:57:51.518Z sha 9f4ffdb :: blocked before merge. :: [P1] Align the restored run helper with the actual protocol | [P1] Remove the obsolete payload kind from the typed label map | [P2] Supply English strings for the restored presentation helpers | [P2] Guard lane publication against superseded requests
  • reviewed 2026-10-02T07:39:56.288Z sha 9f4ffdb :: blocked before merge. :: [P1] Align the restored run helper with the actual protocol | [P1] Remove the obsolete payload kind from the typed label map | [P2] Supply English strings for the restored presentation helpers | [P2] Guard lane publication against superseded requests

Reviewed October 18, 2026, 7:00 AM ET / 11:00 UTC (Revision 41).

@TheArchitectit
TheArchitectit force-pushed the feat/automation-task-lanes branch from 4b70b92 to fffe8a1 Compare September 2, 2026 06:31
@openclaw-barnacle openclaw-barnacle Bot added the agents Agent runtime and tooling label Sep 2, 2026
@clawsweeper clawsweeper Bot added rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. and removed rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. labels Sep 2, 2026
@TheArchitectit
TheArchitectit force-pushed the feat/automation-task-lanes branch 2 times, most recently from debd373 to 3a538a7 Compare September 2, 2026 07:54
@clawsweeper clawsweeper Bot added rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. and removed rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. labels Sep 2, 2026
@TheArchitectit

Copy link
Copy Markdown
Contributor Author

Post-review push + live Control-UI proof on the current head (3a538a7d417), 2026-09-02.

Review-fix commits (each failing-repro-first, details in the PR body):

  1. schemaVersion diagnostics never echo the file's value — a4c91491f45, fixed sentinel + regression test.
  2. Relative provider rootDirs anchor to the state directory, not the process cwd — 9c8d62dd5ab. Proven live: the proof gateway config declares "rootDir": "lanes" (relative), and taskLanes.list returns the board; the same config under a cwd-dependent resolver would silently miss. Sanitized RPC output (redacted paths) is in the PR body.
  3. Lane identity scoped per provider — 2a5a439f44c; two providers sharing a lane id no longer merge items across providers (regression test: alpha/beta "work" → two lanes, one item each).
  4. taskLaneProviders manifest contract omitted — 3a538a7d417. With config-driven registration shipped, no plugin could ever populate the capability — an unreachable contract implying a registration path that doesn't exist. Framing updated in the PR body; the provider-registration handler remains the offered follow-up, and maintainer product judgment on the omission is explicitly requested there.

Live proof on this head: isolated dev gateway (own OPENCLAW_STATE_DIR, own port), taskLanes.list returns the 2-lane demo board with ok diagnostics, and the run-history tab renders the TASK LANES panel from that RPC (screenshot in PR body). The operator's gateway was not used.

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Sep 2, 2026 •

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event exact_review_queue).
Result: when the review finishes, ClawSweeper will create the durable review comment if needed or update the existing comment in place.

Re-review progress:

@clawsweeper clawsweeper Bot added merge-risk: 🚨 availability 🚨 May cause crashes, hangs, restart loops, stalls, or process outages. proof: sufficient ClawSweeper judged the real behavior proof convincing. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. and removed merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. labels Sep 2, 2026
@TheArchitectit
TheArchitectit force-pushed the feat/automation-task-lanes branch from 3a538a7 to 4e82e38 Compare September 2, 2026 08:27
@TheArchitectit

Copy link
Copy Markdown
Contributor Author

Rebased onto the updated PR-1 stack (which itself rebased onto current main); head is now 4e82e38f14e. No PR-2 code changed beyond the rebase; tsgo core+ui green, task-lanes suites 33/33.

@clawsweeper re-review

Forge and others added 24 commits September 5, 2026 20:51
Add the taskLaneProviders contract list to the plugin manifest surface,
mirroring workerProviders exactly: contract type declaration, contract-list
key union, manifest normalization (trim + drop malformed entries),
catalog/manifest merge, and reviewed capability-summary families so plugins
declaring task-lane providers surface them in capability inventory.

Contract-only: no runtime registration this PR.

Validate: manifest-registry 115/115 (2 new tests: accept + malformed-entry
rejection), capability-summary 8/8, tsgo:core exit 0.
Read-only Task lanes section in the Automations activity tab, fed by the
taskLanes.list gateway RPC:

- lanes sorted by id, items newest-first (startedAtMs desc), collapsible
  per-lane rows revealing outcome and artifact link (href rendered as-is;
  the provider sanitizes upstream so only http(s) survives)
- per-provider diagnostic chips (lane/item counts, provider errors)
- empty state, load-failure alert, and defensive response-shape handling
- 150ms debounced reload after cron mutations (create, run, toggle,
  remove); initial load rides ensureInitialData
- i18n keys under cron.lanes.*; styles follow the cron-upcoming precedent;
  no new ui dependencies

Validate: view-task-lanes 7/7, completion-cause 7/7, view/view-run-history/
view-runs.accessibility/cron-page all green (70 tests), tsgo:ui exit 0,
pnpm --dir ui run build exit 0.
Adds the taskLanes config surface for operator-configured JSON-file lane providers: schema section (pattern-validated ids, required rootDir/filePath, strict entries, duplicate-id rejection), help/label/tier metadata, and startup registration into the gateway task-lane service. Configured lanes are visible in taskLanes.list snapshots; an unreadable lane file degrades to a provider diagnostic instead of a startup failure.
…equest-context fixture, honor UI cursor policy

CR-7 sweep follow-up: taskLanes root section added to SECTIONS_WITHOUT_DOCS per schema.hints policy; server-request-context.test.ts Pick fixtures now include the required taskLanes live-state property; the task-lanes summary rule in cron.css uses var(--cursor-action) like every other non-anchor control, satisfying ui/src/styles/cursor-policy.node.test.ts. Tests: schema.hints 1/1, server-request-context 1/1, cursor-policy 1/1 green on dell-u2.
…n, docs-URL registry entry, widened request-context and manifest fixtures, typed tokenBudget test params
…file content

Registry diagnostics are RPC-visible. Raw fs failures (ENOENT realpath, EISDIR
read) and the escapes-root message embedded absolute resolved paths, and the
JSON-parse message could echo file content — observed live when a missing
provider file leaked /home/user001/... onto the taskLanes.list wire.
Errors now report node errno codes only; regression tests assert absence of
tmpdir paths and content sentinels.
The unsupported-schemaVersion message interpolated the untrusted
schemaVersion straight from the lane file, and the registry projects
Error.message into RPC-visible diagnostics. Report the expected version
with a fixed message instead.
Config help documents rootDir as "absolute or relative to the state
directory", but relative values resolved against the gateway process cwd,
so lane files silently failed to load whenever cwd differed from the
state dir. Anchor relative roots at registration via the resolved state
dir threaded from gateway lifecycle.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
Lane ids are unique only within a provider. Snapshot assembly matched
items to lanes by lane id alone, so two providers using the same lane id
cross-assigned each other's items in the RPC snapshot. Track the owning
provider on assembled lanes and flat items, and match on both.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
The taskLaneProviders manifest contract was contract-only: plugins could
declare it, but no SDK hook or runtime consumed the declaration, and the
plugin-owned task-lane registry seam (registerPluginTaskLaneProvider /
rebuildFromPlugins) had no production caller. A declared capability with
no registration route is a dark-shipped surface — plugins would see
silent no-ops. Omit it until the complete route (registration hook,
gateway wiring, docs) lands as one whole change.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
…r, unexport internal helpers, oxlint cleanups
…otlin gateway models

Bumps the schema-modules owner-count ratchet 60 -> 61 for the new
task-lanes schema module and regenerates the Kotlin GatewayProtocol
enum so the generated-tree guard matches.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
…t duplicate lane ids

- cron.status now carries taskLanesConfigured; the Automations page gates
  the taskLanes.list request and panel on it, so an unconfigured install
  never polls lane data or renders an empty panel.
- The JSON provider reads board files through a stat-then-bounded read:
  oversized files are refused before allocation instead of after a full
  fs.readFile.
- Duplicate lane ids within one provider document are rejected during
  normalization instead of merging two lanes' items under one key.
… schema hints

Extract shared cron-page test fixtures into cron-page.test-support.ts so
cron-page.test.ts drops under the max-lines budget, move the task-lanes
gate describe into its own spec, fix the promise-executor lint, and list
taskLanes in the test-local SECTIONS_WITHOUT_DOCS now that the policy
list lives in the test file. Also simplify the cron.status
taskLanesConfigured expression for the boolean-compare lint.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
…d lanes on refresh

Provider JSON is untrusted: startedAtMs/heartbeatAtMs values that are
not non-negative integers are dropped at the boundary so the
taskLanes.list snapshot always satisfies its declared schema. The
operator's Refresh action now also re-reads the lane snapshot (still
capability-gated and debounced) so externally edited boards do not go
stale, with a test covering a changed board appearing after refresh.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
…absent capability

Lane ids are unique only within a provider, so snapshots keep each lane's
providerId and the UI labels lanes as "provider · lane". cron-page also
stops sending taskLanes.list unless cron.status explicitly reports
taskLanesConfigured: true — an absent signal is no longer read as
permission, including while a refresh races a slow status response.
The intentional new config surface is taskLanes.providers (+6 keys:
section, providers list, and per-provider id/rootDir/filePath/schemaVersion
fields). Regenerated via pnpm config:docs:gen; justified in the PR body.
The registry sliced the flat item list at the default page limit but
returned every lane with no total or continuation indicator, so a lane
whose items fell outside the slice rendered as an empty queue —
indistinguishable from a genuinely empty lane. Operators could not tell
omission from emptiness, and the panel offered no way to follow the
truncation.

Snapshot assembly now records each lane's unpaged item total and the
omitted count for the current page, plus a snapshot-level paging block
(offset, limit, totalItems, returnedItems). The wire schema exposes them
as optional fields so older snapshots stay valid. The Control UI renders
"shown of total" counts on lanes that are partially off-page, a
panel-level truncation notice when the page omits items, and requests the
bounded maximum page (200, the schema cap) so the snapshot is as complete
as the registry will serve; the totals signal covers anything beyond.

Regression tests assert the signal: an off-page lane reports
totalItems/omittedItems (registry) and the panel renders "0 of 1" rather
than a bare "0" (view), with a later page clearing the omission.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
…ount caps

The json-file provider caps at 20 lanes and 200 items per lane, but the
load result only carried the retained slices. The registry then reported
totalItems=200, omittedItems=0 for a 205-item lane, and the UI showed
no truncation notice — a silently-cropped snapshot masqueraded as
complete. The same gap existed for the 20-lane cap.

Count input lanes and raw item count before each cap fires in
loadJsonFileProviderLanes, and return omittedLanes/omittedItems
alongside the retained lanes. The registry propagates the counts into
the ok-variant TaskLaneProviderDiagnostic (omitted when zero so older
providers stay valid). The gateway-protocol schema carries the same
optional fields, and the UI renders a distinct warn-styled chip
("...dropped N lanes, M items at provider cap") instead of the bare ok
chip so a capped set cannot pretend to be the full picture.

Failing-first coverage: each cap test now asserts both the retained
length and the omission count, a combined test exercises both caps
simultaneously, the registry test asserts the diagnostic carries the
omission fields, the schema test accepts the optional fields and
rejects negative counts, and the UI test asserts the warn chip.

Verified: 48/48 task-lanes + UI + schema tests; 695/695 gateway-protocol
tests; tsc core zero errors in touched files; oxfmt + oxlint clean.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
…nd manifest contracts

The rebase onto main required adapting to the refactored gateway module
loading (core-handlers.ts) and manifest contract key system
(manifest-contract-keys.ts), which replaced the inline registration
that the original branch used.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
- Remove extra closing brace from cron status loader (P1)
- Add missing PR-1 dependency modules (job-kind, upcoming-jobs,
  completion-cause) that were referenced but absent (P1)
- Remove token-budget control/form field that has no data path in
  this PR (belongs in PR-1) (P1)
- Remove Kind and Token Budget table columns to match CSS grid
  track count (P2)
- Remove unreachable taskLaneProviders manifest contract key and
  type field (P1)

Co-Authored-By: Claude Opus 4.6 <[email protected]>
@TheArchitectit

Copy link
Copy Markdown
Contributor Author

Post-rebase + ClawSweeper CR-8 fix push — head 9f4ffdb3910.

Branch rebased onto latest origin/main (cherry-pick strategy: 25 task-lanes commits on a fresh origin/main branch, avoiding the 27 PR-1 cron commits that would have caused massive conflicts). Mergeable state is now MERGEABLE (was CONFLICTING/DIRTY).

Five review findings addressed:

  1. [P1] Extra closing brace in cron status loader — ui/src/lib/cron/index.ts:491 had a stray } between the if (isCurrent()) block and the catch. Removed.

  2. [P1] Orphaned Automations view imports — view.ts imported job-kind.ts, upcoming-jobs.ts, and view-runs.ts imported completion-cause.ts, all absent from this branch. Copied these three PR-1 dependency modules (they are pure display helpers with no runtime coupling to the budget/completion-cause data path).

  3. [P1] Token-budget control with no data path — Removed payloadTokenBudget from CRON_FIELD_LABEL_KEYS and the corresponding renderCronInputField block in the form. The CronFormState field key, initial values, hydration, and payload builder all belong to PR-1; exposing the control here would render a field that cannot persist. Also removed the formatCronTokenBudget function (dead code after removing the table cell).

  4. [P2] Jobs-table grid misaligned — Removed the Kind and Token Budget table headers and data cells to match the CSS --cron-table-columns track count (5 management / 4 read-only). The detail view still renders the kind badge since it doesn't depend on grid layout.

  5. [P1] Unreachable taskLaneProviders manifest contract — Removed taskLaneProviders from manifest-contract-keys.ts and taskLaneProviders?: string[] from manifest-types.ts. The PR body explicitly deferred this contract until a complete registration route exists; no plugin SDK hook or runtime consumer can populate the task-lane registry.

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Sep 7, 2026 •

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event exact_review_queue).
Result: when the review finishes, ClawSweeper will create the durable review comment if needed or update the existing comment in place.

Re-review progress:

@openclaw-barnacle

Copy link
Copy Markdown

This pull request has been automatically marked as stale due to inactivity.
Please add updates or it will be closed.

@openclaw-barnacle

Copy link
Copy Markdown

Closing due to inactivity.
If you believe this PR should be revived, post in #clawtributors on Discord to talk to a maintainer.
That channel is the escape hatch for high-quality PRs that get auto-closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: android App: android app: web-ui App: web-ui docs Improvements or additions to documentation gateway Gateway runtime P2 Normal backlog priority with limited blast radius. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. scripts Repository scripts size: XL stale Marked as stale due to inactivity status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Automations single-pane: run provenance, typed completion causes; task-lane observability seam

1 participant