Skip to content

fix(web): keep merge pending until refresh - #6271

Open
flamboh wants to merge 1 commit into
pingdotgg:mainfrom
flamboh:t3code/fix-merge-button-completion-state
Open

fix(web): keep merge pending until refresh#6271
flamboh wants to merge 1 commit into
pingdotgg:mainfrom
flamboh:t3code/fix-merge-button-completion-state

Conversation

@flamboh

@flamboh flamboh commented Aug 12, 2026

Copy link
Copy Markdown

What Changed

The Merge button now stays pending until refreshed PR data confirms the merge.

Why

The merge command finished before the detail refresh, so stale open-state data briefly made the Merge button clickable again.

UI Changes

Before

merge button before

After

merge button after

Checklist

  • This PR is small and focused
  • I explained what changed and why
  • I included before/after screenshots for any UI changes
  • I included a video for animation/interaction changes

Created by GPT-5.6-sol using the Codex harness in T3 Code.

Note

Keep pull request action controls pending until refreshed detail reflects the new state

  • Previously, the pending/disabled state on action buttons (merge, close, reopen, draft, ready) cleared immediately after the mutation completed, before the refreshed pull request detail had arrived.
  • Replaces the simple actionPending boolean in PullRequestDetailPanel with a pendingAction object that tracks the pull request key and action, and clears only when isPullRequestActionReflected confirms the new state is visible in the refreshed detail.
  • Adds a new isPullRequestActionReflected utility in pullRequestDetail.logic.ts that checks whether the pull request's current state matches the expected post-action state.
  • On action failure, pending is cleared immediately as before.

Macroscope summarized fd4ffaa.

@coderabbitai

coderabbitai Bot commented Aug 12, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: b02a1d35-932b-4f86-afbd-e0deb6b4ee32

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions github-actions Bot added vouch:unvouched PR author is not yet trusted in the VOUCHED list. size:M 30-99 changed lines (additions + deletions). labels Aug 12, 2026
@macroscopeapp

macroscopeapp Bot commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Approved fd4ffaa

This is a well-scoped UI bug fix that prevents a merge button from briefly reappearing due to stale state after a successful action. The changes are self-contained with clear logic and unit tests, affecting only local state management with no backend or security implications.

You can customize Macroscope's approvability policy. Learn more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:M 30-99 changed lines (additions + deletions). vouch:unvouched PR author is not yet trusted in the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant