ob-metaflow-stubs 6.0.3.125__py2.py3-none-any.whl → 6.0.3.126__py2.py3-none-any.whl

Sign up to get free protection for your applications and to get access to all the features.
Files changed (182) hide show
  1. metaflow-stubs/__init__.pyi +289 -285
  2. metaflow-stubs/cards.pyi +2 -2
  3. metaflow-stubs/cli.pyi +9 -21
  4. metaflow-stubs/{plugins/package_cli.pyi → cli_components/__init__.pyi} +3 -3
  5. metaflow-stubs/cli_components/utils.pyi +35 -0
  6. metaflow-stubs/client/__init__.pyi +2 -2
  7. metaflow-stubs/client/core.pyi +5 -5
  8. metaflow-stubs/client/filecache.pyi +3 -3
  9. metaflow-stubs/events.pyi +3 -3
  10. metaflow-stubs/exception.pyi +2 -2
  11. metaflow-stubs/flowspec.pyi +12 -5
  12. metaflow-stubs/generated_for.txt +1 -1
  13. metaflow-stubs/includefile.pyi +20 -13
  14. metaflow-stubs/info_file.pyi +2 -2
  15. metaflow-stubs/metadata_provider/__init__.pyi +2 -2
  16. metaflow-stubs/metadata_provider/heartbeat.pyi +2 -2
  17. metaflow-stubs/metadata_provider/metadata.pyi +2 -2
  18. metaflow-stubs/metadata_provider/util.pyi +2 -2
  19. metaflow-stubs/metaflow_config.pyi +4 -2
  20. metaflow-stubs/metaflow_current.pyi +131 -131
  21. metaflow-stubs/mf_extensions/__init__.pyi +2 -2
  22. metaflow-stubs/mf_extensions/obcheckpoint/__init__.pyi +2 -2
  23. metaflow-stubs/mf_extensions/obcheckpoint/plugins/__init__.pyi +2 -2
  24. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/__init__.pyi +2 -2
  25. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/checkpoints/__init__.pyi +2 -2
  26. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/checkpoints/checkpoint_storage.pyi +3 -3
  27. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/checkpoints/constructors.pyi +2 -2
  28. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/checkpoints/core.pyi +5 -5
  29. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/checkpoints/exceptions.pyi +2 -2
  30. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/checkpoints/final_api.pyi +3 -3
  31. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/datastore/__init__.pyi +2 -2
  32. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/datastore/core.pyi +3 -3
  33. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/datastore/exceptions.pyi +2 -2
  34. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/datastore/task_utils.pyi +3 -3
  35. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/datastore/utils.pyi +2 -2
  36. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/datastructures.pyi +3 -3
  37. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/exceptions.pyi +2 -2
  38. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/utils/__init__.pyi +2 -2
  39. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/utils/flowspec_utils.pyi +2 -2
  40. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/utils/general.pyi +2 -2
  41. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/utils/identity_utils.pyi +2 -2
  42. metaflow-stubs/mf_extensions/obcheckpoint/plugins/machine_learning_utilities/utils/tar_utils.pyi +3 -3
  43. metaflow-stubs/mf_extensions/outerbounds/__init__.pyi +2 -2
  44. metaflow-stubs/mf_extensions/outerbounds/plugins/__init__.pyi +2 -2
  45. metaflow-stubs/mf_extensions/outerbounds/plugins/snowflake/__init__.pyi +2 -2
  46. metaflow-stubs/mf_extensions/outerbounds/plugins/snowflake/snowflake.pyi +2 -2
  47. metaflow-stubs/mf_extensions/outerbounds/profilers/__init__.pyi +2 -2
  48. metaflow-stubs/mf_extensions/outerbounds/profilers/gpu.pyi +2 -2
  49. metaflow-stubs/mf_extensions/outerbounds/remote_config.pyi +2 -2
  50. metaflow-stubs/mf_extensions/outerbounds/toplevel/__init__.pyi +2 -2
  51. metaflow-stubs/mf_extensions/outerbounds/toplevel/global_aliases_for_metaflow_package.pyi +2 -2
  52. metaflow-stubs/multicore_utils.pyi +2 -2
  53. metaflow-stubs/parameters.pyi +35 -18
  54. metaflow-stubs/plugins/__init__.pyi +14 -14
  55. metaflow-stubs/plugins/airflow/__init__.pyi +2 -2
  56. metaflow-stubs/plugins/airflow/airflow_utils.pyi +2 -2
  57. metaflow-stubs/plugins/airflow/exception.pyi +2 -2
  58. metaflow-stubs/plugins/airflow/sensors/__init__.pyi +2 -2
  59. metaflow-stubs/plugins/airflow/sensors/base_sensor.pyi +2 -2
  60. metaflow-stubs/plugins/airflow/sensors/external_task_sensor.pyi +2 -2
  61. metaflow-stubs/plugins/airflow/sensors/s3_sensor.pyi +2 -2
  62. metaflow-stubs/plugins/argo/__init__.pyi +2 -5
  63. metaflow-stubs/plugins/argo/argo_client.pyi +2 -2
  64. metaflow-stubs/plugins/argo/argo_events.pyi +2 -2
  65. metaflow-stubs/plugins/argo/argo_workflows.pyi +3 -2
  66. metaflow-stubs/plugins/argo/argo_workflows_decorator.pyi +3 -3
  67. metaflow-stubs/plugins/argo/argo_workflows_deployer.pyi +4 -4
  68. metaflow-stubs/plugins/argo/argo_workflows_deployer_objects.pyi +31 -3
  69. metaflow-stubs/plugins/aws/__init__.pyi +2 -2
  70. metaflow-stubs/plugins/aws/aws_client.pyi +2 -2
  71. metaflow-stubs/plugins/aws/aws_utils.pyi +2 -2
  72. metaflow-stubs/plugins/aws/batch/__init__.pyi +2 -2
  73. metaflow-stubs/plugins/aws/batch/batch.pyi +2 -2
  74. metaflow-stubs/plugins/aws/batch/batch_client.pyi +2 -2
  75. metaflow-stubs/plugins/aws/batch/batch_decorator.pyi +3 -3
  76. metaflow-stubs/plugins/aws/secrets_manager/__init__.pyi +2 -2
  77. metaflow-stubs/plugins/aws/secrets_manager/aws_secrets_manager_secrets_provider.pyi +4 -4
  78. metaflow-stubs/plugins/aws/step_functions/__init__.pyi +2 -3
  79. metaflow-stubs/plugins/aws/step_functions/event_bridge_client.pyi +2 -2
  80. metaflow-stubs/plugins/aws/step_functions/schedule_decorator.pyi +2 -2
  81. metaflow-stubs/plugins/aws/step_functions/step_functions.pyi +3 -2
  82. metaflow-stubs/plugins/aws/step_functions/step_functions_client.pyi +2 -2
  83. metaflow-stubs/plugins/aws/step_functions/step_functions_deployer.pyi +5 -5
  84. metaflow-stubs/plugins/aws/step_functions/step_functions_deployer_objects.pyi +3 -3
  85. metaflow-stubs/plugins/azure/__init__.pyi +2 -2
  86. metaflow-stubs/plugins/azure/azure_credential.pyi +2 -2
  87. metaflow-stubs/plugins/azure/azure_exceptions.pyi +2 -2
  88. metaflow-stubs/plugins/azure/azure_secret_manager_secrets_provider.pyi +4 -4
  89. metaflow-stubs/plugins/azure/azure_utils.pyi +2 -2
  90. metaflow-stubs/plugins/azure/blob_service_client_factory.pyi +2 -2
  91. metaflow-stubs/plugins/azure/includefile_support.pyi +2 -2
  92. metaflow-stubs/plugins/cards/__init__.pyi +2 -3
  93. metaflow-stubs/plugins/cards/card_client.pyi +3 -3
  94. metaflow-stubs/plugins/cards/card_creator.pyi +2 -2
  95. metaflow-stubs/plugins/cards/card_datastore.pyi +2 -2
  96. metaflow-stubs/plugins/cards/card_decorator.pyi +2 -2
  97. metaflow-stubs/plugins/cards/card_modules/__init__.pyi +2 -2
  98. metaflow-stubs/plugins/cards/card_modules/basic.pyi +2 -2
  99. metaflow-stubs/plugins/cards/card_modules/card.pyi +2 -2
  100. metaflow-stubs/plugins/cards/card_modules/components.pyi +4 -4
  101. metaflow-stubs/plugins/cards/card_modules/convert_to_native_type.pyi +2 -2
  102. metaflow-stubs/plugins/cards/card_modules/renderer_tools.pyi +2 -2
  103. metaflow-stubs/plugins/cards/card_modules/test_cards.pyi +2 -2
  104. metaflow-stubs/plugins/cards/card_resolver.pyi +2 -2
  105. metaflow-stubs/plugins/cards/component_serializer.pyi +2 -2
  106. metaflow-stubs/plugins/cards/exception.pyi +2 -2
  107. metaflow-stubs/plugins/catch_decorator.pyi +3 -3
  108. metaflow-stubs/plugins/datatools/__init__.pyi +2 -2
  109. metaflow-stubs/plugins/datatools/local.pyi +2 -2
  110. metaflow-stubs/plugins/datatools/s3/__init__.pyi +2 -2
  111. metaflow-stubs/plugins/datatools/s3/s3.pyi +4 -4
  112. metaflow-stubs/plugins/datatools/s3/s3tail.pyi +2 -2
  113. metaflow-stubs/plugins/datatools/s3/s3util.pyi +2 -2
  114. metaflow-stubs/plugins/debug_logger.pyi +2 -2
  115. metaflow-stubs/plugins/debug_monitor.pyi +2 -2
  116. metaflow-stubs/plugins/environment_decorator.pyi +2 -2
  117. metaflow-stubs/plugins/events_decorator.pyi +2 -2
  118. metaflow-stubs/plugins/frameworks/__init__.pyi +2 -2
  119. metaflow-stubs/plugins/frameworks/pytorch.pyi +2 -2
  120. metaflow-stubs/plugins/gcp/__init__.pyi +2 -2
  121. metaflow-stubs/plugins/gcp/gcp_secret_manager_secrets_provider.pyi +4 -4
  122. metaflow-stubs/plugins/gcp/gs_exceptions.pyi +2 -2
  123. metaflow-stubs/plugins/gcp/gs_storage_client_factory.pyi +2 -2
  124. metaflow-stubs/plugins/gcp/gs_utils.pyi +2 -2
  125. metaflow-stubs/plugins/gcp/includefile_support.pyi +2 -2
  126. metaflow-stubs/plugins/kubernetes/__init__.pyi +2 -5
  127. metaflow-stubs/plugins/kubernetes/kube_utils.pyi +2 -2
  128. metaflow-stubs/plugins/kubernetes/kubernetes.pyi +3 -3
  129. metaflow-stubs/plugins/kubernetes/kubernetes_client.pyi +2 -2
  130. metaflow-stubs/plugins/kubernetes/kubernetes_decorator.pyi +3 -3
  131. metaflow-stubs/plugins/kubernetes/kubernetes_jobsets.pyi +2 -2
  132. metaflow-stubs/plugins/parallel_decorator.pyi +2 -2
  133. metaflow-stubs/plugins/perimeters.pyi +2 -2
  134. metaflow-stubs/plugins/project_decorator.pyi +2 -2
  135. metaflow-stubs/plugins/pypi/__init__.pyi +3 -3
  136. metaflow-stubs/plugins/pypi/conda_decorator.pyi +6 -2
  137. metaflow-stubs/plugins/pypi/conda_environment.pyi +4 -4
  138. metaflow-stubs/plugins/pypi/pypi_decorator.pyi +2 -2
  139. metaflow-stubs/plugins/pypi/pypi_environment.pyi +2 -2
  140. metaflow-stubs/plugins/pypi/utils.pyi +2 -2
  141. metaflow-stubs/plugins/resources_decorator.pyi +2 -2
  142. metaflow-stubs/plugins/retry_decorator.pyi +2 -2
  143. metaflow-stubs/plugins/secrets/__init__.pyi +3 -3
  144. metaflow-stubs/plugins/secrets/inline_secrets_provider.pyi +4 -4
  145. metaflow-stubs/plugins/secrets/secrets_decorator.pyi +2 -2
  146. metaflow-stubs/plugins/snowflake/__init__.pyi +2 -2
  147. metaflow-stubs/plugins/storage_executor.pyi +2 -2
  148. metaflow-stubs/plugins/test_unbounded_foreach_decorator.pyi +2 -2
  149. metaflow-stubs/plugins/timeout_decorator.pyi +4 -4
  150. metaflow-stubs/profilers/__init__.pyi +2 -2
  151. metaflow-stubs/pylint_wrapper.pyi +2 -2
  152. metaflow-stubs/runner/__init__.pyi +2 -2
  153. metaflow-stubs/runner/deployer.pyi +30 -30
  154. metaflow-stubs/runner/deployer_impl.pyi +4 -4
  155. metaflow-stubs/runner/metaflow_runner.pyi +5 -5
  156. metaflow-stubs/runner/nbdeploy.pyi +4 -2
  157. metaflow-stubs/runner/nbrun.pyi +3 -3
  158. metaflow-stubs/runner/subprocess_manager.pyi +5 -2
  159. metaflow-stubs/runner/utils.pyi +7 -7
  160. metaflow-stubs/system/__init__.pyi +2 -2
  161. metaflow-stubs/system/system_logger.pyi +3 -3
  162. metaflow-stubs/system/system_monitor.pyi +2 -2
  163. metaflow-stubs/tagging_util.pyi +2 -2
  164. metaflow-stubs/tuple_util.pyi +2 -2
  165. metaflow-stubs/{plugins/aws/step_functions/production_token.pyi → user_configs/__init__.pyi} +5 -11
  166. metaflow-stubs/user_configs/config_decorators.pyi +253 -0
  167. metaflow-stubs/user_configs/config_options.pyi +82 -0
  168. metaflow-stubs/user_configs/config_parameters.pyi +217 -0
  169. {ob_metaflow_stubs-6.0.3.125.dist-info → ob_metaflow_stubs-6.0.3.126.dist-info}/METADATA +1 -1
  170. ob_metaflow_stubs-6.0.3.126.dist-info/RECORD +173 -0
  171. metaflow-stubs/clone_util.pyi +0 -14
  172. metaflow-stubs/mflog/__init__.pyi +0 -6
  173. metaflow-stubs/mflog/mflog.pyi +0 -69
  174. metaflow-stubs/plugins/argo/argo_workflows_cli.pyi +0 -103
  175. metaflow-stubs/plugins/cards/card_cli.pyi +0 -146
  176. metaflow-stubs/plugins/kubernetes/kubernetes_cli.pyi +0 -33
  177. metaflow-stubs/plugins/logs_cli.pyi +0 -46
  178. metaflow-stubs/plugins/tag_cli.pyi +0 -19
  179. metaflow-stubs/procpoll.pyi +0 -53
  180. ob_metaflow_stubs-6.0.3.125.dist-info/RECORD +0 -178
  181. {ob_metaflow_stubs-6.0.3.125.dist-info → ob_metaflow_stubs-6.0.3.126.dist-info}/WHEEL +0 -0
  182. {ob_metaflow_stubs-6.0.3.125.dist-info → ob_metaflow_stubs-6.0.3.126.dist-info}/top_level.txt +0 -0
@@ -1,19 +1,19 @@
1
1
  ######################################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.36.3+obcheckpoint(0.1.4);ob(v1) #
4
- # Generated on 2024-12-10T22:06:22.199167 #
3
+ # MF version: 2.12.39.1+obcheckpoint(0.1.4);ob(v1) #
4
+ # Generated on 2024-12-17T01:10:55.903282 #
5
5
  ######################################################################################################
6
6
 
7
7
  from __future__ import annotations
8
8
 
9
- import metaflow
10
9
  import typing
10
+ import metaflow
11
11
  if typing.TYPE_CHECKING:
12
+ import metaflow.plugins.aws.step_functions.step_functions_deployer
12
13
  import metaflow.plugins.argo.argo_workflows_deployer
13
- import metaflow.plugins.aws.step_functions.step_functions_deployer_objects
14
14
  import metaflow
15
- import metaflow.plugins.aws.step_functions.step_functions_deployer
16
15
  import metaflow.runner.deployer
16
+ import metaflow.plugins.aws.step_functions.step_functions_deployer_objects
17
17
  import metaflow.plugins.argo.argo_workflows_deployer_objects
18
18
 
19
19
  from ..exception import MetaflowNotFound as MetaflowNotFound
@@ -48,31 +48,31 @@ class Deployer(object, metaclass=DeployerMeta):
48
48
  The directory to run the subprocess in; if not specified, the current
49
49
  directory is used.
50
50
  file_read_timeout : int, default 3600
51
- The timeout until which we try to read the deployer attribute file.
51
+ The timeout until which we try to read the deployer attribute file (in seconds).
52
52
  **kwargs : Any
53
53
  Additional arguments that you would pass to `python myflow.py` before
54
54
  the deployment command.
55
55
  """
56
56
  def __init__(self, flow_file: str, show_output: bool = True, profile: typing.Optional[str] = None, env: typing.Optional[typing.Dict] = None, cwd: typing.Optional[str] = None, file_read_timeout: int = 3600, **kwargs):
57
57
  ...
58
- def argo_workflows(self, *, name: typing.Optional[str] = None) -> "metaflow.plugins.argo.argo_workflows_deployer.ArgoWorkflowsDeployer":
58
+ def step_functions(self, *, name: typing.Optional[str] = None) -> "metaflow.plugins.aws.step_functions.step_functions_deployer.StepFunctionsDeployer":
59
59
  """
60
- Deployer implementation for Argo Workflows.
60
+ Deployer implementation for AWS Step Functions.
61
61
 
62
62
  Parameters
63
63
  ----------
64
64
  name : str, optional, default None
65
- Argo workflow name. The flow name is used instead if this option is not specified.
65
+ State Machine name. The flow name is used instead if this option is not specified.
66
66
  """
67
67
  ...
68
- def step_functions(self, *, name: typing.Optional[str] = None) -> "metaflow.plugins.aws.step_functions.step_functions_deployer.StepFunctionsDeployer":
68
+ def argo_workflows(self, *, name: typing.Optional[str] = None) -> "metaflow.plugins.argo.argo_workflows_deployer.ArgoWorkflowsDeployer":
69
69
  """
70
- Deployer implementation for AWS Step Functions.
70
+ Deployer implementation for Argo Workflows.
71
71
 
72
72
  Parameters
73
73
  ----------
74
74
  name : str, optional, default None
75
- State Machine name. The flow name is used instead if this option is not specified.
75
+ Argo workflow name. The flow name is used instead if this option is not specified.
76
76
  """
77
77
  ...
78
78
  ...
@@ -157,45 +157,45 @@ class DeployedFlow(object, metaclass=DeployedFlowMeta):
157
157
  """
158
158
  ...
159
159
  @classmethod
160
- def from_argo_workflows(cls, *, identifier: str, metadata: typing.Optional[str] = None) -> "metaflow.plugins.argo.argo_workflows_deployer_objects.ArgoWorkflowsDeployedFlow":
160
+ def from_step_functions(cls) -> "metaflow.plugins.aws.step_functions.step_functions_deployer_objects.StepFunctionsDeployedFlow":
161
161
  """
162
- Retrieves a `ArgoWorkflowsDeployedFlow` object from an identifier and optional
163
- metadata.
164
-
162
+ This method is not currently implemented for Step Functions.
165
163
 
164
+ Raises
165
+ ------
166
+ NotImplementedError
167
+ This method is not implemented for Step Functions.
166
168
 
167
169
  Parameters
168
170
  ----------
169
- identifier : str
170
- Deployer specific identifier for the workflow to retrieve
171
- metadata : str, optional, default None
172
- Optional deployer specific metadata.
173
-
174
171
 
175
172
 
176
173
  Returns
177
174
  -------
178
- ArgoWorkflowsDeployedFlow
179
- A `ArgoWorkflowsDeployedFlow` object representing the
180
- deployed flow on argo workflows.
181
175
  """
182
176
  ...
183
177
  @classmethod
184
- def from_step_functions(cls) -> "metaflow.plugins.aws.step_functions.step_functions_deployer_objects.StepFunctionsDeployedFlow":
178
+ def from_argo_workflows(cls, *, identifier: str, metadata: typing.Optional[str] = None) -> "metaflow.plugins.argo.argo_workflows_deployer_objects.ArgoWorkflowsDeployedFlow":
185
179
  """
186
- This method is not currently implemented for Step Functions.
180
+ Retrieves a `ArgoWorkflowsDeployedFlow` object from an identifier and optional
181
+ metadata.
182
+
187
183
 
188
- Raises
189
- ------
190
- NotImplementedError
191
- This method is not implemented for Step Functions.
192
184
 
193
185
  Parameters
194
186
  ----------
187
+ identifier : str
188
+ Deployer specific identifier for the workflow to retrieve
189
+ metadata : str, optional, default None
190
+ Optional deployer specific metadata.
191
+
195
192
 
196
193
 
197
194
  Returns
198
195
  -------
196
+ ArgoWorkflowsDeployedFlow
197
+ A `ArgoWorkflowsDeployedFlow` object representing the
198
+ deployed flow on argo workflows.
199
199
  """
200
200
  ...
201
201
  ...
@@ -1,15 +1,15 @@
1
1
  ######################################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.36.3+obcheckpoint(0.1.4);ob(v1) #
4
- # Generated on 2024-12-10T22:06:22.123205 #
3
+ # MF version: 2.12.39.1+obcheckpoint(0.1.4);ob(v1) #
4
+ # Generated on 2024-12-17T01:10:55.794968 #
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.runner.deployer
12
11
  import typing
12
+ import metaflow.runner.deployer
13
13
 
14
14
  from .subprocess_manager import SubprocessManager as SubprocessManager
15
15
  from .utils import get_lower_level_group as get_lower_level_group
@@ -38,7 +38,7 @@ class DeployerImpl(object, metaclass=type):
38
38
  The directory to run the subprocess in; if not specified, the current
39
39
  directory is used.
40
40
  file_read_timeout : int, default 3600
41
- The timeout until which we try to read the deployer attribute file.
41
+ The timeout until which we try to read the deployer attribute file (in seconds).
42
42
  **kwargs : Any
43
43
  Additional arguments that you would pass to `python myflow.py` before
44
44
  the deployment command.
@@ -1,16 +1,16 @@
1
1
  ######################################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.36.3+obcheckpoint(0.1.4);ob(v1) #
4
- # Generated on 2024-12-10T22:06:22.105586 #
3
+ # MF version: 2.12.39.1+obcheckpoint(0.1.4);ob(v1) #
4
+ # Generated on 2024-12-17T01:10:55.778933 #
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.runner.metaflow_runner
12
- import metaflow.client.core
13
11
  import metaflow.runner.subprocess_manager
12
+ import metaflow.client.core
13
+ import metaflow.runner.metaflow_runner
14
14
 
15
15
  from ..client.core import Run as Run
16
16
  from .utils import temporary_fifo as temporary_fifo
@@ -193,7 +193,7 @@ class Runner(object, metaclass=type):
193
193
  The directory to run the subprocess in; if not specified, the current
194
194
  directory is used.
195
195
  file_read_timeout : int, default 3600
196
- The timeout until which we try to read the runner attribute file.
196
+ The timeout until which we try to read the runner attribute file (in seconds).
197
197
  **kwargs : Any
198
198
  Additional arguments that you would pass to `python myflow.py` before
199
199
  the `run` command.
@@ -1,7 +1,7 @@
1
1
  ######################################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.36.3+obcheckpoint(0.1.4);ob(v1) #
4
- # Generated on 2024-12-10T22:06:22.106537 #
3
+ # MF version: 2.12.39.1+obcheckpoint(0.1.4);ob(v1) #
4
+ # Generated on 2024-12-17T01:10:55.779830 #
5
5
  ######################################################################################################
6
6
 
7
7
  from __future__ import annotations
@@ -52,6 +52,8 @@ class NBDeployer(object, metaclass=type):
52
52
  base_dir : str, optional, default None
53
53
  The directory to run the subprocess in; if not specified, the current
54
54
  working directory is used.
55
+ file_read_timeout : int, default 3600
56
+ The timeout until which we try to read the deployer attribute file (in seconds).
55
57
  **kwargs : Any
56
58
  Additional arguments that you would pass to `python myflow.py` i.e. options
57
59
  listed in `python myflow.py --help`
@@ -1,7 +1,7 @@
1
1
  ######################################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.36.3+obcheckpoint(0.1.4);ob(v1) #
4
- # Generated on 2024-12-10T22:06:22.106119 #
3
+ # MF version: 2.12.39.1+obcheckpoint(0.1.4);ob(v1) #
4
+ # Generated on 2024-12-17T01:10:55.779464 #
5
5
  ######################################################################################################
6
6
 
7
7
  from __future__ import annotations
@@ -50,7 +50,7 @@ class NBRunner(object, metaclass=type):
50
50
  The directory to run the subprocess in; if not specified, the current
51
51
  working directory is used.
52
52
  file_read_timeout : int, default 3600
53
- The timeout until which we try to read the runner attribute file.
53
+ The timeout until which we try to read the runner attribute file (in seconds).
54
54
  **kwargs : Any
