Issue 1379 patch - Fix MCP server OAuth not working with Visual Studio Code and others with extra grant_types (#1380)

This commit is contained in:
automaton82 2025-09-29 06:13:16 -04:00 • committed by GitHub
commit 9323efad99
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -68,7 +68,7 @@ class RegistrationHandler:
),
status_code=400,
)
if set(client_metadata.grant_types) != {"authorization_code", "refresh_token"}:
if not {"authorization_code", "refresh_token"}.issubset(set(client_metadata.grant_types)):
return PydanticJSONResponse(
content=RegistrationErrorResponse(
error="invalid_client_metadata",