Allocator ignores active foreign leases and lets one claimed issue blockade the whole author queue #765

Closed
opened 2026-07-19 22:05:36 -05:00 by jcwalker3 · 2 comments
Owner

Problem

allocator_service.allocate_next_work never consults active leases while selecting work. It expires stale leases and checks the terminal-review lock, but it never asks whether a candidate is already claimed by a live lease belonging to a different session.

WorkCandidate.already_claimed_elsewhere exists and classify_skip honours it, but nothing ever populates it from live control-plane state. The MCP candidate loader does not set it.

Consequence: the allocator returns the highest-ranked issue even when another concurrent session holds an active, unexpired lease on it. assign_and_lease then correctly returns wait, but only after that issue was already chosen. Because the allocator does not fall through to the next unclaimed candidate, a single claimed issue becomes a global blockade for every other author session, and the reported inventory is misleading (inventory_complete=true with skipped_total=0 while a leased issue is the selection).

Observed

Live control-plane state carried an active author lease on one issue (status=active, expired_by_time=false, owned by a different session id). A dry-run allocator preview for role author still selected that same issue, reported skipped_total=0, and offered it as primary_next_safe_action. Independent author sessions therefore had no eligible work even though many unclaimed status:ready issues existed.

Ownership cannot be expressed today

Each allocator invocation registers a new session_id (the same process produced ...-68c3c00a and later ...-40b391ef). Session id alone therefore cannot distinguish "my own in-progress task" from "another controller's task", and profile name cannot either, because every author session shares prgs-author. A stable controller identity is required before ownership comparisons are meaningful.

Required behaviour

  1. Build the candidate inventory from all otherwise eligible issues.
  2. Before ranking, exclude candidates that carry an active claim owned by a different controller: an active lease, an active issue lock, a durable handoff assigning the task to another actor, or an active worktree/session ownership record.
  3. Record the exclusion reason as claimed_by_other_session.
  4. Continue ranking the remaining candidates.
  5. Never return an actively claimed issue as primary_next_safe_action for a different controller.
  6. A task-local environment blocker must quarantine only that task, never the whole author phase.
  7. Multiple author sessions may work concurrently on different issues.
  8. A controller may resume its own active task, but must never adopt another controller's task.
  9. When ownership cannot be distinguished, surface an allocator ownership defect and refuse to adopt. Never assume a lease sharing the same profile belongs to this controller.
  10. Add a stable controller_instance_id to ownership comparisons.
  11. The rule must be general; no issue number may be special-cased.

Acceptance criteria

  1. A candidate with an active lease owned by a different controller is excluded before ranking and reported in skipped with reason claimed_by_other_session.
  2. The allocator selects the next unclaimed candidate instead of stopping at the claimed one.
  3. A controller may still be assigned its own actively leased task (resume path).
  4. A task-local blocker on one issue does not prevent selection of unrelated issues.
  5. When every candidate is claimed, the outcome is a wait/idle state, not a claimed selection.
  6. Two sessions sharing a profile but carrying different controller_instance_id values are treated as different owners.
  7. Allocator inventory reporting counts claimed candidates in skipped so skipped_total reflects reality.
  8. controller_instance_id is persisted on sessions and surfaced on lease rows; legacy leases without it are treated as foreign, never silently adopted.
  9. The workflow dashboard reflects the same exclusion so its primary_next_safe_action cannot advertise a claimed issue.

Non-goals

  • No change to lease TTL, heartbeat, or expiry semantics.
  • No change to the terminal-review lock path.
  • No adoption or takeover mechanism is introduced here; exclusion only.
