Skip to content
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

Use convert_bool consistently, use relative Python imports, fix SSO groups #7

Merged
merged 4 commits into from
Jun 28, 2023

Conversation

manics
Copy link
Member

@manics manics commented Jun 20, 2023

Description

Moves convert_bool to a seperate file so it can be used in multiple places, standardises on relative Python imports
Fixes SSO group check- Cognito may add a federated user to a default group, but the code only checks the first group in the returned list.

In theory this means we could pass the list of group memberships from KeyCloak to Cognito instead of adding the user to the relevant Cognito group after they've logged in the first time. In practice we'd need to work out how to pass the list of group memberships from KeyCloak to Cognito....


Declaration : By submitting this pull request, I confirm that my
contribution is made under the terms of the Apache-2.0 license

@manics manics changed the title Use convert_bool consistently, use relative Python imports Use convert_bool consistently, use relative Python imports, fix SSO groups Jun 20, 2023
@manics manics marked this pull request as ready for review June 21, 2023 22:49
@manics manics requested a review from AaronJackson June 22, 2023 08:49
Copy link
Member

@AaronJackson AaronJackson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Assuming the todo comment doesn't matter, this looks good.

Would be keen to get this tested with staging and deployed with HIC's SWB in production

@@ -81,13 +81,15 @@ def update_request(arguments: str, context: Any):

# TO-DO: Inject Environment variables for reviewer group names
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I might have missed something but presumably the group names are stored somewhere configurable? If so, this todo doesn't make sense anymore?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd assume not..... I've created an issue and will come back to it later
#8

@manics manics merged commit 4c5ca2f into main Jun 28, 2023
@manics manics deleted the dev branch June 28, 2023 12:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants