Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
53 changes: 51 additions & 2 deletions .llm/harness/debt/arch-debt.md
Original file line number Diff line number Diff line change
Expand Up @@ -1450,6 +1450,31 @@ match the merged exemplars). IMPL-EVAL must not FAIL a slice for retaining eithe
- **Gate:** none (record-only until the maintainer decision; a future unification run selects
gates).

## plugin-triggers-core — CRON-NEXT-FIRE-ENGINE

- **ID:** `CRON-NEXT-FIRE-ENGINE`
- **Reason:** #181 Slice 5 introduced a triggers-core-owned `computeNextFireTimes` helper so the
connector can back `previewSchedule` without calling the `@netscript/cron` scheduler heuristic.
The helper is deliberately bounded and self-contained: it parses five-field cron expressions,
projects UTC minutes through `Intl.DateTimeFormat`, preserves fall-back duplicates, and maps
spring-forward nonexistent wall times to the first valid minute after the gap. It covers the
locked DST/timezone/leap-day table, but it is still a preview engine, not yet a shared canonical
cron subsystem for workers, triggers, and durable scheduling.
- **Why it is debt:** The repo still has multiple cron-related surfaces (`@netscript/cron`, workers
`.schedule()`, trigger scheduler adapters, and this preview helper). Follow-up should either
upstream the preview semantics into the canonical cron primitive or replace this helper with an
equivalent shared engine once the cron subsystem decision is made, without regressing the #181
DST table.
- **Owner:** `@netscript/plugin-triggers-core` runtime + cron subsystem maintainers.
- **Target:** Cron subsystem unification follow-up after #181.
- **Linked plan:** `.llm/tmp/run/feat-triggers-feature-backing--181/plan.md` Slice 5 / L6.
- **Created:** 2026-06-30.
- **Status:** open, DEBT_ACCEPTED.
- **Gate:** Close when `computeNextFireTimes` is backed by the canonical shared cron engine or the
helper is explicitly blessed as that engine, with table coverage for spring-forward skip,
fall-back duplicate, fixed-offset timezone, omitted `from`, one-shot `persistent: false`, leap
day, impossible dates, and every-N-minutes intervals.

## repo-wide — RUN-ARTIFACT-ARCHIVAL-POLICY (`.llm/tmp/run/` evidence tonnage)

