cloudos-cli 2.91.0__tar.gz → 2.93.0__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 (83) hide show
  1. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/PKG-INFO +143 -144
  2. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/README.md +142 -143
  3. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/__main__.py +0 -2
  4. cloudos_cli-2.93.0/cloudos_cli/_version.py +1 -0
  5. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/datasets/cli.py +11 -17
  6. cloudos_cli-2.93.0/cloudos_cli/interactive_session/__init__.py +5 -0
  7. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/interactive_session/cli.py +336 -98
  8. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/interactive_session/interactive_session.py +18 -129
  9. {cloudos_cli-2.91.0/cloudos_cli/link → cloudos_cli-2.93.0/cloudos_cli/interactive_session}/link.py +74 -117
  10. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/jobs/cli.py +1 -1
  11. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/procurement/cli.py +7 -10
  12. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/procurement/images.py +7 -9
  13. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli.egg-info/PKG-INFO +143 -144
  14. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli.egg-info/SOURCES.txt +4 -3
  15. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/tests/test_interactive_session/test_create_session.py +114 -21
  16. cloudos_cli-2.93.0/tests/test_interactive_session/test_link_error_handling.py +258 -0
  17. cloudos_cli-2.93.0/tests/test_interactive_session/test_link_session.py +280 -0
  18. cloudos_cli-2.93.0/tests/test_interactive_session/test_normalize_path.py +102 -0
  19. cloudos_cli-2.91.0/cloudos_cli/_version.py +0 -1
  20. cloudos_cli-2.91.0/cloudos_cli/interactive_session/__init__.py +0 -1
  21. cloudos_cli-2.91.0/cloudos_cli/link/__init__.py +0 -8
  22. cloudos_cli-2.91.0/cloudos_cli/link/cli.py +0 -224
  23. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/LICENSE +0 -0
  24. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/__init__.py +0 -0
  25. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/bash/__init__.py +0 -0
  26. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/bash/cli.py +0 -0
  27. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/clos.py +0 -0
  28. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/configure/__init__.py +0 -0
  29. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/configure/cli.py +0 -0
  30. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/configure/configure.py +0 -0
  31. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/constants.py +0 -0
  32. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/cost/__init__.py +0 -0
  33. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/cost/cost.py +0 -0
  34. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/cromwell/__init__.py +0 -0
  35. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/cromwell/cli.py +0 -0
  36. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/datasets/__init__.py +0 -0
  37. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/datasets/datasets.py +0 -0
  38. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/import_wf/__init__.py +0 -0
  39. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/import_wf/import_wf.py +0 -0
  40. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/jobs/__init__.py +0 -0
  41. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/jobs/job.py +0 -0
  42. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/logging/__init__.py +0 -0
  43. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/logging/logger.py +0 -0
  44. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/procurement/__init__.py +0 -0
  45. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/projects/__init__.py +0 -0
  46. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/projects/cli.py +0 -0
  47. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/queue/__init__.py +0 -0
  48. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/queue/cli.py +0 -0
  49. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/queue/queue.py +0 -0
  50. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/related_analyses/__init__.py +0 -0
  51. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/related_analyses/related_analyses.py +0 -0
  52. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/utils/__init__.py +0 -0
  53. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/utils/array_job.py +0 -0
  54. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/utils/cli_helpers.py +0 -0
  55. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/utils/cloud.py +0 -0
  56. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/utils/details.py +0 -0
  57. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/utils/errors.py +0 -0
  58. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/utils/last_wf.py +0 -0
  59. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/utils/nextflow_version.py +0 -0
  60. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/utils/requests.py +0 -0
  61. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/utils/resources.py +0 -0
  62. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/workflows/__init__.py +0 -0
  63. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli/workflows/cli.py +0 -0
  64. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli.egg-info/dependency_links.txt +0 -0
  65. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli.egg-info/entry_points.txt +0 -0
  66. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli.egg-info/requires.txt +0 -0
  67. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/cloudos_cli.egg-info/top_level.txt +0 -0
  68. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/setup.cfg +0 -0
  69. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/setup.py +0 -0
  70. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/tests/__init__.py +0 -0
  71. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/tests/functions_for_pytest.py +0 -0
  72. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/tests/test_cli_project_create.py +0 -0
  73. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/tests/test_cost/__init__.py +0 -0
  74. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/tests/test_cost/test_job_cost.py +0 -0
  75. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/tests/test_details.py +0 -0
  76. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/tests/test_error_messages.py +0 -0
  77. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/tests/test_interactive_session/__init__.py +0 -0
  78. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/tests/test_interactive_session/test_list_sessions.py +0 -0
  79. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/tests/test_logging/__init__.py +0 -0
  80. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/tests/test_logging/test_logger.py +0 -0
  81. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/tests/test_nextflow_version.py +0 -0
  82. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/tests/test_related_analyses/__init__.py +0 -0
  83. {cloudos_cli-2.91.0 → cloudos_cli-2.93.0}/tests/test_related_analyses/test_related_analyses.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: cloudos_cli
3
- Version: 2.91.0
3
+ Version: 2.93.0
4
4
  Summary: Python package for interacting with the Lifebit Platform
5
5
  Home-page: https://github.com/lifebit-ai/cloudos-cli
6
6
  Author: David Piñeyro
@@ -231,10 +231,10 @@ This will tell you the implemented commands. Each implemented command has its ow
231
231
  ```bash
232
232
  cloudos job list --help
233
233
  ```
234
- ```console Usage: cloudos job list [OPTIONS]
235
-
236
- Collect workspace jobs from a Lifebit Platform workspace in CSV or JSON format.
237
-
234
+ ```console Usage: cloudos job list [OPTIONS]
235
+
236
+ Collect workspace jobs from a Lifebit Platform workspace in CSV or JSON format.
237
+
238
238
  ╭─ Options ────────────────────────────────────────────────────────────────────────────────────────────────╮
239
239
  │ * --apikey -k TEXT Your Lifebit Platform API key [required] │
240
240
  │ * --cloudos-url -c TEXT The Lifebit Platform url you are trying to access to. │
@@ -299,7 +299,7 @@ $HOME
299
299
 
300
300
  ### Configure Default Profile
301
301
 
302
- To facilitate the reuse of required parameters, you can create profiles.
302
+ To facilitate the reuse of required parameters, you can create profiles.
303
303
 
304
304
  To generate a profile called `default`, use the following command:
305
305
 
@@ -321,7 +321,7 @@ The same prompts will appear, including the execution platform (aws or azure). I
321
321
 
322
322
  When configuring a profile, you can specify:
323
323
  - **API Key**: Your Lifebit Platform API credentials
324
- - **Platform URL**: The Lifebit Platform instance URL
324
+ - **Platform URL**: The Lifebit Platform instance URL
325
325
  - **Project Name**: Default project for commands
326
326
  - **Execution Platform**: `aws` (default) or `azure` - determines default instance types and available features
327
327
  - **Repository Platform**: Version control system (github, gitlab, etc.)
@@ -1314,7 +1314,7 @@ cloudos job cost --profile my_profile --job-id 62c83a1191fe06013b7ef355
1314
1314
  The expected output is a formatted table showing:
1315
1315
 
1316
1316
  ```console
1317
- Job Cost Details - Job ID: 62c83a1191fe06013b7ef355
1317
+ Job Cost Details - Job ID: 62c83a1191fe06013b7ef355
1318
1318
  ┏━━━━━━━━┳━━━━━━━━━━━━┳━━━━━━━━━━━━┳━━━━━━━━━━━━┳━━━━━━━━━━┳━━━━━━━━━━━━━┳━━━━━━━━━━━━┳━━━━━━━━━━━━━┳━━━━━━━━━┓
1319
1319
  ┃ ┃ ┃ ┃ ┃ ┃ ┃ ┃ Compute ┃ ┃
1320
1320
  ┃ ┃ Instance ┃ ┃ Life-cycle ┃ ┃ Compute ┃ Instance ┃ storage ┃ ┃
@@ -1343,7 +1343,7 @@ On page 1/2: n = next, p = prev, q = quit
1343
1343
 
1344
1344
  By pressing 'n', it will show the next page or the last if it is the case.
1345
1345
 
1346
- Job Cost Details - Job ID: 62c83a1191fe06013b7ef355
1346
+ Job Cost Details - Job ID: 62c83a1191fe06013b7ef355
1347
1347
  ┏━━━━━━━━┳━━━━━━━━━━━━┳━━━━━━━━━━━━┳━━━━━━━━━━━━┳━━━━━━━━━━┳━━━━━━━━━━━━━┳━━━━━━━━━━━━┳━━━━━━━━━━━━━┳━━━━━━━━━┓
1348
1348
  ┃ ┃ ┃ ┃ ┃ ┃ ┃ ┃ Compute ┃ ┃
1349
1349
  ┃ ┃ Instance ┃ ┃ Life-cycle ┃ ┃ Compute ┃ Instance ┃ storage ┃ ┃
@@ -1462,7 +1462,7 @@ The expected output is a formatted table showing:
1462
1462
  ```console
