File tree Expand file tree Collapse file tree 2 files changed +2
-35
lines changed Expand file tree Collapse file tree 2 files changed +2
-35
lines changed Original file line number Diff line number Diff line change 24
24
#
25
25
26
26
# 3rd party
27
- from aenum import Enum , IntEnum # type: ignore
27
+ from enum_tools import IntEnum , StrEnum
28
28
29
29
__all__ = ["IntEnum" , "StrEnum" ]
30
-
31
- # class IntEnum(Enum):
32
- # """
33
- # An Enum that can be converted into an integer.
34
- # """
35
- #
36
- # def __int__(self):
37
- # return self.value
38
- #
39
- # def __eq__(self, other):
40
- # if int(self) == other:
41
- # return True
42
- # else:
43
- # return super().__eq__(other)
44
-
45
-
46
- class StrEnum (str , Enum ):
47
- """
48
- An Enum that can be converted into a string.
49
- """
50
-
51
- def __str__ (self ) -> str :
52
- return self .value
53
-
54
- #
55
- # def __repr__(self):
56
- # return self.value
57
-
58
- # def __eq__(self, other):
59
- # if str(self) == other:
60
- # return True
61
- # else:
62
- # return super().__eq__(other)
Original file line number Diff line number Diff line change 1
- aenum >= 2.2.3
2
1
colorama
2
+ enum_tools
3
3
importlib_resources
4
4
pydash >= 4.7.4
5
5
typing_extensions
You can’t perform that action at this time.
0 commit comments