-
Notifications
You must be signed in to change notification settings - Fork 47
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
(PXP-8992): Expire user policies and update Arborist username #986
Conversation
The style in this PR agrees with This formatting comment was generated automatically by a script in uc-cdis/wool. |
Pull Request Test Coverage Report for Build 12056
💛 - Coveralls |
fence/sync/sync_users.py
Outdated
@@ -1664,6 +1666,9 @@ def _update_authz_in_arborist( | |||
policy_id_list = [] | |||
policies = [] | |||
|
|||
if expires is not None: | |||
expires = datetime.datetime.utcfromtimestamp(expires) |
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.
fence/resources/openid/ras_oauth2.py
Outdated
@@ -206,7 +206,11 @@ def map_iss_sub_pair_to_user(self, issuer, subject_id, username, email): | |||
"from the DRS endpoint. Changing said user's username" | |||
f' to "{username}".' | |||
) | |||
# TODO also change username in Arborist | |||
flask.current_app.arborist.update_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.
I think we need to handle the error here? or, I see you raise exception in this function. maybe there's not much we can actually do if this fails... but we should at least catch the exception and log useful information (and not implicitly rely on the library to do that). If it's relatively simple, we could try some simple backoff to retry one more time maybe?
Jira Ticket: PXP-8992
New Features
Dependency updates