-
Notifications
You must be signed in to change notification settings - Fork 14.2k
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
Can't remove permission from a role using the API #25734
Comments
Thanks for opening your first issue here! Be sure to follow the issue template! |
@szczeles Are you planning to take this? I'd be willing to submit a PR if not. |
I think you can start working on it @juliusdelta if there is no response soon -> @szczeles, if you have not looked at it yet you could do a review as well :) . This might be super-helpful. |
Hey, @juliusdelta! I didn't start working on this yet, so feel free to submit PR for this. I'm happy to review and test in my lab when it's done. Good luck! |
@juliusdelta are you still working on this issue? |
Hi There, is there any update on this issue? Currently not able to remove any permissions from roles using |
Apache Airflow version
2.3.3
What happened
There is an API
PATCH /api/v1/roles/[role]
that is supposed to be able to update existing role. When I call it, providing list of permissions to attach inactions
field (in JSON body), the new permissions are added to the role, but removed permissions are not removed. It is related to the fact that API implementation calls security_manager.bulk_sync_roles and the method never removes any permissions, only adds new ones by calling self.add_permission_to_role.What you think should happen instead
API call to
PATCH /api/v1/roles/[role]
should remove the dropped permissions. UI form works that way.How to reproduce
can read on Website
,menu access on Browse
PATCH /api/v1/roles/[role]
to update permissions tocan read on Website
,can read on DAGs
menu access on Browse
is not removedOperating System
Debian 10
Versions of Apache Airflow Providers
No response
Deployment
Official Apache Airflow Helm Chart
Deployment details
No response
Anything else
No response
Are you willing to submit PR?
Code of Conduct
The text was updated successfully, but these errors were encountered: