Skip to content

Commit

Permalink
Fix new mypy error on IIB Web models
Browse files Browse the repository at this point in the history
This fixes the new `mypy` issue:

```
error: Enum members must be left unannotated  [misc]
```
  • Loading branch information
JAVGan committed Jan 8, 2025
1 parent f40b258 commit 14c8027
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions iib/web/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,9 +64,9 @@ def get_names(cls) -> List[str]:
class RequestStateMapping(BaseEnum):
"""An Enum that represents the request states."""

in_progress: int = 1
complete: int = 2
failed: int = 3
in_progress = 1
complete = 2
failed = 3

@staticmethod
def get_final_states() -> List[str]:
Expand Down Expand Up @@ -97,15 +97,15 @@ def validate_state(cls, state: str) -> None:
class RequestTypeMapping(BaseEnum):
"""An Enum that represents the request types."""

generic: int = 0
add: int = 1
rm: int = 2
regenerate_bundle: int = 3
merge_index_image: int = 4
create_empty_index: int = 5
recursive_related_bundles: int = 6
fbc_operations: int = 7
add_deprecations: int = 8
generic = 0
add = 1
rm = 2
regenerate_bundle = 3
merge_index_image = 4
create_empty_index = 5
recursive_related_bundles = 6
fbc_operations = 7
add_deprecations = 8

@classmethod
def pretty(cls, num: int) -> str:
Expand Down

0 comments on commit 14c8027

Please sign in to comment.