Skip to content

Commit 6516e4c

Browse files
committed
Fix issues with python < 3.10
1 parent 7b4dbf8 commit 6516e4c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

modernrpc/types.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
from __future__ import annotations
22

33
from dataclasses import dataclass, field
4-
from typing import Any, Callable, Generic, Sequence, TypeVar
4+
from typing import Any, Callable, Generic, Sequence, TypeVar, Union
55

66

77
@dataclass
@@ -35,4 +35,4 @@ class RpcErrorResult(RpcResult[RequestType]):
3535

3636
NotSetType = object
3737
AuthPredicate = Callable[[RpcRequest], bool]
38-
AuthPredicateType = NotSetType | AuthPredicate | Sequence[AuthPredicate]
38+
AuthPredicateType = Union[NotSetType, AuthPredicate, Sequence[AuthPredicate]]

0 commit comments

Comments
 (0)