Skip to content

Add stacked PR info to PR webview - #8990

Open
Alex Ross (alexr00) wants to merge 1 commit into
mainfrom
alexr00/prime-gamefowl
Open

Alex Ross (alexr00) wants to merge 1 commit into
mainfrom
alexr00/prime-gamefowl

Conversation

@alexr00

Copy link
Copy Markdown
Member

No description provided.

@alexr00 Alex Ross (alexr00) self-assigned this Sep 29, 2026
@alexr00
Alex Ross (alexr00) added this pull request to stack #8993 September 30, 2026 08:59
@alexr00
Alex Ross (alexr00) marked this pull request as ready for review September 30, 2026 09:03
Copilot AI balanced review requested due to automatic review settings September 30, 2026 09:03

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

Stack-loading races can expose stale or incorrect merge behavior, and loading failures unnecessarily block draft readiness actions.

Review effort: Balanced
Findings: 3 Medium severity

Open (3)
What changed in this PR

Adds stacked pull request information and merge support to PR webviews.

Changes:

  • Displays stack position, members, readiness, and base branch.
  • Adds asynchronous stack merge and merge-queue workflows.
  • Adds GraphQL stack loading, compatibility handling, styling, and tests.
File Description
webviews/​editorWebview/​test/​overview.test.tsx Tests stack UI and merge behavior.
webviews/​editorWebview/​test/​builder/​pullRequest.ts Adds stack test defaults.
webviews/​editorWebview/​index.css Styles stack details and badge.
webviews/​components/​pullRequestStack.tsx Renders stack information.
webviews/​components/​merge.tsx Adds stack merge controls.
webviews/​components/​icon.tsx Exposes the layers icon.
webviews/​components/​header.tsx Adds the stack badge.
webviews/​common/​context.tsx Adds stack merge messaging.
webviews/​common/​common.css Styles shared merge controls.
webviews/​activityBarView/​index.css Adapts controls for the activity bar.
src/​test/​mocks/​queryProvider.ts Supports REST errors and rate-limit headers.
src/​test/​github/​pullRequestOverview.test.ts Tests stack merge orchestration.
src/​test/​github/​pullRequestModel.test.ts Tests loading and merging stacks.
src/​test/​github/​githubRepository.test.ts Tests optional-query fallback behavior.
src/​test/​common/​utils.test.ts Tests object type checking.
src/​github/​views.ts Adds stack webview state types.
src/​github/​queriesShared.gql Defines the stack GraphQL query.
src/​github/​pullRequestReviewCommon.ts Handles stack merge requests.
src/​github/​pullRequestOverview.ts Loads stack data into the editor webview.
src/​github/​pullRequestModel.ts Implements stack queries and asynchronous merging.
src/​github/​loggingOctokit.ts Reuses the shared object guard.
src/​github/​interface.ts Defines stack data structures.
src/​github/​graphql.ts Types stack query responses.
src/​github/​githubRepository.ts Makes limited-schema fallback optional.
src/​github/​activityBarViewProvider.ts Loads stacks in the activity-bar view.
src/​common/​utils.ts Adds a shared object guard.
resources/​icons/​codicons/​layers.svg Adds the stack icon asset.
.husky/​pre-commit Suppresses ignored-file ESLint warnings.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +326 to +331
void pullRequest.getStack().then(async stack => {
if (!this._item.equals(pullRequest)) {
return;
}
const stackQueueMethod = stack ? await this._folderRepositoryManager.mergeQueueMethodForBranch(stack.base, pullRequest.remote.owner, pullRequest.remote.repositoryName) : undefined;
if (this._item.equals(pullRequest)) {
}))),
};
if (updateSequence === this._updateSequence) {
stackLoaded = true;
Comment on lines +406 to +410
if (pr.stackLoadError) {
return <div className="status-item">Unable to load pull request stack details. Refresh to retry merging.</div>;
}
if (pr.stackLoaded === false) {
return <div className="status-item">Checking pull request stack membership...</div>;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants