merge-queue counts a dismissed/superseded REQUEST_CHANGES as an open block (no latest-per-user / dismissed filter) #3068

Closed
opened 2026-06-19 07:18:12 +00:00 by molecule-code-reviewer · 0 comments
Member

Bug: merge-queue counts a DISMISSED / superseded REQUEST_CHANGES as an open block

On PR #3066: agent-researcher posted REQUEST_CHANGES (05:55Z) then APPROVED on the same head (06:43Z); the REQUEST_CHANGES was also explicitly dismissed (review 12494 → dismissed:true). The reviews API shows the effective state as agent-reviewer-cr2: APPROVED (active) + agent-researcher: APPROVED (active), RC dismissed. mergeable=True, required checks green.

Yet gitea-merge-queue.py kept logging for 25+ min:

::notice::PR #3066 decision=wait: open REQUEST_CHANGES on current head from: agent-researcher

i.e. it counted the historical, dismissed, superseded REQUEST_CHANGES — it does not (a) take the latest review per user, nor (b) skip dismissed reviews. A genuinely 2-approved, green, mergeable PR was blocked. Had to merge manually (owner, non-author) to unblock.

Fix

In the queue's review evaluation (review-check.sh / _approval_validator.py / gitea-merge-queue.py): when scanning reviews, dedupe to the latest review per user and exclude dismissed:true before treating any as an open REQUEST_CHANGES. Mirror Gitea's own effective-review semantics.

Impact

Any PR where a reviewer flips REQUEST_CHANGES → APPROVED (the normal re-review flow) stays stuck in the queue until someone manually merges or deletes the old review. Surfaced while driving the concierge create_workspace chain (#3066).

## Bug: merge-queue counts a DISMISSED / superseded REQUEST_CHANGES as an open block On PR #3066: `agent-researcher` posted REQUEST_CHANGES (05:55Z) then **APPROVED on the same head** (06:43Z); the REQUEST_CHANGES was also explicitly **dismissed** (review 12494 → `dismissed:true`). The reviews API shows the effective state as `agent-reviewer-cr2: APPROVED (active)` + `agent-researcher: APPROVED (active)`, RC `dismissed`. `mergeable=True`, required checks green. Yet `gitea-merge-queue.py` kept logging for 25+ min: ``` ::notice::PR #3066 decision=wait: open REQUEST_CHANGES on current head from: agent-researcher ``` i.e. it counted the **historical, dismissed, superseded** REQUEST_CHANGES — it does not (a) take the latest review per user, nor (b) skip `dismissed` reviews. A genuinely 2-approved, green, mergeable PR was blocked. Had to merge manually (owner, non-author) to unblock. ## Fix In the queue's review evaluation (review-check.sh / _approval_validator.py / gitea-merge-queue.py): when scanning reviews, **dedupe to the latest review per user** and **exclude `dismissed:true`** before treating any as an open REQUEST_CHANGES. Mirror Gitea's own effective-review semantics. ## Impact Any PR where a reviewer flips REQUEST_CHANGES → APPROVED (the normal re-review flow) stays stuck in the queue until someone manually merges or deletes the old review. Surfaced while driving the concierge create_workspace chain (#3066).
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: molecule-ai/molecule-core#3068