cloudos-cli 2.66.0a2__tar.gz → 2.66.2__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.
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/PKG-INFO +1 -1
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/__main__.py +9 -4
- cloudos_cli-2.66.2/cloudos_cli/_version.py +1 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/datasets/datasets.py +24 -1
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli.egg-info/PKG-INFO +1 -1
- cloudos_cli-2.66.0a2/cloudos_cli/_version.py +0 -1
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/LICENSE +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/README.md +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/__init__.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/clos.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/configure/__init__.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/configure/configure.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/cost/__init__.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/cost/cost.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/datasets/__init__.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/import_wf/__init__.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/import_wf/import_wf.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/jobs/__init__.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/jobs/job.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/link/__init__.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/link/link.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/logging/__init__.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/logging/logger.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/procurement/__init__.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/procurement/images.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/queue/__init__.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/queue/queue.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/utils/__init__.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/utils/array_job.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/utils/cloud.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/utils/details.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/utils/errors.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/utils/last_wf.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/utils/requests.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli/utils/resources.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli.egg-info/SOURCES.txt +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli.egg-info/dependency_links.txt +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli.egg-info/entry_points.txt +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli.egg-info/requires.txt +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/cloudos_cli.egg-info/top_level.txt +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/setup.cfg +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/setup.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/tests/__init__.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/tests/functions_for_pytest.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/tests/test_cli_project_create.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/tests/test_cost/__init__.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/tests/test_cost/test_job_cost.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/tests/test_logging/__init__.py +0 -0
- {cloudos_cli-2.66.0a2 → cloudos_cli-2.66.2}/tests/test_logging/test_logger.py +0 -0
|
@@ -1385,7 +1385,7 @@ def job_cost(ctx,
|
|
|
1385
1385
|
cost_viewer.display_costs(job_id, workspace_id, output_format, verify_ssl)
|
|
1386
1386
|
|
|
1387
1387
|
|
|
1388
|
-
@click.command()
|
|
1388
|
+
@click.command(help='Clone or resume a job with modified parameters')
|
|
1389
1389
|
@click.option('-k',
|
|
1390
1390
|
'--apikey',
|
|
1391
1391
|
help='Your CloudOS API key',
|
|
@@ -1537,9 +1537,15 @@ def clone_resume(ctx,
|
|
|
1537
1537
|
raise ValueError(f"Failed to {mode} job. Failed to {action} job '{job_id}': {str(e)}")
|
|
1538
1538
|
|
|
1539
1539
|
|
|
1540
|
-
#
|
|
1540
|
+
# Apply the best Click solution: Set specific help text for each command registration
|
|
1541
|
+
clone_resume.help = 'Clone a job with modified parameters'
|
|
1541
1542
|
job.add_command(clone_resume, "clone")
|
|
1542
|
-
|
|
1543
|
+
|
|
1544
|
+
# Create a copy with different help text for resume
|
|
1545
|
+
import copy
|
|
1546
|
+
clone_resume_copy = copy.deepcopy(clone_resume)
|
|
1547
|
+
clone_resume_copy.help = 'Resume a job with modified parameters'
|
|
1548
|
+
job.add_command(clone_resume_copy, "resume")
|
|
1543
1549
|
|
|
1544
1550
|
|
|
1545
1551
|
@workflow.command('list')
|
|
@@ -2717,7 +2723,6 @@ def list_files(ctx,
|
|
|
2717
2723
|
path,
|
|
2718
2724
|
details):
|
|
2719
2725
|
"""List contents of a path within a CloudOS workspace dataset."""
|
|
2720
|
-
print("project_name", project_name)
|
|
2721
2726
|
verify_ssl = ssl_selector(disable_ssl_verification, ssl_cert)
|
|
2722
2727
|
|
|
2723
2728
|
datasets = Datasets(
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = '2.66.2'
|
|
@@ -308,6 +308,7 @@ class Datasets(Cloudos):
|
|
|
308
308
|
job_name = parts[path_depth]
|
|
309
309
|
found = False
|
|
310
310
|
|
|
311
|
+
# First, check if this is a folder
|
|
311
312
|
for job_folder in folder_content.get("folders", []):
|
|
312
313
|
if job_folder["name"] == job_name:
|
|
313
314
|
found = True
|
|
@@ -352,8 +353,30 @@ class Datasets(Cloudos):
|
|
|
352
353
|
else:
|
|
353
354
|
raise ValueError(f"Unsupported folder type '{folder_type}' for path '{path}'")
|
|
354
355
|
|
|
356
|
+
# If not found as a folder and this is the last part of the path, check if it's a file
|
|
357
|
+
if not found and path_depth == len(parts) - 1:
|
|
358
|
+
for file_item in folder_content.get("files", []):
|
|
359
|
+
if file_item["name"] == job_name:
|
|
360
|
+
# Return the file as a single-item result
|
|
361
|
+
return {
|
|
362
|
+
"files": [file_item],
|
|
363
|
+
"folders": []
|
|
364
|
+
}
|
|
365
|
+
|
|
366
|
+
# Also check in contents array (for different API response formats)
|
|
367
|
+
for item in folder_content.get("contents", []):
|
|
368
|
+
if item["name"] == job_name and not item.get("isDir", True):
|
|
369
|
+
return {
|
|
370
|
+
"files": [item],
|
|
371
|
+
"folders": []
|
|
372
|
+
}
|
|
373
|
+
|
|
355
374
|
if not found:
|
|
356
|
-
|
|
375
|
+
# Check if we're looking for a file but it's not the last part (invalid path)
|
|
376
|
+
if path_depth < len(parts) - 1:
|
|
377
|
+
raise ValueError(f"Folder '{job_name}' not found under dataset '{dataset_name}'")
|
|
378
|
+
else:
|
|
379
|
+
raise ValueError(f"File or folder '{job_name}' not found under dataset '{dataset_name}'")
|
|
357
380
|
|
|
358
381
|
return folder_content
|
|
359
382
|
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = '2.66.0a2'
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|