File tree Expand file tree Collapse file tree 3 files changed +34
-31
lines changed Expand file tree Collapse file tree 3 files changed +34
-31
lines changed Original file line number Diff line number Diff line change 1
1
from enum import Enum
2
+ from typing import cast
2
3
3
4
from .offsets import BaseOffset
4
5
@@ -29,16 +30,16 @@ class FreqGroup:
29
30
def get_freq_group (code : int ) -> int : ...
30
31
31
32
class Resolution (Enum ):
32
- RESO_NS : int
33
- RESO_US : int
34
- RESO_MS : int
35
- RESO_SEC : int
36
- RESO_MIN : int
37
- RESO_HR : int
38
- RESO_DAY : int
39
- RESO_MTH : int
40
- RESO_QTR : int
41
- RESO_YR : int
33
+ RESO_NS = cast ( int , ...)
34
+ RESO_US = cast ( int , ...)
35
+ RESO_MS = cast ( int , ...)
36
+ RESO_SEC = cast ( int , ...)
37
+ RESO_MIN = cast ( int , ...)
38
+ RESO_HR = cast ( int , ...)
39
+ RESO_DAY = cast ( int , ...)
40
+ RESO_MTH = cast ( int , ...)
41
+ RESO_QTR = cast ( int , ...)
42
+ RESO_YR = cast ( int , ...)
42
43
43
44
def __lt__ (self , other ) -> bool : ...
44
45
def __ge__ (self , other ) -> bool : ...
Original file line number Diff line number Diff line change @@ -11,33 +11,34 @@ import enum
11
11
from typing import (
12
12
Any ,
13
13
TypedDict ,
14
+ cast ,
14
15
)
15
16
16
17
class DlpackDeviceType (enum .IntEnum ):
17
- CPU : int
18
- CUDA : int
19
- CPU_PINNED : int
20
- OPENCL : int
21
- VULKAN : int
22
- METAL : int
23
- VPI : int
24
- ROCM : int
18
+ CPU = cast ( int , ...)
19
+ CUDA = cast ( int , ...)
20
+ CPU_PINNED = cast ( int , ...)
21
+ OPENCL = cast ( int , ...)
22
+ VULKAN = cast ( int , ...)
23
+ METAL = cast ( int , ...)
24
+ VPI = cast ( int , ...)
25
+ ROCM = cast ( int , ...)
25
26
26
27
class DtypeKind (enum .IntEnum ):
27
- INT : int
28
- UINT : int
29
- FLOAT : int
30
- BOOL : int
31
- STRING : int
32
- DATETIME : int
33
- CATEGORICAL : int
28
+ INT = cast ( int , ...)
29
+ UINT = cast ( int , ...)
30
+ FLOAT = cast ( int , ...)
31
+ BOOL = cast ( int , ...)
32
+ STRING = cast ( int , ...)
33
+ DATETIME = cast ( int , ...)
34
+ CATEGORICAL = cast ( int , ...)
34
35
35
36
class ColumnNullType (enum .IntEnum ):
36
- NON_NULLABLE : int
37
- USE_NAN : int
38
- USE_SENTINEL : int
39
- USE_BITMASK : int
40
- USE_BYTEMASK : int
37
+ NON_NULLABLE = cast ( int , ...)
38
+ USE_NAN = cast ( int , ...)
39
+ USE_SENTINEL = cast ( int , ...)
40
+ USE_BITMASK = cast ( int , ...)
41
+ USE_BYTEMASK = cast ( int , ...)
41
42
42
43
class ColumnBuffers (TypedDict ):
43
44
data : tuple [Buffer , Any ]
Original file line number Diff line number Diff line change 1
1
import sys
2
+ from typing import Any
2
3
3
4
from loguru import logger
4
5
5
6
# Config the format of log message
6
- config = {
7
+ config : dict [ str , Any ] = {
7
8
"handlers" : [
8
9
{
9
10
"sink" : sys .stderr ,
You can’t perform that action at this time.
0 commit comments