fractal-server 2.12.0a0__py3-none-any.whl → 2.12.0a1__py3-none-any.whl

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.
@@ -1 +1 @@
1
- __VERSION__ = "2.12.0a0"
1
+ __VERSION__ = "2.12.0a1"
@@ -385,9 +385,7 @@ class FractalSlurmSSHExecutor(SlurmExecutor):
385
385
  args_batches = []
386
386
  batch_size = tasks_per_job
387
387
  for ind_chunk in range(0, tot_tasks, batch_size):
388
- args_batches.append(
389
- list_args[ind_chunk : ind_chunk + batch_size] # noqa
390
- )
388
+ args_batches.append(list_args[ind_chunk : ind_chunk + batch_size])
391
389
  if len(args_batches) != math.ceil(tot_tasks / tasks_per_job):
392
390
  raise RuntimeError("Something wrong here while batching tasks")
393
391
 
@@ -536,10 +534,15 @@ class FractalSlurmSSHExecutor(SlurmExecutor):
536
534
  _prefixes = []
537
535
  _subfolder_names = []
538
536
  for component in components:
539
- if isinstance(component, dict):
537
+ # In Fractal, `component` is `dict` by construction (e.g.
538
+ # `component = {"zarr_url": "/something", "param": 1}``). The
539
+ # try/except covers the case of e.g. `executor.map([1, 2])`,
540
+ # which is useful for testing.
541
+ try:
540
542
  actual_component = component.get(_COMPONENT_KEY_, None)
541
- else:
542
- actual_component = component
543
+ except AttributeError:
544
+ actual_component = str(component)
545
+
543
546
  _task_file_paths = get_task_file_paths(
544
547
  workflow_dir_local=task_files.workflow_dir_local,
545
548
  workflow_dir_remote=task_files.workflow_dir_remote,
@@ -608,11 +608,7 @@ class FractalSlurmExecutor(SlurmExecutor):
608
608
  _prefixes = []
609
609
  _subfolder_names = []
610
610
  for component in components:
611
- if isinstance(component, dict):
612
- # This is needed for V2
613
- actual_component = component.get(_COMPONENT_KEY_, None)
614
- else:
615
- actual_component = component
611
+ actual_component = component.get(_COMPONENT_KEY_, None)
616
612
  _task_file_paths = get_task_file_paths(
617
613
  workflow_dir_local=task_files.workflow_dir_local,
618
614
  workflow_dir_remote=task_files.workflow_dir_remote,
@@ -48,25 +48,6 @@ def valdict_keys(attribute: str):
48
48
  return val
49
49
 
50
50
 
51
- def valint(attribute: str, min_val: int = 1):
52
- """
53
- Check that an integer attribute (e.g. if it is meant to be the ID of a
54
- database entry) is greater or equal to min_val.
55
- """
56
-
57
- def val(integer: Optional[int]) -> Optional[int]:
58
- if integer is None:
59
- raise ValueError(f"Integer attribute '{attribute}' cannot be None")
60
- if integer < min_val:
61
- raise ValueError(
62
- f"Integer attribute '{attribute}' cannot be less than "
63
- f"{min_val} (given {integer})"
64
- )
65
- return integer
66
-
67
- return val
68
-
69
-
70
51
  def val_absolute_path(attribute: str, accept_none: bool = False):
71
52
  """
72
53
  Check that a string attribute is an absolute path
@@ -7,9 +7,5 @@ COLLECTION_FREEZE_FILENAME = "collection_freeze.txt"
7
7
  FORBIDDEN_DEPENDENCY_STRINGS = ["github.com"]
8
8
 
9
9
 
10
- def get_collection_path(base: Path) -> Path:
11
- return base / COLLECTION_FILENAME
12
-
13
-
14
10
  def get_log_path(base: Path) -> Path:
15
11
  return base / COLLECTION_LOG_FILENAME
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: fractal-server
3
- Version: 2.12.0a0
3
+ Version: 2.12.0a1
4
4
  Summary: Backend component of the Fractal analytics platform
5
5
  Home-page: https://github.com/fractal-analytics-platform/fractal-server
6
6
  License: BSD-3-Clause
@@ -1,4 +1,4 @@
1
- fractal_server/__init__.py,sha256=Wn8eJa03y-IsDDGndomL0oqMXnAho6QTuQcpQidSwcA,25
1
+ fractal_server/__init__.py,sha256=gxqCoA1Q81Ojo5b58OAPQxwUtkX0nD4cBL1wD-a3TMg,25
2
2
  fractal_server/__main__.py,sha256=D2YTmSowmXNyvqOjW_HeItCZT2UliWlySl_owicaZg0,8026
3
3
  fractal_server/alembic.ini,sha256=MWwi7GzjzawI9cCAK1LW7NxIBQDUqD12-ptJoq5JpP0,3153
4
4
  fractal_server/app/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -68,12 +68,12 @@ fractal_server/app/runner/executors/slurm/remote.py,sha256=wLziIsGdSMiO-jIXM8x77
68
68
  fractal_server/app/runner/executors/slurm/ssh/__init__.py,sha256=Cjn1rYvljddi96tAwS-qqGkNfOcfPzjChdaEZEObCcM,65
69
69
  fractal_server/app/runner/executors/slurm/ssh/_executor_wait_thread.py,sha256=bKo5Ja0IGxJWpPWyh9dN0AG-PwzTDZzD5LyaEHB3YU4,3742
70
70
  fractal_server/app/runner/executors/slurm/ssh/_slurm_job.py,sha256=rwlqZzoGo4SAb4nSlFjsQJdaCgfM1J6YGcjb8yYxlqc,4506
71
- fractal_server/app/runner/executors/slurm/ssh/executor.py,sha256=gtjXKTY0cP3h5AtTXRZChtFOP-tbJTBmvxs_6VnEWao,54082
71
+ fractal_server/app/runner/executors/slurm/ssh/executor.py,sha256=oqXssvcjBiTYxkud-WVQQuQiAKOiBYumz6piFSY5jNg,54316
72
72
  fractal_server/app/runner/executors/slurm/sudo/__init__.py,sha256=Cjn1rYvljddi96tAwS-qqGkNfOcfPzjChdaEZEObCcM,65
73
73
  fractal_server/app/runner/executors/slurm/sudo/_check_jobs_status.py,sha256=wAgwpVcr6JIslKHOuS0FhRa_6T1KCManyRJqA-fifzw,1909
74
74
  fractal_server/app/runner/executors/slurm/sudo/_executor_wait_thread.py,sha256=uRRyVHQtK9McHCB6OsjYfDnQsu2E8At9K_UYb_pe2pg,4682
75
75
  fractal_server/app/runner/executors/slurm/sudo/_subprocess_run_as_user.py,sha256=g8wqUjSicN17UZVXlfaMomYZ-xOIbBu1oE7HdJTzfvw,5218
76
- fractal_server/app/runner/executors/slurm/sudo/executor.py,sha256=FVgx2mxqCLOhSoH3UTAeNc0BT0eJaxHMglGzGYePGPM,47439
76
+ fractal_server/app/runner/executors/slurm/sudo/executor.py,sha256=z3_VKolY472GQ9mPr1MipQfRIbjt3XW-X13q-x0gAnE,47272
77
77
  fractal_server/app/runner/executors/slurm/utils_executors.py,sha256=naPyJI0I3lD-sYHbSXbMFGUBK4h_SggA5V91Z1Ch1Xg,1416
78
78
  fractal_server/app/runner/extract_archive.py,sha256=tLpjDrX47OjTNhhoWvm6iNukg8KoieWyTb7ZfvE9eWU,2483
79
79
  fractal_server/app/runner/filenames.py,sha256=lPnxKHtdRizr6FqG3zOdjDPyWA7GoaJGTtiuJV0gA8E,70
@@ -106,7 +106,7 @@ fractal_server/app/runner/v2/task_interface.py,sha256=d6HPwPzrytUMVjExTU6fuCEwtv
106
106
  fractal_server/app/runner/versions.py,sha256=dSaPRWqmFPHjg20kTCHmi_dmGNcCETflDtDLronNanU,852
107
107
  fractal_server/app/schemas/__init__.py,sha256=stURAU_t3AOBaH0HSUbV-GKhlPKngnnIMoqWc3orFyI,135
108
108
  fractal_server/app/schemas/_filter_validators.py,sha256=0wJuZzMa-hJsMCEMxtBalW3lSk1Qey25uSVmS7GVcPM,1534
109
- fractal_server/app/schemas/_validators.py,sha256=3dotVxUHWKAmUO3aeoluYDLRKrw1OS-NxcZ4Fg_HOYk,3560
109
+ fractal_server/app/schemas/_validators.py,sha256=wS09d8hX7mN91C8_BF9jfB8rgBbuAmmZ1BAmLKi3BU8,2974
110
110
  fractal_server/app/schemas/user.py,sha256=icjox9gK_invW44Nh_L4CvqfRa92qghyQhmevyg09nQ,2243
111
111
  fractal_server/app/schemas/user_group.py,sha256=t30Kd07PY43G_AqFDb8vjdInTeLeU9WvFZDx8fVLPSI,1750
112
112
  fractal_server/app/schemas/user_settings.py,sha256=re7ZFS8BLjR9MdIoZNRt2DNPc7znCgDpEYFKr8ZsAZg,2980
@@ -171,7 +171,7 @@ fractal_server/ssh/_fabric.py,sha256=lNy4IX1I4We6VoWa4Bz4fUPuApLMSoejpyE6I3jDZeM
171
171
  fractal_server/string_tools.py,sha256=niViRrrZAOo0y6pEFI9L_eUYS1PoOiQZUBtngiLc2_k,1877
172
172
  fractal_server/syringe.py,sha256=3qSMW3YaMKKnLdgnooAINOPxnCOxP7y2jeAQYB21Gdo,2786
173
173
  fractal_server/tasks/__init__.py,sha256=kadmVUoIghl8s190_Tt-8f-WBqMi8u8oU4Pvw39NHE8,23
174
- fractal_server/tasks/utils.py,sha256=iJcfOCU5FAOosj6yEWlHtnvF0PuvaQGGvgdFWbbycYo,376
174
+ fractal_server/tasks/utils.py,sha256=V7dj8o2AnoHhGSTYlqJHcRFhCIpmOrMOUhtiE_DvRVA,291
175
175
  fractal_server/tasks/v2/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
176
176
  fractal_server/tasks/v2/local/__init__.py,sha256=9RVItnS7OyLsJOuJjWMCicaky4ASUPQEYD4SzDs0hOE,141
177
177
  fractal_server/tasks/v2/local/_utils.py,sha256=EvhmVwYjqaNyDCUMEsTWYOUXLgEwR1xr6bu32apCEI8,2491
@@ -197,8 +197,8 @@ fractal_server/tasks/v2/utils_templates.py,sha256=07TZpJ0Mh_A4lXVXrrH2o1VLFFGwxe
197
197
  fractal_server/urls.py,sha256=QjIKAC1a46bCdiPMu3AlpgFbcv6a4l3ABcd5xz190Og,471
198
198
  fractal_server/utils.py,sha256=PMwrxWFxRTQRl1b9h-NRIbFGPKqpH_hXnkAT3NfZdpY,3571
199
199
  fractal_server/zip_tools.py,sha256=GjDgo_sf6V_DDg6wWeBlZu5zypIxycn_l257p_YVKGc,4876
200
- fractal_server-2.12.0a0.dist-info/LICENSE,sha256=QKAharUuhxL58kSoLizKJeZE3mTCBnX6ucmz8W0lxlk,1576
201
- fractal_server-2.12.0a0.dist-info/METADATA,sha256=LghysLw-HvU3qdWps85YpkIfYdEYWBMcl0Wc_JygZaQ,4564
202
- fractal_server-2.12.0a0.dist-info/WHEEL,sha256=RaoafKOydTQ7I_I3JTrPCg6kUmTgtm4BornzOqyEfJ8,88
203
- fractal_server-2.12.0a0.dist-info/entry_points.txt,sha256=8tV2kynvFkjnhbtDnxAqImL6HMVKsopgGfew0DOp5UY,58
204
- fractal_server-2.12.0a0.dist-info/RECORD,,
200
+ fractal_server-2.12.0a1.dist-info/LICENSE,sha256=QKAharUuhxL58kSoLizKJeZE3mTCBnX6ucmz8W0lxlk,1576
201
+ fractal_server-2.12.0a1.dist-info/METADATA,sha256=toS3YbZbnMrVzQOHOFPN8c4uj3gEJbjSdagv3NbrfjA,4564
202
+ fractal_server-2.12.0a1.dist-info/WHEEL,sha256=RaoafKOydTQ7I_I3JTrPCg6kUmTgtm4BornzOqyEfJ8,88
203
+ fractal_server-2.12.0a1.dist-info/entry_points.txt,sha256=8tV2kynvFkjnhbtDnxAqImL6HMVKsopgGfew0DOp5UY,58
204
+ fractal_server-2.12.0a1.dist-info/RECORD,,