## Problem `allocator_service.allocate_next_work` never consults active leases while selecting work. It expires stale leases and checks the terminal-review lock, but it never asks whether a candidate is already claimed by a live lease belonging to a different session. `WorkCandidate.already_claimed_elsewhere` exists and `classify_skip` honours it, but nothing ever populates it from live control-plane state. The MCP candidate loader does not set it. Consequence: the allocator returns the highest-ranked issue even when another concurrent session holds an active, unexpired lease on it. `assign_and_lease` then correctly returns `wait`, but only after that issue was already chosen. Because the allocator does not fall through to the next unclaimed candidate, a single claimed issue becomes a global blockade for every other author session, and the reported inventory is misleading (`inventory_complete=true` with `skipped_total=0` while a leased issue is the selection). ## Observed Live control-plane state carried an active author lease on one issue (`status=active`, `expired_by_time=false`, owned by a different session id). A dry-run allocator preview for role `author` still selected that same issue, reported `skipped_total=0`, and offered it as `primary_next_safe_action`. Independent author sessions therefore had no eligible work even though many unclaimed `status:ready` issues existed. ## Ownership cannot be expressed today Each allocator invocation registers a new `session_id` (the same process produced `...-68c3c00a` and later `...-40b391ef`). Session id alone therefore cannot distinguish "my own in-progress task" from "another controller's task", and profile name cannot either, because every author session shares `prgs-author`. A stable controller identity is required before ownership comparisons are meaningful. ## Required behaviour 1. Build the candidate inventory from all otherwise eligible issues. 2. Before ranking, exclude candidates that carry an active claim owned by a different controller: an active lease, an active issue lock, a durable handoff assigning the task to another actor, or an active worktree/session ownership record. 3. Record the exclusion reason as `claimed_by_other_session`. 4. Continue ranking the remaining candidates. 5. Never return an actively claimed issue as `primary_next_safe_action` for a different controller. 6. A task-local environment blocker must quarantine only that task, never the whole author phase. 7. Multiple author sessions may work concurrently on different issues. 8. A controller may resume its own active task, but must never adopt another controller's task. 9. When ownership cannot be distinguished, surface an allocator ownership defect and refuse to adopt. Never assume a lease sharing the same profile belongs to this controller. 10. Add a stable `controller_instance_id` to ownership comparisons. 11. The rule must be general; no issue number may be special-cased. ## Acceptance criteria 1. A candidate with an active lease owned by a different controller is excluded before ranking and reported in `skipped` with reason `claimed_by_other_session`. 2. The allocator selects the next unclaimed candidate instead of stopping at the claimed one. 3. A controller may still be assigned its own actively leased task (resume path). 4. A task-local blocker on one issue does not prevent selection of unrelated issues. 5. When every candidate is claimed, the outcome is a wait/idle state, not a claimed selection. 6. Two sessions sharing a profile but carrying different `controller_instance_id` values are treated as different owners. 7. Allocator inventory reporting counts claimed candidates in `skipped` so `skipped_total` reflects reality. 8. `controller_instance_id` is persisted on sessions and surfaced on lease rows; legacy leases without it are treated as foreign, never silently adopted. 9. The workflow dashboard reflects the same exclusion so its `primary_next_safe_action` cannot advertise a claimed issue. ## Non-goals * No change to lease TTL, heartbeat, or expiry semantics. * No change to the terminal-review lock path. * No adoption or takeover mechanism is introduced here; exclusion only.
jcwalker3 added the status:readyworkflow-hardeninganti-stompmcp-healthtype:bug labels 2026-07-19 22:05:36 -05:00
Author
Owner

Canonical Issue State

STATE:
correction implemented and verified on a local branch; publication to Gitea was not performed because the author workspace-binding gate refused the commit

WHO_IS_NEXT:
user

NEXT_ACTION:
Operator must bind the gitea-tools author namespace to a branches/ worktree (or land a fix for the binding gap) so gitea_commit_files can publish branch fix/issue-765-allocator-foreign-lease; then a fresh author cycle publishes and opens the PR.

NEXT_PROMPT:

Role: OPERATOR, then AUTHOR
Repo: prgs / Scaled-Tech-Consulting / Gitea-Tools
Issue: #765 - allocator ignores active foreign leases

The correction exists as local commit d06198b on branch
fix/issue-765-allocator-foreign-lease in worktree
branches/issue-765-allocator-ownership. It was not published: the
gitea_commit_files #274 branches-only guard resolved the session workspace to
the stable control checkout and refused the mutation. This is the same
publication gap already recorded on #607; it is a global author-publication
gap, not specific to either task.

