ob-metaflow-stubs 4.9__py2.py3-none-any.whl → 5.0__py2.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.
- metaflow-stubs/__init__.pyi +408 -555
- metaflow-stubs/cards.pyi +5 -5
- metaflow-stubs/cli.pyi +2 -2
- metaflow-stubs/client/__init__.pyi +4 -4
- metaflow-stubs/client/core.pyi +6 -6
- metaflow-stubs/client/filecache.pyi +3 -3
- metaflow-stubs/clone_util.pyi +2 -2
- metaflow-stubs/events.pyi +3 -3
- metaflow-stubs/exception.pyi +2 -2
- metaflow-stubs/flowspec.pyi +5 -5
- metaflow-stubs/generated_for.txt +1 -1
- metaflow-stubs/includefile.pyi +5 -5
- metaflow-stubs/metadata/metadata.pyi +3 -3
- metaflow-stubs/metadata/util.pyi +2 -2
- metaflow-stubs/metaflow_config.pyi +2 -2
- metaflow-stubs/metaflow_current.pyi +17 -17
- 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 +3 -3
- 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 +3 -3
- metaflow-stubs/plugins/airflow/sensors/external_task_sensor.pyi +3 -3
- metaflow-stubs/plugins/airflow/sensors/s3_sensor.pyi +3 -3
- 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 +5 -5
- metaflow-stubs/plugins/argo/argo_workflows_cli.pyi +7 -7
- metaflow-stubs/plugins/argo/argo_workflows_decorator.pyi +5 -5
- metaflow-stubs/plugins/argo/argo_workflows_deployer.pyi +3 -3
- 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/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 +3 -3
- 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 +5 -5
- metaflow-stubs/plugins/cards/card_client.pyi +3 -3
- 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 +3 -3
- metaflow-stubs/plugins/cards/card_resolver.pyi +2 -2
- metaflow-stubs/plugins/cards/component_serializer.pyi +3 -3
- metaflow-stubs/plugins/cards/exception.pyi +2 -2
- metaflow-stubs/plugins/catch_decorator.pyi +3 -3
- metaflow-stubs/plugins/datatools/__init__.pyi +3 -3
- metaflow-stubs/plugins/datatools/local.pyi +2 -2
- metaflow-stubs/plugins/datatools/s3/__init__.pyi +3 -3
- 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 +3 -3
- 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/kubernetes.pyi +2 -2
- metaflow-stubs/plugins/kubernetes/kubernetes_cli.pyi +3 -3
- metaflow-stubs/plugins/kubernetes/kubernetes_client.pyi +2 -2
- metaflow-stubs/plugins/kubernetes/kubernetes_decorator.pyi +3 -3
- metaflow-stubs/plugins/kubernetes/kubernetes_jobsets.pyi +2 -2
- metaflow-stubs/plugins/logs_cli.pyi +3 -3
- 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 +2 -2
- metaflow-stubs/plugins/pypi/conda_decorator.pyi +2 -2
- metaflow-stubs/plugins/pypi/conda_environment.pyi +3 -3
- metaflow-stubs/plugins/pypi/pypi_decorator.pyi +2 -2
- metaflow-stubs/plugins/pypi/pypi_environment.pyi +3 -3
- 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/storage_executor.pyi +2 -2
- metaflow-stubs/plugins/tag_cli.pyi +4 -4
- 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 +3 -3
- metaflow-stubs/runner/metaflow_runner.pyi +4 -4
- 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 +2 -2
- metaflow-stubs/system/__init__.pyi +3 -3
- metaflow-stubs/system/system_logger.pyi +2 -2
- metaflow-stubs/system/system_monitor.pyi +3 -3
- metaflow-stubs/tagging_util.pyi +2 -2
- metaflow-stubs/tuple_util.pyi +2 -2
- {ob_metaflow_stubs-4.9.dist-info → ob_metaflow_stubs-5.0.dist-info}/METADATA +1 -1
- ob_metaflow_stubs-5.0.dist-info/RECORD +137 -0
- metaflow-stubs/plugins/airflow/airflow.pyi +0 -187
- metaflow-stubs/plugins/airflow/airflow_cli.pyi +0 -90
- metaflow-stubs/plugins/airflow/airflow_decorator.pyi +0 -50
- metaflow-stubs/plugins/aws/batch/batch_cli.pyi +0 -46
- metaflow-stubs/plugins/aws/batch/batch_decorator.pyi +0 -145
- metaflow-stubs/plugins/aws/step_functions/dynamo_db_client.pyi +0 -22
- metaflow-stubs/plugins/aws/step_functions/step_functions_cli.pyi +0 -159
- metaflow-stubs/plugins/aws/step_functions/step_functions_decorator.pyi +0 -49
- metaflow-stubs/plugins/cards/card_modules/chevron/__init__.pyi +0 -78
- metaflow-stubs/plugins/cards/card_modules/chevron/main.pyi +0 -77
- metaflow-stubs/plugins/cards/card_modules/chevron/metadata.pyi +0 -11
- metaflow-stubs/plugins/cards/card_modules/chevron/renderer.pyi +0 -114
- metaflow-stubs/plugins/cards/card_modules/chevron/tokenizer.pyi +0 -75
- ob_metaflow_stubs-4.9.dist-info/RECORD +0 -150
- {ob_metaflow_stubs-4.9.dist-info → ob_metaflow_stubs-5.0.dist-info}/WHEEL +0 -0
- {ob_metaflow_stubs-4.9.dist-info → ob_metaflow_stubs-5.0.dist-info}/top_level.txt +0 -0
@@ -1,46 +0,0 @@
|
|
1
|
-
##################################################################################
|
2
|
-
# Auto-generated Metaflow stub file #
|
3
|
-
# MF version: 2.12.10.1+ob(v1) #
|
4
|
-
# Generated on 2024-07-31T05:43:21.060159 #
|
5
|
-
##################################################################################
|
6
|
-
|
7
|
-
from __future__ import annotations
|
8
|
-
|
9
|
-
import typing
|
10
|
-
if typing.TYPE_CHECKING:
|
11
|
-
import metaflow.exception
|
12
|
-
|
13
|
-
class CommandException(metaflow.exception.MetaflowException, metaclass=type):
|
14
|
-
...
|
15
|
-
|
16
|
-
METAFLOW_EXIT_DISALLOW_RETRY: int
|
17
|
-
|
18
|
-
def sync_local_metadata_from_datastore(metadata_local_dir, task_ds):
|
19
|
-
...
|
20
|
-
|
21
|
-
DATASTORE_LOCAL_DIR: str
|
22
|
-
|
23
|
-
TASK_LOG_SOURCE: str
|
24
|
-
|
25
|
-
UBF_CONTROL: str
|
26
|
-
|
27
|
-
UBF_TASK: str
|
28
|
-
|
29
|
-
class Batch(object, metaclass=type):
|
30
|
-
def __init__(self, metadata, environment):
|
31
|
-
...
|
32
|
-
def list_jobs(self, flow_name, run_id, user, echo):
|
33
|
-
...
|
34
|
-
def kill_jobs(self, flow_name, run_id, user, echo):
|
35
|
-
...
|
36
|
-
def create_job(self, step_name, step_cli, task_spec, code_package_sha, code_package_url, code_package_ds, image, queue, iam_role = None, execution_role = None, cpu = None, gpu = None, memory = None, run_time_limit = None, shared_memory = None, max_swap = None, swappiness = None, inferentia = None, efa = None, env = {}, attrs = {}, host_volumes = None, efs_volumes = None, use_tmpfs = None, tmpfs_tempdir = None, tmpfs_size = None, tmpfs_path = None, num_parallel = 0, ephemeral_storage = None, log_driver = None, log_options = None):
|
37
|
-
...
|
38
|
-
def launch_job(self, step_name, step_cli, task_spec, code_package_sha, code_package_url, code_package_ds, image, queue, iam_role = None, execution_role = None, cpu = None, gpu = None, memory = None, run_time_limit = None, shared_memory = None, max_swap = None, swappiness = None, inferentia = None, efa = None, host_volumes = None, efs_volumes = None, use_tmpfs = None, tmpfs_tempdir = None, tmpfs_size = None, tmpfs_path = None, num_parallel = 0, env = {}, attrs = {}, ephemeral_storage = None, log_driver = None, log_options = None):
|
39
|
-
...
|
40
|
-
def wait(self, stdout_location, stderr_location, echo = None):
|
41
|
-
...
|
42
|
-
...
|
43
|
-
|
44
|
-
class BatchKilledException(metaflow.exception.MetaflowException, metaclass=type):
|
45
|
-
...
|
46
|
-
|
@@ -1,145 +0,0 @@
|
|
1
|
-
##################################################################################
|
2
|
-
# Auto-generated Metaflow stub file #
|
3
|
-
# MF version: 2.12.10.1+ob(v1) #
|
4
|
-
# Generated on 2024-07-31T05:43:21.059594 #
|
5
|
-
##################################################################################
|
6
|
-
|
7
|
-
from __future__ import annotations
|
8
|
-
|
9
|
-
import typing
|
10
|
-
if typing.TYPE_CHECKING:
|
11
|
-
import metaflow.decorators
|
12
|
-
import metaflow.exception
|
13
|
-
import metaflow.metaflow_current
|
14
|
-
|
15
|
-
current: metaflow.metaflow_current.Current
|
16
|
-
|
17
|
-
class ResourcesDecorator(metaflow.decorators.StepDecorator, metaclass=type):
|
18
|
-
...
|
19
|
-
|
20
|
-
def get_run_time_limit_for_task(step_decos):
|
21
|
-
...
|
22
|
-
|
23
|
-
class MetaDatum(tuple, metaclass=type):
|
24
|
-
@staticmethod
|
25
|
-
def __new__(_cls, field, value, type, tags):
|
26
|
-
"""
|
27
|
-
Create new instance of MetaDatum(field, value, type, tags)
|
28
|
-
"""
|
29
|
-
...
|
30
|
-
def __repr__(self):
|
31
|
-
"""
|
32
|
-
Return a nicely formatted representation string
|
33
|
-
"""
|
34
|
-
...
|
35
|
-
def __getnewargs__(self):
|
36
|
-
"""
|
37
|
-
Return self as a plain tuple. Used by copy and pickle.
|
38
|
-
"""
|
39
|
-
...
|
40
|
-
...
|
41
|
-
|
42
|
-
def sync_local_metadata_to_datastore(metadata_local_dir, task_ds):
|
43
|
-
...
|
44
|
-
|
45
|
-
ECS_S3_ACCESS_IAM_ROLE: None
|
46
|
-
|
47
|
-
BATCH_JOB_QUEUE: None
|
48
|
-
|
49
|
-
BATCH_CONTAINER_IMAGE: None
|
50
|
-
|
51
|
-
BATCH_CONTAINER_REGISTRY: None
|
52
|
-
|
53
|
-
ECS_FARGATE_EXECUTION_ROLE: None
|
54
|
-
|
55
|
-
DATASTORE_LOCAL_DIR: str
|
56
|
-
|
57
|
-
UBF_CONTROL: str
|
58
|
-
|
59
|
-
class BatchException(metaflow.exception.MetaflowException, metaclass=type):
|
60
|
-
...
|
61
|
-
|
62
|
-
def compute_resource_attributes(decos, compute_deco, step_name, resource_defaults):
|
63
|
-
"""
|
64
|
-
Compute resource values taking into account defaults, the values specified
|
65
|
-
in the compute decorator (like @batch or @kubernetes) directly, and
|
66
|
-
resources specified via @resources decorator.
|
67
|
-
|
68
|
-
Returns a dictionary of resource attr -> value (str).
|
69
|
-
"""
|
70
|
-
...
|
71
|
-
|
72
|
-
def get_docker_registry(image_uri):
|
73
|
-
"""
|
74
|
-
Explanation:
|
75
|
-
(.+?(?:[:.].+?)\/)? - [GROUP 0] REGISTRY
|
76
|
-
.+? - A registry must start with at least one character
|
77
|
-
(?:[:.].+?)\/ - A registry must have ":" or "." and end with "/"
|
78
|
-
? - Make a registry optional
|
79
|
-
(.*?) - [GROUP 1] REPOSITORY
|
80
|
-
.*? - Get repository name until separator
|
81
|
-
(?:[@:])? - SEPARATOR
|
82
|
-
?: - Don't capture separator
|
83
|
-
[@:] - The separator must be either "@" or ":"
|
84
|
-
? - The separator is optional
|
85
|
-
((?<=[@:]).*)? - [GROUP 2] TAG / DIGEST
|
86
|
-
(?<=[@:]) - A tag / digest must be preceded by "@" or ":"
|
87
|
-
.* - Capture rest of tag / digest
|
88
|
-
? - A tag / digest is optional
|
89
|
-
Examples:
|
90
|
-
image
|
91
|
-
- None
|
92
|
-
- image
|
93
|
-
- None
|
94
|
-
example/image
|
95
|
-
- None
|
96
|
-
- example/image
|
97
|
-
- None
|
98
|
-
example/image:tag
|
99
|
-
- None
|
100
|
-
- example/image
|
101
|
-
- tag
|
102
|
-
example.domain.com/example/image:tag
|
103
|
-
- example.domain.com/
|
104
|
-
- example/image
|
105
|
-
- tag
|
106
|
-
123.123.123.123:123/example/image:tag
|
107
|
-
- 123.123.123.123:123/
|
108
|
-
- example/image
|
109
|
-
- tag
|
110
|
-
example.domain.com/example/image@sha256:45b23dee0
|
111
|
-
- example.domain.com/
|
112
|
-
- example/image
|
113
|
-
- sha256:45b23dee0
|
114
|
-
"""
|
115
|
-
...
|
116
|
-
|
117
|
-
def get_ec2_instance_metadata():
|
118
|
-
"""
|
119
|
-
Fetches the EC2 instance metadata through AWS instance metadata service
|
120
|
-
|
121
|
-
Returns either an empty dictionary, or one with the keys
|
122
|
-
- ec2-instance-id
|
123
|
-
- ec2-instance-type
|
124
|
-
- ec2-region
|
125
|
-
- ec2-availability-zone
|
126
|
-
"""
|
127
|
-
...
|
128
|
-
|
129
|
-
class BatchDecorator(metaflow.decorators.StepDecorator, metaclass=type):
|
130
|
-
def __init__(self, attributes = None, statically_defined = False):
|
131
|
-
...
|
132
|
-
def step_init(self, flow, graph, step, decos, environment, flow_datastore, logger):
|
133
|
-
...
|
134
|
-
def runtime_init(self, flow, graph, package, run_id):
|
135
|
-
...
|
136
|
-
def runtime_task_created(self, task_datastore, task_id, split_index, input_paths, is_cloned, ubf_context):
|
137
|
-
...
|
138
|
-
def runtime_step_cli(self, cli_args, retry_count, max_user_code_retries, ubf_context):
|
139
|
-
...
|
140
|
-
def task_pre_step(self, step_name, task_datastore, metadata, run_id, task_id, flow, graph, retry_count, max_retries, ubf_context, inputs):
|
141
|
-
...
|
142
|
-
def task_finished(self, step_name, flow, graph, is_task_ok, retry_count, max_retries):
|
143
|
-
...
|
144
|
-
...
|
145
|
-
|
@@ -1,22 +0,0 @@
|
|
1
|
-
##################################################################################
|
2
|
-
# Auto-generated Metaflow stub file #
|
3
|
-
# MF version: 2.12.10.1+ob(v1) #
|
4
|
-
# Generated on 2024-07-31T05:43:21.051337 #
|
5
|
-
##################################################################################
|
6
|
-
|
7
|
-
from __future__ import annotations
|
8
|
-
|
9
|
-
|
10
|
-
SFN_DYNAMO_DB_TABLE: None
|
11
|
-
|
12
|
-
class DynamoDbClient(object, metaclass=type):
|
13
|
-
def __init__(self):
|
14
|
-
...
|
15
|
-
def save_foreach_cardinality(self, foreach_split_task_id, foreach_cardinality, ttl):
|
16
|
-
...
|
17
|
-
def save_parent_task_id_for_foreach_join(self, foreach_split_task_id, foreach_join_parent_task_id):
|
18
|
-
...
|
19
|
-
def get_parent_task_ids_for_foreach_join(self, foreach_split_task_id):
|
20
|
-
...
|
21
|
-
...
|
22
|
-
|
@@ -1,159 +0,0 @@
|
|
1
|
-
##################################################################################
|
2
|
-
# Auto-generated Metaflow stub file #
|
3
|
-
# MF version: 2.12.10.1+ob(v1) #
|
4
|
-
# Generated on 2024-07-31T05:43:21.056756 #
|
5
|
-
##################################################################################
|
6
|
-
|
7
|
-
from __future__ import annotations
|
8
|
-
|
9
|
-
import typing
|
10
|
-
if typing.TYPE_CHECKING:
|
11
|
-
import metaflow.decorators
|
12
|
-
import metaflow.exception
|
13
|
-
import metaflow.metaflow_current
|
14
|
-
import metaflow.parameters
|
15
|
-
|
16
|
-
JSONType: metaflow.parameters.JSONTypeClass
|
17
|
-
|
18
|
-
current: metaflow.metaflow_current.Current
|
19
|
-
|
20
|
-
def get_metadata() -> str:
|
21
|
-
"""
|
22
|
-
Returns the current Metadata provider.
|
23
|
-
|
24
|
-
If this is not set explicitly using `metadata`, the default value is
|
25
|
-
determined through the Metaflow configuration. You can use this call to
|
26
|
-
check that your configuration is set up properly.
|
27
|
-
|
28
|
-
If multiple configuration profiles are present, this call returns the one
|
29
|
-
selected through the `METAFLOW_PROFILE` environment variable.
|
30
|
-
|
31
|
-
Returns
|
32
|
-
-------
|
33
|
-
str
|
34
|
-
Information about the Metadata provider currently selected. This information typically
|
35
|
-
returns provider specific information (like URL for remote providers or local paths for
|
36
|
-
local providers).
|
37
|
-
"""
|
38
|
-
...
|
39
|
-
|
40
|
-
class MetaflowException(Exception, metaclass=type):
|
41
|
-
def __init__(self, msg = "", lineno = None):
|
42
|
-
...
|
43
|
-
def __str__(self):
|
44
|
-
...
|
45
|
-
...
|
46
|
-
|
47
|
-
class MetaflowInternalError(metaflow.exception.MetaflowException, metaclass=type):
|
48
|
-
...
|
49
|
-
|
50
|
-
SERVICE_VERSION_CHECK: bool
|
51
|
-
|
52
|
-
SFN_STATE_MACHINE_PREFIX: None
|
53
|
-
|
54
|
-
UI_URL: None
|
55
|
-
|
56
|
-
class BatchDecorator(metaflow.decorators.StepDecorator, metaclass=type):
|
57
|
-
def __init__(self, attributes = None, statically_defined = False):
|
58
|
-
...
|
59
|
-
def step_init(self, flow, graph, step, decos, environment, flow_datastore, logger):
|
60
|
-
...
|
61
|
-
def runtime_init(self, flow, graph, package, run_id):
|
62
|
-
...
|
63
|
-
def runtime_task_created(self, task_datastore, task_id, split_index, input_paths, is_cloned, ubf_context):
|
64
|
-
...
|
65
|
-
def runtime_step_cli(self, cli_args, retry_count, max_user_code_retries, ubf_context):
|
66
|
-
...
|
67
|
-
def task_pre_step(self, step_name, task_datastore, metadata, run_id, task_id, flow, graph, retry_count, max_retries, ubf_context, inputs):
|
68
|
-
...
|
69
|
-
def task_finished(self, step_name, flow, graph, is_task_ok, retry_count, max_retries):
|
70
|
-
...
|
71
|
-
...
|
72
|
-
|
73
|
-
def validate_tags(tags, existing_tags = None):
|
74
|
-
"""
|
75
|
-
Raises MetaflowTaggingError if invalid based on these rules:
|
76
|
-
|
77
|
-
Tag set size is too large. But it's OK if tag set is not larger
|
78
|
-
than an existing tag set (if provided).
|
79
|
-
|
80
|
-
Then, we validate each tag. See validate_tag()
|
81
|
-
"""
|
82
|
-
...
|
83
|
-
|
84
|
-
def load_token(token_prefix):
|
85
|
-
...
|
86
|
-
|
87
|
-
def new_token(token_prefix, prev_token = None):
|
88
|
-
...
|
89
|
-
|
90
|
-
def store_token(token_prefix, token):
|
91
|
-
...
|
92
|
-
|
93
|
-
class StepFunctions(object, metaclass=type):
|
94
|
-
def __init__(self, name, graph, flow, code_package_sha, code_package_url, production_token, metadata, flow_datastore, environment, event_logger, monitor, tags = None, namespace = None, username = None, max_workers = None, workflow_timeout = None, is_project = False, use_distributed_map = False):
|
95
|
-
...
|
96
|
-
def to_json(self):
|
97
|
-
...
|
98
|
-
def trigger_explanation(self):
|
99
|
-
...
|
100
|
-
def deploy(self, log_execution_history):
|
101
|
-
...
|
102
|
-
def schedule(self):
|
103
|
-
...
|
104
|
-
@classmethod
|
105
|
-
def delete(cls, name):
|
106
|
-
...
|
107
|
-
@classmethod
|
108
|
-
def terminate(cls, flow_name, name):
|
109
|
-
...
|
110
|
-
@classmethod
|
111
|
-
def trigger(cls, name, parameters):
|
112
|
-
...
|
113
|
-
@classmethod
|
114
|
-
def list(cls, name, states):
|
115
|
-
...
|
116
|
-
@classmethod
|
117
|
-
def get_existing_deployment(cls, name):
|
118
|
-
...
|
119
|
-
@classmethod
|
120
|
-
def get_execution(cls, state_machine_name, name):
|
121
|
-
...
|
122
|
-
...
|
123
|
-
|
124
|
-
class IncorrectProductionToken(metaflow.exception.MetaflowException, metaclass=type):
|
125
|
-
...
|
126
|
-
|
127
|
-
class RunIdMismatch(metaflow.exception.MetaflowException, metaclass=type):
|
128
|
-
...
|
129
|
-
|
130
|
-
class IncorrectMetadataServiceVersion(metaflow.exception.MetaflowException, metaclass=type):
|
131
|
-
...
|
132
|
-
|
133
|
-
class StepFunctionsStateMachineNameTooLong(metaflow.exception.MetaflowException, metaclass=type):
|
134
|
-
...
|
135
|
-
|
136
|
-
def check_metadata_service_version(obj):
|
137
|
-
...
|
138
|
-
|
139
|
-
def resolve_state_machine_name(obj, name):
|
140
|
-
...
|
141
|
-
|
142
|
-
def make_flow(obj, token, name, tags, namespace, max_workers, workflow_timeout, is_project, use_distributed_map):
|
143
|
-
...
|
144
|
-
|
145
|
-
def resolve_token(name, token_prefix, obj, authorize, given_token, generate_new_token, is_project):
|
146
|
-
...
|
147
|
-
|
148
|
-
def validate_run_id(state_machine_name, token_prefix, authorize, run_id, instructions_fn = None):
|
149
|
-
...
|
150
|
-
|
151
|
-
def validate_token(name, token_prefix, authorize, instruction_fn = None):
|
152
|
-
"""
|
153
|
-
Validate that the production token matches that of the deployed flow.
|
154
|
-
|
155
|
-
In case both the user and token do not match, raises an error.
|
156
|
-
Optionally outputs instructions on token usage via the provided instruction_fn(flow_name, prev_user)
|
157
|
-
"""
|
158
|
-
...
|
159
|
-
|
@@ -1,49 +0,0 @@
|
|
1
|
-
##################################################################################
|
2
|
-
# Auto-generated Metaflow stub file #
|
3
|
-
# MF version: 2.12.10.1+ob(v1) #
|
4
|
-
# Generated on 2024-07-31T05:43:21.051725 #
|
5
|
-
##################################################################################
|
6
|
-
|
7
|
-
from __future__ import annotations
|
8
|
-
|
9
|
-
import typing
|
10
|
-
if typing.TYPE_CHECKING:
|
11
|
-
import metaflow.decorators
|
12
|
-
|
13
|
-
class MetaDatum(tuple, metaclass=type):
|
14
|
-
@staticmethod
|
15
|
-
def __new__(_cls, field, value, type, tags):
|
16
|
-
"""
|
17
|
-
Create new instance of MetaDatum(field, value, type, tags)
|
18
|
-
"""
|
19
|
-
...
|
20
|
-
def __repr__(self):
|
21
|
-
"""
|
22
|
-
Return a nicely formatted representation string
|
23
|
-
"""
|
24
|
-
...
|
25
|
-
def __getnewargs__(self):
|
26
|
-
"""
|
27
|
-
Return self as a plain tuple. Used by copy and pickle.
|
28
|
-
"""
|
29
|
-
...
|
30
|
-
...
|
31
|
-
|
32
|
-
class DynamoDbClient(object, metaclass=type):
|
33
|
-
def __init__(self):
|
34
|
-
...
|
35
|
-
def save_foreach_cardinality(self, foreach_split_task_id, foreach_cardinality, ttl):
|
36
|
-
...
|
37
|
-
def save_parent_task_id_for_foreach_join(self, foreach_split_task_id, foreach_join_parent_task_id):
|
38
|
-
...
|
39
|
-
def get_parent_task_ids_for_foreach_join(self, foreach_split_task_id):
|
40
|
-
...
|
41
|
-
...
|
42
|
-
|
43
|
-
class StepFunctionsInternalDecorator(metaflow.decorators.StepDecorator, metaclass=type):
|
44
|
-
def task_pre_step(self, step_name, task_datastore, metadata, run_id, task_id, flow, graph, retry_count, max_user_code_retries, ubf_context, inputs):
|
45
|
-
...
|
46
|
-
def task_finished(self, step_name, flow, graph, is_task_ok, retry_count, max_user_code_retries):
|
47
|
-
...
|
48
|
-
...
|
49
|
-
|
@@ -1,78 +0,0 @@
|
|
1
|
-
##################################################################################
|
2
|
-
# Auto-generated Metaflow stub file #
|
3
|
-
# MF version: 2.12.10.1+ob(v1) #
|
4
|
-
# Generated on 2024-07-31T05:43:21.051020 #
|
5
|
-
##################################################################################
|
6
|
-
|
7
|
-
from __future__ import annotations
|
8
|
-
|
9
|
-
|
10
|
-
def main(template, data = None, **kwargs):
|
11
|
-
...
|
12
|
-
|
13
|
-
def cli_main():
|
14
|
-
"""
|
15
|
-
Render mustache templates using json files
|
16
|
-
"""
|
17
|
-
...
|
18
|
-
|
19
|
-
def render(template = "", data = {}, partials_path = ".", partials_ext = "mustache", partials_dict = {}, padding = "", def_ldel = "{{", def_rdel = "}}", scopes = None, warn = False, keep = False):
|
20
|
-
"""
|
21
|
-
Render a mustache template.
|
22
|
-
|
23
|
-
Renders a mustache template with a data scope and partial capability.
|
24
|
-
Given the file structure...
|
25
|
-
╷
|
26
|
-
├─╼ main.py
|
27
|
-
├─╼ main.ms
|
28
|
-
└─┮ partials
|
29
|
-
└── part.ms
|
30
|
-
|
31
|
-
then main.py would make the following call:
|
32
|
-
|
33
|
-
render(open('main.ms', 'r'), {...}, 'partials', 'ms')
|
34
|
-
|
35
|
-
|
36
|
-
Arguments:
|
37
|
-
|
38
|
-
template -- A file-like object or a string containing the template
|
39
|
-
|
40
|
-
data -- A python dictionary with your data scope
|
41
|
-
|
42
|
-
partials_path -- The path to where your partials are stored
|
43
|
-
If set to None, then partials won't be loaded from the file system
|
44
|
-
(defaults to '.')
|
45
|
-
|
46
|
-
partials_ext -- The extension that you want the parser to look for
|
47
|
-
(defaults to 'mustache')
|
48
|
-
|
49
|
-
partials_dict -- A python dictionary which will be search for partials
|
50
|
-
before the filesystem is. {'include': 'foo'} is the same
|
51
|
-
as a file called include.mustache
|
52
|
-
(defaults to {})
|
53
|
-
|
54
|
-
padding -- This is for padding partials, and shouldn't be used
|
55
|
-
(but can be if you really want to)
|
56
|
-
|
57
|
-
def_ldel -- The default left delimiter
|
58
|
-
("{{" by default, as in spec compliant mustache)
|
59
|
-
|
60
|
-
def_rdel -- The default right delimiter
|
61
|
-
("}}" by default, as in spec compliant mustache)
|
62
|
-
|
63
|
-
scopes -- The list of scopes that get_key will look through
|
64
|
-
|
65
|
-
warn -- Issue a warning to stderr when a template substitution isn't found in the data
|
66
|
-
|
67
|
-
keep -- Keep unreplaced tags when a template substitution isn't found in the data
|
68
|
-
|
69
|
-
|
70
|
-
Returns:
|
71
|
-
|
72
|
-
A string containing the rendered template.
|
73
|
-
"""
|
74
|
-
...
|
75
|
-
|
76
|
-
class ChevronError(SyntaxError, metaclass=type):
|
77
|
-
...
|
78
|
-
|
@@ -1,77 +0,0 @@
|
|
1
|
-
##################################################################################
|
2
|
-
# Auto-generated Metaflow stub file #
|
3
|
-
# MF version: 2.12.10.1+ob(v1) #
|
4
|
-
# Generated on 2024-07-31T05:43:21.062161 #
|
5
|
-
##################################################################################
|
6
|
-
|
7
|
-
from __future__ import annotations
|
8
|
-
|
9
|
-
|
10
|
-
def render(template = "", data = {}, partials_path = ".", partials_ext = "mustache", partials_dict = {}, padding = "", def_ldel = "{{", def_rdel = "}}", scopes = None, warn = False, keep = False):
|
11
|
-
"""
|
12
|
-
Render a mustache template.
|
13
|
-
|
14
|
-
Renders a mustache template with a data scope and partial capability.
|
15
|
-
Given the file structure...
|
16
|
-
╷
|
17
|
-
├─╼ main.py
|
18
|
-
├─╼ main.ms
|
19
|
-
└─┮ partials
|
20
|
-
└── part.ms
|
21
|
-
|
22
|
-
then main.py would make the following call:
|
23
|
-
|
24
|
-
render(open('main.ms', 'r'), {...}, 'partials', 'ms')
|
25
|
-
|
26
|
-
|
27
|
-
Arguments:
|
28
|
-
|
29
|
-
template -- A file-like object or a string containing the template
|
30
|
-
|
31
|
-
data -- A python dictionary with your data scope
|
32
|
-
|
33
|
-
partials_path -- The path to where your partials are stored
|
34
|
-
If set to None, then partials won't be loaded from the file system
|
35
|
-
(defaults to '.')
|
36
|
-
|
37
|
-
partials_ext -- The extension that you want the parser to look for
|
38
|
-
(defaults to 'mustache')
|
39
|
-
|
40
|
-
partials_dict -- A python dictionary which will be search for partials
|
41
|
-
before the filesystem is. {'include': 'foo'} is the same
|
42
|
-
as a file called include.mustache
|
43
|
-
(defaults to {})
|
44
|
-
|
45
|
-
padding -- This is for padding partials, and shouldn't be used
|
46
|
-
(but can be if you really want to)
|
47
|
-
|
48
|
-
def_ldel -- The default left delimiter
|
49
|
-
("{{" by default, as in spec compliant mustache)
|
50
|
-
|
51
|
-
def_rdel -- The default right delimiter
|
52
|
-
("}}" by default, as in spec compliant mustache)
|
53
|
-
|
54
|
-
scopes -- The list of scopes that get_key will look through
|
55
|
-
|
56
|
-
warn -- Issue a warning to stderr when a template substitution isn't found in the data
|
57
|
-
|
58
|
-
keep -- Keep unreplaced tags when a template substitution isn't found in the data
|
59
|
-
|
60
|
-
|
61
|
-
Returns:
|
62
|
-
|
63
|
-
A string containing the rendered template.
|
64
|
-
"""
|
65
|
-
...
|
66
|
-
|
67
|
-
version: str
|
68
|
-
|
69
|
-
def main(template, data = None, **kwargs):
|
70
|
-
...
|
71
|
-
|
72
|
-
def cli_main():
|
73
|
-
"""
|
74
|
-
Render mustache templates using json files
|
75
|
-
"""
|
76
|
-
...
|
77
|
-
|
@@ -1,11 +0,0 @@
|
|
1
|
-
##################################################################################
|
2
|
-
# Auto-generated Metaflow stub file #
|
3
|
-
# MF version: 2.12.10.1+ob(v1) #
|
4
|
-
# Generated on 2024-07-31T05:43:21.061891 #
|
5
|
-
##################################################################################
|
6
|
-
|
7
|
-
from __future__ import annotations
|
8
|
-
|
9
|
-
|
10
|
-
version: str
|
11
|
-
|