-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: merge project permissions into advanced permissions #28115
Conversation
Size Change: +5 B (0%) Total Size: 1.16 MB ℹ️ View Unchanged
|
📸 UI snapshots have been updated6 snapshot changes in total. 0 added, 6 modified, 0 deleted:
Triggered by this commit. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PR Summary
This PR consolidates project-based permissions into advanced permissions across the PostHog codebase. Here's a summary of the key changes:
- Removes
PROJECT_BASED_PERMISSIONING
feature flag and merges its functionality intoADVANCED_PERMISSIONS
across all files - Updates feature checks in access control components and logic to use
ADVANCED_PERMISSIONS
instead ofPROJECT_BASED_PERMISSIONING
- Maintains existing functionality since both features were previously available on the same plans
- Aligns with new RBAC/access control system where permissions will be available through teams add-on
- Includes comprehensive test updates to verify permission system still works correctly after consolidation
Key points to review:
- TODO comment on line 115 in AccessControlObject.tsx about index mapping needs to be addressed
- Migration path for existing installations should be verified to ensure smooth transition
- Documentation and frontend code references to
PROJECT_BASED_PERMISSIONING
need to be updated - Legacy test classes that are commented out should be reviewed for proper migration to new system
16 file(s) reviewed, no comment(s)
Edit PR Review Bot Settings | Greptile
📸 UI snapshots have been updated3 snapshot changes in total. 0 added, 3 modified, 0 deleted:
Triggered by this commit. |
Changes
Follow along on RBAC: #24512
Billing PR to be shipped after this: https://github.com/PostHog/billing/pull/1092
Deprecating
project_based_permissioning
and merging intoadvanced_permissions
.Currently
advanced_permissions
is used for dashboard permissions andproject_based_permissioning
is used for permissions around projects like private projects. With the new RBAC / access control system we are merging these together and they will be available on the teams add-on.Since both of these are available on the same plans right now, this should have no affect to users. I confirmed that every plan that has
advanced_permissions
also hasproject_based_permissioning
and vice versa.👉 Stay up-to-date with PostHog coding conventions for a smoother review.
Does this work well for both Cloud and self-hosted?
It doesn't have an impact.
How did you test this code?