Skip to content

No flow in this app auto-launches — requires: ['triggers'] is undeclared, and the boot summary says so on every start #68

Description

@os-warren

objectstack.config.ts declares requires: ['automation', 'hierarchy-security']. automation gives the app a flow engine; it does not give it any trigger. Every trigger — record_change, schedule, time_relative, api — ships in @objectstack/trigger-* and is installed by the triggers capability, which nothing declares.

The packages are already on disk (@objectstack/trigger-record-change, @objectstack/trigger-schedule, @objectstack/trigger-api, all 17.2.0, pulled in transitively). They are simply never wired.

Measured on a real boot

PORT=3117 pnpm start on claude/issue-11-reminders (which adds three sweeps to the one existing flow):

  Flows:   4 flow(s) 0 bound to triggers
  ⚠ flow 'duly_assignment_fanout' declares a 'record_change' trigger but is NOT bound —
      no 'record_change' trigger is registered — add requires: ['triggers']
      (record_change/schedule/time_relative/api ship in @objectstack/trigger-*)
  ⚠ flow 'duly_task_lead_time_reminder' declares a 'time_relative' trigger but is NOT bound — …
  ⚠ flow 'duly_task_due_soon_reminder' declares a 'time_relative' trigger but is NOT bound — …
  ⚠ flow 'duly_task_overdue_owner_escalation' declares a 'time_relative' trigger but is NOT bound — …

Zero of four. The assignment fan-out (#33) does not fan out. The three reminder sweeps (#11) do not sweep. Every one of them is authored correctly — the engine resolves each flow's intended binding type, which is why it can name it in the warning — and none of them will ever fire.

Why it is easy to miss

pnpm validate, pnpm typecheck, pnpm test and pnpm build all exit 0 with every flow unbound. validate prints Logic: 4 Flows and says nothing. The only channel that tells you is the CLI startup summary, because — in the platform's own words in service-automation — "the boot-quiet stdout window swallows plain warn/info logs, so the summary is the reliable channel in os dev / os start". A branch that never boots the app ships a flow that reads as wired, passes every gate, and does nothing.

The fix

One line in objectstack.config.ts:

requires: ['automation', 'triggers', 'hierarchy-security'],

Deliberately not done on the #11 branch: that file is the one file every parallel task would otherwise collide on (AGENTS.md rule 2), and this is not #11's change to make — it affects #33's flow too, and it is the difference between "this app runs automations" and "this app does not", which deserves its own commit and its own boot check rather than riding along in a feature PR.

Worth pairing the change with a check that keeps it from silently regressing — the engine already exposes getTriggerBindingAudit(), so "every active flow is bound" is assertable, and unlike the four gates it would actually have caught this.

Found while implementing #11.


Generated by Claude Code

Activity

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

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions