Add stacked PR info to PR webview - #8990
Open
Alex Ross (alexr00) wants to merge 1 commit into
Open
Alex Ross (alexr00) wants to merge 1 commit into
Alex Ross (alexr00) wants to merge 1 commit into
Conversation
Alex Ross (alexr00)
added this pull request to stack #8993
September 30, 2026 08:59
Alex Ross (alexr00)
marked this pull request as ready for review
September 30, 2026 09:03
Dirk Bäumer (dbaeumer)
approved these changes
Sep 30, 2026
Contributor
There was a problem hiding this comment.
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
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>; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

No description provided.