Coverage for /usr/local/lib/python3.12/site-packages/prefect/server/schemas/statuses.py: 86%
21 statements
« prev ^ index » next coverage.py v7.10.6, created at 2025-12-05 11:21 +0000
« prev ^ index » next coverage.py v7.10.6, created at 2025-12-05 11:21 +0000
1from prefect.utilities.collections import AutoEnum 1a
4class WorkPoolStatus(AutoEnum): 1a
5 """Enumeration of work pool statuses."""
7 READY = AutoEnum.auto() 1a
8 NOT_READY = AutoEnum.auto() 1a
9 PAUSED = AutoEnum.auto() 1a
11 def in_kebab_case(self) -> str: 1a
12 return self.value.lower().replace("_", "-")
15class WorkerStatus(AutoEnum): 1a
16 """Enumeration of worker statuses."""
18 ONLINE = AutoEnum.auto() 1a
19 OFFLINE = AutoEnum.auto() 1a
22class DeploymentStatus(AutoEnum): 1a
23 """Enumeration of deployment statuses."""
25 READY = AutoEnum.auto() 1a
26 NOT_READY = AutoEnum.auto() 1a
28 def in_kebab_case(self) -> str: 1a
29 return self.value.lower().replace("_", "-")
32class WorkQueueStatus(AutoEnum): 1a
33 """Enumeration of work queue statuses."""
35 READY = AutoEnum.auto() 1a
36 NOT_READY = AutoEnum.auto() 1a
37 PAUSED = AutoEnum.auto() 1a
39 def in_kebab_case(self) -> str: 1a
40 return self.value.lower().replace("_", "-")