quapp-hpc 0.0.1.dev1__tar.gz → 0.0.1.dev3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (27) hide show
  1. {quapp_hpc-0.0.1.dev1/quapp_hpc.egg-info → quapp_hpc-0.0.1.dev3}/PKG-INFO +2 -2
  2. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/pyproject.toml +2 -2
  3. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/component/backend/slurm_job_fetching.py +3 -7
  4. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/model/device/slurm_device.py +2 -6
  5. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3/quapp_hpc.egg-info}/PKG-INFO +2 -2
  6. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc.egg-info/requires.txt +1 -1
  7. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/LICENSE +0 -0
  8. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/README.md +0 -0
  9. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/__init__.py +0 -0
  10. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/component/__init__.py +0 -0
  11. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/component/backend/__init__.py +0 -0
  12. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/component/backend/hpc_invocation.py +0 -0
  13. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/factory/__init__.py +0 -0
  14. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/factory/hpc_device_factory.py +0 -0
  15. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/factory/hpc_handler_factory.py +0 -0
  16. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/factory/hpc_provider_factory.py +0 -0
  17. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/handler/__init__.py +0 -0
  18. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/handler/invocation_handler.py +0 -0
  19. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/handler/job_fetching_handler.py +0 -0
  20. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/model/__init__.py +0 -0
  21. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/model/device/__init__.py +0 -0
  22. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/model/provider/__init__.py +0 -0
  23. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc/model/provider/slurm_provider.py +0 -0
  24. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc.egg-info/SOURCES.txt +0 -0
  25. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc.egg-info/dependency_links.txt +0 -0
  26. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/quapp_hpc.egg-info/top_level.txt +0 -0
  27. {quapp_hpc-0.0.1.dev1 → quapp_hpc-0.0.1.dev3}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: quapp-hpc
3
- Version: 0.0.1.dev1
3
+ Version: 0.0.1.dev3
4
4
  Summary: Quapp HPC library — Slurm integration for Quapp Platform
5
5
  Author-email: "CITYNOW Co. Ltd." <corp@citynow.vn>
6
6
  License: The MIT License (MIT)
@@ -19,7 +19,7 @@ Classifier: Programming Language :: Python :: 3
19
19
  Requires-Python: <3.13,>=3.10
20
20
  Description-Content-Type: text/markdown
21
21
  License-File: LICENSE
22
- Requires-Dist: quapp-common==0.0.11.dev9
22
+ Requires-Dist: quapp-common==0.0.12.dev3
23
23
  Requires-Dist: requests>=2.31.0
24
24
  Requires-Dist: boto3>=1.28.0
25
25
  Provides-Extra: dev
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "quapp-hpc"
7
- version = "0.0.1.dev1"
7
+ version = "0.0.1.dev3"
8
8
  description = "Quapp HPC library — Slurm integration for Quapp Platform"
9
9
  readme = "README.md"
10
10
  authors = [{ name = "CITYNOW Co. Ltd.", email = "corp@citynow.vn" }]
@@ -16,7 +16,7 @@ classifiers = [
16
16
  ]
17
17
  keywords = ["quapp", "quapp-hpc", "slurm", "hpc"]
18
18
  dependencies = [
19
- "quapp-common==0.0.11.dev9",
19
+ "quapp-common==0.0.12.dev3",
20
20
  "requests>=2.31.0",
21
21
  "boto3>=1.28.0",
22
22
  ]
@@ -14,11 +14,7 @@ SLURM_JWT = os.getenv("SLURM_JWT", "")
14
14
  S3_BUCKET = os.getenv("S3_BUCKET", "quapp-slurm-output-dev")
15
15
  AWS_REGION = os.getenv("AWS_REGION", "ap-southeast-1")
16
16
 
17
- _SLURM_TO_JOB_STATUS = {
18
- "PENDING": JobStatus.RUNNING.value,
19
- "CONFIGURING": JobStatus.RUNNING.value,
20
- "RUNNING": JobStatus.RUNNING.value,
21
- "COMPLETING": JobStatus.RUNNING.value,
17
+ _SLURM_TERMINAL_TO_JOB_STATUS = {
22
18
  "COMPLETED": JobStatus.DONE.value,
23
19
  "FAILED": JobStatus.ERROR.value,
24
20
  "CANCELLED": JobStatus.ERROR.value,
@@ -85,7 +81,7 @@ class SlurmJobFetching(JobFetching):
85
81
 
86
82
  jobs = data.get("jobs", [data])
87
83
  if not jobs:
88
- return JobStatus.RUNNING.value
84
+ return "UNKNOWN"
89
85
 
90
86
  raw_state = jobs[0].get("job_state", "UNKNOWN")
91
87
  if isinstance(raw_state, list):
@@ -93,7 +89,7 @@ class SlurmJobFetching(JobFetching):
93
89
 
94
90
  state = str(raw_state).strip()
95
91
  self._logger.info(f"Slurm job {slurm_job_id} state: {state}")
96
- return _SLURM_TO_JOB_STATUS.get(state, JobStatus.RUNNING.value)
92
+ return _SLURM_TERMINAL_TO_JOB_STATUS.get(state, state)
97
93
 
98
94
  def _get_job_result(self, job: dict) -> _SlurmJobResult:
99
95
  return _SlurmJobResult(job_uuid=self.job_id, s3_bucket=S3_BUCKET, aws_region=AWS_REGION)
@@ -23,11 +23,7 @@ SLURM_TIME_LIMIT = int(os.getenv("SLURM_TIME_LIMIT_MIN", "60"))
23
23
  _TERMINAL_STATES = {"COMPLETED", "FAILED", "CANCELLED", "TIMEOUT", "NODE_FAIL", "PREEMPTED"}
24
24
  _DONE_STATE = "COMPLETED"
25
25
 
26
- _SLURM_TO_JOB_STATUS = {
27
- "PENDING": JobStatus.RUNNING.value,
28
- "CONFIGURING": JobStatus.RUNNING.value,
29
- "RUNNING": JobStatus.RUNNING.value,
30
- "COMPLETING": JobStatus.RUNNING.value,
26
+ _SLURM_TERMINAL_TO_JOB_STATUS = {
31
27
  "COMPLETED": JobStatus.DONE.value,
32
28
  "FAILED": JobStatus.ERROR.value,
33
29
  "CANCELLED": JobStatus.ERROR.value,
@@ -115,7 +111,7 @@ class SlurmDevice(Device):
115
111
 
116
112
  def _get_job_status(self, job: dict) -> str:
117
113
  state = self._fetch_slurm_state(job["slurm_job_id"])
118
- return _SLURM_TO_JOB_STATUS.get(state, JobStatus.RUNNING.value)
114
+ return _SLURM_TERMINAL_TO_JOB_STATUS.get(state, state)
119
115
 
120
116
  def _get_job_result(self, job: dict):
121
117
  """Block until Slurm job finishes, then download result from S3."""
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: quapp-hpc
3
- Version: 0.0.1.dev1
3
+ Version: 0.0.1.dev3
4
4
  Summary: Quapp HPC library — Slurm integration for Quapp Platform
5
5
  Author-email: "CITYNOW Co. Ltd." <corp@citynow.vn>
6
6
  License: The MIT License (MIT)
@@ -19,7 +19,7 @@ Classifier: Programming Language :: Python :: 3
19
19
  Requires-Python: <3.13,>=3.10
20
20
  Description-Content-Type: text/markdown
21
21
  License-File: LICENSE
22
- Requires-Dist: quapp-common==0.0.11.dev9
22
+ Requires-Dist: quapp-common==0.0.12.dev3
23
23
  Requires-Dist: requests>=2.31.0
24
24
  Requires-Dist: boto3>=1.28.0
25
25
  Provides-Extra: dev
@@ -1,4 +1,4 @@
1
- quapp-common==0.0.11.dev9
1
+ quapp-common==0.0.12.dev3
2
2
  requests>=2.31.0
3
3
  boto3>=1.28.0
4
4
 
File without changes
File without changes
File without changes