fix(dashboard-auth): exclude non-interactive providers from interactive login surfaces (#53239)

* Return None instead of erroring on drain login failure

* Fix login on drain

* Remove login for drained endpoints flow and clean the code

* chore: drop unrelated credits changes from this PR

* Remove extra comments that were not really necessary
This commit is contained in:
Nacho Avecilla 2026-06-26 21:08:13 -03:00 committed by GitHub
parent 7a38d64a85
commit dbe734beff
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
10 changed files with 89 additions and 6 deletions

View file

@ -78,6 +78,11 @@ class TestProvider:
p = drain.DrainSecretProvider(secret=_strong_secret())
assert p.supports_token is True
def test_is_non_interactive(self, drain):
# Excluded from interactive surfaces via list_session_providers().
p = drain.DrainSecretProvider(secret=_strong_secret())
assert p.supports_session is False
def test_verify_token_accepts_matching_secret(self, drain):
s = _strong_secret()
p = drain.DrainSecretProvider(secret=s, scope="drain")