You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
porch pending lists dead gates: pending records on completed/merged projects, and the same project once per worktree copy #1759
In a long-lived workspace (porch 3.3.4, ~1,750 project dirs under codev/projects/), porch pending reports 810 gates pending approval, the oldest from February. None are live asks. Two causes, both in pending() (dist/commands/porch/index.js):
No liveness filter. A gate is listed whenever gates[name].status === 'pending' and requested_at is set. It ignores the project's phase and whether the protocol has finished. Older flows (and PRs merged by the builder after an out-of-band approval word) left pr: {status: pending} behind on projects that then advanced to verify/verified/completed, or that record a merged PR. In this workspace 352 of the 384 root-level status files with a pending gate also record a merged PR; phases among them: 182 pr, 95 review, 33 implement, 29 verify, 29 hypothesis, 5 verified.
Dedupe by real path, not by project. The scan covers codev/projects plus every .builders/*/codev/projects. Each worktree holds its own copy of the committed status files, so one project is listed once per worktree (384 root records → 810 lines with six worktrees).
Expected
Skip a pending gate when the project has moved past the gate's phase (gate phase index < current phase index), when the protocol is complete (phase not in the protocol's phases, or a terminal phase such as verified), or when a merged PR is recorded.
Dedupe by project id, preferring the root codev/projects copy; list a worktree copy only when the root has no record (an unmerged lane).
Optionally a porch pending --all to show the raw view, and a one-line summary of how many stale records were hidden, so nothing is silently lost.
Approval stays human-only and named; this is a listing fix, not a way to clear gates.
Activity
Fix #1759: address review — worktree-first dedupe via listAllProjects…
Merge pull request #1760 from cluesmith/fix/porch-pending-stale-gates
Fix cluesmith#1759: porch pending hides stale gate records and counts…