Skip to content

feat(crew): store background crews and their runs on this device - #525

Merged
kinqsradio merged 1 commit into
mainfrom
feat/background-crew-state
Nov 12, 2026
Merged

kinqsradio merged 1 commit into
mainfrom
feat/background-crew-state

Conversation

@kinqsradio

Copy link
Copy Markdown
Member

Summary

  • Background crews and their runs are stored per device in the data folder (schema 41), not in .orbyn/crew.json (rule 4).
  • A crew: template (fix failing CI, flaky test, dependency bump, security advisory), trigger (CI failure, issue label, schedule, dependency update) with strict settings, a run budget fixed at creation, an enabled flag; created off.
  • Runs track state (running, stopped with reason, needs review) and spend against budget. Reaching the budget stops the run with reason budget and queues it for review. No merge authority.
  • Routes under /api/crew/background: list, read, runs; create, update, enable, disable, delete. Preview-gated, local only for writes, listed in the N1 marker. Every change writes an audit row in the same transaction.
  • Not built: triggers, any engine start (slice 4h), UI, joining a budget-stopped run to the after-merge Review queue.

Closes #

none (no issue)

Parity rows

none

Frames built

Frames built: none

Testing

  • CI covers the rest.
  • Locally: fmt, clippy -D warnings, check_rust_arch.py, orbyn-core store and crew tests, orbynd route tests over real HTTP, generated bindings committed.
  • Not tested: none

Co-authors

none

AI usage

  • Written by hand, with no AI
  • Harness and version: Claude Code 2.1.321
  • Models: claude-sonnet-5-5 (all)
  • Effort: medium
  • Human role: assigned the task and its boundaries; review pending
  • Sources: none

Checklist

  • Works on Windows and macOS
  • web/src/generated with any contract change; docs/architecture.md with any rule change
  • No copied source, secrets, credentials or personal data; no AI attribution in commits, title or branch

Background crews and their runs are kept in the data folder (schema 41), not in a repository file. A crew has a template, a trigger with strict settings, a run budget fixed at creation and an on/off switch. A run that reaches its budget stops with the reason budget and waits for review. Routes under /api/crew/background list, read, create, update, turn on or off and delete a crew and read its runs; every change is audited in the same transaction. No trigger fires and no engine starts.
@github-actions github-actions Bot added area: core crates/orbyn-core: runs, drivers, workspace, approvals, storage area: contracts crates/orbyn-contracts and web/src/generated area: service crates/orbynd: local service and CLI area: docs docs and Markdown files labels Nov 12, 2026
@kinqsradio
kinqsradio merged commit af1dda4 into main Nov 12, 2026
42 checks passed
@kinqsradio
kinqsradio deleted the feat/background-crew-state branch November 12, 2026 12:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: contracts crates/orbyn-contracts and web/src/generated area: core crates/orbyn-core: runs, drivers, workspace, approvals, storage area: docs docs and Markdown files area: service crates/orbynd: local service and CLI

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant