ob-metaflow-stubs 6.0.3.104__py2.py3-none-any.whl → 6.0.3.105__py2.py3-none-any.whl

Sign up to get free protection for your applications and to get access to all the features.
Files changed (140) hide show
  1. metaflow-stubs/__init__.pyi +888 -550
  2. metaflow-stubs/cards.pyi +210 -4
  3. metaflow-stubs/cli.pyi +22 -2
  4. metaflow-stubs/client/__init__.pyi +128 -3
  5. metaflow-stubs/client/core.pyi +226 -6
  6. metaflow-stubs/client/filecache.pyi +3 -3
  7. metaflow-stubs/clone_util.pyi +5 -2
  8. metaflow-stubs/events.pyi +21 -3
  9. metaflow-stubs/exception.pyi +2 -2
  10. metaflow-stubs/flowspec.pyi +71 -5
  11. metaflow-stubs/generated_for.txt +1 -1
  12. metaflow-stubs/includefile.pyi +158 -5
  13. metaflow-stubs/info_file.pyi +2 -2
  14. metaflow-stubs/metadata/metadata.pyi +9 -3
  15. metaflow-stubs/metadata/util.pyi +2 -2
  16. metaflow-stubs/metaflow_config.pyi +2 -2
  17. metaflow-stubs/metaflow_current.pyi +69 -66
  18. metaflow-stubs/mflog/mflog.pyi +2 -2
  19. metaflow-stubs/multicore_utils.pyi +2 -2
  20. metaflow-stubs/parameters.pyi +69 -3
  21. metaflow-stubs/plugins/__init__.pyi +14 -3
  22. metaflow-stubs/plugins/airflow/__init__.pyi +2 -2
  23. metaflow-stubs/plugins/airflow/airflow_utils.pyi +2 -2
  24. metaflow-stubs/plugins/airflow/exception.pyi +2 -2
  25. metaflow-stubs/plugins/airflow/sensors/__init__.pyi +80 -2
  26. metaflow-stubs/plugins/airflow/sensors/base_sensor.pyi +6 -3
  27. metaflow-stubs/plugins/airflow/sensors/external_task_sensor.pyi +46 -4
  28. metaflow-stubs/plugins/airflow/sensors/s3_sensor.pyi +46 -4
  29. metaflow-stubs/plugins/argo/__init__.pyi +2 -2
  30. metaflow-stubs/plugins/argo/argo_client.pyi +2 -2
  31. metaflow-stubs/plugins/argo/argo_events.pyi +16 -2
  32. metaflow-stubs/plugins/argo/argo_workflows.pyi +17 -4
  33. metaflow-stubs/plugins/argo/argo_workflows_cli.pyi +97 -6
  34. metaflow-stubs/plugins/argo/argo_workflows_decorator.pyi +35 -7
  35. metaflow-stubs/plugins/argo/argo_workflows_deployer.pyi +50 -5
  36. metaflow-stubs/plugins/aws/__init__.pyi +2 -2
  37. metaflow-stubs/plugins/aws/aws_client.pyi +2 -2
  38. metaflow-stubs/plugins/aws/aws_utils.pyi +2 -2
  39. metaflow-stubs/plugins/aws/batch/__init__.pyi +2 -2
  40. metaflow-stubs/plugins/aws/batch/batch.pyi +2 -2
  41. metaflow-stubs/plugins/aws/batch/batch_client.pyi +2 -2
  42. metaflow-stubs/plugins/aws/batch/batch_decorator.pyi +103 -3
  43. metaflow-stubs/plugins/aws/secrets_manager/__init__.pyi +2 -2
  44. metaflow-stubs/plugins/aws/secrets_manager/aws_secrets_manager_secrets_provider.pyi +15 -3
  45. metaflow-stubs/plugins/aws/step_functions/__init__.pyi +2 -2
  46. metaflow-stubs/plugins/aws/step_functions/event_bridge_client.pyi +2 -2
  47. metaflow-stubs/plugins/aws/step_functions/production_token.pyi +2 -2
  48. metaflow-stubs/plugins/aws/step_functions/schedule_decorator.pyi +21 -2
  49. metaflow-stubs/plugins/aws/step_functions/step_functions.pyi +2 -2
  50. metaflow-stubs/plugins/aws/step_functions/step_functions_client.pyi +2 -2
  51. metaflow-stubs/plugins/aws/step_functions/step_functions_deployer.pyi +49 -4
  52. metaflow-stubs/plugins/azure/__init__.pyi +2 -2
  53. metaflow-stubs/plugins/azure/azure_credential.pyi +2 -2
  54. metaflow-stubs/plugins/azure/azure_exceptions.pyi +2 -2
  55. metaflow-stubs/plugins/azure/azure_secret_manager_secrets_provider.pyi +21 -3
  56. metaflow-stubs/plugins/azure/azure_utils.pyi +2 -2
  57. metaflow-stubs/plugins/azure/blob_service_client_factory.pyi +2 -2
  58. metaflow-stubs/plugins/azure/includefile_support.pyi +2 -2
  59. metaflow-stubs/plugins/cards/__init__.pyi +2 -2
  60. metaflow-stubs/plugins/cards/card_cli.pyi +62 -4
  61. metaflow-stubs/plugins/cards/card_client.pyi +34 -3
  62. metaflow-stubs/plugins/cards/card_creator.pyi +5 -2
  63. metaflow-stubs/plugins/cards/card_datastore.pyi +8 -2
  64. metaflow-stubs/plugins/cards/card_decorator.pyi +53 -3
  65. metaflow-stubs/plugins/cards/card_modules/__init__.pyi +28 -2
  66. metaflow-stubs/plugins/cards/card_modules/basic.pyi +42 -3
  67. metaflow-stubs/plugins/cards/card_modules/card.pyi +28 -2
  68. metaflow-stubs/plugins/cards/card_modules/components.pyi +183 -3
  69. metaflow-stubs/plugins/cards/card_modules/convert_to_native_type.pyi +5 -2
  70. metaflow-stubs/plugins/cards/card_modules/renderer_tools.pyi +2 -2
  71. metaflow-stubs/plugins/cards/card_modules/test_cards.pyi +36 -3
  72. metaflow-stubs/plugins/cards/card_resolver.pyi +2 -2
  73. metaflow-stubs/plugins/cards/component_serializer.pyi +56 -3
  74. metaflow-stubs/plugins/cards/exception.pyi +8 -2
  75. metaflow-stubs/plugins/catch_decorator.pyi +20 -3
  76. metaflow-stubs/plugins/datatools/__init__.pyi +64 -4
  77. metaflow-stubs/plugins/datatools/local.pyi +16 -2
  78. metaflow-stubs/plugins/datatools/s3/__init__.pyi +73 -4
  79. metaflow-stubs/plugins/datatools/s3/s3.pyi +82 -5
  80. metaflow-stubs/plugins/datatools/s3/s3tail.pyi +2 -2
  81. metaflow-stubs/plugins/datatools/s3/s3util.pyi +2 -2
  82. metaflow-stubs/plugins/debug_logger.pyi +2 -2
  83. metaflow-stubs/plugins/debug_monitor.pyi +2 -2
  84. metaflow-stubs/plugins/environment_decorator.pyi +10 -2
  85. metaflow-stubs/plugins/events_decorator.pyi +107 -3
  86. metaflow-stubs/plugins/frameworks/__init__.pyi +2 -2
  87. metaflow-stubs/plugins/frameworks/pytorch.pyi +25 -4
  88. metaflow-stubs/plugins/gcp/__init__.pyi +2 -2
  89. metaflow-stubs/plugins/gcp/gcp_secret_manager_secrets_provider.pyi +15 -3
  90. metaflow-stubs/plugins/gcp/gs_exceptions.pyi +2 -2
  91. metaflow-stubs/plugins/gcp/gs_storage_client_factory.pyi +2 -2
  92. metaflow-stubs/plugins/gcp/gs_utils.pyi +2 -2
  93. metaflow-stubs/plugins/gcp/includefile_support.pyi +2 -2
  94. metaflow-stubs/plugins/kubernetes/__init__.pyi +2 -2
  95. metaflow-stubs/plugins/kubernetes/kube_utils.pyi +2 -2
  96. metaflow-stubs/plugins/kubernetes/kubernetes.pyi +11 -2
  97. metaflow-stubs/plugins/kubernetes/kubernetes_cli.pyi +67 -4
  98. metaflow-stubs/plugins/kubernetes/kubernetes_client.pyi +2 -2
  99. metaflow-stubs/plugins/kubernetes/kubernetes_decorator.pyi +100 -3
  100. metaflow-stubs/plugins/kubernetes/kubernetes_jobsets.pyi +5 -2
  101. metaflow-stubs/plugins/logs_cli.pyi +3 -3
  102. metaflow-stubs/plugins/package_cli.pyi +2 -2
  103. metaflow-stubs/plugins/parallel_decorator.pyi +30 -3
  104. metaflow-stubs/plugins/perimeters.pyi +2 -2
  105. metaflow-stubs/plugins/project_decorator.pyi +60 -3
  106. metaflow-stubs/plugins/pypi/__init__.pyi +2 -2
  107. metaflow-stubs/plugins/pypi/conda_decorator.pyi +45 -2
  108. metaflow-stubs/plugins/pypi/conda_environment.pyi +5 -5
  109. metaflow-stubs/plugins/pypi/pypi_decorator.pyi +33 -2
  110. metaflow-stubs/plugins/pypi/pypi_environment.pyi +2 -2
  111. metaflow-stubs/plugins/pypi/utils.pyi +2 -2
  112. metaflow-stubs/plugins/resources_decorator.pyi +33 -2
  113. metaflow-stubs/plugins/retry_decorator.pyi +21 -2
  114. metaflow-stubs/plugins/secrets/__init__.pyi +2 -2
  115. metaflow-stubs/plugins/secrets/inline_secrets_provider.pyi +2 -2
  116. metaflow-stubs/plugins/secrets/secrets_decorator.pyi +11 -2
  117. metaflow-stubs/plugins/storage_executor.pyi +6 -2
  118. metaflow-stubs/plugins/tag_cli.pyi +35 -4
  119. metaflow-stubs/plugins/test_unbounded_foreach_decorator.pyi +10 -3
  120. metaflow-stubs/plugins/timeout_decorator.pyi +24 -3
  121. metaflow-stubs/procpoll.pyi +2 -2
  122. metaflow-stubs/profilers/__init__.pyi +2 -2
  123. metaflow-stubs/pylint_wrapper.pyi +2 -2
  124. metaflow-stubs/runner/__init__.pyi +2 -2
  125. metaflow-stubs/runner/deployer.pyi +70 -131
  126. metaflow-stubs/runner/metaflow_runner.pyi +117 -9
  127. metaflow-stubs/runner/nbdeploy.pyi +66 -2
  128. metaflow-stubs/runner/nbrun.pyi +79 -2
  129. metaflow-stubs/runner/subprocess_manager.pyi +16 -4
  130. metaflow-stubs/runner/utils.pyi +32 -2
  131. metaflow-stubs/system/__init__.pyi +3 -3
  132. metaflow-stubs/system/system_logger.pyi +2 -2
  133. metaflow-stubs/system/system_monitor.pyi +2 -2
  134. metaflow-stubs/tagging_util.pyi +2 -2
  135. metaflow-stubs/tuple_util.pyi +2 -2
  136. {ob_metaflow_stubs-6.0.3.104.dist-info → ob_metaflow_stubs-6.0.3.105.dist-info}/METADATA +1 -1
  137. ob_metaflow_stubs-6.0.3.105.dist-info/RECORD +140 -0
  138. ob_metaflow_stubs-6.0.3.104.dist-info/RECORD +0 -140
  139. {ob_metaflow_stubs-6.0.3.104.dist-info → ob_metaflow_stubs-6.0.3.105.dist-info}/WHEEL +0 -0
  140. {ob_metaflow_stubs-6.0.3.104.dist-info → ob_metaflow_stubs-6.0.3.105.dist-info}/top_level.txt +0 -0
@@ -1,7 +1,7 @@
1
1
  ##################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.22.1+obcheckpoint(0.0.11);ob(v1) #
4
- # Generated on 2024-09-20T21:46:07.407292 #
3
+ # MF version: 2.12.24.1+obcheckpoint(0.0.11);ob(v1) #
4
+ # Generated on 2024-10-04T10:13:10.701106 #
5
5
  ##################################################################################
6
6
 
7
7
  from __future__ import annotations
@@ -88,6 +88,15 @@ UBF_CONTROL: str
88
88
 
89
89
  UBF_TASK: str
90
90
 
91
+ def init_config() -> typing.Dict[str, str]:
92
+ """
93
+ OSS Metaflow reads the config file on every step initialization. This is because OSS assumes config files change
94
+ relatively infrequently. We want to avoid config values changing between flow steps. Our solution to prevent this
95
+ is to read a config once and cache it on an environment variable. Environment variables carry over between steps
96
+ because steps are executed in subprocesses (local) or environments which expect environment variables to be set.
97
+ """
98
+ ...
99
+
91
100
  BASH_SAVE_LOGS: str
92
101
 
93
102
  class KubernetesClient(object, metaclass=type):
@@ -1,16 +1,16 @@
1
1
  ##################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.22.1+obcheckpoint(0.0.11);ob(v1) #
4
- # Generated on 2024-09-20T21:46:07.410888 #
3
+ # MF version: 2.12.24.1+obcheckpoint(0.0.11);ob(v1) #
4
+ # Generated on 2024-10-04T10:13:10.704675 #
5
5
  ##################################################################################
6
6
 
7
7
  from __future__ import annotations
8
8
 
9
9
  import typing
10
10
  if typing.TYPE_CHECKING:
11
- import metaflow.decorators
12
- import metaflow.exception
13
11
  import metaflow._vendor.click.types
12
+ import metaflow.exception
13
+ import metaflow.decorators
14
14
 
15
15
  def parse_cli_options(flow_name, run_id, user, my_runs, echo):
16
16
  ...
@@ -86,6 +86,69 @@ def parse_kube_keyvalue_list(items: typing.List[str], requires_both: bool = True
86
86
  ...
87
87
 
88
88
  class KubernetesDecorator(metaflow.decorators.StepDecorator, metaclass=type):
89
+ """
90
+ Specifies that this step should execute on Kubernetes.
91
+
92
+ Parameters
93
+ ----------
94
+ cpu : int, default 1
95
+ Number of CPUs required for this step. If `@resources` is
96
+ also present, the maximum value from all decorators is used.
97
+ memory : int, default 4096
98
+ Memory size (in MB) required for this step. If
99
+ `@resources` is also present, the maximum value from all decorators is
100
+ used.
101
+ disk : int, default 10240
102
+ Disk size (in MB) required for this step. If
103
+ `@resources` is also present, the maximum value from all decorators is
104
+ used.
105
+ image : str, optional, default None
106
+ Docker image to use when launching on Kubernetes. If not specified, and
107
+ METAFLOW_KUBERNETES_CONTAINER_IMAGE is specified, that image is used. If
108
+ not, a default Docker image mapping to the current version of Python is used.
109
+ image_pull_policy: str, default KUBERNETES_IMAGE_PULL_POLICY
110
+ If given, the imagePullPolicy to be applied to the Docker image of the step.
111
+ service_account : str, default METAFLOW_KUBERNETES_SERVICE_ACCOUNT
112
+ Kubernetes service account to use when launching pod in Kubernetes.
113
+ secrets : List[str], optional, default None
114
+ Kubernetes secrets to use when launching pod in Kubernetes. These
115
+ secrets are in addition to the ones defined in `METAFLOW_KUBERNETES_SECRETS`
116
+ in Metaflow configuration.
117
+ node_selector: Union[Dict[str,str], str], optional, default None
118
+ Kubernetes node selector(s) to apply to the pod running the task.
119
+ Can be passed in as a comma separated string of values e.g. "kubernetes.io/os=linux,kubernetes.io/arch=amd64"
120
+ or as a dictionary {"kubernetes.io/os": "linux", "kubernetes.io/arch": "amd64"}
121
+ namespace : str, default METAFLOW_KUBERNETES_NAMESPACE
122
+ Kubernetes namespace to use when launching pod in Kubernetes.
123
+ gpu : int, optional, default None
124
+ Number of GPUs required for this step. A value of zero implies that
125
+ the scheduled node should not have GPUs.
126
+ gpu_vendor : str, default KUBERNETES_GPU_VENDOR
127
+ The vendor of the GPUs to be used for this step.
128
+ tolerations : List[str], default []
129
+ The default is extracted from METAFLOW_KUBERNETES_TOLERATIONS.
130
+ Kubernetes tolerations to use when launching pod in Kubernetes.
131
+ use_tmpfs : bool, default False
132
+ This enables an explicit tmpfs mount for this step.
133
+ tmpfs_tempdir : bool, default True
134
+ sets METAFLOW_TEMPDIR to tmpfs_path if set for this step.
135
+ tmpfs_size : int, optional, default: None
136
+ The value for the size (in MiB) of the tmpfs mount for this step.
137
+ This parameter maps to the `--tmpfs` option in Docker. Defaults to 50% of the
138
+ memory allocated for this step.
139
+ tmpfs_path : str, optional, default /metaflow_temp
140
+ Path to tmpfs mount for this step.
141
+ persistent_volume_claims : Dict[str, str], optional, default None
142
+ A map (dictionary) of persistent volumes to be mounted to the pod for this step. The map is from persistent
143
+ volumes to the path to which the volume is to be mounted, e.g., `{'pvc-name': '/path/to/mount/on'}`.
144
+ shared_memory: int, optional
145
+ Shared memory size (in MiB) required for this step
146
+ port: int, optional
147
+ Port number to specify in the Kubernetes job object
148
+ compute_pool : str, optional, default None
149
+ Compute pool to be used for for this step.
150
+ If not specified, any accessible compute pool within the perimeter is used.
151
+ """
89
152
  def __init__(self, attributes = None, statically_defined = False):
90
153
  ...
91
154
  def step_init(self, flow, graph, step, decos, environment, flow_datastore, logger):
@@ -1,7 +1,7 @@
1
1
  ##################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.22.1+obcheckpoint(0.0.11);ob(v1) #
4
- # Generated on 2024-09-20T21:46:07.327505 #
3
+ # MF version: 2.12.24.1+obcheckpoint(0.0.11);ob(v1) #
4
+ # Generated on 2024-10-04T10:13:10.624748 #
5
5
  ##################################################################################
6
6
 
7
7
  from __future__ import annotations
@@ -1,16 +1,16 @@
1
1
  ##################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.22.1+obcheckpoint(0.0.11);ob(v1) #
4
- # Generated on 2024-09-20T21:46:07.408174 #
3
+ # MF version: 2.12.24.1+obcheckpoint(0.0.11);ob(v1) #
4
+ # Generated on 2024-10-04T10:13:10.702068 #
5
5
  ##################################################################################
6
6
 
7
7
  from __future__ import annotations
8
8
 
9
9
  import typing
10
10
  if typing.TYPE_CHECKING:
11
- import metaflow.decorators
12
11
  import metaflow.exception
13
12
  import metaflow.metaflow_current
13
+ import metaflow.decorators
14
14
 
15
15
  current: metaflow.metaflow_current.Current
16
16
 
@@ -22,6 +22,9 @@ class MetaflowException(Exception, metaclass=type):
22
22
  ...
23
23
 
24
24
  class MetaDatum(tuple, metaclass=type):
25
+ """
26
+ MetaDatum(field, value, type, tags)
27
+ """
25
28
  @staticmethod
26
29
  def __new__(_cls, field, value, type, tags):
27
30
  """
@@ -76,6 +79,37 @@ KUBERNETES_SHARED_MEMORY: None
76
79
  KUBERNETES_TOLERATIONS: str
77
80
 
78
81
  class ResourcesDecorator(metaflow.decorators.StepDecorator, metaclass=type):
82
+ """
83
+ Specifies the resources needed when executing this step.
84
+
85
+ Use `@resources` to specify the resource requirements
86
+ independently of the specific compute layer (`@batch`, `@kubernetes`).
87
+
88
+ You can choose the compute layer on the command line by executing e.g.
89
+ ```
90
+ python myflow.py run --with batch
91
+ ```
92
+ or
93
+ ```
94
+ python myflow.py run --with kubernetes
95
+ ```
96
+ which executes the flow on the desired system using the
97
+ requirements specified in `@resources`.
98
+
99
+ Parameters
100
+ ----------
101
+ cpu : int, default 1
102
+ Number of CPUs required for this step.
103
+ gpu : int, default 0
104
+ Number of GPUs required for this step.
105
+ disk : int, optional, default None
106
+ Disk size (in MB) required for this step. Only applies on Kubernetes.
107
+ memory : int, default 4096
108
+ Memory size (in MB) required for this step.
109
+ shared_memory : int, optional, default None
110
+ The value for the size (in MiB) of the /dev/shm volume for this step.
111
+ This parameter maps to the `--shm-size` option in Docker.
112
+ """
79
113
  ...
80
114
 
81
115
  def get_run_time_limit_for_task(step_decos):
@@ -151,6 +185,69 @@ MAX_MEMORY_PER_TASK: None
151
185
  MAX_CPU_PER_TASK: None
152
186
 
153
187
  class KubernetesDecorator(metaflow.decorators.StepDecorator, metaclass=type):
188
+ """
189
+ Specifies that this step should execute on Kubernetes.
190
+
191
+ Parameters
192
+ ----------
193
+ cpu : int, default 1
194
+ Number of CPUs required for this step. If `@resources` is
195
+ also present, the maximum value from all decorators is used.
196
+ memory : int, default 4096
197
+ Memory size (in MB) required for this step. If
198
+ `@resources` is also present, the maximum value from all decorators is
199
+ used.
200
+ disk : int, default 10240
201
+ Disk size (in MB) required for this step. If
202
+ `@resources` is also present, the maximum value from all decorators is
203
+ used.
204
+ image : str, optional, default None
205
+ Docker image to use when launching on Kubernetes. If not specified, and
206
+ METAFLOW_KUBERNETES_CONTAINER_IMAGE is specified, that image is used. If
207
+ not, a default Docker image mapping to the current version of Python is used.
208
+ image_pull_policy: str, default KUBERNETES_IMAGE_PULL_POLICY
209
+ If given, the imagePullPolicy to be applied to the Docker image of the step.
210
+ service_account : str, default METAFLOW_KUBERNETES_SERVICE_ACCOUNT
211
+ Kubernetes service account to use when launching pod in Kubernetes.
212
+ secrets : List[str], optional, default None
213
+ Kubernetes secrets to use when launching pod in Kubernetes. These
214
+ secrets are in addition to the ones defined in `METAFLOW_KUBERNETES_SECRETS`
215
+ in Metaflow configuration.
216
+ node_selector: Union[Dict[str,str], str], optional, default None
217
+ Kubernetes node selector(s) to apply to the pod running the task.
218
+ Can be passed in as a comma separated string of values e.g. "kubernetes.io/os=linux,kubernetes.io/arch=amd64"
219
+ or as a dictionary {"kubernetes.io/os": "linux", "kubernetes.io/arch": "amd64"}
220
+ namespace : str, default METAFLOW_KUBERNETES_NAMESPACE
221
+ Kubernetes namespace to use when launching pod in Kubernetes.
222
+ gpu : int, optional, default None
223
+ Number of GPUs required for this step. A value of zero implies that
224
+ the scheduled node should not have GPUs.
225
+ gpu_vendor : str, default KUBERNETES_GPU_VENDOR
226
+ The vendor of the GPUs to be used for this step.
227
+ tolerations : List[str], default []
228
+ The default is extracted from METAFLOW_KUBERNETES_TOLERATIONS.
229
+ Kubernetes tolerations to use when launching pod in Kubernetes.
230
+ use_tmpfs : bool, default False
231
+ This enables an explicit tmpfs mount for this step.
232
+ tmpfs_tempdir : bool, default True
233
+ sets METAFLOW_TEMPDIR to tmpfs_path if set for this step.
234
+ tmpfs_size : int, optional, default: None
235
+ The value for the size (in MiB) of the tmpfs mount for this step.
236
+ This parameter maps to the `--tmpfs` option in Docker. Defaults to 50% of the
237
+ memory allocated for this step.
238
+ tmpfs_path : str, optional, default /metaflow_temp
239
+ Path to tmpfs mount for this step.
240
+ persistent_volume_claims : Dict[str, str], optional, default None
241
+ A map (dictionary) of persistent volumes to be mounted to the pod for this step. The map is from persistent
242
+ volumes to the path to which the volume is to be mounted, e.g., `{'pvc-name': '/path/to/mount/on'}`.
243
+ shared_memory: int, optional
244
+ Shared memory size (in MiB) required for this step
245
+ port: int, optional
246
+ Port number to specify in the Kubernetes job object
247
+ compute_pool : str, optional, default None
248
+ Compute pool to be used for for this step.
249
+ If not specified, any accessible compute pool within the perimeter is used.
250
+ """
154
251
  def __init__(self, attributes = None, statically_defined = False):
155
252
  ...
156
253
  def step_init(self, flow, graph, step, decos, environment, flow_datastore, logger):
@@ -1,7 +1,7 @@
1
1
  ##################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.22.1+obcheckpoint(0.0.11);ob(v1) #
4
- # Generated on 2024-09-20T21:46:07.409567 #
3
+ # MF version: 2.12.24.1+obcheckpoint(0.0.11);ob(v1) #
4
+ # Generated on 2024-10-04T10:13:10.703325 #
5
5
  ##################################################################################
6
6
 
7
7
  from __future__ import annotations
@@ -30,6 +30,9 @@ def k8s_retry(deadline_seconds = 60, max_backoff = 32):
30
30
  ...
31
31
 
32
32
  class JobsetStatus(tuple, metaclass=type):
33
+ """
34
+ JobsetStatus(control_pod_failed, control_exit_code, control_pod_status, control_started, control_completed, worker_pods_failed, workers_are_suspended, workers_have_started, all_jobs_are_suspended, jobset_finished, jobset_failed, status_unknown, jobset_was_terminated, some_jobs_are_running)
35
+ """
33
36
  @staticmethod
34
37
  def __new__(_cls, control_pod_failed, control_exit_code, control_pod_status, control_started, control_completed, worker_pods_failed, workers_are_suspended, workers_have_started, all_jobs_are_suspended, jobset_finished, jobset_failed, status_unknown, jobset_was_terminated, some_jobs_are_running):
35
38
  """
@@ -1,7 +1,7 @@
1
1
  ##################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.22.1+obcheckpoint(0.0.11);ob(v1) #
4
- # Generated on 2024-09-20T21:46:07.376746 #
3
+ # MF version: 2.12.24.1+obcheckpoint(0.0.11);ob(v1) #
4
+ # Generated on 2024-10-04T10:13:10.675217 #
5
5
  ##################################################################################
6
6
 
7
7
  from __future__ import annotations
@@ -9,8 +9,8 @@ from __future__ import annotations
9
9
  import typing
10
10
  if typing.TYPE_CHECKING:
11
11
  import metaflow.exception
12
- import metaflow.plugins.logs_cli
13
12
  import metaflow._vendor.click.core
13
+ import metaflow.plugins.logs_cli
14
14
 
15
15
  LOGGER_TIMESTAMP: str
16
16
 
@@ -1,7 +1,7 @@
1
1
  ##################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.22.1+obcheckpoint(0.0.11);ob(v1) #
4
- # Generated on 2024-09-20T21:46:07.376349 #
3
+ # MF version: 2.12.24.1+obcheckpoint(0.0.11);ob(v1) #
4
+ # Generated on 2024-10-04T10:13:10.676537 #
5
5
  ##################################################################################
6
6
 
7
7
  from __future__ import annotations
@@ -1,15 +1,15 @@
1
1
  ##################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.22.1+obcheckpoint(0.0.11);ob(v1) #
4
- # Generated on 2024-09-20T21:46:07.373144 #
3
+ # MF version: 2.12.24.1+obcheckpoint(0.0.11);ob(v1) #
4
+ # Generated on 2024-10-04T10:13:10.671812 #
5
5
  ##################################################################################
6
6
 
7
7
  from __future__ import annotations
8
8
 
9
9
  import typing
10
10
  if typing.TYPE_CHECKING:
11
- import metaflow.decorators
12
11
  import metaflow.metaflow_current
12
+ import metaflow.decorators
13
13
 
14
14
  UBF_CONTROL: str
15
15
 
@@ -23,6 +23,9 @@ class MetaflowException(Exception, metaclass=type):
23
23
  ...
24
24
 
25
25
  class MetaDatum(tuple, metaclass=type):
26
+ """
27
+ MetaDatum(field, value, type, tags)
28
+ """
26
29
  @staticmethod
27
30
  def __new__(_cls, field, value, type, tags):
28
31
  """
@@ -44,6 +47,9 @@ class MetaDatum(tuple, metaclass=type):
44
47
  current: metaflow.metaflow_current.Current
45
48
 
46
49
  class Parallel(tuple, metaclass=type):
50
+ """
51
+ Parallel(main_ip, num_nodes, node_index, control_task_id)
52
+ """
47
53
  @staticmethod
48
54
  def __new__(_cls, main_ip, num_nodes, node_index, control_task_id):
49
55
  """
@@ -63,6 +69,27 @@ class Parallel(tuple, metaclass=type):
63
69
  ...
64
70
 
65
71
  class ParallelDecorator(metaflow.decorators.StepDecorator, metaclass=type):
72
+ """
73
+ MF Add To Current
74
+ -----------------
75
+ parallel -> metaflow.metaflow_current.Parallel
76
+
77
+ @@ Returns
78
+ -------
79
+ Parallel
80
+ `namedtuple` with the following fields:
81
+ - main_ip : str
82
+ The IP address of the control task.
83
+ - num_nodes : int
84
+ The total number of tasks created by @parallel
85
+ - node_index : int
86
+ The index of the current task in all the @parallel tasks.
87
+ - control_task_id : Optional[str]
88
+ The task ID of the control task. Available to all tasks.
89
+
90
+ is_parallel -> bool
91
+ True if the current step is a @parallel step.
92
+ """
66
93
  def __init__(self, attributes = None, statically_defined = False):
67
94
  ...
68
95
  def runtime_step_cli(self, cli_args, retry_count, max_user_code_retries, ubf_context):
@@ -1,7 +1,7 @@
1
1
  ##################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.22.1+obcheckpoint(0.0.11);ob(v1) #
4
- # Generated on 2024-09-20T21:46:07.327811 #
3
+ # MF version: 2.12.24.1+obcheckpoint(0.0.11);ob(v1) #
4
+ # Generated on 2024-10-04T10:13:10.625071 #
5
5
  ##################################################################################
6
6
 
7
7
  from __future__ import annotations
@@ -1,15 +1,15 @@
1
1
  ##################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.22.1+obcheckpoint(0.0.11);ob(v1) #
4
- # Generated on 2024-09-20T21:46:07.374489 #
3
+ # MF version: 2.12.24.1+obcheckpoint(0.0.11);ob(v1) #
4
+ # Generated on 2024-10-04T10:13:10.673074 #
5
5
  ##################################################################################
6
6
 
7
7
  from __future__ import annotations
8
8
 
9
9
  import typing
10
10
  if typing.TYPE_CHECKING:
11
- import metaflow.decorators
12
11
  import metaflow.metaflow_current
12
+ import metaflow.decorators
13
13
 
14
14
  class MetaflowException(Exception, metaclass=type):
15
15
  def __init__(self, msg = "", lineno = None):
@@ -25,6 +25,63 @@ VALID_NAME_RE: str
25
25
  VALID_NAME_LEN: int
26
26
 
27
27
  class ProjectDecorator(metaflow.decorators.FlowDecorator, metaclass=type):
28
+ """
29
+ Specifies what flows belong to the same project.
30
+
31
+ A project-specific namespace is created for all flows that
32
+ use the same `@project(name)`.
33
+
34
+ Parameters
35
+ ----------
36
+ name : str
37
+ Project name. Make sure that the name is unique amongst all
38
+ projects that use the same production scheduler. The name may
39
+ contain only lowercase alphanumeric characters and underscores.
40
+
41
+ MF Add To Current
42
+ -----------------
43
+ project_name -> str
44
+ The name of the project assigned to this flow, i.e. `X` in `@project(name=X)`.
45
+
46
+ @@ Returns
47
+ -------
48
+ str
49
+ Project name.
50
+
51
+ project_flow_name -> str
52
+ The flow name prefixed with the current project and branch. This name identifies
53
+ the deployment on a production scheduler.
54
+
55
+ @@ Returns
56
+ -------
57
+ str
58
+ Flow name prefixed with project information.
59
+
60
+ branch_name -> str
61
+ The current branch, i.e. `X` in `--branch=X` set during deployment or run.
62
+
63
+ @@ Returns
64
+ -------
65
+ str
66
+ Branch name.
67
+
68
+ is_user_branch -> bool
69
+ True if the flow is deployed without a specific `--branch` or a `--production`
70
+ flag.
71
+
72
+ @@ Returns
73
+ -------
74
+ bool
75
+ True if the deployment does not correspond to a specific branch.
76
+
77
+ is_production -> bool
78
+ True if the flow is deployed with the `--production` flag
79
+
80
+ @@ Returns
81
+ -------
82
+ bool
83
+ True if the flow is deployed with `--production`.
84
+ """
28
85
  def flow_init(self, flow, graph, environment, flow_datastore, metadata, logger, echo, options):
29
86
  ...
30
87
  def get_top_level_options(self):
@@ -1,7 +1,7 @@
1
1
  ##################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.22.1+obcheckpoint(0.0.11);ob(v1) #
4
- # Generated on 2024-09-20T21:46:07.371108 #
3
+ # MF version: 2.12.24.1+obcheckpoint(0.0.11);ob(v1) #
4
+ # Generated on 2024-10-04T10:13:10.667586 #
5
5
  ##################################################################################
6
6
 
7
7
  from __future__ import annotations
@@ -1,7 +1,7 @@
1
1
  ##################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.22.1+obcheckpoint(0.0.11);ob(v1) #
4
- # Generated on 2024-09-20T21:46:07.391660 #
3
+ # MF version: 2.12.24.1+obcheckpoint(0.0.11);ob(v1) #
4
+ # Generated on 2024-10-04T10:13:10.682646 #
5
5
  ##################################################################################
6
6
 
7
7
  from __future__ import annotations
@@ -13,6 +13,9 @@ if typing.TYPE_CHECKING:
13
13
  EXT_PKG: str
14
14
 
15
15
  class MetaDatum(tuple, metaclass=type):
16
+ """
17
+ MetaDatum(field, value, type, tags)
18
+ """
16
19
  @staticmethod
17
20
  def __new__(_cls, field, value, type, tags):
18
21
  """
@@ -34,6 +37,27 @@ class MetaDatum(tuple, metaclass=type):
34
37
  INFO_FILE: str
35
38
 
36
39
  class CondaStepDecorator(metaflow.decorators.StepDecorator, metaclass=type):
40
+ """
41
+ Specifies the Conda environment for the step.
42
+
43
+ Information in this decorator will augment any
44
+ attributes set in the `@conda_base` flow-level decorator. Hence,
45
+ you can use `@conda_base` to set packages required by all
46
+ steps and use `@conda` to specify step-specific overrides.
47
+
48
+ Parameters
49
+ ----------
50
+ packages : Dict[str, str], default {}
51
+ Packages to use for this step. The key is the name of the package
52
+ and the value is the version to use.
53
+ libraries : Dict[str, str], default {}
54
+ Supported for backward compatibility. When used with packages, packages will take precedence.
55
+ python : str, optional, default None
56
+ Version of Python to use, e.g. '3.7.4'. A default value of None implies
57
+ that the version used will correspond to the version of the Python interpreter used to start the run.
58
+ disabled : bool, default False
59
+ If set to True, disables @conda.
60
+ """
37
61
  def __init__(self, attributes = None, statically_defined = False):
38
62
  ...
39
63
  def is_attribute_user_defined(self, name):
@@ -53,6 +77,25 @@ class CondaStepDecorator(metaflow.decorators.StepDecorator, metaclass=type):
53
77
  ...
54
78
 
55
79
  class CondaFlowDecorator(metaflow.decorators.FlowDecorator, metaclass=type):
80
+ """
81
+ Specifies the Conda environment for all steps of the flow.
82
+
83
+ Use `@conda_base` to set common libraries required by all
84
+ steps and use `@conda` to specify step-specific additions.
85
+
86
+ Parameters
87
+ ----------
88
+ packages : Dict[str, str], default {}
89
+ Packages to use for this flow. The key is the name of the package
90
+ and the value is the version to use.
91
+ libraries : Dict[str, str], default {}
92
+ Supported for backward compatibility. When used with packages, packages will take precedence.
93
+ python : str, optional, default None
94
+ Version of Python to use, e.g. '3.7.4'. A default value of None implies
95
+ that the version used will correspond to the version of the Python interpreter used to start the run.
96
+ disabled : bool, default False
97
+ If set to True, disables Conda.
98
+ """
56
99
  def __init__(self, attributes = None, statically_defined = False):
57
100
  ...
58
101
  def is_attribute_user_defined(self, name):
@@ -1,17 +1,17 @@
1
1
  ##################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.22.1+obcheckpoint(0.0.11);ob(v1) #
4
- # Generated on 2024-09-20T21:46:07.393035 #
3
+ # MF version: 2.12.24.1+obcheckpoint(0.0.11);ob(v1) #
4
+ # Generated on 2024-10-04T10:13:10.683719 #
5
5
  ##################################################################################
6
6
 
7
7
  from __future__ import annotations
8
8
 
9
9
  import typing
10
10
  if typing.TYPE_CHECKING:
11
- import abc
12
- import metaflow.exception
13
- import metaflow.metaflow_environment
14
11
  import io
12
+ import metaflow.metaflow_environment
13
+ import metaflow.exception
14
+ import abc
15
15
 
16
16
  class MetaflowException(Exception, metaclass=type):
17
17
  def __init__(self, msg = "", lineno = None):
@@ -1,7 +1,7 @@
1
1
  ##################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.22.1+obcheckpoint(0.0.11);ob(v1) #
4
- # Generated on 2024-09-20T21:46:07.391960 #
3
+ # MF version: 2.12.24.1+obcheckpoint(0.0.11);ob(v1) #
4
+ # Generated on 2024-10-04T10:13:10.682057 #
5
5
  ##################################################################################
6
6
 
7
7
  from __future__ import annotations
@@ -11,6 +11,23 @@ if typing.TYPE_CHECKING:
11
11
  import metaflow.decorators
12
12
 
13
13
  class PyPIStepDecorator(metaflow.decorators.StepDecorator, metaclass=type):
14
+ """
15
+ Specifies the PyPI packages for the step.
16
+
17
+ Information in this decorator will augment any
18
+ attributes set in the `@pyi_base` flow-level decorator. Hence,
19
+ you can use `@pypi_base` to set packages required by all
20
+ steps and use `@pypi` to specify step-specific overrides.
21
+
22
+ Parameters
23
+ ----------
24
+ packages : Dict[str, str], default: {}
25
+ Packages to use for this step. The key is the name of the package
26
+ and the value is the version to use.
27
+ python : str, optional, default: None
28
+ Version of Python to use, e.g. '3.7.4'. A default value of None implies
29
+ that the version used will correspond to the version of the Python interpreter used to start the run.
30
+ """
14
31
  def __init__(self, attributes = None, statically_defined = False):
15
32
  ...
16
33
  def step_init(self, flow, graph, step, decos, environment, flow_datastore, logger):
@@ -20,6 +37,20 @@ class PyPIStepDecorator(metaflow.decorators.StepDecorator, metaclass=type):
20
37
  ...
21
38
 
22
39
  class PyPIFlowDecorator(metaflow.decorators.FlowDecorator, metaclass=type):
40
+ """
41
+ Specifies the PyPI packages for all steps of the flow.
42
+
43
+ Use `@pypi_base` to set common packages required by all
44
+ steps and use `@pypi` to specify step-specific overrides.
45
+ Parameters
46
+ ----------
47
+ packages : Dict[str, str], default: {}
48
+ Packages to use for this flow. The key is the name of the package
49
+ and the value is the version to use.
50
+ python : str, optional, default: None
51
+ Version of Python to use, e.g. '3.7.4'. A default value of None implies
52
+ that the version used will correspond to the version of the Python interpreter used to start the run.
53
+ """
23
54
  def __init__(self, attributes = None, statically_defined = False):
24
55
  ...
25
56
  def flow_init(self, flow, graph, environment, flow_datastore, metadata, logger, echo, options):
@@ -1,7 +1,7 @@
1
1
  ##################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.22.1+obcheckpoint(0.0.11);ob(v1) #
4
- # Generated on 2024-09-20T21:46:07.393443 #
3
+ # MF version: 2.12.24.1+obcheckpoint(0.0.11);ob(v1) #
4
+ # Generated on 2024-10-04T10:13:10.684138 #
5
5
  ##################################################################################
6
6
 
7
7
  from __future__ import annotations
@@ -1,7 +1,7 @@
1
1
  ##################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.22.1+obcheckpoint(0.0.11);ob(v1) #
4
- # Generated on 2024-09-20T21:46:07.392268 #
3
+ # MF version: 2.12.24.1+obcheckpoint(0.0.11);ob(v1) #
4
+ # Generated on 2024-10-04T10:13:10.682954 #
5
5
  ##################################################################################
6
6
 
7
7
  from __future__ import annotations