Labels
Clear labels
allocator
anti-stomp
architecture
bug
chore
codex
concurrency
contamination
control-plane
dashboard
database
design
documentation
enhancement
gitea
glitchtip
important
incident
incident-bridge
integration
jenkins
labels
leases
mcp
mcp-health
mcp-menu
multi-project
mutating
nice-to-have
observability
portability
preflight
protected-branch
queue
read-only
reconnect
recovery
refactor
release
reliability
resumable-review
reviewer
roadmap
safety
security
self-hosted
sentry
stale-runtime
status:blocked
status:in-progress
status:pr-open
status:ready
terminal-lock
testing
tracker
type:bug
type:feature
type:feature
type:guardrail
visibility
workflow
workflow-hardening
workflow-hardening
Controller-owned work allocator
Prevent concurrent LLM session stomping
Architecture / structural design
OpenAI Codex client / workflow session surface
Concurrent session safety
Workflow or session contamination incident
MCP control-plane coordination and allocation authority
MCP operational dashboard/queue view
Internal coordination storage (SQLite/Postgres)
Design / investigation, no implementation
Docs / runbooks
New feature or improvement
Gitea MCP workflow
GlitchTip integration
Operational or process incident requiring durable audit trail
Sentry-to-Gitea incident bridging
Integration testing
Jenkins integration
Label taxonomy management
Lease adopt/release/expire lifecycle
MCP server / tooling
MCP namespace and runtime health
MCP menu surface
Work spanning multiple monitoring projects or Gitea repos
Mutating action; requires gating
Observability, metrics, traces, error reporting
Cross-platform / portability
Shared preflight gates before mutation
Protected branch / stable-branch policy concern
Work queue visibility and allocation
Read-only, no mutation
MCP client reconnect/reload recovery path
Recovery paths for stale/foreign leases
Code refactor / restructure
Release / versioning
Reliability / failure handling
Persist and resume prepared review verdicts across sessions
Reviewer workflow tooling
Roadmap / umbrella issue
Safety rails and fail-closed mutation guards
Security / trust boundary
Self-hosted infrastructure integration
Sentry error monitoring integration
Stale backend daemon / runtime-vs-master parity failures
Issue is blocked
Issue is being worked on
Issue has an open pull request
Issue is ready for work
Terminal review lock (#332) path
Tests / test coverage
Issue tracker hygiene / meta
Bug or defect
Feature or enhancement
Feature or enhancement
Safety gate or guardrail
Workflow state visibility for LLMs/operators
Cross-tool workflow
LLM workflow coordination hardening
LLM workflow coordination hardening
No labels
Milestone
No items
No Milestone
Projects
Clear projects
No projects
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: Scaled-Tech-Consulting/Gitea-Tools#595
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Summary
Implements #594: a canonical MCP path to clear durable #332 review-decision locks that outlive the PR they protected (after #559 session-state persistence).
Problem
~/.cache/gitea-tools/session-state/review_decision_lock-prgs-reviewer.jsonretained a terminalapprovefor already-merged PR #586 and blocked formal review of a later PR (#592).Changes
stale_review_decision_lock.py: pure assess/moot policy + audit helpersgitea_cleanup_stale_review_decision_lock: read-first (apply=false), gated apply with live PR proof, identity/profile checks, durable audit + optional PR commentValidation
Head:
b98e8dfa1a4a47ee0e94cfa77840ccea5f8b8577Closes #594
Canonical Issue State
STATE:
PR-open
WHO_IS_NEXT:
reviewer
NEXT_ACTION:
Review and merge PR #595 (issue #594) so gitea_cleanup_stale_review_decision_lock is available on live MCP, then clear the stale #586 prgs-reviewer decision lock and formal-APPROVE PR #592.
NEXT_PROMPT:
WHAT_HAPPENED:
Author implemented #594 and opened PR #595. Live MCP does not yet expose gitea_cleanup_stale_review_decision_lock (code not on master; MCP also reports stale-runtime). Formal APPROVE for PR #592 remains blocked until #595 lands, MCP restarts, and the moot #586 lock is cleared via the new tool.
WHY:
#332 must stay fail-closed for open PRs; only a gated moot-cleanup path (#594) may clear durable locks after merge. Manual session-state file deletion is not the workflow.
RELATED_DISCUSSION:
none
RELATED_PRS:
BRANCH:
feat/issue-594-stale-decision-lock-cleanup
HEAD_SHA:
b98e8dfa1aVALIDATION:
pytest tests/test_stale_review_decision_lock_cleanup.py tests/test_terminal_review_hard_stop.py -q → 27 passed (full trio with session-state was 34 earlier).
BLOCKERS:
PR #592 formal APPROVE blocked until: (1) #595 reviewed+merged, (2) gitea-reviewer MCP fully restarted onto new code, (3) gitea_cleanup_stale_review_decision_lock apply for expected_terminal_pr=586 succeeds.
LAST_UPDATED_BY:
jcwalker3 / prgs-author / 2026-07-09
repo: Scaled-Tech-Consulting/Gitea-Tools
pr: #595
issue: #594
reviewer_identity: sysadmin
profile: prgs-reviewer
session_id: 40160-0858dd531460
worktree: /Users/jasonwalker/Development/Gitea-Tools/branches/review-pr-595-issue-594
phase: claimed
candidate_head:
b98e8dfa1atarget_branch: master
target_branch_sha: none
last_activity: 2026-07-09T19:42:52Z
expires_at: 2026-07-09T21:42:52Z
blocker: none
Canonical Issue State
STATE:
blocked
WHO_IS_NEXT:
user
NEXT_ACTION:
Unblock formal review submission for PR #595 (and later #592) by clearing the durable prgs-reviewer #332 lock that still ends with approve on already-merged PR #586. Prefer a path that does not require the not-yet-merged #594 tool: operator-supported session reset for prgs-reviewer, or temporary fresh reviewer session identity, then re-submit formal APPROVE on #595 at
b98e8df. Do not hand-delete session-state as the normal workflow once #595 lands.NEXT_PROMPT:
WHAT_HAPPENED:
Independent reviewer (sysadmin / prgs-reviewer) completed full technical review of PR #595 for Issue #594 in branches/review-pr-595-issue-594. Code, tests, and docs match #594 acceptance criteria. Formal APPROVE could not be submitted: gitea_mark_final_review_decision blocked by durable #332 ledger (approve on merged PR #586). Dry-run APPROVE would_perform=true. Lease 8539 acquired. No formal review ID.
WHY:
#332 hard-stop is working as designed for a terminal mutation, but the durable ledger (#559) still references merged #586. The fix for that is this PR (#595 / #594). Cannot use the new cleanup tool until it is on the running MCP. No #332 bypass or session-state hand-delete performed.
RELATED_DISCUSSION:
none
RELATED_PRS:
BRANCH:
feat/issue-594-stale-decision-lock-cleanup
HEAD_SHA:
b98e8dfa1aVALIDATION:
b98e8dfBLOCKERS:
Durable #332 decision lock for prgs-reviewer ends with approve on merged PR #586 — blocks gitea_mark_final_review_decision / formal APPROVE for any other PR including #595. Unblock: supported clear of review_decision_lock-prgs-reviewer (or a reviewer session without that lock), then formal re-review of #595.
LAST_UPDATED_BY:
sysadmin / prgs-reviewer / 2026-07-09
Technical review (informal; intended formal decision once unblocked: APPROVE)
Cleanup tool is correctly fail-closed for open/active locks, requires identity + gitea.pr.review for apply, records durable audit, preserves #332 hard-stop tests, documents allowed vs forbidden paths. Minimal test isolation in conftest/TestMergePR is scoped support for deterministic hard-stop coverage, not a production #332 weaken.
Review decision: BLOCKED + DIAGNOSE (tooling/session #332). No formal review ID from gitea_submit_pr_review.
Lease comment_id: 8539
repo: Scaled-Tech-Consulting/Gitea-Tools
pr: #595
issue: #594
reviewer_identity: sysadmin
profile: prgs-reviewer
session_id: 40160-0858dd531460
worktree: /Users/jasonwalker/Development/Gitea-Tools/branches/review-pr-595-issue-594
phase: released
candidate_head:
b98e8dfa1atarget_branch: master
target_branch_sha: none
last_activity: 2026-07-09T19:44:41Z
expires_at: 2026-07-09T21:44:41Z
blocker: manual-release
Canonical Issue State
STATE: BLOCKED
WHO_IS_NEXT: user
NEXT_ACTION: Operator must free the prgs-reviewer durable #332 decision lock (stale terminal approve on already-merged PR #586) so a formal APPROVE can be submitted for PR #595 — e.g. restart prgs-reviewer with a fresh GITEA_MCP_SESSION_STATE_DIR, or clear only the obsolete review_decision_lock-prgs-reviewer artifact under operator control — then re-run formal mark+submit APPROVE for head
b98e8dfa1a.NEXT_PROMPT:
WHAT_HAPPENED: Independent reviewer (sysadmin / prgs-reviewer, not author jcwalker3) fully validated PR #595 at live head
b98e8dfa1a. Implementation matches #594 acceptance criteria. Formal gitea_mark_final_review_decision fail-closed under #332 because durable host session-state still records terminal approve for already-merged PR #586. Live MCP does not yet expose gitea_cleanup_stale_review_decision_lock (that tool is introduced by this PR) — bootstrap chicken-egg.WHY: Durable #559 lock outlives merged PR #586; #332 hard-stop correctly blocks new terminal reviews until moot cleanup exists in the running process. Manual session-state rm by the LLM is forbidden; correction path (#211) is the wrong semantic for multi-PR resume.
RELATED_PRS: #595 (this PR), #594 (issue), #586 (stale terminal approve target, already merged), #592 (blocked earlier by same lock; retry after #595 lands + MCP restart + cleanup)
BLOCKERS: UNBLOCK when review_decision_lock-prgs-reviewer no longer hard-stops mark_ready for PRs other than a live open approved PR (specifically when terminal approve on merged #586 is cleared for this profile). Currently: gitea_mark_final_review_decision returns terminal review mutation already consumed (approve on PR #586).
VALIDATION:
b98e8dfa1a(matches expected)LAST_UPDATED_BY: sysadmin (prgs-reviewer)
Implementation inspection summary
repo: Scaled-Tech-Consulting/Gitea-Tools
pr: #595
issue: #594
reviewer_identity: sysadmin
profile: prgs-reviewer
session_id: 40160-6ae73ec596f6
worktree: /Users/jasonwalker/Development/Gitea-Tools/branches/review-pr-595-issue-594
phase: claimed
candidate_head:
b98e8dfa1atarget_branch: master
target_branch_sha: none
last_activity: 2026-07-09T19:51:08Z
expires_at: 2026-07-09T21:51:08Z
blocker: none
Canonical PR State
STATE:
approved
WHO_IS_NEXT:
merger
NEXT_ACTION:
Merge PR #595 at head
b98e8dfa1a, restart gitea-reviewer MCP onto master, run gitea_cleanup_stale_review_decision_lock for any remaining moot locks if needed, then formal APPROVE PR #592.NEXT_PROMPT:
WHAT_HAPPENED:
Independent reviewer (sysadmin / prgs-reviewer) formal APPROVED PR #595 for Issue #594 at head
b98e8dfa1a.Operator-approved #211 correction was used to re-open the review path after a moot durable #332 terminal mutation (approve on already-merged PR #586). Permanent cleanup path remains this PR's gitea_cleanup_stale_review_decision_lock after merge (#594).
WHY:
Scoped, tested #594 implementation: moot-only decision-lock cleanup with live PR proof, identity/profile gates, durable audit, #332 preserved for open PRs. Validation green. Safe and merge-ready.
ISSUE:
#594
BASE:
master
HEAD:
feat/issue-594-stale-decision-lock-cleanup
HEAD_SHA:
b98e8dfa1aREVIEW_STATUS:
approved
VALIDATION:
BLOCKERS:
none for this PR
SUPERSEDES:
none
SUPERSEDED_BY:
none
MERGE_READY:
yes — formal approval at current head, mergeable true, tests green
LAST_UPDATED_BY:
sysadmin / prgs-reviewer / 2026-07-09
APPROVE. Does not merge.
repo: Scaled-Tech-Consulting/Gitea-Tools
pr: #595
issue: #594
reviewer_identity: sysadmin
profile: prgs-reviewer
session_id: 40160-6ae73ec596f6
worktree: /Users/jasonwalker/Development/Gitea-Tools/branches/review-pr-595-issue-594
phase: released
candidate_head:
b98e8dfa1atarget_branch: master
target_branch_sha: none
last_activity: 2026-07-09T19:54:01Z
expires_at: 2026-07-09T21:54:01Z
blocker: manual-release
repo: Scaled-Tech-Consulting/Gitea-Tools
pr: #595
issue: #594
reviewer_identity: sysadmin
profile: prgs-reviewer
session_id: 88834-8a9bb0fc22cd
worktree: /Users/jasonwalker/Development/Gitea-Tools/branches/review-pr-595-issue-594
phase: claimed
candidate_head:
b98e8dfa1atarget_branch: master
target_branch_sha:
6913ac98f1last_activity: 2026-07-09T19:55:42Z
expires_at: 2026-07-09T21:55:42Z
blocker: none
Canonical PR State
STATE: approved
WHO_IS_NEXT: merger
NEXT_ACTION: Merge PR #595 at head
b98e8dfa1aafter pre-merge gates, then restart MCP so gitea_cleanup_stale_review_decision_lock is available for future stale locks (including unblocking PR #592 if still open).NEXT_PROMPT:
WHAT_HAPPENED: Independent reviewer sysadmin/prgs-reviewer approved PR #595 after operator recovery of stale durable #332 lock (merged PR #586 terminal state). Technical validation green; formal APPROVE submitted at pinned head.
WHY: Implementation meets #594 acceptance criteria — moot cleanup only for merged/closed prior terminal PRs, active #332 preserved, identity/profile gates + audit trail, tests and docs present.
ISSUE: #594
HEAD_SHA:
b98e8dfa1aREVIEW_STATUS: APPROVED by sysadmin at current head
MERGE_READY: yes
BLOCKERS: none
VALIDATION:
b98e8dfa1aLAST_UPDATED_BY: sysadmin (prgs-reviewer)
APPROVE summary
Safe, scoped, tested, merge-ready. Does not merge.
adopted_at: 2026-07-09T19:59:18Z
adopted_by_identity: sysadmin
adopted_by_profile: prgs-merger
adopted_from_session_id: 88834-8a9bb0fc22cd
adopted_from_profile: prgs-reviewer
adopted_from_reviewer_identity: sysadmin
adopted_from_comment_id: 8585
adoption_reason: merger-handoff-approved-head
repo: Scaled-Tech-Consulting/Gitea-Tools
pr: #595
issue: #594
reviewer_identity: sysadmin
profile: prgs-merger
session_id: 40158-bc50b026f9a2
worktree: /Users/jasonwalker/Development/Gitea-Tools/branches/merge-pr-595-issue-594
phase: adopted
candidate_head:
b98e8dfa1atarget_branch: master
target_branch_sha:
6913ac98f1last_activity: 2026-07-09T19:59:18Z
expires_at: 2026-07-09T21:59:18Z
blocker: none