55
55
  Additional arguments that you would pass to `python myflow.py` before
56
56
  the `run` command.
@@ -1,7 +1,7 @@
1
1
  ######################################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.36.3+obcheckpoint(0.1.4);ob(v1) #
4
- # Generated on 2024-12-10T22:06:22.122667 #
3
+ # MF version: 2.12.39.1+obcheckpoint(0.1.4);ob(v1) #
4
+ # Generated on 2024-12-17T01:10:55.794394 #
5
5
  ######################################################################################################
6
6
 
7
7
  from __future__ import annotations
@@ -37,6 +37,9 @@ class SubprocessManager(object, metaclass=type):
37
37
  """
38
38
  Run a command synchronously and return its process ID.
39
39
 
40
+ Note: in no case does this wait for the process to *finish*. Use sync_wait()
41
+ to wait for the command to finish.
42
+
40
43
  Parameters
41
44
  ----------
42
45
  command : List[str]
@@ -1,7 +1,7 @@
1
1
  ######################################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.36.3+obcheckpoint(0.1.4);ob(v1) #
4
- # Generated on 2024-12-10T22:06:22.121510 #
3
+ # MF version: 2.12.39.1+obcheckpoint(0.1.4);ob(v1) #
4
+ # Generated on 2024-12-17T01:10:55.793297 #
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.runner.subprocess_manager
12
- import metaflow.runner.click_api
13
12
  import typing
13
+ import metaflow.runner.click_api
14
14
 
15
15
 
16
16
  TYPE_CHECKING: bool
@@ -54,7 +54,7 @@ def read_from_fifo_when_ready(fifo_fd: int, command_obj: "metaflow.runner.subpro
54
54
  encoding : str, optional
55
55
  Encoding to use while reading the file, by default "utf-8".
56
56
  timeout : int, optional
57
- Timeout for reading the file in milliseconds, by default 3600.
57
+ Timeout for reading the file in seconds, by default 3600.
58
58
 
59
59
  Returns
60
60
  -------
@@ -84,7 +84,7 @@ def async_read_from_fifo_when_ready(fifo_fd: int, command_obj: "metaflow.runner.
84
84
  encoding : str, optional
85
85
  Encoding to use while reading the file, by default "utf-8".
86
86
  timeout : int, optional
87
- Timeout for reading the file in milliseconds, by default 3600.
87
+ Timeout for reading the file in seconds, by default 3600.
88
88
 
89
89
  Returns
90
90
  -------
@@ -116,7 +116,7 @@ def handle_timeout(attribute_file_fd: int, command_obj: "metaflow.runner.subproc
116
116
  command_obj : CommandManager
117
117
  Command manager object that encapsulates the running command details.
118
118
  file_read_timeout : int
119
- Timeout for reading the file.
119
+ Timeout for reading the file, in seconds
120
120
 
121
121
  Returns
122
122
  -------
@@ -143,7 +143,7 @@ def async_handle_timeout(attribute_file_fd: int, command_obj: "metaflow.runner.s
143
143
  command_obj : CommandManager
144
144
  Command manager object that encapsulates the running command details.
145
145
  file_read_timeout : int
146
- Timeout for reading the file.
146
+ Timeout for reading the file, in seconds
147
147
 
148
148
  Returns
149
149
  -------
@@ -1,7 +1,7 @@
1
1
  ######################################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.36.3+obcheckpoint(0.1.4);ob(v1) #
4
- # Generated on 2024-12-10T22:06:22.110648 #
3
+ # MF version: 2.12.39.1+obcheckpoint(0.1.4);ob(v1) #
4
+ # Generated on 2024-12-17T01:10:55.783124 #
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.36.3+obcheckpoint(0.1.4);ob(v1) #
4
- # Generated on 2024-12-10T22:06:22.134883 #
3
+ # MF version: 2.12.39.1+obcheckpoint(0.1.4);ob(v1) #
4
+ # Generated on 2024-12-17T01:10:55.805962 #
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.event_logger
12
11
  import typing
12
+ import metaflow.event_logger
13
13
 
14
14
 
15
15
  class SystemLogger(object, metaclass=type):
@@ -1,7 +1,7 @@
1
1
  ######################################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.36.3+obcheckpoint(0.1.4);ob(v1) #
4
- # Generated on 2024-12-10T22:06:22.134544 #
3
+ # MF version: 2.12.39.1+obcheckpoint(0.1.4);ob(v1) #
4
+ # Generated on 2024-12-17T01:10:55.805619 #
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.3+obcheckpoint(0.1.4);ob(v1) #
4
- # Generated on 2024-12-10T22:06:22.095403 #
3
+ # MF version: 2.12.39.1+obcheckpoint(0.1.4);ob(v1) #
4
+ # Generated on 2024-12-17T01:10:55.765838 #
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.3+obcheckpoint(0.1.4);ob(v1) #
4
- # Generated on 2024-12-10T22:06:22.096807 #
3
+ # MF version: 2.12.39.1+obcheckpoint(0.1.4);ob(v1) #
4
+ # Generated on 2024-12-17T01:10:55.770550 #
5
5
  ######################################################################################################
6
6
 
7
7
  from __future__ import annotations
@@ -1,19 +1,13 @@
1
1
  ######################################################################################################
2
2
  # Auto-generated Metaflow stub file #
3
- # MF version: 2.12.36.3+obcheckpoint(0.1.4);ob(v1) #
4
- # Generated on 2024-12-10T22:06:22.166738 #
3
+ # MF version: 2.12.39.1+obcheckpoint(0.1.4);ob(v1) #
4
+ # Generated on 2024-12-17T01:10:55.765525 #
5
5
  ######################################################################################################
6
6
 
7
7
  from __future__ import annotations
8
8
 
9
9
 
10
-
11
- def new_token(token_prefix, prev_token = None):
12
- ...
13
-
14
- def load_token(token_prefix):
15
- ...
16
-
17
- def store_token(token_prefix, token):
18
- ...
10
+ from . import config_parameters as config_parameters
11
+ from . import config_decorators as config_decorators
12
+ from . import config_options as config_options
19
13
 
@@ -0,0 +1,253 @@
1
+ ######################################################################################################
2
+ # Auto-generated Metaflow stub file #
3
+ # MF version: 2.12.39.1+obcheckpoint(0.1.4);ob(v1) #
4
+ # Generated on 2024-12-17T01:10:55.769764 #
5
+ ######################################################################################################
6
+
7
+ from __future__ import annotations
8
+
9
+ import typing
10
+ if typing.TYPE_CHECKING:
11
+ import metaflow.user_configs.config_decorators
12
+ import metaflow.flowspec
13
+ import metaflow.user_configs.config_parameters
14
+ import metaflow.parameters
15
+ import typing
16
+ import metaflow.decorators
17
+ import functools
18
+
19
+ from ..exception import MetaflowException as MetaflowException
20
+ from .config_parameters import ConfigValue as ConfigValue
21
+ from .config_parameters import resolve_delayed_evaluator as resolve_delayed_evaluator
22
+
23
+ TYPE_CHECKING: bool
24
+
25
+ class MutableStep(object, metaclass=type):
26
+ """
27
+ A MutableStep is a wrapper passed to the `CustomStepDecorator`'s `evaluate` method
28
+ to allow the decorator to interact with the step and providing easy methods to
29
+ modify the behavior of the step.
30
+ """
31
+ def __init__(self, flow_spec: "metaflow.flowspec.FlowSpec", step: typing.Union[typing.Callable[["metaflow.decorators.FlowSpecDerived"], None], typing.Callable[["metaflow.decorators.FlowSpecDerived", typing.Any], None]]):
32
+ ...
33
+ @property
34
+ def flow(self) -> MutableFlow:
35
+ """
36
+ The flow that contains this step
37
+
38
+ Returns
39
+ -------
40
+ MutableFlow
41
+ The flow that contains this step
42
+ """
43
+ ...
44
+ @property
45
+ def decorators(self) -> typing.Generator["metaflow.decorators.StepDecorator", None, None]:
46
+ """
47
+ Iterate over all the decorators of this step. Note that the same type of decorator
48
+ may be present multiple times and no order is guaranteed.
49
+
50
+ Yields
51
+ ------
52
+ metaflow.decorators.StepDecorator
53
+ A decorator of the step
54
+ """
55
+ ...
56
+ def add_decorator(self, deco_type: functools.partial, **kwargs):
57
+ """
58
+ Add a Metaflow decorator to a step.
59
+
60
+ Parameters
61
+ ----------
62
+ deco_type : partial
63
+ The decorator class to add to this step
64
+ """
65
+ ...
66
+ def remove_decorator(self, deco_name: str, all: bool = True, **kwargs) -> bool:
67
+ """
68
+ Remove one or more Metaflow decorators from a step.
69
+
70
+ Some decorators can be applied multiple times to a step. This method allows you
71
+ to choose which decorator to remove or just remove all of them or one of them.
72
+
73
+ Parameters
74
+ ----------
75
+ deco_name : str
76
+ Name of the decorator to remove
77
+ all : bool, default True
78
+ If True, remove all instances of the decorator that match the filters
79
+ passed using kwargs (or all the instances of the decorator if no filters are
80
+ passed). If False, removes only the first found instance of the decorator.
81
+
82
+ Returns
83
+ -------
84
+ bool
85
+ Returns True if at least one decorator was removed.
86
+ """
87
+ ...
88
+ ...
89
+
90
+ class MutableFlow(object, metaclass=type):
91
+ def __init__(self, flow_spec: "metaflow.flowspec.FlowSpec"):
92
+ ...
93
+ @property
94
+ def decorators(self) -> typing.Generator["metaflow.decorators.FlowDecorator", None, None]:
95
+ """
96
+ Iterate over all the decorators of this flow. Note that the same type of decorator
97
+ may be present multiple times and no order is guaranteed.
98
+
99
+ Yields
100
+ ------
101
+ metaflow.decorators.FlowDecorator
102
+ A decorator of the flow
103
+ """
104
+ ...
105
+ @property
106
+ def configs(self) -> typing.Generator[typing.Tuple[str, metaflow.user_configs.config_parameters.ConfigValue], None, None]:
107
+ """
108
+ Iterate over all user configurations in this flow
109
+
110
+ Use this to parameterize your flow based on configuration. As an example, the
111
+ `evaluate` method of your `CustomFlowDecorator` can use this to add an
112
+ environment decorator.
113
+ ```
114
+ class MyDecorator(CustomFlowDecorator):
115
+ def evaluate(flow: MutableFlow):
116
+ val = next(flow.configs)[1].steps.start.cpu
117
+ flow.start.add_decorator(environment, vars={'mycpu': val})
118
+ return flow
119
+
120
+ @MyDecorator()
121
+ class TestFlow(FlowSpec):
122
+ config = Config('myconfig.json')
123
+
124
+ @step
125
+ def start(self):
126
+ pass
127
+ ```
128
+ can be used to add an environment decorator to the `start` step.
129
+
130
+ Yields
131
+ ------
132
+ Tuple[str, ConfigValue]
133
+ Iterates over the configurations of the flow
134
+ """
135
+ ...
136
+ @property
137
+ def parameters(self) -> typing.Generator[typing.Tuple[str, typing.Any], None, None]:
138
+ ...
139
+ @property
140
+ def steps(self) -> typing.Generator[typing.Tuple[str, MutableStep], None, None]:
141
+ """
142
+ Iterate over all the steps in this flow. The order of the steps
143
+ returned is not guaranteed.
144
+
145
+ Yields
146
+ ------
147
+ Tuple[str, MutableStep]
148
+ A tuple with the step name and the step proxy
149
+ """
150
+ ...
151
+ def add_parameter(self, name: str, value: "metaflow.parameters.Parameter", overwrite: bool = False):
152
+ ...
153
+ def remove_parameter(self, parameter_name: str) -> bool:
154
+ """
155
+ Remove a parameter from the flow.
156
+
157
+ The name given should match the name of the parameter (can be different
158
+ from the name of the parameter in the flow. You can not remove config parameters.
159
+
160
+ Parameters
161
+ ----------
162
+ parameter_name : str
163
+ Name of the parameter
164
+
165
+ Returns
166
+ -------
167
+ bool
168
+ Returns True if the parameter was removed
169
+ """
170
+ ...
171
+ def add_decorator(self, deco_type: functools.partial, **kwargs):
172
+ """
173
+ Add a Metaflow decorator to a flow.
174
+
175
+ Parameters
176
+ ----------
177
+ deco_type : partial
178
+ The decorator class to add to this flow
179
+ """
180
+ ...
181
+ def remove_decorator(self, deco_name: str, all: bool = True, **kwargs) -> bool:
182
+ """
183
+ Remove one or more Metaflow decorators from a flow.
184
+
185
+ Some decorators can be applied multiple times to a flow. This method allows you
186
+ to choose which decorator to remove or just remove all of them or one of them.
187
+
188
+ Parameters
189
+ ----------
190
+ deco_name : str
191
+ Name of the decorator to remove
192
+ all : bool, default True
193
+ If True, remove all instances of the decorator that match the filters
194
+ passed using kwargs (or all the instances of the decorator if no filters are
195
+ passed). If False, removes only the first found instance of the decorator.
196
+
197
+ Returns
198
+ -------
199
+ bool
200
+ Returns True if at least one decorator was removed.
201
+ """
202
+ ...
203
+ def __getattr__(self, name):
204
+ ...
205
+ ...
206
+
207
+ class CustomFlowDecorator(object, metaclass=type):
208
+ def __init__(self, *args, **kwargs):
209
+ ...
210
+ def __get__(self, instance, owner):
211
+ ...
212
+ def __call__(self, flow_spec: typing.Optional["metaflow.flowspec.FlowSpecMeta"] = None) -> "metaflow.flowspec.FlowSpecMeta":
213
+ ...
214
+ def init(self, *args, **kwargs):
215
+ """
216
+ This method is intended to be optionally overridden if you need to
217
+ have an initializer.
218
+ """
219
+ ...
220
+ def evaluate(self, mutable_flow: MutableFlow):
221
+ """
222
+ Implement this method to act on the flow and modify it as needed.
223
+
224
+ Parameters
225
+ ----------
226
+ mutable_flow : MutableFlow
227
+ Flow
228
+
229
+ Raises
230
+ ------
231
+ NotImplementedError
232
+ _description_
233
+ """
234
+ ...
235
+ ...
236
+
237
+ class CustomStepDecorator(object, metaclass=type):
238
+ def __init__(self, *args, **kwargs):
239
+ ...
240
+ def __get__(self, instance, owner):
241
+ ...
242
+ def __call__(self, step: typing.Union[typing.Callable[["metaflow.decorators.FlowSpecDerived"], None], typing.Callable[["metaflow.decorators.FlowSpecDerived", typing.Any], None], None] = None) -> typing.Union[typing.Callable[["metaflow.decorators.FlowSpecDerived"], None], typing.Callable[["metaflow.decorators.FlowSpecDerived", typing.Any], None]]:
243
+ ...
244
+ def init(self, *args, **kwargs):
245
+ """
246
+ This method is intended to be optionally overridden if you need to
247
+ have an initializer.
248
+ """
249
+ ...
250
+ def evaluate(self, mutable_step: MutableStep):
251
+ ...
252
+ ...
253
+