Skip to content

Auto-integrate: suppress "Ready for integration / run orch_integrate()" banner when the batch already auto-integrated #610

Description

@HenryLach

Summary

When a batch completes with integration set to Auto (auto fast-forward into the working branch), the engine still emits the manual-integration completion banner:

📋 Ready for your input.
Batch <id> ... 
Ready for integration. Run orch_integrate() or review first.

But at that point the batch has already been integrated automatically:

  • the orch branch was fast-forwarded into the working branch (develop),
  • the orch/* and task/* branches were cleaned up,
  • .pi/batch-state.json was removed.

So the prompt is misleading, and following it is a no-op-at-best: calling orch_integrate() then errors because there is no batch state left to integrate.

Expected

In Auto integration mode, once the batch has successfully auto-integrated, the completion banner should reflect that (e.g. "✅ Batch complete and integrated into ") and should not print the "Ready for integration / run orch_integrate()" prompt.

The manual-integration prompt should only appear when integration has not already happened — i.e. manual integration mode, or Auto integration was skipped/failed (batch left in a non-integrated terminal state).

Repro

  1. Configure a project with auto-integration (fast-forward) enabled.
  2. Run a single-task batch that succeeds and merges cleanly.
  3. Observe: develop is fast-forwarded, orch/task branches gone, batch-state.json removed — yet the completion banner still says "Ready for integration. Run orch_integrate() or review first."

Suggested fix

Gate the manual-integration prompt in the batch-completion banner on the actual integration status (e.g. integratedAt/phase, or an "already integrated" flag) rather than always printing it on batch completion. When auto-integration has completed, emit an "integrated" confirmation instead.

Notes

Observed repeatedly across several auto-integrated batches (single-task waves that fast-forwarded to develop). Cosmetic/UX severity, but it causes operators to attempt orch_integrate() unnecessarily (which then errors on missing state).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions