fix get_client_metadata_scopes on 401 (#1631)

Co-authored-by: Max Isbey <224885523+maxisbey@users.noreply.github.com>
This commit is contained in:
Andrii Blyzniuk 2025-11-16 19:18:50 +02:00 • committed by GitHub
commit 5489e8b6fb
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -506,7 +506,7 @@ class OAuthClientProvider(httpx.Auth):
# Step 3: Apply scope selection strategy
self.context.client_metadata.scope = get_client_metadata_scopes(
www_auth_resource_metadata_url,
extract_scope_from_www_auth(response),
self.context.protected_resource_metadata,
self.context.oauth_metadata,
)