- **Reason:** `.llm/tmp/run/` carries large tracked harness-evidence volume. The bulk is durable by
Expand Down Expand Up @@ -1607,14 +1632,38 @@ match the merged exemplars). IMPL-EVAL must not FAIL a slice for retaining eithe
run as a WSL Codex daemon-attached slice, not the connector slice.
- **Linked plan:** `feat/scaffold-surface-167` triggers thin-connector convergence slice (#172).
- **Created:** 2026-06-30.
- **Status:** open, DEBT_ACCEPTED — recorded as part of the additive thin-connector convergence; the
connector compiles/lints clean, the smoke test passes, and `deno publish --dry-run` succeeds.
- **Status:** closed 2026-06-30 by #181 Slices 1-6. The connector now backs the six deferred routes
through triggers-core seams: enabled/name fields + enabled-state store, manual dispatcher, webhook
test delivery, cron preview engine, and in-process event subscription.
- **Gate:** Close each route as its triggers-core seam lands (manual/test-fire helper -> `fireTrigger`
+ `testWebhook`; enabled-state store + `enabled`/`name` fields -> `enableTrigger`/`disableTrigger`
+ un-synthesized `listTriggers`/`getTrigger`; cron preview engine -> `previewSchedule`; event SSE
seam -> `subscribeEvents`), each with its own contract-route assertion and the connector smoke
test extended to assert the now-backed behavior. Remove the webhook brand cast when a public brand
constructor lands.
- **Closing evidence:** #181 per-slice gates passed with scoped core/connector check/lint/fmt,
focused contract/connector tests, `deno publish --dry-run --allow-dirty` for
`@netscript/plugin-triggers-core` and `@netscript/plugin-triggers`, and `deno task arch:check`
exiting 0 (`FAIL=0`). Slice 6 connector smoke asserts `subscribeEvents` streams a heartbeat.

## plugin-triggers-core — TRIGGERS-SSE-MULTI-REPLICA

- **ID:** `TRIGGERS-SSE-MULTI-REPLICA`
- **Reason:** #181 Slice 6 backs `subscribeEvents` with `createEventSubscription`, an in-process
single-replica event hub. It is appropriate for local service/runtime smoke and preserves the thin
connector boundary, but it does not fan out events across multiple service replicas or processes.
- **Why it is debt:** Production deployments with more than one triggers service replica need a
shared subscription backend, likely KV watch, pub/sub, or the eventual durable trigger event bus.
Without that backend, a client subscribed to replica A will not receive lifecycle messages
published by replica B.
- **Owner:** `@netscript/plugin-triggers-core` runtime + triggers connector deployment maintainers.
- **Target:** Multi-replica triggers service follow-up after #181.
- **Linked plan:** `.llm/tmp/run/feat-triggers-feature-backing--181/plan.md` Slice 6 / L11.
- **Created:** 2026-06-30.
- **Status:** open, DEBT_ACCEPTED.
- **Gate:** Close when `TriggerEventSubscriptionPort` has a shared backend with tests proving
cross-process or cross-replica delivery while keeping the current in-process adapter as the local
testing/smoke implementation.

## plugins/{sagas,triggers,workers} — PLUGIN-RUNTIME-ADAPTER-RELOCATION (#172b/c/d)

Expand Down
8 changes: 8 additions & 0 deletions .llm/tmp/run/feat-triggers-feature-backing--181/commits.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Commits — #181 Triggers Feature-Backing

- a79e13ea: feat(triggers): add definition name and enabled fields
- a19ca64f: feat(triggers): persist enabled state overrides
- 6ead7da4: feat(triggers): back manual fire dispatch
- 3ef180f7: feat(triggers): back webhook test delivery
- e710297f: feat(triggers): back schedule previews
- 24c03bf3: feat(triggers): back event subscriptions
37 changes: 37 additions & 0 deletions .llm/tmp/run/feat-triggers-feature-backing--181/context-pack.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# Context Pack — #181 Triggers Feature-Backing

Current phase: implementation after PLAN-EVAL `PASS`.

Base after pre-flight reset: `e77e68b6`.

Locked implementation order:
1. Domain fields `enabled` + `name`.
2. Enabled-state port/store and connector enable/disable.
3. Manual-fire dispatcher.
4. Webhook test delivery.
5. Cron next-fire preview engine.
6. Event subscription/SSE.

Hard constraints:
- Do not restructure `createPluginService(router, {...}).serve()` in `plugins/triggers/services/src/main.ts`.
- Only construct new default ports inside `createTriggersServiceContext`.
- No new `any`; avoid new casts.
- Keep memory testing adapters on the testing subpath.
- Commit, push, PR-comment, and update artifacts per slice.

Latest slice:
- Slice 1 implemented optional definition `name`/`enabled`, builder propagation, and connector
response `name` mapping. Gates are green; commit `a79e13ea` is recorded in `commits.md`.
- Slice 2 implemented `TriggerEnabledStatePort`, KV and memory stores, public
`createKvTriggerEnabledStateStore`, connector enable/disable backing, and `enabled=false` list
filtering. Gates are green; commit `a19ca64f` is recorded in `commits.md`.
- Slice 3 implemented `createManualDispatcher` and backed connector `fireTrigger`. Gates are green;
commit `6ead7da4` is recorded in `commits.md`.
- Slice 4 implemented `createWebhookTestDelivery` and backed connector `testWebhook` through
ingress-signed synthetic requests. Gates are green; commit `3ef180f7` is recorded in
`commits.md`.
- Slice 5 implemented `computeNextFireTimes` and backed connector `previewSchedule`. Gates are
green; commit `e710297f` is recorded in `commits.md`.
- Slice 6 implemented `TriggerEventSubscriptionPort`, `createEventSubscription`, lifecycle
publishing, and connector `subscribeEvents`. Gates are green; commit `24c03bf3` is recorded in
`commits.md`.
15 changes: 15 additions & 0 deletions .llm/tmp/run/feat-triggers-feature-backing--181/drift.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Drift — #181 Triggers Feature-Backing

- 2026-06-30: After the required reset to `origin/feat/triggers-feature-backing`, the run directory
contained only `plan.md` and `research.md`. The separate PLAN-EVAL `PASS` exists as a PR #192
OpenHands comment and the reconciled findings are already folded into `plan.md`; this session
restored minimal local `plan-eval.md`, `worklog.md`, `context-pack.md`, and `commits.md`
tracking artifacts before committing Slice 1.
- 2026-06-30: Slice 3's default manual event-id factory needs the same local branded-id cast pattern
already used by `create-trigger-ingress.ts` because `TriggerEventId` has no public constructor.
The cast is confined to the runtime edge that mints a new event id; callers can still inject a
typed `createEventId` factory in tests.
- 2026-06-30: Slice 4 signs every synthetic webhook test request. When no `secretEnv` value is
available, the helper uses a deterministic non-empty fallback secret before calling ingress so the
memory verifier path preserves MemoryWebhookVerifier semantics and HMAC definitions still fail or
pass through the real ingress verifier instead of bypassing it.
10 changes: 10 additions & 0 deletions .llm/tmp/run/feat-triggers-feature-backing--181/plan-eval.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# PLAN-EVAL — #181 Triggers Feature-Backing

Verdict: `PASS`

Evidence source: PR #192 OpenHands PLAN-EVAL comment dated 2026-06-30T19:54:18Z, model
`openrouter/minimax/minimax-m3`, run `28471834087`.

The evaluator returned `PASS` with findings F1-F5/F6. The reconciled findings are already folded
into `plan.md` as L1, L4, L9, L13, and the Slice 5 table-test requirements.

Loading
Loading