Skip to content

chore(Flag Dependency): GA Flag Dependency - #8882

Merged
khvn26 merged 1 commit into
mainfrom
fix/ga-flag-dependency
Nov 5, 2026
Merged

khvn26 merged 1 commit into
mainfrom
fix/ga-flag-dependency

Conversation

@emyller

@emyller emyller commented Nov 4, 2026

Copy link
Copy Markdown
Contributor

Thanks for submitting a PR! Please check the boxes below:

  • I have read the Contributing Guide.
  • I have added information to docs/ if required so people know about the feature.
  • I have filled in the "Changes" section below.
  • I have filled in the "How did you test this code" section below.

Changes

Closes #8881

Flag dependencies are now enabled for everyone in SaaS and OSS, so the dashboard no longer checks the flag_dependencies or flag_dependencies_change_requests feature flags.

  • The Dependencies tab shows on every feature, including where change requests are enforced.
  • Change request diffs always show dependency changes.
  • The Flag Dependencies E2E test always runs.

Review effort: 1/5

How did you test this code?

  • ESLint passes on the changed files.
  • npm run typecheck reports no new errors; the errors in DiffChangeRequest.tsx and ChangeRequestDetailPage.tsx also fail on main.
  • The E2E test was not run locally; CI covers it.

🤖 Generated with Claude Code

@emyller
emyller requested a review from a team as a code owner November 4, 2026 23:22
@vercel

vercel Bot commented Nov 4, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
flagsmith-frontend-preview Ready Ready Preview Nov 4, 2026 11:25pm UTC
flagsmith-frontend-staging Ready Ready Preview Nov 4, 2026 11:25pm UTC
1 Skipped Deployment
Project Deployment Actions Updated
docs Ignored Ignored Preview Nov 4, 2026 11:25pm UTC

Request Review

@emyller
emyller requested review from talissoncosta and removed request for a team November 4, 2026 23:22
@github-actions github-actions Bot added the front-end Issue related to the React Front End Dashboard label Nov 4, 2026
@coderabbitai

coderabbitai Bot commented Nov 4, 2026 •

Copy link
Copy Markdown

Explain Change →

Important

Review skipped

Review was skipped as selected files did not have any reviewable changes.

Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: f85b5c57-36c8-4569-9c31-197e7063ffb3
Commits

Reviewing files that changed from the base of the PR and between a869fea and 40ec72a.

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
Walkthrough

The changes remove flag_dependencies and flag_dependencies_change_requests checks from dependency tab access and dependency loading. The dependency end-to-end test no longer skips when flag_dependencies is disabled. Dependency loading still skips under its other existing conditions.

Estimated code review effort: 2 (Simple) | ~8 minutes

Merge Risk: Minimal · previous review a869f

The change removes dependency feature-flag checks without changing save ordering or existing diff restrictions. Existing dependency-editing issues warrant fixes, but no new merge-blocking regression is established for this change.

- [ ] Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

@github-actions

github-actions Bot commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

Docker builds report

Image Build Status Security report
ghcr.io/flagsmith/flagsmith-api-test:pr-8882 Finished ✅ Skipped
ghcr.io/flagsmith/flagsmith-e2e:pr-8882 Finished ✅ Skipped
ghcr.io/flagsmith/flagsmith-frontend:pr-8882 Finished ✅ Results ✅
ghcr.io/flagsmith/flagsmith-api:pr-8882 Finished ✅ Results ✅
ghcr.io/flagsmith/flagsmith:pr-8882 Finished ✅ Results ✅
ghcr.io/flagsmith/flagsmith-private-cloud:pr-8882 Finished ✅ Results ✅

Remove the `flag_dependencies` and `flag_dependencies_change_requests`
feature flags now that flag dependencies are enabled for everyone.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@emyller
emyller force-pushed the fix/ga-flag-dependency branch from a869fea to 40ec72a Compare November 4, 2026 23:25
@emyller emyller changed the title chore(Dependencies): GA Flag Dependency chore(Flag Dependency): GA Flag Dependency Nov 4, 2026
@github-actions github-actions Bot added chore and removed chore labels Nov 4, 2026
@github-actions

github-actions Bot commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor
✅ private-cloud · depot-ubuntu-latest-arm-16 — run #22872 (attempt 1)

Playwright Test Results (private-cloud - depot-ubuntu-latest-arm-16)

passed  3 passed

Details

stats  3 tests across 3 suites
duration  36 seconds
commit  40ec72a
info  🔄 Run: #22872 (attempt 1)

🗂️ Previous results
✅ private-cloud · depot-ubuntu-latest-16 — run #22872 (attempt 1)

Playwright Test Results (private-cloud - depot-ubuntu-latest-16)

passed  4 passed

Details

stats  4 tests across 4 suites
duration  43.1 seconds
commit  40ec72a
info  🔄 Run: #22872 (attempt 1)

✅ private-cloud · depot-ubuntu-latest-16 — run #22871 (attempt 1)

Playwright Test Results (private-cloud - depot-ubuntu-latest-16)

passed  2 passed

Details

stats  2 tests across 2 suites
duration  34.9 seconds
commit  a869fea
info  🔄 Run: #22871 (attempt 1)

✅ oss · depot-ubuntu-latest-arm-16 — run #22872 (attempt 1)

Playwright Test Results (oss - depot-ubuntu-latest-arm-16)

passed  1 passed

Details

stats  1 test across 1 suite
duration  35.3 seconds
commit  40ec72a
info  🔄 Run: #22872 (attempt 1)

