-
Notifications
You must be signed in to change notification settings - Fork 370
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
User property role_entites does not check if role exist #527
Comments
Hi @seiimonn , Sorry for the delay in response. We are unable to reproduce the issue on our end with similar environment. Also can you please elaborate more on how |
Hi @akaila-splunk
Somehow the role is still in the users roles even though it does not exist anymore in the system. |
Hi @seiimonn ,
Note - When we verified the user roles through code and UI, the deleted role was not present. |
Hi @seiimonn , sorry for the delay but we have published a new version of Python SDK v2.0.1 with the suggested change. Request you to test with the latest SDK and let us know if the issue is resolved. Thanks |
Closing the Issue as we haven't received any response. @seiimonn please reopen the Issue if you are still facing the issue. |
Describe the bug
As Splunk allows users to have non existent roles, calling role_entites on a user with roles assigned that are not existent leads to exceptions.
Defective code:
Possible solution:
Or with (I suppose more calls to the API)
return [self.service.roles[name] for name in self.content.roles if name in self.content.roles]
Splunk (please complete the following information):
SDK (please complete the following information):
The text was updated successfully, but these errors were encountered: