feat: support selecting among multiple IDPs [ENG-4075]#71
Merged
albertodonato merged 1 commit intomainfrom Jul 16, 2025
Merged
Conversation
f972775 to
23f1163
Compare
tvansteenburgh
previously approved these changes
Jul 16, 2025
Contributor
tvansteenburgh
left a comment
There was a problem hiding this comment.
Thanks @albertodonato. Good with it as-is, but a test would be nice.
stacklet/client/platform/cli.py
Outdated
| ) | ||
| @click.option( | ||
| "--idp", | ||
| help="Name of the Identity Provider to use for authentication, in case more than one are used", |
Contributor
There was a problem hiding this comment.
Suggested change
| help="Name of the Identity Provider to use for authentication, in case more than one are used", | |
| help="Name of the Identity Provider to use for authentication, if more than one is available", |
stacklet/client/platform/cli.py
Outdated
| if len(saml_config) == 1: | ||
| idp_id, _ = saml_config.popitem() | ||
| else: | ||
| name_to_id = {idp_id: name for name, idp_id in saml_config.items()} |
Contributor
There was a problem hiding this comment.
This seems backwards to me, which makes it hard to understand when reading the code. Shouldn't it be:
name_to_id = {name: idp_id for idp_id, name in saml_config.items()}
[ENG-4075](https://stacklet.atlassian.net/browse/ENG-4075) ### what support selecting an identity provider in `auto-configure` when the server reports multiple. If multiple IDPs are detected, the `--idp` option is required to pick one. ### why Allow logging in when multiple IDPs are configured in platform. ### testing tested against my sandbox with the corresponding platform change ### docs n/a
23f1163 to
916c155
Compare
tvansteenburgh
approved these changes
Jul 16, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
ENG-4075
what
support selecting an identity provider in
auto-configurewhen the serverreports multiple.
If multiple IDPs are detected, the
--idpoption is required to pick one.why
Allow logging in when multiple IDPs are configured in platform.
testing
tested against my sandbox with the corresponding platform change
docs
n/a