✅ oss · depot-ubuntu-latest-16 — run #22872 (attempt 1)

Playwright Test Results (oss - depot-ubuntu-latest-16)

passed  1 passed

Details

stats  1 test across 1 suite
duration  31 seconds
commit  40ec72a
info  🔄 Run: #22872 (attempt 1)

✅ private-cloud · depot-ubuntu-latest-arm-16 — run #22871 (attempt 1)

Playwright Test Results (private-cloud - depot-ubuntu-latest-arm-16)

passed  3 passed

Details

stats  3 tests across 3 suites
duration  48.3 seconds
commit  a869fea
info  🔄 Run: #22871 (attempt 1)

✅ oss · depot-ubuntu-latest-16 — run #22871 (attempt 1)

Playwright Test Results (oss - depot-ubuntu-latest-16)

passed  1 passed

Details

stats  1 test across 1 suite
duration  33.6 seconds
commit  a869fea
info  🔄 Run: #22871 (attempt 1)

✅ oss · depot-ubuntu-latest-arm-16 — run #22871 (attempt 1)

Playwright Test Results (oss - depot-ubuntu-latest-arm-16)

passed  21 passed
skipped  1 skipped

Details

stats  22 tests across 14 suites
duration  1 minute, 8 seconds
commit  a869fea
info  🔄 Run: #22871 (attempt 1)

Skipped tests

firefox › tests/onboarding-tests.pw.ts › Onboarding › New user connects via the single-page onboarding flow @oss

@github-actions

github-actions Bot commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

Visual Regression

24 screenshots compared. See report for details.
View full report

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to GitHub limitations.

⚠️ Outside diff range comments (1)

Major · Start the automatic commit only after prerequisite staging… · feature-list-store.ts:709-714

frontend/common/stores/feature-list-store.ts:709-714
Major · Data Integrity & Integration · Heavy lift

Start the automatic commit only after prerequisite staging succeeds.

For a non-4-eyes save with staged prerequisite changes, the store dispatches commit without waiting for the prerequisite requests. prom resolves after the commit POST is sent, store.saved runs onSave, and onSave then calls dependencyChanges.stageInto(changeRequestId). Nothing orders the commit before the prerequisite requests.

If the commit completes first, the dependency endpoints reject later requests with ChangeRequestAlreadyCommittedError. stageInto then clears the staged prerequisites and shows a banner. The change request is committed without the intended prerequisite edits.

The commit must wait until staging returns without a failure. Blocking reviewer approval during staging is a separate correction for the 4-eyes path and does not fix this path.

Note

Follow-up findings are listed below so you can review them separately from inline comments.

Follow-ups (2)
Major (1)
Major · Block dependency edits while the flag is frozen for an experiment. · index.tsx:481

frontend/web/components/modals/create-feature/index.tsx:481
Major · Functional Correctness · Quick win

Block dependency edits while the flag is frozen for an experiment.

The Dependencies tab does not receive freeze, and canManage ignores it. Users can add or remove prerequisites on a flag in a running experiment. Direct edits move the new override to priority 0, which changes the values the experiment serves.

Suggested fix

Pass freeze to FeatureDependenciesTab in index.tsx, add it to the component props, and include it in the edit guard:

-  const canManage = permission && mode !== 'readOnly' && !isSubmitting
+  const canManage =
+    permission && mode !== 'readOnly' && !isSubmitting && !freeze?.isFrozen
Minor (1)
Minor · Show dependency changes for committed change requests that are not… · DiffChangeRequest.tsx:57

frontend/web/components/diff/DiffChangeRequest.tsx:57
Minor · Functional Correctness · Poor tradeoff

Show dependency changes for committed change requests that are not yet live.

For a committed change request, skipDependencies is true, so the dependency diff is never loaded. Scheduled changes that add or remove prerequisites are missing from the diff, while feature-state changes for the same request still appear.

Additional comments: 1
frontend/web/components/diff/DiffChangeRequest.tsx-57-57: 1

57-57: Minor · Potential issue · Heavy lift

Unverified finding
We couldn't verify this from the code. It is shown for review, not as a verified issue.

Removing the flags still leaves dependency loading gated on CREATE_CHANGE_REQUEST; the supplied hook returns no dependency changes when skipped. Reviewers who can approve but not create requests may therefore see an incomplete diff.

The reviewer can approve without seeing the prerequisite changes.

This can occur when: Such a reviewer opens a request containing dependency changes.

Review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: 8a403c42-1b07-4c73-99da-58b7eb775ce1
Commits

Reviewing files that changed from the base of the PR and between 45cfd10 and a869fea.

Files selected for processing: 3
  • frontend/e2e/tests/flag-dependencies-test.pw.ts
  • frontend/web/components/diff/DiffChangeRequest.tsx
  • frontend/web/components/modals/create-feature/index.tsx

Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.

@khvn26
khvn26 merged commit 42379e8 into main Nov 5, 2026
31 checks passed
@khvn26
khvn26 deleted the fix/ga-flag-dependency branch November 5, 2026 10:04

This branch was successfully deployed

2 active deployments
Preview – flagsmith-frontend-staging — 40ec72a0 Deployed Nov 4, 2026 by vercel[bot]
Preview – flagsmith-frontend-preview — 40ec72a0 Deployed Nov 4, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

chore front-end Issue related to the React Front End Dashboard

Projects

None yet

Development

Successfully merging this pull request may close these issues.

GA Flag Dependency

3 participants