Skip to content

Commit 222fe39

Browse files
committed
[Authlib] get_header_zip() and get_claim_cls_by_response_type() can return None
JsonWebEncryption.get_header_zip() returns None when the header has no zip member, and get_claim_cls_by_response_type() returns None for a response type that no ID token class lists.
1 parent dc4eed3 commit 222fe39

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

‎stubs/Authlib/authlib/jose/rfc7516/jwe.pyi‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,6 @@ class JsonWebEncryption:
2929
def parse_json(obj) -> dict[Incomplete, Incomplete]: ...
3030
def get_header_alg(self, header) -> JWEAlgorithmBase: ...
3131
def get_header_enc(self, header) -> JWEEncAlgorithm: ...
32-
def get_header_zip(self, header) -> JWEZipAlgorithm: ...
32+
def get_header_zip(self, header) -> JWEZipAlgorithm | None: ...
3333

3434
def prepare_key(alg, header, key): ...

‎stubs/Authlib/authlib/oidc/core/claims.pyi‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,4 +33,4 @@ class UserInfo(dict[str, object]):
3333
def filter(self, scope: str) -> UserInfo: ...
3434
def __getattr__(self, key): ...
3535

36-
def get_claim_cls_by_response_type(response_type) -> type: ...
36+
def get_claim_cls_by_response_type(response_type) -> type | None: ...

0 commit comments

Comments
 (0)