Operator options (pick one):
1. Set GITEA_AUTHOR_WORKTREE (or GITEA_ACTIVE_WORKTREE) for the gitea-tools
   namespace launcher to the session worktree, then reconnect the MCP client.
2. Land a fix so gitea_commit_files accepts worktree_path, or so author
   workspace resolution consults the author issue-lock worktree the way
   reviewer/merger leases are consulted (see #618).

Then run a fresh author cycle for #765: publish the branch, open the PR against
master, and hand off to an independent reviewer. Do not re-implement - the code
and tests already exist.

After #765 merges and the MCP daemon serves it, the corrected allocator selects
the next eligible unclaimed issue automatically.

WHAT_HAPPENED:
Issue #765 was filed for the allocator ownership defect, locked to branch fix/issue-765-allocator-foreign-lease in worktree branches/issue-765-allocator-ownership, and implemented. Live claims are now loaded before ranking; candidates claimed by a different controller are excluded and reported in skipped with reason_code claimed_by_other_session, and ranking continues to the next unclaimed candidate. A stable controller_instance_id is persisted on sessions and surfaced on lease rows, so a controller can resume its own task while never adopting another controller's. The workflow dashboard applies the same exclusion. Work is preserved as local commit d06198b. gitea_commit_files was attempted exactly once and refused pre-API; a read-back of the branch returns 404, proving no branch, commit, or PR was created on Gitea.

WHY:
Session ids are regenerated per allocator invocation and every author session shares the prgs-author profile, so neither can express controller ownership. Without a durable identity the allocator either blockades the queue on someone else's lease or risks adopting it. A stable controller_instance_id makes the comparison decidable, and unidentifiable claims are excluded rather than adopted so the failure mode stays safe.

RELATED_PRS:
none - no PR was opened

BLOCKERS:
Blocker classification: environment/tooling blocker
gitea_commit_files exposes no worktree_path parameter, and neither GITEA_ACTIVE_WORKTREE nor GITEA_AUTHOR_WORKTREE is set on the running gitea-tools process, so the author workspace resolves to the stable control checkout and the #274 guard fails closed. This gap blocks all author publication, not one task. Direct git push, editing server env, writing a repo-root .env, and restarting MCP are outside sanctioned author authority, so no fallback was attempted.

VALIDATION:
New tests: tests/test_allocator_foreign_lease_exclusion.py, 23 cases covering ownership classification, foreign-lease exclusion, next-unclaimed selection, own-task resume across a new session id, task-local blocker isolation, concurrent controllers on different issues, all-claimed wait with owner_session_id preserved, ownership-defect reporting, skipped inventory accounting, and end-to-end exclusion against a real ControlPlaneDB. Full suite: 3717 passed, 6 skipped. Two failures (test_issue_702_review_findings_f1_f6, test_reconciler_supersession_close) were re-run against unmodified master at fcf6981 and fail identically there, so they are pre-existing and unrelated. One pre-existing contract test caught an over-broad first draft of the ownership classifier and the classifier was narrowed so that a claim with no identity on either side is foreign rather than unidentifiable, preserving the earlier wait contract. Read-only check against the live control-plane DB: the sole active claim is classified foreign, and with the live author-safe queue in dashboard order the corrected allocator skips that issue with reason_code claimed_by_other_session and selects the next unclaimed one, where the shipped allocator selected the claimed issue and reported zero skips.

LAST_UPDATED_BY:
jcwalker3 / prgs-author / scheduled controller author cycle / 2026-07-20

[THREAD STATE LEDGER]

What is true now:

  • Server-side decision state: no server-side state changed beyond creating issue #765 and this comment. No branch, commit, PR, or review exists on Gitea for #765.
  • Local verdict/state: correction complete and verified locally at commit d06198b on fix/issue-765-allocator-foreign-lease; full suite run with only pre-existing master failures.
  • Issue #765 is open with its issue lock held by this author session (expires 2026-07-20T07:06:09Z).

What changed:

  • Local only: live-claim exclusion in allocator_service.py, controller_instance_id persistence plus list_active_claims in control_plane_db.py, the same exclusion in workflow_dashboard.py, controller-identity plumbing in gitea_mcp_server.py, and the new regression test module.
  • Server-side mutation ledger:
    issue #765 created; this canonical comment posted. No branch, commit, PR, review, or merge. The single gitea_commit_files attempt was refused before any API call and read-back confirmed absence.

What is blocked:

  • Blocker classification: environment/tooling blocker
  • Publication of branch fix/issue-765-allocator-foreign-lease cannot proceed through gitea_commit_files while the author workspace binding resolves to the stable control checkout.

Who/what acts next:

  • Next actor: user
  • Required action: bind the gitea-tools author namespace to the branches/ worktree via GITEA_AUTHOR_WORKTREE or GITEA_ACTIVE_WORKTREE and reconnect the MCP client, or land the commit_files worktree_path fix; then run a fresh author cycle to publish and open the PR for #765.

Do not do:

  • Do not re-implement #765 or open a second branch, worktree, or issue for it; commit d06198b already contains the correction and its tests.
  • Do not publish the branch with direct git push, force-push, or any raw Gitea API, curl, gh, tea, or web-UI path; publication must go through gitea_commit_files once the binding is corrected.
  • Do not run the live allocator with apply=true before this fix is served by the MCP daemon: the shipped allocator still targets the issue claimed by another controller.
  • Do not touch, reclaim, release, or comment on the task claimed by the other controller; its lease is foreign and must be left alone.
  • Do not write a .env into the stable control checkout and do not mutate the control checkout to work around the guard.
  • Do not kill, restart, or respawn MCP server processes to force a rebind; client reconnect is the operator-owned recovery path.
  • Do not review, approve, or merge this work from the author namespace; an independent reviewer is required after the PR exists.
## Canonical Issue State STATE: correction implemented and verified on a local branch; publication to Gitea was not performed because the author workspace-binding gate refused the commit WHO_IS_NEXT: user NEXT_ACTION: Operator must bind the gitea-tools author namespace to a branches/ worktree (or land a fix for the binding gap) so gitea_commit_files can publish branch fix/issue-765-allocator-foreign-lease; then a fresh author cycle publishes and opens the PR. NEXT_PROMPT: ```text Role: OPERATOR, then AUTHOR Repo: prgs / Scaled-Tech-Consulting / Gitea-Tools Issue: #765 - allocator ignores active foreign leases The correction exists as local commit d06198b on branch fix/issue-765-allocator-foreign-lease in worktree branches/issue-765-allocator-ownership. It was not published: the gitea_commit_files #274 branches-only guard resolved the session workspace to the stable control checkout and refused the mutation. This is the same publication gap already recorded on #607; it is a global author-publication gap, not specific to either task. Operator options (pick one): 1. Set GITEA_AUTHOR_WORKTREE (or GITEA_ACTIVE_WORKTREE) for the gitea-tools namespace launcher to the session worktree, then reconnect the MCP client. 2. Land a fix so gitea_commit_files accepts worktree_path, or so author workspace resolution consults the author issue-lock worktree the way reviewer/merger leases are consulted (see #618). Then run a fresh author cycle for #765: publish the branch, open the PR against master, and hand off to an independent reviewer. Do not re-implement - the code and tests already exist. After #765 merges and the MCP daemon serves it, the corrected allocator selects the next eligible unclaimed issue automatically. ``` WHAT_HAPPENED: Issue #765 was filed for the allocator ownership defect, locked to branch fix/issue-765-allocator-foreign-lease in worktree branches/issue-765-allocator-ownership, and implemented. Live claims are now loaded before ranking; candidates claimed by a different controller are excluded and reported in skipped with reason_code claimed_by_other_session, and ranking continues to the next unclaimed candidate. A stable controller_instance_id is persisted on sessions and surfaced on lease rows, so a controller can resume its own task while never adopting another controller's. The workflow dashboard applies the same exclusion. Work is preserved as local commit d06198b. gitea_commit_files was attempted exactly once and refused pre-API; a read-back of the branch returns 404, proving no branch, commit, or PR was created on Gitea. WHY: Session ids are regenerated per allocator invocation and every author session shares the prgs-author profile, so neither can express controller ownership. Without a durable identity the allocator either blockades the queue on someone else's lease or risks adopting it. A stable controller_instance_id makes the comparison decidable, and unidentifiable claims are excluded rather than adopted so the failure mode stays safe. RELATED_PRS: none - no PR was opened BLOCKERS: Blocker classification: environment/tooling blocker gitea_commit_files exposes no worktree_path parameter, and neither GITEA_ACTIVE_WORKTREE nor GITEA_AUTHOR_WORKTREE is set on the running gitea-tools process, so the author workspace resolves to the stable control checkout and the #274 guard fails closed. This gap blocks all author publication, not one task. Direct git push, editing server env, writing a repo-root .env, and restarting MCP are outside sanctioned author authority, so no fallback was attempted. VALIDATION: New tests: tests/test_allocator_foreign_lease_exclusion.py, 23 cases covering ownership classification, foreign-lease exclusion, next-unclaimed selection, own-task resume across a new session id, task-local blocker isolation, concurrent controllers on different issues, all-claimed wait with owner_session_id preserved, ownership-defect reporting, skipped inventory accounting, and end-to-end exclusion against a real ControlPlaneDB. Full suite: 3717 passed, 6 skipped. Two failures (test_issue_702_review_findings_f1_f6, test_reconciler_supersession_close) were re-run against unmodified master at fcf6981 and fail identically there, so they are pre-existing and unrelated. One pre-existing contract test caught an over-broad first draft of the ownership classifier and the classifier was narrowed so that a claim with no identity on either side is foreign rather than unidentifiable, preserving the earlier wait contract. Read-only check against the live control-plane DB: the sole active claim is classified foreign, and with the live author-safe queue in dashboard order the corrected allocator skips that issue with reason_code claimed_by_other_session and selects the next unclaimed one, where the shipped allocator selected the claimed issue and reported zero skips. LAST_UPDATED_BY: jcwalker3 / prgs-author / scheduled controller author cycle / 2026-07-20 [THREAD STATE LEDGER] What is true now: - Server-side decision state: no server-side state changed beyond creating issue #765 and this comment. No branch, commit, PR, or review exists on Gitea for #765. - Local verdict/state: correction complete and verified locally at commit d06198b on fix/issue-765-allocator-foreign-lease; full suite run with only pre-existing master failures. - Issue #765 is open with its issue lock held by this author session (expires 2026-07-20T07:06:09Z). What changed: - Local only: live-claim exclusion in allocator_service.py, controller_instance_id persistence plus list_active_claims in control_plane_db.py, the same exclusion in workflow_dashboard.py, controller-identity plumbing in gitea_mcp_server.py, and the new regression test module. - Server-side mutation ledger: issue #765 created; this canonical comment posted. No branch, commit, PR, review, or merge. The single gitea_commit_files attempt was refused before any API call and read-back confirmed absence. What is blocked: - Blocker classification: environment/tooling blocker - Publication of branch fix/issue-765-allocator-foreign-lease cannot proceed through gitea_commit_files while the author workspace binding resolves to the stable control checkout. Who/what acts next: - Next actor: user - Required action: bind the gitea-tools author namespace to the branches/ worktree via GITEA_AUTHOR_WORKTREE or GITEA_ACTIVE_WORKTREE and reconnect the MCP client, or land the commit_files worktree_path fix; then run a fresh author cycle to publish and open the PR for #765. Do not do: - Do not re-implement #765 or open a second branch, worktree, or issue for it; commit d06198b already contains the correction and its tests. - Do not publish the branch with direct git push, force-push, or any raw Gitea API, curl, gh, tea, or web-UI path; publication must go through gitea_commit_files once the binding is corrected. - Do not run the live allocator with apply=true before this fix is served by the MCP daemon: the shipped allocator still targets the issue claimed by another controller. - Do not touch, reclaim, release, or comment on the task claimed by the other controller; its lease is foreign and must be left alone. - Do not write a .env into the stable control checkout and do not mutate the control checkout to work around the guard. - Do not kill, restart, or respawn MCP server processes to force a rebind; client reconnect is the operator-owned recovery path. - Do not review, approve, or merge this work from the author namespace; an independent reviewer is required after the PR exists.
Owner

Canonical Issue State

STATE:
AUTHOR_RECOVERY_REQUIRED — coherent #765 implementation exists only as local commit d06198b97d583f0b960adcb435931effbf305516 on branch fix/issue-765-allocator-foreign-lease; behavior is absent from master edaeede250f46f361784061f025ab0e867172d2c; no PR opened; remote branch unpublished

WHO_IS_NEXT:
author

NEXT_ACTION:
When the author WIP slot is free: bind the author MCP namespace to worktree branches/issue-765-allocator-ownership, re-lock/adopt #765 onto fix/issue-765-allocator-foreign-lease, rebase or re-apply d06198b onto current master if needed, publish only via gitea_commit_files, then open one PR closing #765 for independent review. Do not re-implement. Do not open a reconciler PR.

NEXT_PROMPT:

Role: AUTHOR (prgs-author)
Repo: prgs / Scaled-Tech-Consulting / Gitea-Tools
Issue: #765 — allocator foreign-lease exclusion

Preserved work (do not re-implement):
- Branch: fix/issue-765-allocator-foreign-lease
- SHA: d06198b97d583f0b960adcb435931effbf305516
- Patch-id: bacafc5f96f709ea195fdce733ba98449ae4513f
- Worktree: /Users/jasonwalker/Development/Gitea-Tools/branches/issue-765-allocator-ownership
- Clean; no upstream; no open PR

Master gap proof (reconciler disposition 2026-07-20):
- Master edaeede lacks classify_claim_ownership, list_active_claims,
  controller_instance_id, claimed_by_other_session exclusion, dashboard parity,
  and tests/test_allocator_foreign_lease_exclusion.py
- No PR among 349 implements/supersedes #765
- Candidate is 1 unique commit on base fcf6981; master advanced 4 commits
  (#723, #768) that do not land #765

Publication steps:
1. Bind GITEA_AUTHOR_WORKTREE (or GITEA_ACTIVE_WORKTREE) to the worktree above;
   reconnect author MCP if required (#618).
2. gitea_whoami + gitea_resolve_task_capability + lock/adopt #765 to this branch/worktree.
3. If needed, rebase d06198b onto current master without discarding the fix.
4. Publish only through gitea_commit_files; never git push / curl / gh / tea / raw API.
5. Open one PR closing #765; hand off to independent reviewer.

Do not touch #607/#767, #681, #618, #695, #723, or other worktrees.

WHAT_HAPPENED:
Supervised reconciler branch-disposition for Issue #765 only (profile prgs-reconciler, identity sysadmin). Preflight: jasonwalker/UID 502; clean control checkout on master@edaeede matching prgs/master. Candidate worktree clean at d06198b. Issue #765 open with labels anti-stomp, mcp-health, status:ready, type:bug, workflow-hardening. Durable author handoff comment 13053 already recorded local completion + publication failure (workspace binding / #274). Comparison: d06198b not ancestor of master; stable patch-id bacafc5f… unmatched on master file history; all five changed blobs differ; master only has inert already_claimed_elsewhere. Worktree path alias issue-765-allocator-ownership is the lock-recorded semantic path (not branch-slug path). Issue lock exists for jcwalker3/prgs-author pid 86632, expires_at 2026-07-20T07:06:09Z (TTL elapsed; audit has_active_issue_lock=false). No active control-plane lease on #765. Worktree audit: active_issue_work, clean, no open PR, not removable. No mutations other than this disposition comment; artifacts preserved.

WHY:
The #765 defect (allocator ignores active foreign leases and blockades the author queue) is still present on shipped master. The candidate fully implements the required ownership model and tests. Without publishing this commit, concurrent author sessions remain at risk of selecting foreign-claimed work. Disposition is recovery of existing work, not new allocation or supersession cleanup.

RELATED_PRS:
none for #765. Open PR inventory complete (1 open: #767 Closes #607 only). Closed inventory scanned (349 total, inventory_complete=true): no PR title/body/head implements, supersedes, or closes #765.

BLOCKERS:
Blocker classification: environment/tooling + author-slot sequencing

  1. Author publication still requires branches/ worktree binding for gitea_commit_files (#274 / #618 gap noted in comment 13053).
  2. Publish only when author WIP slot is available; do not stomp foreign author work.
  3. Master moved 4 commits past candidate base fcf6981 — author must rebase/re-apply before PR if merge would conflict, without discarding d06198b semantics.

VALIDATION:

  • Local unique commit: d06198b (Closes #765) — 5 files, +735/-22
  • Files: allocator_service.py, control_plane_db.py, gitea_mcp_server.py, workflow_dashboard.py, tests/test_allocator_foreign_lease_exclusion.py
  • AC1–AC9 present on candidate, absent on master (see table in disposition proof)
  • Author-reported tests: 23 focused cases; full suite 3717 passed / 6 skipped; 2 pre-existing master failures unrelated
  • Reconciler did not re-run the full suite; disposition is comparison-based plus durable author validation
  • Control checkout remained clean; no source edits, no PR, no merge, no push, no delete

LAST_UPDATED_BY:
sysadmin / prgs-reconciler / supervised branch-disposition / 2026-07-20

[DISPOSITION PROOF]

Disposition class: AUTHOR_RECOVERY_REQUIRED

Check Result
Candidate HEAD d06198b97d583f0b960adcb435931effbf305516
Stable patch-id bacafc5f96f709ea195fdce733ba98449ae4513f
On master? no
Patch-id on master file history? no match
PR for #765? none
Remote branch (MCP PR inventory + author 404 proof) unpublished / not present
Worktree clean? yes
Contaminated/unrelated diff? no (scoped 5-file #765 fix)
Incomplete vs ACs? no (all 9 ACs on candidate)

Preservation: keep branch + worktree until author publishes. No reconciler PR. No orphan cleanup yet.

## Canonical Issue State STATE: AUTHOR_RECOVERY_REQUIRED — coherent #765 implementation exists only as local commit d06198b97d583f0b960adcb435931effbf305516 on branch fix/issue-765-allocator-foreign-lease; behavior is absent from master edaeede250f46f361784061f025ab0e867172d2c; no PR opened; remote branch unpublished WHO_IS_NEXT: author NEXT_ACTION: When the author WIP slot is free: bind the author MCP namespace to worktree branches/issue-765-allocator-ownership, re-lock/adopt #765 onto fix/issue-765-allocator-foreign-lease, rebase or re-apply d06198b onto current master if needed, publish only via gitea_commit_files, then open one PR closing #765 for independent review. Do not re-implement. Do not open a reconciler PR. NEXT_PROMPT: ```text Role: AUTHOR (prgs-author) Repo: prgs / Scaled-Tech-Consulting / Gitea-Tools Issue: #765 — allocator foreign-lease exclusion Preserved work (do not re-implement): - Branch: fix/issue-765-allocator-foreign-lease - SHA: d06198b97d583f0b960adcb435931effbf305516 - Patch-id: bacafc5f96f709ea195fdce733ba98449ae4513f - Worktree: /Users/jasonwalker/Development/Gitea-Tools/branches/issue-765-allocator-ownership - Clean; no upstream; no open PR Master gap proof (reconciler disposition 2026-07-20): - Master edaeede lacks classify_claim_ownership, list_active_claims, controller_instance_id, claimed_by_other_session exclusion, dashboard parity, and tests/test_allocator_foreign_lease_exclusion.py - No PR among 349 implements/supersedes #765 - Candidate is 1 unique commit on base fcf6981; master advanced 4 commits (#723, #768) that do not land #765 Publication steps: 1. Bind GITEA_AUTHOR_WORKTREE (or GITEA_ACTIVE_WORKTREE) to the worktree above; reconnect author MCP if required (#618). 2. gitea_whoami + gitea_resolve_task_capability + lock/adopt #765 to this branch/worktree. 3. If needed, rebase d06198b onto current master without discarding the fix. 4. Publish only through gitea_commit_files; never git push / curl / gh / tea / raw API. 5. Open one PR closing #765; hand off to independent reviewer. Do not touch #607/#767, #681, #618, #695, #723, or other worktrees. ``` WHAT_HAPPENED: Supervised reconciler branch-disposition for Issue #765 only (profile prgs-reconciler, identity sysadmin). Preflight: jasonwalker/UID 502; clean control checkout on master@edaeede matching prgs/master. Candidate worktree clean at d06198b. Issue #765 open with labels anti-stomp, mcp-health, status:ready, type:bug, workflow-hardening. Durable author handoff comment 13053 already recorded local completion + publication failure (workspace binding / #274). Comparison: d06198b not ancestor of master; stable patch-id bacafc5f… unmatched on master file history; all five changed blobs differ; master only has inert already_claimed_elsewhere. Worktree path alias issue-765-allocator-ownership is the lock-recorded semantic path (not branch-slug path). Issue lock exists for jcwalker3/prgs-author pid 86632, expires_at 2026-07-20T07:06:09Z (TTL elapsed; audit has_active_issue_lock=false). No active control-plane lease on #765. Worktree audit: active_issue_work, clean, no open PR, not removable. No mutations other than this disposition comment; artifacts preserved. WHY: The #765 defect (allocator ignores active foreign leases and blockades the author queue) is still present on shipped master. The candidate fully implements the required ownership model and tests. Without publishing this commit, concurrent author sessions remain at risk of selecting foreign-claimed work. Disposition is recovery of existing work, not new allocation or supersession cleanup. RELATED_PRS: none for #765. Open PR inventory complete (1 open: #767 Closes #607 only). Closed inventory scanned (349 total, inventory_complete=true): no PR title/body/head implements, supersedes, or closes #765. BLOCKERS: Blocker classification: environment/tooling + author-slot sequencing 1. Author publication still requires branches/ worktree binding for gitea_commit_files (#274 / #618 gap noted in comment 13053). 2. Publish only when author WIP slot is available; do not stomp foreign author work. 3. Master moved 4 commits past candidate base fcf6981 — author must rebase/re-apply before PR if merge would conflict, without discarding d06198b semantics. VALIDATION: - Local unique commit: d06198b (Closes #765) — 5 files, +735/-22 - Files: allocator_service.py, control_plane_db.py, gitea_mcp_server.py, workflow_dashboard.py, tests/test_allocator_foreign_lease_exclusion.py - AC1–AC9 present on candidate, absent on master (see table in disposition proof) - Author-reported tests: 23 focused cases; full suite 3717 passed / 6 skipped; 2 pre-existing master failures unrelated - Reconciler did not re-run the full suite; disposition is comparison-based plus durable author validation - Control checkout remained clean; no source edits, no PR, no merge, no push, no delete LAST_UPDATED_BY: sysadmin / prgs-reconciler / supervised branch-disposition / 2026-07-20 [DISPOSITION PROOF] Disposition class: **AUTHOR_RECOVERY_REQUIRED** | Check | Result | |---|---| | Candidate HEAD | d06198b97d583f0b960adcb435931effbf305516 | | Stable patch-id | bacafc5f96f709ea195fdce733ba98449ae4513f | | On master? | no | | Patch-id on master file history? | no match | | PR for #765? | none | | Remote branch (MCP PR inventory + author 404 proof) | unpublished / not present | | Worktree clean? | yes | | Contaminated/unrelated diff? | no (scoped 5-file #765 fix) | | Incomplete vs ACs? | no (all 9 ACs on candidate) | Preservation: keep branch + worktree until author publishes. No reconciler PR. No orphan cleanup yet.
jcwalker3 added status:pr-open and removed status:ready labels 2026-07-20 13:53:24 -05:00
sysadmin removed the status:pr-open label 2026-07-20 14:36:11 -05:00
Sign in to join this conversation.
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Scaled-Tech-Consulting/Gitea-Tools#765