Skip to content

Disable stack features by default - #9002

Open
Alex Ross (alexr00) wants to merge 2 commits into
alexr00/prime-boarfrom
alexr00/fond-meadowlark
Open

Alex Ross (alexr00) wants to merge 2 commits into
alexr00/prime-boarfrom
alexr00/fond-meadowlark

Conversation

@alexr00

Copy link
Copy Markdown
Member

No description provided.

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.

Warning

Copilot couldn't run its full agentic review because it didn't start before the timeout. Make sure your repository has a runner available, or add a copilot-code-review.yml file specifying one with the runs-on attribute. See the docs for more details.

Copilot review overview

Review effort: Lite
Findings: 1 High severity · 3 Medium severity

Open (4)
What changed in this PR

Introduces an opt-in setting to disable pull request stack functionality by default, and gates stack-related UI/actions based on that setting.

Changes:

  • Added githubPullRequests.experimental.stacks setting (default false) plus a shared areStacksEnabled() helper.
  • Disabled/guarded stack-dependent behaviors in the PR tree, PR overview/webviews, merge-stack, unstack, and create-PR stack flows.
  • Added test coverage and a reusable test mock for the new stacks setting.
File Description
src/​view/​prsTreeDataProvider.ts Gates tree multi-select and “Add to Stack” enablement/execution based on the stacks setting.
src/​github/​pullRequestStack.ts Prevents stack creation logic from running when stacks are disabled.
src/​github/​pullRequestReviewCommon.ts Blocks merge-stack when stacks are disabled.
src/​github/​pullRequestOverview.ts Skips stack loading/refresh and blocks unstack when stacks are disabled; refreshes on setting changes.
src/​github/​createPRViewProvider.ts Skips stack candidate lookup and blocks stack operations when stacks are disabled; reacts to setting changes.
src/​github/​activityBarViewProvider.ts Skips stack loading in the activity bar view when stacks are disabled; refreshes on setting changes.
src/​common/​settingsUtils.ts Adds areStacksEnabled() helper reading the new setting.
src/​common/​settingKeys.ts Adds EXPERIMENTAL_STACKS setting key constant.
package.json Contributes the new experimental stacks setting (default disabled).
package.nls.json Adds localized description string for the new setting.
src/​test/​mocks/​mockStackSetting.ts Adds a shared test helper to toggle stacks on/off via config stubbing.
src/​test/​view/​prsTree.test.ts Adds tests ensuring stack UI is disabled when stacks are disabled.
src/​test/​github/​pullRequestStack.test.ts Adds test ensuring stack creation is rejected when disabled.
src/​test/​github/​pullRequestOverview.test.ts Adds tests ensuring stack membership/merge/unstack are blocked or skipped when disabled.
src/​test/​github/​createPRViewProvider.test.ts Adds tests ensuring stack candidate lookup/stack selection is blocked when disabled.

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

Comment thread src/view/prsTreeDataProvider.ts
Comment thread package.json
Comment thread src/github/createPRViewProvider.ts
Comment thread src/github/pullRequestStack.ts Outdated
@alexr00
Alex Ross (alexr00) removed this pull request from stack #9001 October 2, 2026 18:51
@alexr00
Alex Ross (alexr00) added this pull request to stack #9012 October 3, 2026 10:39
@alexr00
Alex Ross (alexr00) marked this pull request as ready for review October 3, 2026 10:40
Copilot AI balanced review requested due to automatic review settings October 3, 2026 10:40

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.

Comment on lines +259 to +263
this._register(vscode.workspace.onDidChangeConfiguration(e => {
if (e.affectsConfiguration(`${PR_SETTINGS_NAMESPACE}.${EXPERIMENTAL_STACKS}`)) {
void this.refreshPanel();
}
}));
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