1463
1463
  Total related analyses found: 15
1464
1464
 
1465
- Related Analyses
1465
+ Related Analyses
1466
1466
  ┏━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━┳━━━━━━━━━━━━┓
1467
1467
  ┃ Status ┃ Name ┃ Owner ┃ ID ┃ Submit time ┃ Run time ┃ Total Cost ┃
1468
1468
  ┡━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━╇━━━━━━━━━━━━┩
@@ -1944,7 +1944,7 @@ Example Python Script:
1944
1944
  #!/usr/bin/python3
1945
1945
  print("Hello world")
1946
1946
  ```
1947
-
1947
+
1948
1948
  2. Or use an interpreter command in the executable field
1949
1949
 
1950
1950
  If your script doesn’t have a shebang line, you can execute it by explicitly specifying the interpreter in the executable command:
@@ -2021,7 +2021,7 @@ Interactive sessions allow you to work within the platform using different virtu
2021
2021
 
2022
2022
  You can get a list of all interactive sessions in your workspace by running `cloudos interactive-session list`. The command can produce three different output formats that can be selected using the `--output-format` option:
2023
2023
 
2024
- - **stdout** (default): Displays a table directly in the terminal with interactive pagination
2024
+ - **stdout** (default): Displays a table directly in the terminal with interactive pagination
2025
2025
  - **csv**: Saves session data to a CSV file with a minimum predefined set of columns by default, or all available columns using the `--all-fields` parameter
2026
2026
  - **json**: Saves complete session information to a JSON file with all available fields
2027
2027
 
@@ -2036,7 +2036,7 @@ cloudos interactive-session list --profile my_profile --output-format stdout
2036
2036
  The table displays sessions with pagination controls (press `n` for next page, `p` for previous page, or `q` to quit):
2037
2037
 
2038
2038
  ```console
2039
- Interactive Sessions
2039
+ Interactive Sessions
2040
2040
  ┏━━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━┳━━━━━━━━┓
2041
2041
  ┃ Status ┃ Name ┃ Type ┃ ID ┃ Owner ┃
2042
2042
  ┡━━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━╇━━━━━━━━┩
@@ -2182,9 +2182,9 @@ cloudos interactive-session create \
2182
2182
  - `--shutdown-in`: Auto-shutdown duration (e.g., `8h`, `2d`, `30m`, default: `12h`)
2183
2183
 
2184
2184
  **Data & Storage Management:**
2185
- - `--mount`: Mount a data file into the session. Supports both Lifebit Platform datasets and S3 files (AWS only). Format: `project_name/dataset_path` (e.g., `leila-test/Data/file.csv`) or `s3://bucket/path/to/file` (e.g., `s3://my-bucket/data/file.csv`). Can be used multiple times.
2186
- - `--link`: Link a file or folder into the session for read access (AWS only). Supports S3 files/folders (e.g., `s3://my-bucket/data/file.csv`, `s3://my-bucket/data/`) and File Explorer files/folders (e.g., `my-project/Data/file.csv`, `my-project/Data/results`). S3 paths whose last segment contains a `.` are treated as files; paths ending with `/` or without an extension are treated as folders. Multiple items can be specified using multiple `--link` flags or as comma-separated paths in a single `--link` argument.
2187
- **Note:** Linking is not supported on Azure. Use Lifebit Platform File Explorer for data access.
2185
+ - `--link`: Link a file or folder into the session for read access (AWS only). Supports S3 files/folders (e.g., `s3://my-bucket/data/file.csv`, `s3://my-bucket/data/`) and File Explorer files/folders (e.g., `my-project/Data/file.csv`, `my-project/Data/results`). S3 paths whose last segment contains a `.` are treated as files; paths ending with `/` or without an extension are treated as folders. Multiple items can be specified using multiple `--link` flags or as comma-separated paths in a single `--link` argument. Use `--copy` to copy data into the session instead.
2186
+ - `--copy`: Copy data into the session instead of linking for read access. When specified, the paths provided by `--link` are copied into the session's data volume. Supports Lifebit Platform datasets (`project_name/Data/file.csv`) and S3 files (`s3://bucket/path/to/file`). AWS only for S3 files.
2187
+ **Note:** Linking is not supported on Azure. Use `--link --copy` to copy Lifebit Platform data into the session on Azure.
2188
2188
 
2189
2189
  **Backend-Specific:**
2190
2190
  - `--r-version`: R version for RStudio (options: `4.4.2`, `4.5.2`) - **optional for rstudio** (default: `4.4.2`)
@@ -2197,20 +2197,21 @@ cloudos interactive-session create \
2197
2197
  **Data Management**
2198
2198
 
2199
2199
  CloudOS CLI supports multiple ways to access data in interactive sessions, depending on your execution platform:
2200
- - **Mount files** (`--mount`): Files are copied into the session's mounted-data volume. Supports CloudOS File Explorer files and S3 files (AWS only).
2200
+ - **Copy files** (`--link --copy`): Files are copied into the session's data volume. Supports Lifebit Platform File Explorer files and S3 files (AWS only).
2201
2201
  - **Link files/folders** (`--link`): Files and folders are mounted as read-accessible items in the session (AWS only). Supports S3 files, S3 folders, and Lifebit Platform File Explorer files and folders. Linked items appear with unique mount names based on the item name. Maximum 100 items per session.
2202
2202
 
2203
2203
 
2204
- **Data Mounting Examples**
2204
+ **Data Management Examples**
2205
2205
 
2206
- Mount a file from File Explorer:
2206
+ Copy a file from File Explorer into the session:
2207
2207
 
2208
2208
  ```bash
2209
2209
  cloudos interactive-session create \
2210
2210
  --profile my_profile \
2211
2211
  --name "Data Analysis" \
2212
2212
  --session-type jupyter \
2213
- --mount "my_project/training_data.csv"
2213
+ --link "my_project/training_data.csv" \
2214
+ --copy
2214
2215
  ```
2215
2216
 
2216
2217
  Link an S3 folder:
@@ -2613,7 +2614,114 @@ All configuration parameters are optional. If not specified, the session resumes
2613
2614
  - `--cost-limit <USD>` - Update compute cost limit (-1 for unlimited)
2614
2615
  - `--shutdown-in <DURATION>` - Update auto-shutdown time (e.g., 8h, 2d)
2615
2616
 
2616
- > To link or mount data to a running session, use `cloudos link` or `cloudos datasets link` after the session has resumed.
2617
+ > To link or copy data to a running session, use `cloudos interactive-session link` after the session has resumed.
2618
+
2619
+ ### Link
2620
+
2621
+ The `cloudos interactive-session link` command provides a unified interface for linking files and folders to interactive analysis sessions. It consolidates functionality previously available through separate commands (`cloudos job results --link`, `cloudos job workdir --link`, `cloudos job logs --link`, and `cloudos datasets link`) into a single, intuitive interface.
2622
+
2623
+ #### Link Files and Folders to Interactive Analysis
2624
+
2625
+ Link job-related folders or custom S3/File Explorer paths (files and folders) to your interactive analysis sessions for direct access to data without needing to copy files.
2626
+
2627
+ **Two modes of operation:**
2628
+
2629
+ 1. **Job-based linking** (`--job-id`): Links folders from a completed or running job
2630
+ - By default, links results, workdir, and logs folders
2631
+ - Use `--results`, `--workdir`, or `--logs` flags to link only specific folders
2632
+
2633
+ 2. **Direct path linking** (PATH argument): Links specific S3 or File Explorer paths (files or folders). Supports a single path or comma-separated multiple paths.
2634
+ - S3 paths whose last segment contains a `.` are treated as files (e.g., `s3://bucket/data/file.csv`)
2635
+ - S3 paths ending with `/` or without an extension are treated as folders
2636
+ - File Explorer paths can point to either files or folders — the CLI detects the type automatically
2637
+ - If the first path segment is a standard top-level folder name (`Data`, `AnalysesResults`, `Analyses_Results`, `Analyses-Results`, `Cohorts`), the path is resolved against the profile project. Otherwise the first segment is treated as the project name (e.g. `other-project/Data/file.csv`).
2638
+
2639
+ **Basic usage:**
2640
+
2641
+ ```bash
2642
+ # Link all job folders (results, workdir, logs) - default behavior
2643
+ cloudos interactive-session link --job-id <JOB_ID> --session-id <SESSION_ID> --profile my_profile
2644
+
2645
+ # Link only specific folders from a job
2646
+ cloudos interactive-session link --job-id <JOB_ID> --session-id <SESSION_ID> --results --profile my_profile
2647
+ cloudos interactive-session link --job-id <JOB_ID> --session-id <SESSION_ID> --workdir --logs --profile my_profile
2648
+
2649
+ # Link a single S3 folder
2650
+ cloudos interactive-session link s3://bucket/folder/ --session-id <SESSION_ID> --profile my_profile
2651
+
2652
+ # Link a single S3 file
2653
+ cloudos interactive-session link s3://bucket/data/file.csv --session-id <SESSION_ID> --profile my_profile
2654
+
2655
+ # Link multiple S3 paths (comma-separated, files and folders mixed)
2656
+ cloudos interactive-session link s3://bucket1/data/,s3://bucket2/results/file.csv --session-id <SESSION_ID> --profile my_profile
2657
+
2658
+ # Link a File Explorer folder from the profile project
2659
+ cloudos interactive-session link Data/MyFolder --session-id <SESSION_ID> --profile my_profile
2660
+
2661
+ # Link a File Explorer file from a different project
2662
+ cloudos interactive-session link other-project/Data/file.csv --session-id <SESSION_ID> --profile my_profile
2663
+
2664
+ # Mix paths from the profile project, another project, and S3
2665
+ cloudos interactive-session link Data/MultiQC,other-project/Data/file.csv,s3://bucket/results/ --session-id <SESSION_ID> --profile my_profile
2666
+ ```
2667
+
2668
+ **Command options:**
2669
+
2670
+ - `PATH`: S3 or File Explorer path(s) to link (positional argument, required if `--job-id` is not provided). Supports comma-separated multiple paths for batch linking (e.g., `s3://bucket1/path1,s3://bucket2/path2`)
2671
+ - `--apikey` / `-k`: Your Lifebit Platform API key (required)
2672
+ - `--cloudos-url` / `-c`: The Lifebit Platform URL (default: https://cloudos.lifebit.ai)
2673
+ - `--workspace-id`: The specific Lifebit Platform workspace ID (required)
2674
+ - `--session-id`: The specific Lifebit Platform interactive session ID (required)
2675
+ - `--job-id`: The job ID in Lifebit Platform (links results, workdir, and logs by default)
2676
+ - `--project-name`: Lifebit Platform project name (used as fallback for job-based linking)
2677
+ - `--results`: Link only results folder (only works with `--job-id`)
2678
+ - `--workdir`: Link only working directory (only works with `--job-id`)
2679
+ - `--logs`: Link only logs folder (only works with `--job-id`)
2680
+ - `--verbose`: Print detailed information messages
2681
+ - `--disable-ssl-verification`: Disable SSL certificate verification
2682
+ - `--ssl-cert`: Path to your SSL certificate file
2683
+ - `--profile`: Profile to use from the config file
2684
+
2685
+ **Examples:**
2686
+
2687
+ ```bash
2688
+ # Link all folders from a completed job
2689
+ cloudos interactive-session link --job-id 62c83a1191fe06013b7ef355 --session-id abc123 --profile my_profile
2690
+
2691
+ # Link only results from a job
2692
+ cloudos interactive-session link --job-id 62c83a1191fe06013b7ef355 --session-id abc123 --results --profile my_profile
2693
+
2694
+ # Link workdir and logs (but not results)
2695
+ cloudos interactive-session link --job-id 62c83a1191fe06013b7ef355 --session-id abc123 --workdir --logs --profile my_profile
2696
+
2697
+ # Link a single S3 bucket folder
2698
+ cloudos interactive-session link s3://my-bucket/analysis-results/2024 --session-id abc123 --profile my_profile
2699
+
2700
+ # Link multiple S3 folders in one command
2701
+ cloudos interactive-session link s3://bucket1/data,s3://bucket2/results,s3://bucket3/final-output --session-id abc123 --profile my_profile
2702
+
2703
+ # Link File Explorer paths from the profile project
2704
+ cloudos interactive-session link Data/MultiQC --session-id abc123 --profile my_profile
2705
+
2706
+ # Link File Explorer paths from multiple projects in one command
2707
+ cloudos interactive-session link leila-test/Data/MultiQC,Daniel_Test_Files/Data/20131219.populations.tsv --session-id abc123 --profile my_profile
2708
+ ```
2709
+
2710
+ **Error handling:**
2711
+
2712
+ The command provides clear error messages for common scenarios:
2713
+ - Job not completed (for results linking)
2714
+ - Folders not available or deleted
2715
+ - Job still initializing
2716
+ - Invalid paths or permissions
2717
+
2718
+ > [!NOTE]
2719
+ > If running the CLI inside a Jupyter session, the pre-configured CLI installation will have the session ID already configured and only the `--apikey` needs to be added.
2720
+
2721
+ > [!NOTE]
2722
+ > Azure Blob Storage paths (az://) are not supported for linking in Azure environments.
2723
+
2724
+ ---
2617
2725
 
2618
2726
  ### Datasets
2619
2727
 
@@ -2646,7 +2754,7 @@ The `datasets ls` command supports different output formats using the `--output-
2646
2754
  - **`stdout` (default)**: Displays results in the console with Rich formatting
2647
2755
  - Without `--details`: Simple list of file/folder names with color coding (blue underlined for folders)
2648
2756
  - With `--details`: Rich formatted table with all file information
2649
-
2757
+
2650
2758
  - **`csv`**: Saves results to a CSV file
2651
2759
  - Without `--details`: CSV with two columns: "Name,Storage Path"
2652
2760
  - With `--details`: CSV with columns "Type, Owner, Size, Size (bytes), Last Updated, Virtual Name, Storage Path"
@@ -2696,7 +2804,7 @@ Any of the `source_path` must be a full path, starting from the `Data` datasets
2696
2804
  An example of such command is:
2697
2805
 
2698
2806
  ```
2699
- cloudos datasets mv Data/results/my_plot.png Data/plots
2807
+ cloudos datasets mv Data/results/my_plot.png Data/plots
2700
2808
  ```
2701
2809
 
2702
2810
  #### Rename Files
@@ -2707,7 +2815,7 @@ Change file and folder names while keeping them in the same location. This helps
2707
2815
  > Files and folders within the `Data` dataset can be renamed using the following command
2708
2816
 
2709
2817
  ```bash
2710
- cloudos datasets rename <path> <new_name> --profile my_profile
2818
+ cloudos datasets rename <path> <new_name> --profile my_profile
2711
2819
  ```
2712
2820
  where `path` is the full path to the file/folder to be renamed and `new_name` is just the name, no path required, as the file will not be moved.
2713
2821
 
@@ -2733,12 +2841,12 @@ or it can happen **across different projects** within the same workspace
2733
2841
  cloudos datasets cp <source_path> <destination_path> --profile <profile> --destination-project-name <project>
2734
2842
  ```
2735
2843
 
2736
- Any of the `source_path` must be a full path; any `destination_path` must be a path starting with `Data` and finishing with the folder where to move the file/folder.
2844
+ Any of the `source_path` must be a full path; any `destination_path` must be a path starting with `Data` and finishing with the folder where to move the file/folder.
2737
2845
 
2738
2846
  An example of such command is:
2739
2847
 
2740
2848
  ```
2741
- cloudos datasets cp AnalysesResults/my_analysis/results/my_plot.png Data/plots
2849
+ cloudos datasets cp AnalysesResults/my_analysis/results/my_plot.png Data/plots
2742
2850
  ```
2743
2851
 
2744
2852
 
@@ -2789,7 +2897,7 @@ Create new organizational folders within your projects to maintain structured da
2789
2897
  > New folders can be created within the `Data` dataset and its subfolders.
2790
2898
 
2791
2899
  ```bash
2792
- cloudos datasets mkdir <new_folder_path> --profile my_profile
2900
+ cloudos datasets mkdir <new_folder_path> --profile my_profile
2793
2901
  ```
2794
2902
 
2795
2903
  #### Remove Files or Folders
@@ -2797,120 +2905,13 @@ cloudos datasets mkdir <new_folder_path> --profile my_profile
2797
2905
  Remove unnecessary files or empty folders from your File Explorer. Note that this removes files from Lifebit Platform but not from underlying cloud storage.
2798
2906
 
2799
2907
  > [!NOTE]
2800
- > Files and folders can be removed in the `Data` datasets and its subfolders.
2908
+ > Files and folders can be removed in the `Data` datasets and its subfolders.
2801
2909
 
2802
2910
  ```bash
2803
2911
  cloudos datasets rm <path> --profile my_profile
2804
2912
  ```
2805
2913
  > [!NOTE]
2806
2914
  > If a file was uploaded by the user, in order to be removed you must use `--force` and that will permanently remove the file. If the file is "linked" (e.g a s3 folder or file), removing it using `cloudos datasets rm` will not remove it from the the s3 bucket.
2807
-
2808
- ---
2809
-
2810
- ### Link
2811
-
2812
- The `cloudos link` command provides a unified interface for linking files and folders to interactive analysis sessions. This command consolidates functionality previously available through separate commands (`cloudos job results --link`, `cloudos job workdir --link`, `cloudos job logs --link`, and `cloudos datasets link`) into a single, intuitive interface.
2813
-
2814
- #### Link Files and Folders to Interactive Analysis
2815
-
2816
- Link job-related folders or custom S3/File Explorer paths (files and folders) to your interactive analysis sessions for direct access to data without needing to copy files.
2817
-
2818
- **Two modes of operation:**
2819
-
2820
- 1. **Job-based linking** (`--job-id`): Links folders from a completed or running job
2821
- - By default, links results, workdir, and logs folders
2822
- - Use `--results`, `--workdir`, or `--logs` flags to link only specific folders
2823
-
2824
- 2. **Direct path linking** (PATH argument): Links specific S3 or File Explorer paths (files or folders). Supports a single path or comma-separated multiple paths.
2825
- - S3 paths whose last segment contains a `.` are treated as files (e.g., `s3://bucket/data/file.csv`)
2826
- - S3 paths ending with `/` or without an extension are treated as folders
2827
- - File Explorer paths can point to either files or folders — the CLI detects the type automatically
2828
-
2829
- **Basic usage:**
2830
-
2831
- ```bash
2832
- # Link all job folders (results, workdir, logs) - default behavior
2833
- cloudos link --job-id <JOB_ID> --session-id <SESSION_ID> --profile my_profile
2834
-
2835
- # Link only specific folders from a job
2836
- cloudos link --job-id <JOB_ID> --session-id <SESSION_ID> --results --profile my_profile
2837
- cloudos link --job-id <JOB_ID> --session-id <SESSION_ID> --workdir --logs --profile my_profile
2838
-
2839
- # Link a single S3 folder
2840
- cloudos link s3://bucket/folder/ --session-id <SESSION_ID> --profile my_profile
2841
-
2842
- # Link a single S3 file
2843
- cloudos link s3://bucket/data/file.csv --session-id <SESSION_ID> --profile my_profile
2844
-
2845
- # Link multiple S3 paths (comma-separated, files and folders mixed)
2846
- cloudos link s3://bucket1/data/,s3://bucket2/results/file.csv --session-id <SESSION_ID> --profile my_profile
2847
-
2848
- # Link a File Explorer folder (path is RELATIVE to --project-name; do NOT prepend the project)
2849
- cloudos link "Data/MyFolder" --project-name my-project --session-id <SESSION_ID> --profile my_profile
2850
-
2851
- # Link a File Explorer file (path is RELATIVE to --project-name)
2852
- cloudos link "Data/file.csv" --project-name my-project --session-id <SESSION_ID> --profile my_profile
2853
-
2854
- # Link several File Explorer items at once (all in the same project)
2855
- cloudos link "Data/MyFolder,Data/file.csv,Results/run-1" --project-name my-project --session-id <SESSION_ID> --profile my_profile
2856
- ```
2857
-
2858
- > [!IMPORTANT]
2859
- > **`cloudos link` is single-project for File Explorer paths.** All File Explorer items linked in one invocation must belong to the project named in `--project-name`. The path must be relative to that project — prepending the project name to the path (e.g. `my-project/Data/file.csv`) is rejected. To link items from a different project, run `cloudos link` again with a different `--project-name`.
2860
-
2861
- **Command options:**
2862
-
2863
-
2864
- - `PATH`: S3 or File Explorer path(s) to link (positional argument, required if `--job-id` is not provided). Supports comma-separated multiple paths for batch linking (e.g., `s3://bucket1/path1,s3://bucket2/path2`)
2865
- - `--apikey` / `-k`: Your Lifebit Platform API key (required)
2866
- - `--cloudos-url` / `-c`: The Lifebit Platform URL (default: https://cloudos.lifebit.ai)
2867
- - `--workspace-id`: The specific Lifebit Platform workspace ID (required)
2868
- - `--session-id`: The specific Lifebit Platform interactive session ID (required)
2869
- - `--job-id`: The job ID in Lifebit Platform (links results, workdir, and logs by default)
2870
- - `--project-name`: Lifebit Platform project name. Required when any PATH is a File Explorer path. All FE paths in one invocation must belong to this project and must be RELATIVE to it (do not prepend the project name)
2871
- - `--results`: Link only results folder (only works with `--job-id`)
2872
- - `--workdir`: Link only working directory (only works with `--job-id`)
2873
- - `--logs`: Link only logs folder (only works with `--job-id`)
2874
- - `--verbose`: Print detailed information messages
2875
- - `--disable-ssl-verification`: Disable SSL certificate verification
2876
- - `--ssl-cert`: Path to your SSL certificate file
2877
- - `--profile`: Profile to use from the config file
2878
-
2879
- **Examples:**
2880
-
2881
- ```bash
2882
- # Link all folders from a completed job
2883
- cloudos link --job-id 62c83a1191fe06013b7ef355 --session-id abc123 --profile my_profile
2884
-
2885
- # Link only results from a job
2886
- cloudos link --job-id 62c83a1191fe06013b7ef355 --session-id abc123 --results --profile my_profile
2887
-
2888
- # Link workdir and logs (but not results)
2889
- cloudos link --job-id 62c83a1191fe06013b7ef355 --session-id abc123 --workdir --logs --profile my_profile
2890
-
2891
- # Link a single S3 bucket folder
2892
- cloudos link s3://my-bucket/analysis-results/2024 --session-id abc123 --profile my_profile
2893
-
2894
- # Link multiple S3 folders in one command
2895
- cloudos link s3://bucket1/data,s3://bucket2/results,s3://bucket3/final-output --session-id abc123 --profile my_profile
2896
-
2897
- # Mix different S3 prefixes from the same or different buckets
2898
- cloudos link s3://lifebit-datasets/pipelines/vep/,s3://lifebit-datasets/pipelines/phewas/,s3://my-results/output/ --session-id abc123 --profile my_profile
2899
- ```
2900
-
2901
- **Error handling:**
2902
-
2903
- The command provides clear error messages for common scenarios:
2904
- - Job not completed (for results linking)
2905
- - Folders not available or deleted
2906
- - Job still initializing
2907
- - Invalid paths or permissions
2908
-
2909
- > [!NOTE]
2910
- > If running the CLI inside a Jupyter session, the pre-configured CLI installation will have the session ID already configured and only the `--apikey` needs to be added.
2911
-
2912
- > [!NOTE]
2913
- > Azure Blob Storage paths (az://) are not supported for linking in Azure environments.
2914
2915
 
2915
2916
  ---
2916
2917
 
@@ -2926,7 +2927,7 @@ To list images for a specific procurement, use the following command:
2926
2927
 
2927
2928
  ```bash
2928
2929
  cloudos procurement images ls \
2929
- -- profile procurement_profile
2930
+ -- profile procurement_profile
2930
2931
  --procurement-id "your_procurement_id_here"
2931
2932
  ```
2932
2933
 
@@ -2985,12 +2986,10 @@ cloudos procurement images set --profile procurement_profile --image-type "JobDe
2985
2986
  - `--image-type`: The Lifebit Platform resource image type (required). Possible values:
2986
2987
  - `RegularInteractiveSessions`
2987
2988
  - `SparkInteractiveSessions`
2988
- - `RStudioInteractiveSessions`
2989
- - `JupyterInteractiveSessions`
2990
2989
  - `JobDefault`
2991
2990
  - `NextflowBatchComputeEnvironment`
2992
- - `--provider`: The cloud provider (required). Currently only `aws` is supported
2993
- - `--region`: The cloud region (required). Currently only AWS regions are supported
2991
+ - `--provider`: The cloud provider (required). Currently only supporting `aws` and `azure`.
2992
+ - `--region`: The cloud region (required). Currently only supporting aws and azure regions.
2994
2993
  - `--image-id`: The new image ID value (required)
2995
2994
  - `--image-name`: The new image name value (optional)
2996
2995
  - `--image-version`: The new image version (required)
@@ -3023,7 +3022,7 @@ cloudos procurement images reset --profile procurement_profile --image-type "Job
3023
3022
  - `--organisation-id`: The organization ID where the change will be applied (required)
3024
3023
  - `--image-type`: The Lifebit Platform resource image type (required). Same values as for `set` command
3025
3024
  - `--provider`: The cloud provider (required). Currently only `aws` is supported
3026
- - `--region`: The cloud region (required). Currently only AWS regions are supported
3025
+ - `--region`: The cloud region (required). Currently only supporting aws and azure regions.
3027
3026
  - `--disable-ssl-verification`: Disable SSL certificate verification
3028
3027
  - `--ssl-cert`: Path to your SSL certificate file
3029
3028
  - `--profile`: Profile to use from the config file
@@ -3052,7 +3051,7 @@ Executing status...
3052
3051
  Current Cromwell server status is: Stopped
3053
3052
  ```
3054
3053
 
3055
- ```bash
3054
+ ```bash
3056
3055
  # Cromwell start
3057
3056
  cloudos cromwell start --profile my_profile
3058
3057
  ```
@@ -3278,8 +3277,8 @@ responses>=0.21.0
3278
3277
  mock>=3.0.5
3279
3278
  ```
3280
3279
 
3281
- Command to run tests from the `cloudos-cli` main folder:
3280
+ Command to run tests from the `cloudos-cli` main folder:
3282
3281
 
3283
3282
  ```
3284
3283
  python -m pytest -s -v
3285
- ```
3284
+ ```