File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change 23
23
Union ,
24
24
no_type_check ,
25
25
)
26
- from typing_extensions import get_args , get_origin
27
26
28
27
import aioredis
29
28
from aioredis .client import Pipeline
33
32
from pydantic .main import ModelMetaclass , validate_model
34
33
from pydantic .typing import NoArgAnyCallable
35
34
from pydantic .utils import Representation
35
+ from typing_extensions import Protocol , get_args , get_origin
36
36
from ulid import ULID
37
37
38
38
from ..checks import has_redis_json , has_redisearch
@@ -848,13 +848,14 @@ async def get_item(self, item: int):
848
848
return result [0 ]
849
849
850
850
851
- class PrimaryKeyCreator (abc . ABC ):
851
+ class PrimaryKeyCreator (Protocol ):
852
852
def create_pk (self , * args , ** kwargs ) -> str :
853
853
"""Create a new primary key"""
854
854
855
855
856
856
class UlidPrimaryKey :
857
- """A client-side generated primary key that follows the ULID spec.
857
+ """
858
+ A client-side generated primary key that follows the ULID spec.
858
859
https://github.com/ulid/javascript#specification
859
860
"""
860
861
You can’t perform that action at this time.
0 commit comments