Skip to content

Integrate and harden long-running goals end to end #2015

Description

@integry

Context

Final integration task for #2002. Start only after the integration PRs for #2003, #2004, and #2005 are merged into 2002-epic-long-running-goals.

Scope

Resolve cross-stream integration, finish end-to-end and recovery coverage, document operation/API behavior, and validate the complete product through the final epic branch. This issue must not weaken provider, lifecycle, security, or durability semantics to make integration easier.

End-to-end scenarios

Automate representative flows using realistic fakes plus pinned-image smoke coverage where provider credentials are not appropriate for CI:

  1. Create a small goal that produces one issue PR and a final epic PR.
  2. Create a larger goal with two sub-epics, dependencies, and a configurable active-task cap; verify independent work runs concurrently and same-branch merges serialize.
  3. Kill the provider container during output/tool work, restart the daemon with Redis cleared, resume the same provider session, and prove no duplicate messages, issues, branches, PRs, or accepted turns.
  4. Pause with active work, observe pausing then paused, restart services, resume, and verify active/paused time plus concurrency accounting.
  5. Send “what’s done?”, “what’s left?”, and a free-form correction; verify FIFO state, controller-derived status, provider response, and replay after reconnect.
  6. Request a model change during work and verify requested/effective/audit/token attribution before and after the safe boundary.
  7. Exercise Claude, Codex, and Antigravity contract fixtures for resume, steering, pause, model change, cancel, and completion.
  8. Run Ultrafix/CI/merge gating through leaf, sub-epic, and final epic readiness, including failure and manual circuit-breaker cases.
  9. Attempt cross-user HTTP/socket access and stale fenced-worker writes; prove both are rejected.
  10. Run demo/read-only flows and existing Planner/Task/issue execution regressions.

Operational behavior

  • Add architecture and operator documentation for durable storage, leases, recovery, retention, pause semantics, safe-boundary model changes, message delivery, hierarchy, parallelism, Ultrafix, and completion.
  • Document authenticated REST and realtime APIs with request/response/event examples suitable for running ProPR remotely or from a Dockerized client; a CLI implementation is not required.
  • Document supported provider CLI/image version floors and actionable diagnostics for missing resume/App Server capabilities.
  • Add upgrade/migration and rollback notes plus storage/retention implications.
  • Add observability for controller lease changes, recovery attempts, queue depth, active caps, message lag, event lag, provider/model usage, and terminal failure reasons without logging objectives, messages, credentials, or transcript contents.
  • Ensure shutdown drains or checkpoints active goal sessions within a bounded timeout and reports sessions needing recovery.

Final epic validation

  • Merge this issue PR only into 2002-epic-long-running-goals.
  • Confirm the final draft epic PR targets main, links/closes the complete issue hierarchy, and contains no unrelated changes.
  • Run the repository’s full CI/typecheck/test/security suites on the integrated branch.
  • Trigger a dedicated final /ultrafix goal=9 max=8 loop on the epic PR and resolve all authorized findings.
  • Keep the epic PR draft/unmerged for human approval after all automated gates are green.

Acceptance criteria

  • All scenarios above have reproducible evidence in tests or documented smoke runs.
  • SQL-only recovery reconstructs authoritative state; Redis loss changes performance, not correctness.
  • No leaf or sub-epic implementation PR targets main.
  • No provider goal state crosses goal/user boundaries.
  • Existing one-shot issue, review, indexing, planner, socket, and demo behavior remains green.
  • Final epic PR CI and Ultrafix reach the specified gate with a concise validation summary.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions