feat(desktop): remove automations-access feature flag#4213
feat(desktop): remove automations-access feature flag#4213saddlepaddle merged 2 commits intomainfrom
Conversation
Automations is now available to everyone (paid-plan paywall still enforces actual access via GATED_FEATURES.AUTOMATIONS).
|
ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughThis PR removes the ChangesAutomations Feature Flag Consolidation
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Poem
🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (1 warning, 1 inconclusive)
✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
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. Comment |
Greptile SummaryThis PR removes the
Confidence Score: 3/5Safe to merge from a gating perspective, but the collapsed and expanded sidebar render Automations and Tasks in opposite orders, which will be visible to every user now that the flag guard is gone. The paywall is intact and the flag removal itself is clean with no dangling references. The concern is the item-order mismatch between the collapsed sidebar (Tasks → Automations) and the expanded sidebar (Automations → Tasks): previously hidden by the flag for most users, it is now universally observable and will cause the two nav items to swap positions whenever the sidebar is toggled. DashboardSidebarHeader.tsx — the collapsed and expanded branches need their item ordering aligned.
|
| Filename | Overview |
|---|---|
| apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/components/DashboardSidebarHeader/DashboardSidebarHeader.tsx | Removes the PostHog flag guard for Automations; both collapsed and expanded sidebar now always render the button. Introduces a visible ordering inconsistency: Tasks precedes Automations in the collapsed view but follows it in the expanded view. |
| packages/shared/src/constants.ts | Removes the AUTOMATIONS_ACCESS entry from FEATURE_FLAGS; no remaining references to the key exist in the codebase. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[User clicks Automations in sidebar] --> B[handleAutomationsClick]
B --> C[gateFeature GATED_FEATURES.AUTOMATIONS]
C --> D{Paid plan?}
D -- Yes --> E[navigate to /automations]
D -- No --> F[Show paywall modal]
subgraph "Before PR"
G[PostHog automations-access flag] -->|enabled| H[Show sidebar button]
G -->|disabled| I[Hide sidebar button]
end
subgraph "After PR"
J[Sidebar button always visible] --> B
end
Prompt To Fix All With AI
Fix the following 1 code review issue. Work through them one at a time, proposing concise fixes.
---
### Issue 1 of 1
apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/components/DashboardSidebarHeader/DashboardSidebarHeader.tsx:140-156
**Automations/Tasks order flips between collapsed and expanded views**
In the collapsed sidebar the order is Workspaces → Tasks → Automations (lines 122 → 140), but in the expanded sidebar it is Workspaces → Automations → Tasks (lines 234 → 248). Since the flag guard previously hid Automations for most users this mismatch was invisible, but now that Automations is always shown every user who toggles the sidebar will see the two items swap positions. Consistent ordering between the two states is expected behavior for this kind of collapsible nav pattern.
Reviews (1): Last reviewed commit: "feat(desktop): remove automations-access..." | Re-trigger Greptile
| <Tooltip delayDuration={300}> | ||
| <TooltipTrigger asChild> | ||
| <button | ||
| type="button" | ||
| onClick={handleAutomationsClick} | ||
| className={cn( | ||
| "flex size-8 items-center justify-center rounded-md transition-colors", | ||
| isAutomationsOpen | ||
| ? "bg-accent text-foreground" | ||
| : "text-muted-foreground hover:bg-accent/50 hover:text-foreground", | ||
| )} | ||
| > | ||
| <LuClock className="size-4" /> | ||
| </button> | ||
| </TooltipTrigger> | ||
| <TooltipContent side="right">Automations</TooltipContent> | ||
| </Tooltip> |
There was a problem hiding this comment.
Automations/Tasks order flips between collapsed and expanded views
In the collapsed sidebar the order is Workspaces → Tasks → Automations (lines 122 → 140), but in the expanded sidebar it is Workspaces → Automations → Tasks (lines 234 → 248). Since the flag guard previously hid Automations for most users this mismatch was invisible, but now that Automations is always shown every user who toggles the sidebar will see the two items swap positions. Consistent ordering between the two states is expected behavior for this kind of collapsible nav pattern.
Prompt To Fix With AI
This is a comment left during a code review.
Path: apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/components/DashboardSidebarHeader/DashboardSidebarHeader.tsx
Line: 140-156
Comment:
**Automations/Tasks order flips between collapsed and expanded views**
In the collapsed sidebar the order is Workspaces → Tasks → Automations (lines 122 → 140), but in the expanded sidebar it is Workspaces → Automations → Tasks (lines 234 → 248). Since the flag guard previously hid Automations for most users this mismatch was invisible, but now that Automations is always shown every user who toggles the sidebar will see the two items swap positions. Consistent ordering between the two states is expected behavior for this kind of collapsible nav pattern.
How can I resolve this? If you propose a fix, please make it concise.There was a problem hiding this comment.
1 issue found across 2 files
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/components/DashboardSidebarHeader/DashboardSidebarHeader.tsx">
<violation number="1" location="apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/components/DashboardSidebarHeader/DashboardSidebarHeader.tsx:245">
P2: Automations/Tasks ordering is inconsistent between collapsed and expanded sidebar states. In the collapsed view the order is Tasks → Automations, but here in the expanded view Automations comes before Tasks. Now that Automations is unconditionally shown, toggling the sidebar will cause users to see these items swap positions. Move this Automations button below the Tasks button to match the collapsed view ordering.</violation>
</file>
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.
🚀 Preview Deployment🔗 Preview Links
Preview updates automatically with new commits |
Recorded as integrated via -s ours after batch PRs #455-#464. Taken via individual PRs: - PR 1 (#455): v2 polish 前半 safe set (9 commits) - PR 2 (#456): v2/host-service polish 中盤 (12 commits) - PR 3 (#457): sidebar polish + jwt API (5 commits) - PR 4 (#458): host-service tRPC retry/cache/timeout (3 commits) - PR 5 (#459): v2 diff pane / file pane polish (2 commits) - PR 7 (#462): host-service v2 canonical workspace.create + attachment store (PR1 superset-sh#3893 + PR2 superset-sh#3916) - PR 11 (#463): agents API + onboarding (7 commits + 1 cleanup) - PR 12 (#464): v1→v2 import flow rewrite (11 commits + 2 follow-ups) - PR 13 (#460): host-service shell env probe + typo (2 commits) - PR 16 (#461): marketplace 19 themes (1 commit) Skipped / deferred (recorded as integrated for behind=0): - PR 6: CLI v1 launch (superset-sh#3898 + 30+ CLI/SDK followups) — defer to dedicated migration - PR 9: v2 PR3 (superset-sh#3940) + revert (superset-sh#4017) — net-zero pair - PR 10: pty-daemon (superset-sh#3896, superset-sh#3971, superset-sh#4054) — fork keeps its terminal-host - PR 14: Slack MCP-v2 (superset-sh#4197, superset-sh#4208) — depends on mcp-v2/sdk divergence - PR 15: onboarding remaining (superset-sh#4115, superset-sh#4125, superset-sh#4214, superset-sh#4213, superset-sh#4222, superset-sh#4225) — depends on fork's deleted setup pages Behind: 0 after this merge.
Summary
automations-accessPostHog flag — Automations is now visible in the sidebar for everyoneGATED_FEATURES.AUTOMATIONS) still gates actual access via the route + click handlerTest plan
/automationsNote: the
automations-accessflag in PostHog (Production) is left in place for now and can be deleted separately.Summary by cubic
Makes Automations visible in the desktop sidebar for all users by removing the
automations-accessfeature flag; access is still enforced byGATED_FEATURES.AUTOMATIONS(free plans see the paywall; paid plans go to/automations). Also aligns the collapsed sidebar order with the expanded view (Automations before Tasks).Refactors
FEATURE_FLAGS.AUTOMATIONS_ACCESSfrom@superset/shared/constants.useFeatureFlagEnabledgating inDashboardSidebarHeader; the Automations button always renders and the click handler enforces paywall/navigation.Bug Fixes
Written for commit 7f39fbf. Summary will update on new commits.
Summary by CodeRabbit