-
Notifications
You must be signed in to change notification settings - Fork 6
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
feat: set teams that automatically grant permissions #504
Conversation
213dfe7
to
adad1cd
Compare
We sort teams such that special-permissions teams are sync'd last, so that inherited permissions are not overwritten in child folders. This is because we assume that the special-permissions teams have broader access to folders (ie leads get access to a parent folder), at least for Launch Pad.
Codecov Report
@@ Coverage Diff @@
## master #504 +/- ##
==========================================
- Coverage 94.40% 93.62% -0.78%
==========================================
Files 46 46
Lines 2521 2590 +69
Branches 326 342 +16
==========================================
+ Hits 2380 2425 +45
- Misses 92 113 +21
- Partials 49 52 +3
Continue to review full report at Codecov.
|
Co-authored-by: Cheuk Yin Ng <[email protected]>
Brain keeps being lazy with these edge cases... added some tests: e3a89c5 |
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.
do not lie
no papa
if user.permissions_level < t['permission']: | ||
user.permissions_level = t['permission'] | ||
self.facade.store(user) |
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.
mmmm yes that sextuple indent
Pull Request
Description
Give a brief description of your changes:
Adds ability for all members in certain teams to get Rocket permissions. Need this to automatically grant everyone in @ubclaunchpad/leads the ability to create teams.
We'll need to add the following to our config:
I know we talked about possibly dropping refresh (#490), but we still need a way to perform the initial sync - I imagine refresh might stay around purely for use cases like this.
There is also a workaround for #497 that I think should work in 35e1209
Testing
If testing this change requires extra setup, please document it here:
Ticket(s)
Closes #496
(Create a copy of that line for each Github Issue affected,
and replace "Affects" with "Closes" if merging this will close the relevant ticket.)