Skip to content

feat(v2designer): add feature flags for MCP client tools feature#8970

Merged
anthony0t merged 1 commit intomainfrom
tonytang/ff
Mar 27, 2026
Merged

feat(v2designer): add feature flags for MCP client tools feature#8970
anthony0t merged 1 commit intomainfrom
tonytang/ff

Conversation

@anthony0t
Copy link
Copy Markdown
Contributor

@anthony0t anthony0t commented Mar 27, 2026

Commit Type

  • feature - New functionality
  • fix - Bug fix
  • refactor - Code restructuring without behavior change
  • perf - Performance improvement
  • docs - Documentation update
  • test - Test-related changes
  • chore - Maintenance/tooling

Risk Level

  • Low - Minor changes, limited scope
  • Medium - Moderate changes, some user impact
  • High - Major changes, significant user/system impact

What & Why

Add disableMcpClientTools and disableNativeMcpClientTools feature flags. If not set, default will be false. These flags allow partners to hide the MCP servers category and the native built-in MCP client tools tab in the Browse panel.

Impact of Change

  • Users:
    feature could be hidden
  • Developers:
    Partners will use this flag to hide two features for their customers
  • System:

Test Plan

  • Unit tests added/updated
  • E2E tests added/updated
  • Manual testing completed
  • Tested in: local

Contributors

Screenshots/Videos

Copilot AI review requested due to automatic review settings March 27, 2026 06:26
@github-actions
Copy link
Copy Markdown

github-actions bot commented Mar 27, 2026

🤖 AI PR Validation Report

PR Review Results

Thank you for your submission! Here's detailed feedback on your PR title and body compliance:

PR Title

  • Current: feat(v2designer): add feature flags for MCP client tools feature
  • Issue: None — title is concise and follows convention (type(scope): summary). It indicates a feature and the affected area.
  • Recommendation: (Optional) If you want extra clarity, you can mention the exact flags added, e.g. feat(v2designer): add disableMcpClientTools & disableNativeMcpClientTools feature flags.

Commit Type

  • Properly selected (feature).
  • Note: Only one option is selected which is correct for this change.

Risk Level

  • Assessment: The PR is small, local, and scoped to designer options, selectors, a couple of components, and associated unit tests. The label on the PR is risk:low, which matches the changes.

⚠️ What & Why

  • Current: "Add disableMcpClientTools and disableNativeMcpClientTools feature flags. If not set, default will be false. These flags allow partners to hide the MCP servers category and the native built-in MCP client tools tab in the Browse panel."
  • Issue: The content is good but could be slightly clearer about where these flags live (hostOptions/designerOptions) and their defaults/behavior.
  • Recommendation: Expand to a single clarifying sentence. Example: "Add two boolean designer hostOptions flags (disableMcpClientTools, disableNativeMcpClientTools) — default false — which allow partners to hide the MCP servers category and/or hide the native built-in MCP client tools tab in the Browse panel. These flags are read from state.designerOptions.hostOptions."

⚠️ Impact of Change

  • Issue: The Impact section is present but sparse. The System subsection is empty and Users could be more explicit about the UX impact.
  • Recommendation:
    • Users: The MCP servers category and the native MCP client tools tab in the Browse panel can be hidden for partner configurations. Add a short line clarifying user-visible behavior (e.g., "When enabled, MCP servers category will not appear in the Browse view; native client tools will not be listed or selectable").
    • Developers: Note that two new optional hostOptions flags were added to DesignerOptionsState and selectors were added (useDisableMcpClientTools, useDisableNativeMcpClientTools). Call-sites were updated to pass the flags into getActionCategories and McpServersBrowse.
    • System: Mention there are no performance or architecture changes; this is a configuration/state driven UI toggle with no backend schema changes.

Test Plan

  • Assessment: Unit tests were added/updated (I verified updates in browse helper and component spec files). Manual testing was marked and local testing listed. E2E tests are not included which is acceptable here because this is a UI toggle with unit coverage.
  • Recommendation: Ensure CI passes and consider an E2E or integration check if Browse panel behavior is covered by broader UI tests in your repo.

⚠️ Contributors

  • Assessment: Contributors section is empty.
  • Recommendation: Add any reviewers/PMs/designers who contributed to the change or leave a short note if none. This helps attribution.

Screenshots/Videos

  • Assessment: Not applicable for this change. No screenshots required.

Summary Table

Section Status Recommendation
Title (Optional) mention exact flag names for extra clarity
Commit Type No change needed
Risk Level No change needed
What & Why ⚠️ Clarify hostOptions path and default behavior
Impact of Change ⚠️ Fill out Users/System sections with concrete effects
Test Plan Ensure CI passes; consider E2E if available
Contributors ⚠️ Add contributor credits or a short note
Screenshots/Videos Not required

Final Notes
This PR passes the PR-title/body checks and I agree with the risk:low label based on the diff (small, localized UI flags + tests). Please update the What & Why and Impact sections with the suggested clarifications and add contributors (if any). After those small edits, this PR should be ready to merge.

Thank you for the clear PR and the added unit tests — they made validation straightforward!


Last updated: Fri, 27 Mar 2026 16:17:47 GMT

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds host-configurable feature flags to optionally hide MCP client tools entry points in the v2 designer browse experience.

Changes:

  • Introduces disableMcpClientTools and disableNativeMcpClientTools host options (interfaces + selector hooks).
  • Gates the MCP Servers category and parts of the MCP Servers browse UI behind these flags.
  • Updates/extends unit tests for category visibility logic.

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
libs/designer-v2/src/lib/ui/panel/recommendation/browse/mcpServersBrowse.tsx Hides the “Others” tab and removes native MCP items when disableNativeMcpClientTools is enabled.
libs/designer-v2/src/lib/ui/panel/recommendation/browse/helper.ts Adds disableMcpClientTools parameter to hide the MCP Servers browse category.
libs/designer-v2/src/lib/ui/panel/recommendation/browse/browseView.tsx Reads disableMcpClientTools and passes it into category generation.
libs/designer-v2/src/lib/ui/panel/recommendation/browse/test/helper.spec.ts Adds tests for disableMcpClientTools visibility behavior.
libs/designer-v2/src/lib/core/state/designerOptions/designerOptionsSelectors.ts Adds selector hooks for the new flags.
libs/designer-v2/src/lib/core/state/designerOptions/designerOptionsInterfaces.ts Extends hostOptions interface with the two new flags.
apps/Standalone/src/designer/state/workflowLoadingSlice.ts Sets default values for the new host options in the Standalone harness (currently type-mismatched).

@anthony0t anthony0t added the risk:low Low risk change with minimal impact label Mar 27, 2026
@github-actions
Copy link
Copy Markdown

github-actions bot commented Mar 27, 2026

📊 Coverage Check

The following changed files need attention:

⚠️ libs/designer-v2/src/lib/core/state/designerOptions/designerOptionsSelectors.ts - 48% covered (needs improvement)

Please add tests for the uncovered files before merging.

@anthony0t anthony0t merged commit b2ee635 into main Mar 27, 2026
13 checks passed
@anthony0t anthony0t deleted the tonytang/ff branch March 27, 2026 16:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-validated risk:low Low risk change with minimal impact

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants