ob-metaflow-stubs 6.0.3.123__py2.py3-none-any.whl → 6.0.3.125__py2.py3-none-any.whl
Sign up to get free protection for your applications and to get access to all the features.
- metaflow-stubs/__init__.pyi +211 -210
- metaflow-stubs/cards.pyi +2 -2
- metaflow-stubs/cli.pyi +2 -2
- metaflow-stubs/client/__init__.pyi +2 -2
- metaflow-stubs/client/core.pyi +5 -5
- metaflow-stubs/client/filecache.pyi +3 -3
- metaflow-stubs/clone_util.pyi +2 -2
- metaflow-stubs/events.pyi +2 -2
- metaflow-stubs/exception.pyi +2 -2
- metaflow-stubs/flowspec.pyi +6 -6
- metaflow-stubs/generated_for.txt +1 -1
- metaflow-stubs/includefile.pyi +4 -4
- metaflow-stubs/info_file.pyi +2 -2
- metaflow-stubs/metadata_provider/__init__.pyi +2 -2
- metaflow-stubs/metadata_provider/heartbeat.pyi +2 -2
- metaflow-stubs/metadata_provider/metadata.pyi +2 -2
- metaflow-stubs/metadata_provider/util.pyi +2 -2
- metaflow-stubs/metaflow_config.pyi +2 -2
- metaflow-stubs/metaflow_current.pyi +135 -135
- metaflow-stubs/mf_extensions/__init__.pyi +2 -2
- metaflow-stubs/mf_extensions/obcheckpoint/__init__.pyi +2 -2
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/__init__.pyi +2 -2
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/__init__.pyi +2 -2
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/checkpoints/__init__.pyi +2 -2
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/checkpoints/checkpoint_storage.pyi +4 -4
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/checkpoints/constructors.pyi +2 -2
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/checkpoints/core.pyi +4 -4
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/checkpoints/exceptions.pyi +2 -2
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/checkpoints/final_api.pyi +3 -3
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/datastore/__init__.pyi +2 -2
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/datastore/core.pyi +3 -3
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/datastore/exceptions.pyi +2 -2
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/datastore/task_utils.pyi +4 -4
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/datastore/utils.pyi +2 -2
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/datastructures.pyi +3 -3
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/exceptions.pyi +2 -2
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/utils/__init__.pyi +2 -2
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/utils/flowspec_utils.pyi +2 -2
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/utils/general.pyi +2 -2
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/utils/identity_utils.pyi +3 -3
- metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/utils/tar_utils.pyi +3 -3
- metaflow-stubs/mf_extensions/outerbounds/__init__.pyi +2 -2
- metaflow-stubs/mf_extensions/outerbounds/plugins/__init__.pyi +6 -0
- metaflow-stubs/mf_extensions/outerbounds/plugins/snowflake/__init__.pyi +6 -0
- metaflow-stubs/mf_extensions/outerbounds/plugins/snowflake/snowflake.pyi +92 -0
- metaflow-stubs/mf_extensions/outerbounds/profilers/__init__.pyi +2 -2
- metaflow-stubs/mf_extensions/outerbounds/profilers/gpu.pyi +2 -2
- metaflow-stubs/mf_extensions/outerbounds/remote_config.pyi +2 -2
- metaflow-stubs/mf_extensions/outerbounds/toplevel/__init__.pyi +2 -2
- metaflow-stubs/mf_extensions/outerbounds/toplevel/global_aliases_for_metaflow_package.pyi +3 -2
- metaflow-stubs/mflog/__init__.pyi +2 -2
- metaflow-stubs/mflog/mflog.pyi +2 -2
- metaflow-stubs/multicore_utils.pyi +2 -2
- metaflow-stubs/parameters.pyi +4 -4
- metaflow-stubs/plugins/__init__.pyi +11 -10
- metaflow-stubs/plugins/airflow/__init__.pyi +2 -2
- metaflow-stubs/plugins/airflow/airflow_utils.pyi +2 -2
- metaflow-stubs/plugins/airflow/exception.pyi +2 -2
- metaflow-stubs/plugins/airflow/sensors/__init__.pyi +2 -2
- metaflow-stubs/plugins/airflow/sensors/base_sensor.pyi +2 -2
- metaflow-stubs/plugins/airflow/sensors/external_task_sensor.pyi +2 -2
- metaflow-stubs/plugins/airflow/sensors/s3_sensor.pyi +2 -2
- metaflow-stubs/plugins/argo/__init__.pyi +2 -2
- metaflow-stubs/plugins/argo/argo_client.pyi +2 -2
- metaflow-stubs/plugins/argo/argo_events.pyi +2 -2
- metaflow-stubs/plugins/argo/argo_workflows.pyi +3 -3
- metaflow-stubs/plugins/argo/argo_workflows_cli.pyi +2 -2
- metaflow-stubs/plugins/argo/argo_workflows_decorator.pyi +3 -3
- metaflow-stubs/plugins/argo/argo_workflows_deployer.pyi +4 -4
- metaflow-stubs/plugins/argo/argo_workflows_deployer_objects.pyi +4 -4
- metaflow-stubs/plugins/aws/__init__.pyi +2 -2
- metaflow-stubs/plugins/aws/aws_client.pyi +2 -2
- metaflow-stubs/plugins/aws/aws_utils.pyi +2 -2
- metaflow-stubs/plugins/aws/batch/__init__.pyi +2 -2
- metaflow-stubs/plugins/aws/batch/batch.pyi +2 -2
- metaflow-stubs/plugins/aws/batch/batch_client.pyi +2 -2
- metaflow-stubs/plugins/aws/batch/batch_decorator.pyi +2 -2
- metaflow-stubs/plugins/aws/secrets_manager/__init__.pyi +2 -2
- metaflow-stubs/plugins/aws/secrets_manager/aws_secrets_manager_secrets_provider.pyi +3 -3
- metaflow-stubs/plugins/aws/step_functions/__init__.pyi +2 -2
- metaflow-stubs/plugins/aws/step_functions/event_bridge_client.pyi +2 -2
- metaflow-stubs/plugins/aws/step_functions/production_token.pyi +2 -2
- metaflow-stubs/plugins/aws/step_functions/schedule_decorator.pyi +2 -2
- metaflow-stubs/plugins/aws/step_functions/step_functions.pyi +2 -2
- metaflow-stubs/plugins/aws/step_functions/step_functions_client.pyi +2 -2
- metaflow-stubs/plugins/aws/step_functions/step_functions_deployer.pyi +4 -4
- metaflow-stubs/plugins/aws/step_functions/step_functions_deployer_objects.pyi +4 -4
- metaflow-stubs/plugins/azure/__init__.pyi +2 -2
- metaflow-stubs/plugins/azure/azure_credential.pyi +2 -2
- metaflow-stubs/plugins/azure/azure_exceptions.pyi +2 -2
- metaflow-stubs/plugins/azure/azure_secret_manager_secrets_provider.pyi +3 -3
- metaflow-stubs/plugins/azure/azure_utils.pyi +2 -2
- metaflow-stubs/plugins/azure/blob_service_client_factory.pyi +2 -2
- metaflow-stubs/plugins/azure/includefile_support.pyi +2 -2
- metaflow-stubs/plugins/cards/__init__.pyi +2 -2
- metaflow-stubs/plugins/cards/card_cli.pyi +2 -2
- metaflow-stubs/plugins/cards/card_client.pyi +2 -2
- metaflow-stubs/plugins/cards/card_creator.pyi +2 -2
- metaflow-stubs/plugins/cards/card_datastore.pyi +2 -2
- metaflow-stubs/plugins/cards/card_decorator.pyi +2 -2
- metaflow-stubs/plugins/cards/card_modules/__init__.pyi +2 -2
- metaflow-stubs/plugins/cards/card_modules/basic.pyi +3 -3
- metaflow-stubs/plugins/cards/card_modules/card.pyi +2 -2
- metaflow-stubs/plugins/cards/card_modules/components.pyi +4 -4
- metaflow-stubs/plugins/cards/card_modules/convert_to_native_type.pyi +2 -2
- metaflow-stubs/plugins/cards/card_modules/renderer_tools.pyi +2 -2
- metaflow-stubs/plugins/cards/card_modules/test_cards.pyi +2 -2
- metaflow-stubs/plugins/cards/card_resolver.pyi +2 -2
- metaflow-stubs/plugins/cards/component_serializer.pyi +2 -2
- metaflow-stubs/plugins/cards/exception.pyi +2 -2
- metaflow-stubs/plugins/catch_decorator.pyi +3 -3
- metaflow-stubs/plugins/datatools/__init__.pyi +2 -2
- metaflow-stubs/plugins/datatools/local.pyi +2 -2
- metaflow-stubs/plugins/datatools/s3/__init__.pyi +2 -2
- metaflow-stubs/plugins/datatools/s3/s3.pyi +5 -5
- metaflow-stubs/plugins/datatools/s3/s3tail.pyi +2 -2
- metaflow-stubs/plugins/datatools/s3/s3util.pyi +2 -2
- metaflow-stubs/plugins/debug_logger.pyi +2 -2
- metaflow-stubs/plugins/debug_monitor.pyi +2 -2
- metaflow-stubs/plugins/environment_decorator.pyi +2 -2
- metaflow-stubs/plugins/events_decorator.pyi +2 -2
- metaflow-stubs/plugins/frameworks/__init__.pyi +2 -2
- metaflow-stubs/plugins/frameworks/pytorch.pyi +2 -2
- metaflow-stubs/plugins/gcp/__init__.pyi +2 -2
- metaflow-stubs/plugins/gcp/gcp_secret_manager_secrets_provider.pyi +3 -3
- metaflow-stubs/plugins/gcp/gs_exceptions.pyi +2 -2
- metaflow-stubs/plugins/gcp/gs_storage_client_factory.pyi +2 -2
- metaflow-stubs/plugins/gcp/gs_utils.pyi +2 -2
- metaflow-stubs/plugins/gcp/includefile_support.pyi +2 -2
- metaflow-stubs/plugins/kubernetes/__init__.pyi +2 -2
- metaflow-stubs/plugins/kubernetes/kube_utils.pyi +2 -2
- metaflow-stubs/plugins/kubernetes/kubernetes.pyi +3 -3
- metaflow-stubs/plugins/kubernetes/kubernetes_cli.pyi +2 -2
- metaflow-stubs/plugins/kubernetes/kubernetes_client.pyi +2 -2
- metaflow-stubs/plugins/kubernetes/kubernetes_decorator.pyi +2 -2
- metaflow-stubs/plugins/kubernetes/kubernetes_jobsets.pyi +2 -2
- metaflow-stubs/plugins/logs_cli.pyi +2 -2
- metaflow-stubs/plugins/package_cli.pyi +2 -2
- metaflow-stubs/plugins/parallel_decorator.pyi +2 -2
- metaflow-stubs/plugins/perimeters.pyi +2 -2
- metaflow-stubs/plugins/project_decorator.pyi +2 -2
- metaflow-stubs/plugins/pypi/__init__.pyi +3 -3
- metaflow-stubs/plugins/pypi/conda_decorator.pyi +2 -2
- metaflow-stubs/plugins/pypi/conda_environment.pyi +5 -5
- metaflow-stubs/plugins/pypi/pypi_decorator.pyi +2 -2
- metaflow-stubs/plugins/pypi/pypi_environment.pyi +2 -2
- metaflow-stubs/plugins/pypi/utils.pyi +2 -2
- metaflow-stubs/plugins/resources_decorator.pyi +2 -2
- metaflow-stubs/plugins/retry_decorator.pyi +2 -2
- metaflow-stubs/plugins/secrets/__init__.pyi +2 -2
- metaflow-stubs/plugins/secrets/inline_secrets_provider.pyi +2 -2
- metaflow-stubs/plugins/secrets/secrets_decorator.pyi +2 -2
- metaflow-stubs/plugins/snowflake/__init__.pyi +14 -0
- metaflow-stubs/plugins/storage_executor.pyi +2 -2
- metaflow-stubs/plugins/tag_cli.pyi +2 -2
- metaflow-stubs/plugins/test_unbounded_foreach_decorator.pyi +3 -3
- metaflow-stubs/plugins/timeout_decorator.pyi +3 -3
- metaflow-stubs/procpoll.pyi +2 -2
- metaflow-stubs/profilers/__init__.pyi +2 -2
- metaflow-stubs/pylint_wrapper.pyi +2 -2
- metaflow-stubs/runner/__init__.pyi +2 -2
- metaflow-stubs/runner/deployer.pyi +5 -5
- metaflow-stubs/runner/deployer_impl.pyi +3 -3
- metaflow-stubs/runner/metaflow_runner.pyi +3 -3
- metaflow-stubs/runner/nbdeploy.pyi +2 -2
- metaflow-stubs/runner/nbrun.pyi +2 -2
- metaflow-stubs/runner/subprocess_manager.pyi +2 -2
- metaflow-stubs/runner/utils.pyi +3 -3
- metaflow-stubs/system/__init__.pyi +2 -2
- metaflow-stubs/system/system_logger.pyi +3 -3
- metaflow-stubs/system/system_monitor.pyi +2 -2
- metaflow-stubs/tagging_util.pyi +2 -2
- metaflow-stubs/tuple_util.pyi +2 -2
- {ob_metaflow_stubs-6.0.3.123.dist-info → ob_metaflow_stubs-6.0.3.125.dist-info}/METADATA +1 -1
- ob_metaflow_stubs-6.0.3.125.dist-info/RECORD +178 -0
- ob_metaflow_stubs-6.0.3.123.dist-info/RECORD +0 -174
- {ob_metaflow_stubs-6.0.3.123.dist-info → ob_metaflow_stubs-6.0.3.125.dist-info}/WHEEL +0 -0
- {ob_metaflow_stubs-6.0.3.123.dist-info → ob_metaflow_stubs-6.0.3.125.dist-info}/top_level.txt +0 -0
metaflow-stubs/__init__.pyi
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
######################################################################################################
|
2
2
|
# Auto-generated Metaflow stub file #
|
3
|
-
# MF version: 2.12.36.
|
4
|
-
# Generated on 2024-12-
|
3
|
+
# MF version: 2.12.36.3+obcheckpoint(0.1.4);ob(v1) #
|
4
|
+
# Generated on 2024-12-10T22:06:22.196386 #
|
5
5
|
######################################################################################################
|
6
6
|
|
7
7
|
from __future__ import annotations
|
8
8
|
|
9
9
|
import typing
|
10
10
|
if typing.TYPE_CHECKING:
|
11
|
-
import typing
|
12
11
|
import datetime
|
12
|
+
import typing
|
13
13
|
FlowSpecDerived = typing.TypeVar("FlowSpecDerived", bound="FlowSpec", contravariant=False, covariant=False)
|
14
14
|
StepFlag = typing.NewType("StepFlag", bool)
|
15
15
|
|
@@ -58,6 +58,7 @@ from .runner.nbdeploy import NBDeployer as NBDeployer
|
|
58
58
|
from .mf_extensions.obcheckpoint.plugins.machine_learning_utilities.checkpoints.final_api import Checkpoint as Checkpoint
|
59
59
|
from .mf_extensions.obcheckpoint.plugins.machine_learning_utilities.datastructures import load_model as load_model
|
60
60
|
from .mf_extensions.outerbounds.toplevel.global_aliases_for_metaflow_package import get_aws_client as get_aws_client
|
61
|
+
from .mf_extensions.outerbounds.plugins.snowflake.snowflake import Snowflake as Snowflake
|
61
62
|
from . import system as system
|
62
63
|
from . import pylint_wrapper as pylint_wrapper
|
63
64
|
from . import procpoll as procpoll
|
@@ -140,82 +141,142 @@ def step(f: typing.Union[typing.Callable[[FlowSpecDerived], None], typing.Callab
|
|
140
141
|
"""
|
141
142
|
...
|
142
143
|
|
143
|
-
|
144
|
+
@typing.overload
|
145
|
+
def fast_bakery_internal(f: typing.Callable[[FlowSpecDerived, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, StepFlag], None]:
|
144
146
|
"""
|
145
|
-
|
147
|
+
Internal decorator to support Fast bakery
|
146
148
|
"""
|
147
149
|
...
|
148
150
|
|
149
151
|
@typing.overload
|
150
|
-
def
|
152
|
+
def fast_bakery_internal(f: typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]:
|
153
|
+
...
|
154
|
+
|
155
|
+
def fast_bakery_internal(f: typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None], None] = None):
|
151
156
|
"""
|
152
|
-
|
157
|
+
Internal decorator to support Fast bakery
|
153
158
|
"""
|
154
159
|
...
|
155
160
|
|
156
161
|
@typing.overload
|
157
|
-
def
|
162
|
+
def environment(*, vars: typing.Dict[str, str] = {}) -> typing.Callable[[typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]], typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]]:
|
163
|
+
"""
|
164
|
+
Specifies environment variables to be set prior to the execution of a step.
|
165
|
+
"""
|
158
166
|
...
|
159
167
|
|
160
168
|
@typing.overload
|
161
|
-
def
|
169
|
+
def environment(f: typing.Callable[[FlowSpecDerived, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, StepFlag], None]:
|
162
170
|
...
|
163
171
|
|
164
|
-
|
172
|
+
@typing.overload
|
173
|
+
def environment(f: typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]:
|
174
|
+
...
|
175
|
+
|
176
|
+
def environment(f: typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None], None] = None, *, vars: typing.Dict[str, str] = {}):
|
165
177
|
"""
|
166
|
-
|
178
|
+
Specifies environment variables to be set prior to the execution of a step.
|
167
179
|
"""
|
168
180
|
...
|
169
181
|
|
170
182
|
@typing.overload
|
171
|
-
def
|
183
|
+
def resources(*, cpu: int = 1, gpu: typing.Optional[int] = None, disk: typing.Optional[int] = None, memory: int = 4096, shared_memory: typing.Optional[int] = None) -> typing.Callable[[typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]], typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]]:
|
172
184
|
"""
|
173
|
-
Specifies the
|
185
|
+
Specifies the resources needed when executing this step.
|
174
186
|
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
187
|
+
Use `@resources` to specify the resource requirements
|
188
|
+
independently of the specific compute layer (`@batch`, `@kubernetes`).
|
189
|
+
|
190
|
+
You can choose the compute layer on the command line by executing e.g.
|
191
|
+
```
|
192
|
+
python myflow.py run --with batch
|
193
|
+
```
|
194
|
+
or
|
195
|
+
```
|
196
|
+
python myflow.py run --with kubernetes
|
197
|
+
```
|
198
|
+
which executes the flow on the desired system using the
|
199
|
+
requirements specified in `@resources`.
|
179
200
|
"""
|
180
201
|
...
|
181
202
|
|
182
203
|
@typing.overload
|
183
|
-
def
|
204
|
+
def resources(f: typing.Callable[[FlowSpecDerived, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, StepFlag], None]:
|
184
205
|
...
|
185
206
|
|
186
207
|
@typing.overload
|
187
|
-
def
|
208
|
+
def resources(f: typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]:
|
188
209
|
...
|
189
210
|
|
190
|
-
def
|
211
|
+
def resources(f: typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None], None] = None, *, cpu: int = 1, gpu: typing.Optional[int] = None, disk: typing.Optional[int] = None, memory: int = 4096, shared_memory: typing.Optional[int] = None):
|
191
212
|
"""
|
192
|
-
Specifies the
|
213
|
+
Specifies the resources needed when executing this step.
|
193
214
|
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
215
|
+
Use `@resources` to specify the resource requirements
|
216
|
+
independently of the specific compute layer (`@batch`, `@kubernetes`).
|
217
|
+
|
218
|
+
You can choose the compute layer on the command line by executing e.g.
|
219
|
+
```
|
220
|
+
python myflow.py run --with batch
|
221
|
+
```
|
222
|
+
or
|
223
|
+
```
|
224
|
+
python myflow.py run --with kubernetes
|
225
|
+
```
|
226
|
+
which executes the flow on the desired system using the
|
227
|
+
requirements specified in `@resources`.
|
198
228
|
"""
|
199
229
|
...
|
200
230
|
|
201
231
|
@typing.overload
|
202
|
-
def
|
232
|
+
def catch(*, var: typing.Optional[str] = None, print_exception: bool = True) -> typing.Callable[[typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]], typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]]:
|
203
233
|
"""
|
204
|
-
Specifies
|
234
|
+
Specifies that the step will success under all circumstances.
|
235
|
+
|
236
|
+
The decorator will create an optional artifact, specified by `var`, which
|
237
|
+
contains the exception raised. You can use it to detect the presence
|
238
|
+
of errors, indicating that all happy-path artifacts produced by the step
|
239
|
+
are missing.
|
205
240
|
"""
|
206
241
|
...
|
207
242
|
|
208
243
|
@typing.overload
|
209
|
-
def
|
244
|
+
def catch(f: typing.Callable[[FlowSpecDerived, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, StepFlag], None]:
|
210
245
|
...
|
211
246
|
|
212
247
|
@typing.overload
|
213
|
-
def
|
248
|
+
def catch(f: typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]:
|
214
249
|
...
|
215
250
|
|
216
|
-
def
|
251
|
+
def catch(f: typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None], None] = None, *, var: typing.Optional[str] = None, print_exception: bool = True):
|
217
252
|
"""
|
218
|
-
Specifies
|
253
|
+
Specifies that the step will success under all circumstances.
|
254
|
+
|
255
|
+
The decorator will create an optional artifact, specified by `var`, which
|
256
|
+
contains the exception raised. You can use it to detect the presence
|
257
|
+
of errors, indicating that all happy-path artifacts produced by the step
|
258
|
+
are missing.
|
259
|
+
"""
|
260
|
+
...
|
261
|
+
|
262
|
+
@typing.overload
|
263
|
+
def model(*, load: typing.Union[typing.List[str], str, typing.List[typing.Tuple[str, typing.Optional[str]]]] = None, temp_dir_root: str = None) -> typing.Callable[[typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]], typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]]:
|
264
|
+
"""
|
265
|
+
Enables loading / saving of models within a step.
|
266
|
+
"""
|
267
|
+
...
|
268
|
+
|
269
|
+
@typing.overload
|
270
|
+
def model(f: typing.Callable[[FlowSpecDerived, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, StepFlag], None]:
|
271
|
+
...
|
272
|
+
|
273
|
+
@typing.overload
|
274
|
+
def model(f: typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]:
|
275
|
+
...
|
276
|
+
|
277
|
+
def model(f: typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None], None] = None, *, load: typing.Union[typing.List[str], str, typing.List[typing.Tuple[str, typing.Optional[str]]]] = None, temp_dir_root: str = None):
|
278
|
+
"""
|
279
|
+
Enables loading / saving of models within a step.
|
219
280
|
"""
|
220
281
|
...
|
221
282
|
|
@@ -250,83 +311,59 @@ def pypi(f: typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typ
|
|
250
311
|
"""
|
251
312
|
...
|
252
313
|
|
253
|
-
def huggingface_hub(*, temp_dir_root: typing.Optional[str] = None, load: typing.Union[typing.List[str], typing.List[typing.Tuple[typing.Dict, str]], typing.List[typing.Tuple[str, str]], typing.List[typing.Dict], None]) -> typing.Callable[[typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]], typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]]:
|
254
|
-
"""
|
255
|
-
Decorator that helps cache, version and store models/datasets from huggingface hub.
|
256
|
-
"""
|
257
|
-
...
|
258
|
-
|
259
314
|
@typing.overload
|
260
|
-
def
|
315
|
+
def conda(*, packages: typing.Dict[str, str] = {}, libraries: typing.Dict[str, str] = {}, python: typing.Optional[str] = None, disabled: bool = False) -> typing.Callable[[typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]], typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]]:
|
261
316
|
"""
|
262
|
-
|
317
|
+
Specifies the Conda environment for the step.
|
263
318
|
|
264
|
-
|
319
|
+
Information in this decorator will augment any
|
320
|
+
attributes set in the `@conda_base` flow-level decorator. Hence,
|
321
|
+
you can use `@conda_base` to set packages required by all
|
322
|
+
steps and use `@conda` to specify step-specific overrides.
|
265
323
|
"""
|
266
324
|
...
|
267
325
|
|
268
326
|
@typing.overload
|
269
|
-
def
|
327
|
+
def conda(f: typing.Callable[[FlowSpecDerived, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, StepFlag], None]:
|
270
328
|
...
|
271
329
|
|
272
330
|
@typing.overload
|
273
|
-
def
|
331
|
+
def conda(f: typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]:
|
274
332
|
...
|
275
333
|
|
276
|
-
def
|
334
|
+
def conda(f: typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None], None] = None, *, packages: typing.Dict[str, str] = {}, libraries: typing.Dict[str, str] = {}, python: typing.Optional[str] = None, disabled: bool = False):
|
277
335
|
"""
|
278
|
-
|
336
|
+
Specifies the Conda environment for the step.
|
279
337
|
|
280
|
-
|
338
|
+
Information in this decorator will augment any
|
339
|
+
attributes set in the `@conda_base` flow-level decorator. Hence,
|
340
|
+
you can use `@conda_base` to set packages required by all
|
341
|
+
steps and use `@conda` to specify step-specific overrides.
|
281
342
|
"""
|
282
343
|
...
|
283
344
|
|
284
345
|
@typing.overload
|
285
|
-
def
|
346
|
+
def card(*, type: str = 'default', id: typing.Optional[str] = None, options: typing.Dict[str, typing.Any] = {}, timeout: int = 45) -> typing.Callable[[typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]], typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]]:
|
286
347
|
"""
|
287
|
-
|
288
|
-
|
289
|
-
Use `@resources` to specify the resource requirements
|
290
|
-
independently of the specific compute layer (`@batch`, `@kubernetes`).
|
348
|
+
Creates a human-readable report, a Metaflow Card, after this step completes.
|
291
349
|
|
292
|
-
|
293
|
-
```
|
294
|
-
python myflow.py run --with batch
|
295
|
-
```
|
296
|
-
or
|
297
|
-
```
|
298
|
-
python myflow.py run --with kubernetes
|
299
|
-
```
|
300
|
-
which executes the flow on the desired system using the
|
301
|
-
requirements specified in `@resources`.
|
350
|
+
Note that you may add multiple `@card` decorators in a step with different parameters.
|
302
351
|
"""
|
303
352
|
...
|
304
353
|
|
305
354
|
@typing.overload
|
306
|
-
def
|
355
|
+
def card(f: typing.Callable[[FlowSpecDerived, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, StepFlag], None]:
|
307
356
|
...
|
308
357
|
|
309
358
|
@typing.overload
|
310
|
-
def
|
359
|
+
def card(f: typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]:
|
311
360
|
...
|
312
361
|
|
313
|
-
def
|
362
|
+
def card(f: typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None], None] = None, *, type: str = 'default', id: typing.Optional[str] = None, options: typing.Dict[str, typing.Any] = {}, timeout: int = 45):
|
314
363
|
"""
|
315
|
-
|
316
|
-
|
317
|
-
Use `@resources` to specify the resource requirements
|
318
|
-
independently of the specific compute layer (`@batch`, `@kubernetes`).
|
364
|
+
Creates a human-readable report, a Metaflow Card, after this step completes.
|
319
365
|
|
320
|
-
|
321
|
-
```
|
322
|
-
python myflow.py run --with batch
|
323
|
-
```
|
324
|
-
or
|
325
|
-
```
|
326
|
-
python myflow.py run --with kubernetes
|
327
|
-
```
|
328
|
-
which executes the flow on the desired system using the
|
329
|
-
requirements specified in `@resources`.
|
366
|
+
Note that you may add multiple `@card` decorators in a step with different parameters.
|
330
367
|
"""
|
331
368
|
...
|
332
369
|
|
@@ -349,37 +386,6 @@ def parallel(f: typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None],
|
|
349
386
|
"""
|
350
387
|
...
|
351
388
|
|
352
|
-
@typing.overload
|
353
|
-
def catch(*, var: typing.Optional[str] = None, print_exception: bool = True) -> typing.Callable[[typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]], typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]]:
|
354
|
-
"""
|
355
|
-
Specifies that the step will success under all circumstances.
|
356
|
-
|
357
|
-
The decorator will create an optional artifact, specified by `var`, which
|
358
|
-
contains the exception raised. You can use it to detect the presence
|
359
|
-
of errors, indicating that all happy-path artifacts produced by the step
|
360
|
-
are missing.
|
361
|
-
"""
|
362
|
-
...
|
363
|
-
|
364
|
-
@typing.overload
|
365
|
-
def catch(f: typing.Callable[[FlowSpecDerived, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, StepFlag], None]:
|
366
|
-
...
|
367
|
-
|
368
|
-
@typing.overload
|
369
|
-
def catch(f: typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]:
|
370
|
-
...
|
371
|
-
|
372
|
-
def catch(f: typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None], None] = None, *, var: typing.Optional[str] = None, print_exception: bool = True):
|
373
|
-
"""
|
374
|
-
Specifies that the step will success under all circumstances.
|
375
|
-
|
376
|
-
The decorator will create an optional artifact, specified by `var`, which
|
377
|
-
contains the exception raised. You can use it to detect the presence
|
378
|
-
of errors, indicating that all happy-path artifacts produced by the step
|
379
|
-
are missing.
|
380
|
-
"""
|
381
|
-
...
|
382
|
-
|
383
389
|
@typing.overload
|
384
390
|
def timeout(*, seconds: int = 0, minutes: int = 0, hours: int = 0) -> typing.Callable[[typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]], typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]]:
|
385
391
|
"""
|
@@ -419,6 +425,18 @@ def timeout(f: typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None],
|
|
419
425
|
"""
|
420
426
|
...
|
421
427
|
|
428
|
+
def huggingface_hub(*, temp_dir_root: typing.Optional[str] = None, load: typing.Union[typing.List[str], typing.List[typing.Tuple[typing.Dict, str]], typing.List[typing.Tuple[str, str]], typing.List[typing.Dict], None]) -> typing.Callable[[typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]], typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]]:
|
429
|
+
"""
|
430
|
+
Decorator that helps cache, version and store models/datasets from huggingface hub.
|
431
|
+
"""
|
432
|
+
...
|
433
|
+
|
434
|
+
def kubernetes(*, cpu: int = 1, memory: int = 4096, disk: int = 10240, image: typing.Optional[str] = None, image_pull_policy: str = 'KUBERNETES_IMAGE_PULL_POLICY', service_account: str = 'METAFLOW_KUBERNETES_SERVICE_ACCOUNT', secrets: typing.Optional[typing.List[str]] = None, node_selector: typing.Union[typing.Dict[str, str], str, None] = None, namespace: str = 'METAFLOW_KUBERNETES_NAMESPACE', gpu: typing.Optional[int] = None, gpu_vendor: str = 'KUBERNETES_GPU_VENDOR', tolerations: typing.List[str] = [], use_tmpfs: bool = False, tmpfs_tempdir: bool = True, tmpfs_size: typing.Optional[int] = None, tmpfs_path: typing.Optional[str] = '/metaflow_temp', persistent_volume_claims: typing.Optional[typing.Dict[str, str]] = None, shared_memory: typing.Optional[int] = None, port: typing.Optional[int] = None, compute_pool: typing.Optional[str] = None, hostname_resolution_timeout: int = 600, qos: str = 'Burstable') -> typing.Callable[[typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]], typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]]:
|
435
|
+
"""
|
436
|
+
Specifies that this step should execute on Kubernetes.
|
437
|
+
"""
|
438
|
+
...
|
439
|
+
|
422
440
|
@typing.overload
|
423
441
|
def secrets(*, sources: typing.List[typing.Union[str, typing.Dict[str, typing.Any]]] = []) -> typing.Callable[[typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]], typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]]:
|
424
442
|
"""
|
@@ -442,6 +460,27 @@ def secrets(f: typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None],
|
|
442
460
|
"""
|
443
461
|
...
|
444
462
|
|
463
|
+
@typing.overload
|
464
|
+
def checkpoint(*, load_policy: str = 'fresh', temp_dir_root: str = None) -> typing.Callable[[typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]], typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]]:
|
465
|
+
"""
|
466
|
+
Enables checkpointing for a step.
|
467
|
+
"""
|
468
|
+
...
|
469
|
+
|
470
|
+
@typing.overload
|
471
|
+
def checkpoint(f: typing.Callable[[FlowSpecDerived, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, StepFlag], None]:
|
472
|
+
...
|
473
|
+
|
474
|
+
@typing.overload
|
475
|
+
def checkpoint(f: typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]:
|
476
|
+
...
|
477
|
+
|
478
|
+
def checkpoint(f: typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None], None] = None, *, load_policy: str = 'fresh', temp_dir_root: str = None):
|
479
|
+
"""
|
480
|
+
Enables checkpointing for a step.
|
481
|
+
"""
|
482
|
+
...
|
483
|
+
|
445
484
|
@typing.overload
|
446
485
|
def retry(*, times: int = 3, minutes_between_retries: int = 2) -> typing.Callable[[typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]], typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]]:
|
447
486
|
"""
|
@@ -481,44 +520,6 @@ def retry(f: typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], ty
|
|
481
520
|
"""
|
482
521
|
...
|
483
522
|
|
484
|
-
@typing.overload
|
485
|
-
def fast_bakery_internal(f: typing.Callable[[FlowSpecDerived, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, StepFlag], None]:
|
486
|
-
"""
|
487
|
-
Internal decorator to support Fast bakery
|
488
|
-
"""
|
489
|
-
...
|
490
|
-
|
491
|
-
@typing.overload
|
492
|
-
def fast_bakery_internal(f: typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]:
|
493
|
-
...
|
494
|
-
|
495
|
-
def fast_bakery_internal(f: typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None], None] = None):
|
496
|
-
"""
|
497
|
-
Internal decorator to support Fast bakery
|
498
|
-
"""
|
499
|
-
...
|
500
|
-
|
501
|
-
@typing.overload
|
502
|
-
def model(*, load: typing.Union[typing.List[str], str, typing.List[typing.Tuple[str, typing.Optional[str]]]] = None, temp_dir_root: str = None) -> typing.Callable[[typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]], typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]]]:
|
503
|
-
"""
|
504
|
-
Enables loading / saving of models within a step.
|
505
|
-
"""
|
506
|
-
...
|
507
|
-
|
508
|
-
@typing.overload
|
509
|
-
def model(f: typing.Callable[[FlowSpecDerived, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, StepFlag], None]:
|
510
|
-
...
|
511
|
-
|
512
|
-
@typing.overload
|
513
|
-
def model(f: typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]) -> typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None]:
|
514
|
-
...
|
515
|
-
|
516
|
-
def model(f: typing.Union[typing.Callable[[FlowSpecDerived, StepFlag], None], typing.Callable[[FlowSpecDerived, typing.Any, StepFlag], None], None] = None, *, load: typing.Union[typing.List[str], str, typing.List[typing.Tuple[str, typing.Optional[str]]]] = None, temp_dir_root: str = None):
|
517
|
-
"""
|
518
|
-
Enables loading / saving of models within a step.
|
519
|
-
"""
|
520
|
-
...
|
521
|
-
|
522
523
|
def nim(*, models: "list[NIM]", backend: str) -> typing.Callable[[typing.Type[FlowSpecDerived]], typing.Type[FlowSpecDerived]]:
|
523
524
|
"""
|
524
525
|
This decorator is used to run NIM containers in Metaflow tasks as sidecars.
|
@@ -543,6 +544,23 @@ def nim(*, models: "list[NIM]", backend: str) -> typing.Callable[[typing.Type[Fl
|
|
543
544
|
"""
|
544
545
|
...
|
545
546
|
|
547
|
+
def airflow_external_task_sensor(*, timeout: int, poke_interval: int, mode: str, exponential_backoff: bool, pool: str, soft_fail: bool, name: str, description: str, external_dag_id: str, external_task_ids: typing.List[str], allowed_states: typing.List[str], failed_states: typing.List[str], execution_delta: "datetime.timedelta", check_existence: bool) -> typing.Callable[[typing.Type[FlowSpecDerived]], typing.Type[FlowSpecDerived]]:
|
548
|
+
"""
|
549
|
+
The `@airflow_external_task_sensor` decorator attaches a Airflow [ExternalTaskSensor](https://airflow.apache.org/docs/apache-airflow/stable/_api/airflow/sensors/external_task/index.html#airflow.sensors.external_task.ExternalTaskSensor) before the start step of the flow.
|
550
|
+
This decorator only works when a flow is scheduled on Airflow and is compiled using `airflow create`. More than one `@airflow_external_task_sensor` can be added as a flow decorators. Adding more than one decorator will ensure that `start` step starts only after all sensors finish.
|
551
|
+
"""
|
552
|
+
...
|
553
|
+
|
554
|
+
def airflow_s3_key_sensor(*, timeout: int, poke_interval: int, mode: str, exponential_backoff: bool, pool: str, soft_fail: bool, name: str, description: str, bucket_key: typing.Union[str, typing.List[str]], bucket_name: str, wildcard_match: bool, aws_conn_id: str, verify: bool) -> typing.Callable[[typing.Type[FlowSpecDerived]], typing.Type[FlowSpecDerived]]:
|
555
|
+
"""
|
556
|
+
The `@airflow_s3_key_sensor` decorator attaches a Airflow [S3KeySensor](https://airflow.apache.org/docs/apache-airflow-providers-amazon/stable/_api/airflow/providers/amazon/aws/sensors/s3/index.html#airflow.providers.amazon.aws.sensors.s3.S3KeySensor)
|
557
|
+
before the start step of the flow. This decorator only works when a flow is scheduled on Airflow
|
558
|
+
and is compiled using `airflow create`. More than one `@airflow_s3_key_sensor` can be
|
559
|
+
added as a flow decorators. Adding more than one decorator will ensure that `start` step
|
560
|
+
starts only after all sensors finish.
|
561
|
+
"""
|
562
|
+
...
|
563
|
+
|
546
564
|
@typing.overload
|
547
565
|
def trigger(*, event: typing.Union[str, typing.Dict[str, typing.Any], None] = None, events: typing.List[typing.Union[str, typing.Dict[str, typing.Any]]] = [], options: typing.Dict[str, typing.Any] = {}) -> typing.Callable[[typing.Type[FlowSpecDerived]], typing.Type[FlowSpecDerived]]:
|
548
566
|
"""
|
@@ -616,13 +634,54 @@ def trigger(f: typing.Optional[typing.Type[FlowSpecDerived]] = None, *, event: t
|
|
616
634
|
"""
|
617
635
|
...
|
618
636
|
|
619
|
-
|
637
|
+
@typing.overload
|
638
|
+
def schedule(*, hourly: bool = False, daily: bool = True, weekly: bool = False, cron: typing.Optional[str] = None, timezone: typing.Optional[str] = None) -> typing.Callable[[typing.Type[FlowSpecDerived]], typing.Type[FlowSpecDerived]]:
|
620
639
|
"""
|
621
|
-
|
622
|
-
|
623
|
-
|
624
|
-
|
625
|
-
|
640
|
+
Specifies the times when the flow should be run when running on a
|
641
|
+
production scheduler.
|
642
|
+
"""
|
643
|
+
...
|
644
|
+
|
645
|
+
@typing.overload
|
646
|
+
def schedule(f: typing.Type[FlowSpecDerived]) -> typing.Type[FlowSpecDerived]:
|
647
|
+
...
|
648
|
+
|
649
|
+
def schedule(f: typing.Optional[typing.Type[FlowSpecDerived]] = None, *, hourly: bool = False, daily: bool = True, weekly: bool = False, cron: typing.Optional[str] = None, timezone: typing.Optional[str] = None):
|
650
|
+
"""
|
651
|
+
Specifies the times when the flow should be run when running on a
|
652
|
+
production scheduler.
|
653
|
+
"""
|
654
|
+
...
|
655
|
+
|
656
|
+
def project(*, name: str) -> typing.Callable[[typing.Type[FlowSpecDerived]], typing.Type[FlowSpecDerived]]:
|
657
|
+
"""
|
658
|
+
Specifies what flows belong to the same project.
|
659
|
+
|
660
|
+
A project-specific namespace is created for all flows that
|
661
|
+
use the same `@project(name)`.
|
662
|
+
"""
|
663
|
+
...
|
664
|
+
|
665
|
+
@typing.overload
|
666
|
+
def conda_base(*, packages: typing.Dict[str, str] = {}, libraries: typing.Dict[str, str] = {}, python: typing.Optional[str] = None, disabled: bool = False) -> typing.Callable[[typing.Type[FlowSpecDerived]], typing.Type[FlowSpecDerived]]:
|
667
|
+
"""
|
668
|
+
Specifies the Conda environment for all steps of the flow.
|
669
|
+
|
670
|
+
Use `@conda_base` to set common libraries required by all
|
671
|
+
steps and use `@conda` to specify step-specific additions.
|
672
|
+
"""
|
673
|
+
...
|
674
|
+
|
675
|
+
@typing.overload
|
676
|
+
def conda_base(f: typing.Type[FlowSpecDerived]) -> typing.Type[FlowSpecDerived]:
|
677
|
+
...
|
678
|
+
|
679
|
+
def conda_base(f: typing.Optional[typing.Type[FlowSpecDerived]] = None, *, packages: typing.Dict[str, str] = {}, libraries: typing.Dict[str, str] = {}, python: typing.Optional[str] = None, disabled: bool = False):
|
680
|
+
"""
|
681
|
+
Specifies the Conda environment for all steps of the flow.
|
682
|
+
|
683
|
+
Use `@conda_base` to set common libraries required by all
|
684
|
+
steps and use `@conda` to specify step-specific additions.
|
626
685
|
"""
|
627
686
|
...
|
628
687
|
|
@@ -649,13 +708,6 @@ def pypi_base(f: typing.Optional[typing.Type[FlowSpecDerived]] = None, *, packag
|
|
649
708
|
"""
|
650
709
|
...
|
651
710
|
|
652
|
-
def airflow_external_task_sensor(*, timeout: int, poke_interval: int, mode: str, exponential_backoff: bool, pool: str, soft_fail: bool, name: str, description: str, external_dag_id: str, external_task_ids: typing.List[str], allowed_states: typing.List[str], failed_states: typing.List[str], execution_delta: "datetime.timedelta", check_existence: bool) -> typing.Callable[[typing.Type[FlowSpecDerived]], typing.Type[FlowSpecDerived]]:
|
653
|
-
"""
|
654
|
-
The `@airflow_external_task_sensor` decorator attaches a Airflow [ExternalTaskSensor](https://airflow.apache.org/docs/apache-airflow/stable/_api/airflow/sensors/external_task/index.html#airflow.sensors.external_task.ExternalTaskSensor) before the start step of the flow.
|
655
|
-
This decorator only works when a flow is scheduled on Airflow and is compiled using `airflow create`. More than one `@airflow_external_task_sensor` can be added as a flow decorators. Adding more than one decorator will ensure that `start` step starts only after all sensors finish.
|
656
|
-
"""
|
657
|
-
...
|
658
|
-
|
659
711
|
@typing.overload
|
660
712
|
def trigger_on_finish(*, flow: typing.Union[typing.Dict[str, str], str, None] = None, flows: typing.List[typing.Union[str, typing.Dict[str, str]]] = [], options: typing.Dict[str, typing.Any] = {}) -> typing.Callable[[typing.Type[FlowSpecDerived]], typing.Type[FlowSpecDerived]]:
|
661
713
|
"""
|
@@ -737,56 +789,5 @@ def trigger_on_finish(f: typing.Optional[typing.Type[FlowSpecDerived]] = None, *
|
|
737
789
|
"""
|
738
790
|
...
|
739
791
|
|
740
|
-
def project(*, name: str) -> typing.Callable[[typing.Type[FlowSpecDerived]], typing.Type[FlowSpecDerived]]:
|
741
|
-
"""
|
742
|
-
Specifies what flows belong to the same project.
|
743
|
-
|
744
|
-
A project-specific namespace is created for all flows that
|
745
|
-
use the same `@project(name)`.
|
746
|
-
"""
|
747
|
-
...
|
748
|
-
|
749
|
-
@typing.overload
|
750
|
-
def conda_base(*, packages: typing.Dict[str, str] = {}, libraries: typing.Dict[str, str] = {}, python: typing.Optional[str] = None, disabled: bool = False) -> typing.Callable[[typing.Type[FlowSpecDerived]], typing.Type[FlowSpecDerived]]:
|
751
|
-
"""
|
752
|
-
Specifies the Conda environment for all steps of the flow.
|
753
|
-
|
754
|
-
Use `@conda_base` to set common libraries required by all
|
755
|
-
steps and use `@conda` to specify step-specific additions.
|
756
|
-
"""
|
757
|
-
...
|
758
|
-
|
759
|
-
@typing.overload
|
760
|
-
def conda_base(f: typing.Type[FlowSpecDerived]) -> typing.Type[FlowSpecDerived]:
|
761
|
-
...
|
762
|
-
|
763
|
-
def conda_base(f: typing.Optional[typing.Type[FlowSpecDerived]] = None, *, packages: typing.Dict[str, str] = {}, libraries: typing.Dict[str, str] = {}, python: typing.Optional[str] = None, disabled: bool = False):
|
764
|
-
"""
|
765
|
-
Specifies the Conda environment for all steps of the flow.
|
766
|
-
|
767
|
-
Use `@conda_base` to set common libraries required by all
|
768
|
-
steps and use `@conda` to specify step-specific additions.
|
769
|
-
"""
|
770
|
-
...
|
771
|
-
|
772
|
-
@typing.overload
|
773
|
-
def schedule(*, hourly: bool = False, daily: bool = True, weekly: bool = False, cron: typing.Optional[str] = None, timezone: typing.Optional[str] = None) -> typing.Callable[[typing.Type[FlowSpecDerived]], typing.Type[FlowSpecDerived]]:
|
774
|
-
"""
|
775
|
-
Specifies the times when the flow should be run when running on a
|
776
|
-
production scheduler.
|
777
|
-
"""
|
778
|
-
...
|
779
|
-
|
780
|
-
@typing.overload
|
781
|
-
def schedule(f: typing.Type[FlowSpecDerived]) -> typing.Type[FlowSpecDerived]:
|
782
|
-
...
|
783
|
-
|
784
|
-
def schedule(f: typing.Optional[typing.Type[FlowSpecDerived]] = None, *, hourly: bool = False, daily: bool = True, weekly: bool = False, cron: typing.Optional[str] = None, timezone: typing.Optional[str] = None):
|
785
|
-
"""
|
786
|
-
Specifies the times when the flow should be run when running on a
|
787
|
-
production scheduler.
|
788
|
-
"""
|
789
|
-
...
|
790
|
-
|
791
792
|
pkg_name: str
|
792
793
|
|
metaflow-stubs/cards.pyi
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
######################################################################################################
|
2
2
|
# Auto-generated Metaflow stub file #
|
3
|
-
# MF version: 2.12.36.
|
4
|
-
# Generated on 2024-12-
|
3
|
+
# MF version: 2.12.36.3+obcheckpoint(0.1.4);ob(v1) #
|
4
|
+
# Generated on 2024-12-10T22:06:22.097033 #
|
5
5
|
######################################################################################################
|
6
6
|
|
7
7
|
from __future__ import annotations
|
metaflow-stubs/cli.pyi
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
######################################################################################################
|
2
2
|
# Auto-generated Metaflow stub file #
|
3
|
-
# MF version: 2.12.36.
|
4
|
-
# Generated on 2024-12-
|
3
|
+
# MF version: 2.12.36.3+obcheckpoint(0.1.4);ob(v1) #
|
4
|
+
# Generated on 2024-12-10T22:06:22.112435 #
|
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.36.
|
4
|
-
# Generated on 2024-12-
|
3
|
+
# MF version: 2.12.36.3+obcheckpoint(0.1.4);ob(v1) #
|
4
|
+
# Generated on 2024-12-10T22:06:22.100196 #
|
5
5
|
######################################################################################################
|
6
6
|
|
7
7
|
from __future__ import annotations
|