zenml-nightly 0.58.2.dev20240623__py3-none-any.whl → 0.61.0.dev20240712__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.
- README.md +30 -9
- RELEASE_NOTES.md +240 -0
- zenml/VERSION +1 -1
- zenml/actions/base_action.py +177 -174
- zenml/actions/pipeline_run/pipeline_run_action.py +28 -23
- zenml/analytics/enums.py +3 -0
- zenml/artifact_stores/base_artifact_store.py +7 -1
- zenml/artifacts/utils.py +13 -10
- zenml/cli/__init__.py +28 -0
- zenml/cli/artifact.py +1 -2
- zenml/cli/integration.py +9 -8
- zenml/cli/server.py +6 -0
- zenml/cli/service_connectors.py +1 -0
- zenml/cli/stack.py +946 -39
- zenml/cli/stack_components.py +7 -0
- zenml/cli/text_utils.py +35 -1
- zenml/cli/utils.py +127 -10
- zenml/client.py +257 -72
- zenml/config/compiler.py +10 -9
- zenml/config/docker_settings.py +33 -14
- zenml/constants.py +11 -2
- zenml/container_registries/base_container_registry.py +1 -0
- zenml/enums.py +7 -0
- zenml/event_hub/base_event_hub.py +5 -5
- zenml/event_hub/event_hub.py +20 -14
- zenml/event_sources/base_event.py +0 -11
- zenml/event_sources/base_event_source.py +7 -0
- zenml/event_sources/webhooks/base_webhook_event_source.py +1 -4
- zenml/exceptions.py +4 -0
- zenml/hooks/hook_validators.py +2 -3
- zenml/integrations/aws/__init__.py +1 -0
- zenml/integrations/azure/__init__.py +1 -0
- zenml/integrations/bitbucket/plugins/event_sources/bitbucket_webhook_event_source.py +3 -3
- zenml/integrations/deepchecks/__init__.py +1 -0
- zenml/integrations/discord/__init__.py +1 -0
- zenml/integrations/evidently/__init__.py +1 -0
- zenml/integrations/facets/__init__.py +1 -0
- zenml/integrations/feast/__init__.py +1 -0
- zenml/integrations/gcp/__init__.py +3 -1
- zenml/integrations/gcp/google_credentials_mixin.py +1 -1
- zenml/integrations/gcp/service_connectors/gcp_service_connector.py +320 -64
- zenml/integrations/huggingface/__init__.py +1 -0
- zenml/integrations/integration.py +24 -0
- zenml/integrations/kubeflow/__init__.py +3 -0
- zenml/integrations/kubeflow/flavors/kubeflow_orchestrator_flavor.py +1 -1
- zenml/integrations/kubeflow/orchestrators/kubeflow_orchestrator.py +0 -1
- zenml/integrations/kubernetes/__init__.py +3 -1
- zenml/integrations/kubernetes/orchestrators/kube_utils.py +4 -1
- zenml/integrations/label_studio/annotators/label_studio_annotator.py +1 -0
- zenml/integrations/langchain/__init__.py +1 -0
- zenml/integrations/mlflow/__init__.py +4 -2
- zenml/integrations/neural_prophet/__init__.py +1 -0
- zenml/integrations/polars/__init__.py +1 -0
- zenml/integrations/prodigy/__init__.py +1 -0
- zenml/integrations/pycaret/__init__.py +6 -0
- zenml/integrations/registry.py +37 -0
- zenml/integrations/s3/artifact_stores/s3_artifact_store.py +93 -9
- zenml/integrations/seldon/__init__.py +1 -0
- zenml/integrations/seldon/model_deployers/seldon_model_deployer.py +1 -0
- zenml/integrations/skypilot/flavors/skypilot_orchestrator_base_vm_config.py +2 -2
- zenml/integrations/skypilot/orchestrators/skypilot_base_vm_orchestrator.py +1 -1
- zenml/integrations/skypilot/orchestrators/skypilot_orchestrator_entrypoint.py +2 -2
- zenml/integrations/skypilot_aws/__init__.py +2 -1
- zenml/integrations/skypilot_azure/__init__.py +1 -1
- zenml/integrations/skypilot_gcp/__init__.py +1 -1
- zenml/integrations/skypilot_lambda/__init__.py +1 -1
- zenml/integrations/skypilot_lambda/flavors/skypilot_orchestrator_lambda_vm_flavor.py +1 -1
- zenml/integrations/slack/__init__.py +1 -0
- zenml/integrations/tekton/__init__.py +1 -0
- zenml/integrations/tensorboard/__init__.py +0 -1
- zenml/integrations/tensorflow/__init__.py +18 -6
- zenml/integrations/wandb/__init__.py +1 -0
- zenml/logging/step_logging.py +54 -51
- zenml/models/__init__.py +28 -0
- zenml/models/v2/core/action.py +276 -0
- zenml/models/v2/core/component.py +18 -0
- zenml/models/v2/core/model.py +1 -2
- zenml/models/v2/core/service_connector.py +17 -0
- zenml/models/v2/core/stack.py +31 -0
- zenml/models/v2/core/trigger.py +182 -141
- zenml/models/v2/misc/full_stack.py +97 -0
- zenml/models/v2/misc/stack_deployment.py +86 -0
- zenml/new/pipelines/pipeline.py +14 -4
- zenml/new/pipelines/pipeline_decorator.py +1 -2
- zenml/new/pipelines/run_utils.py +1 -12
- zenml/new/steps/step_decorator.py +2 -3
- zenml/orchestrators/input_utils.py +3 -6
- zenml/pipelines/base_pipeline.py +0 -2
- zenml/pipelines/pipeline_decorator.py +1 -2
- zenml/stack/stack.py +3 -6
- zenml/stack/stack_component.py +4 -0
- zenml/stack_deployments/__init__.py +14 -0
- zenml/stack_deployments/aws_stack_deployment.py +254 -0
- zenml/stack_deployments/gcp_stack_deployment.py +260 -0
- zenml/stack_deployments/stack_deployment.py +208 -0
- zenml/stack_deployments/utils.py +44 -0
- zenml/steps/base_step.py +1 -2
- zenml/steps/step_decorator.py +1 -2
- zenml/types.py +10 -1
- zenml/utils/function_utils.py +1 -1
- zenml/utils/pagination_utils.py +7 -5
- zenml/utils/pipeline_docker_image_builder.py +117 -73
- zenml/utils/pydantic_utils.py +6 -5
- zenml/zen_server/cloud_utils.py +18 -3
- zenml/zen_server/dashboard/assets/{404-CDPQCl4D.js → 404-DpJaNHKF.js} +1 -1
- zenml/zen_server/dashboard/assets/@radix-CFOkMR_E.js +85 -0
- zenml/zen_server/dashboard/assets/{@react-router-DYovave8.js → @react-router-CO-OsFwI.js} +2 -2
- zenml/zen_server/dashboard/assets/{@reactflow-CHBapDaj.js → @reactflow-DJfzkHO1.js} +2 -2
- zenml/zen_server/dashboard/assets/@tanstack-DYiOyJUL.js +22 -0
- zenml/zen_server/dashboard/assets/AwarenessChannel-BYDLT2xC.js +1 -0
- zenml/zen_server/dashboard/assets/{CodeSnippet-BidtnWOi.js → CodeSnippet-BkOuRmyq.js} +2 -2
- zenml/zen_server/dashboard/assets/Commands-ZvWR1BRs.js +1 -0
- zenml/zen_server/dashboard/assets/CopyButton-DVwLkafa.js +2 -0
- zenml/zen_server/dashboard/assets/{CsvVizualization-BOuez-fG.js → CsvVizualization-C2IiqX4I.js} +7 -7
- zenml/zen_server/dashboard/assets/DisplayDate-DYgIjlDF.js +1 -0
- zenml/zen_server/dashboard/assets/EmptyState-BMLnFVlB.js +1 -0
- zenml/zen_server/dashboard/assets/Error-CqX0VqW_.js +1 -0
- zenml/zen_server/dashboard/assets/ExecutionStatus-BoLUXR9t.js +1 -0
- zenml/zen_server/dashboard/assets/Helpbox-LFydyVwh.js +1 -0
- zenml/zen_server/dashboard/assets/Infobox-DnENC0sh.js +1 -0
- zenml/zen_server/dashboard/assets/InlineAvatar-CbJtYr0t.js +1 -0
- zenml/zen_server/dashboard/assets/{MarkdownVisualization-DsB2QZiK.js → MarkdownVisualization-xp3hhULl.js} +2 -2
- zenml/zen_server/dashboard/assets/Pagination-DEbVUupy.js +1 -0
- zenml/zen_server/dashboard/assets/PasswordChecker-DUveqlva.js +1 -0
- zenml/zen_server/dashboard/assets/SetPassword-BYBdbQDo.js +1 -0
- zenml/zen_server/dashboard/assets/SuccessStep-Nx743hll.js +1 -0
- zenml/zen_server/dashboard/assets/{UpdatePasswordSchemas-DnM-c11H.js → UpdatePasswordSchemas-DF9gSzE0.js} +1 -1
- zenml/zen_server/dashboard/assets/{aws-t0gKCj_R.js → aws-BgKTfTfx.js} +1 -1
- zenml/zen_server/dashboard/assets/{check-circle-BVvhm5dy.js → check-circle-i56092KI.js} +1 -1
- zenml/zen_server/dashboard/assets/{chevron-down-zcvCWmyP.js → chevron-down-D_ZlKMqH.js} +1 -1
- zenml/zen_server/dashboard/assets/{chevron-right-double-CJ50E9Gr.js → chevron-right-double-BiEMg7rd.js} +1 -1
- zenml/zen_server/dashboard/assets/cloud-only-DVbIeckv.js +1 -0
- zenml/zen_server/dashboard/assets/{copy-BRhQz3j-.js → copy-BXNk6BjL.js} +1 -1
- zenml/zen_server/dashboard/assets/{database-CRRnyFWh.js → database-1xWSgZfO.js} +1 -1
- zenml/zen_server/dashboard/assets/{docker-BAonhm6G.js → docker-CQMVm_4d.js} +1 -1
- zenml/zen_server/dashboard/assets/{file-text-CbVERUON.js → file-text-CqD_iu6l.js} +1 -1
- zenml/zen_server/dashboard/assets/{help-B8rqCvqn.js → help-bu_DgLKI.js} +1 -1
- zenml/zen_server/dashboard/assets/index-C_CrU4vI.js +1 -0
- zenml/zen_server/dashboard/assets/index-DK1ynKjA.js +55 -0
- zenml/zen_server/dashboard/assets/index-inApY3KQ.css +1 -0
- zenml/zen_server/dashboard/assets/index-rK_Wuy2W.js +1 -0
- zenml/zen_server/dashboard/assets/index.esm-Corw4lXQ.js +1 -0
- zenml/zen_server/dashboard/assets/{login-mutation-wzzl23C6.js → login-mutation-BUnVASxp.js} +1 -1
- zenml/zen_server/dashboard/assets/not-found-B4VnX8gK.js +1 -0
- zenml/zen_server/dashboard/assets/package-CsUhPmou.js +1 -0
- zenml/zen_server/dashboard/assets/{page-BmkSiYeQ.js → page-3efNCDeb.js} +2 -2
- zenml/zen_server/dashboard/assets/page-7zTHbhhI.js +1 -0
- zenml/zen_server/dashboard/assets/page-BEs6jK71.js +1 -0
- zenml/zen_server/dashboard/assets/page-BpSqIf4B.js +1 -0
- zenml/zen_server/dashboard/assets/{page-AQKopn_4.js → page-Bx6o0ARS.js} +1 -1
- zenml/zen_server/dashboard/assets/page-C43QGHTt.js +9 -0
- zenml/zen_server/dashboard/assets/page-CR0OG7ss.js +1 -0
- zenml/zen_server/dashboard/assets/page-CRTJ0UuR.js +1 -0
- zenml/zen_server/dashboard/assets/page-CUZIGO-3.js +1 -0
- zenml/zen_server/dashboard/assets/page-CaopxiU1.js +1 -0
- zenml/zen_server/dashboard/assets/{page-CuT1SUik.js → page-Cx67M0QT.js} +1 -1
- zenml/zen_server/dashboard/assets/page-D7Z399xy.js +1 -0
- zenml/zen_server/dashboard/assets/page-D93kd7Xj.js +1 -0
- zenml/zen_server/dashboard/assets/{page-BzVZGExK.js → page-DKlIdAe5.js} +1 -1
- zenml/zen_server/dashboard/assets/{page-Bi5AI0S7.js → page-DMOYZppS.js} +1 -1
- zenml/zen_server/dashboard/assets/page-DMsSn3dv.js +2 -0
- zenml/zen_server/dashboard/assets/{page-BW6Ket3a.js → page-Dc_7KMQE.js} +1 -1
- zenml/zen_server/dashboard/assets/page-DvCvroOM.js +1 -0
- zenml/zen_server/dashboard/assets/page-Hus2pr9T.js +1 -0
- zenml/zen_server/dashboard/assets/page-JyfeDUfu.js +1 -0
- zenml/zen_server/dashboard/assets/{page-yN4rZ-ZS.js → page-Sxn82W-5.js} +1 -1
- zenml/zen_server/dashboard/assets/page-TKXERe16.js +1 -0
- zenml/zen_server/dashboard/assets/page-Xu8JEjSU.js +1 -0
- zenml/zen_server/dashboard/assets/{play-circle-DK5QMJyp.js → play-circle-CNtZKDnW.js} +1 -1
- zenml/zen_server/dashboard/assets/plus-DOeLmm7C.js +1 -0
- zenml/zen_server/dashboard/assets/{terminal-B2ovgWuz.js → terminal-By9cErXc.js} +1 -1
- zenml/zen_server/dashboard/assets/{update-server-settings-mutation-0Wgz8pUE.js → update-server-settings-mutation-CR8e3Sir.js} +1 -1
- zenml/zen_server/dashboard/assets/{url-6_xv0WJS.js → url-DuQMeqYA.js} +1 -1
- zenml/zen_server/dashboard/assets/{zod-DrZvVLjd.js → zod-BhoGpZ63.js} +1 -1
- zenml/zen_server/dashboard/index.html +7 -7
- zenml/zen_server/dashboard_legacy/asset-manifest.json +4 -4
- zenml/zen_server/dashboard_legacy/index.html +1 -1
- zenml/zen_server/dashboard_legacy/{precache-manifest.f4abc5b7cfa7d90c1caf5521918e29a8.js → precache-manifest.c8c57fb0d2132b1d3c2119e776b7dfb3.js} +4 -4
- zenml/zen_server/dashboard_legacy/service-worker.js +1 -1
- zenml/zen_server/dashboard_legacy/static/js/{main.ac2f17d0.chunk.js → main.382439a7.chunk.js} +2 -2
- zenml/zen_server/dashboard_legacy/static/js/{main.ac2f17d0.chunk.js.map → main.382439a7.chunk.js.map} +1 -1
- zenml/zen_server/deploy/helm/Chart.yaml +1 -1
- zenml/zen_server/deploy/helm/README.md +2 -2
- zenml/zen_server/feature_gate/zenml_cloud_feature_gate.py +11 -5
- zenml/zen_server/pipeline_deployment/utils.py +57 -44
- zenml/zen_server/rbac/models.py +1 -0
- zenml/zen_server/rbac/utils.py +22 -1
- zenml/zen_server/rbac/zenml_cloud_rbac.py +11 -5
- zenml/zen_server/routers/actions_endpoints.py +324 -0
- zenml/zen_server/routers/stack_deployment_endpoints.py +158 -0
- zenml/zen_server/routers/triggers_endpoints.py +30 -158
- zenml/zen_server/routers/workspaces_endpoints.py +64 -0
- zenml/zen_server/zen_server_api.py +4 -0
- zenml/zen_stores/migrations/utils.py +1 -1
- zenml/zen_stores/migrations/versions/0.60.0_release.py +23 -0
- zenml/zen_stores/migrations/versions/0.61.0_release.py +23 -0
- zenml/zen_stores/migrations/versions/0d707865f404_adding_labels_to_stacks.py +30 -0
- zenml/zen_stores/migrations/versions/25155145c545_separate_actions_and_triggers.py +228 -0
- zenml/zen_stores/rest_zen_store.py +248 -8
- zenml/zen_stores/schemas/__init__.py +2 -0
- zenml/zen_stores/schemas/action_schemas.py +192 -0
- zenml/zen_stores/schemas/stack_schemas.py +10 -0
- zenml/zen_stores/schemas/step_run_schemas.py +27 -11
- zenml/zen_stores/schemas/trigger_schemas.py +43 -50
- zenml/zen_stores/schemas/user_schemas.py +10 -2
- zenml/zen_stores/schemas/workspace_schemas.py +5 -0
- zenml/zen_stores/sql_zen_store.py +540 -36
- zenml/zen_stores/zen_store_interface.py +165 -0
- {zenml_nightly-0.58.2.dev20240623.dist-info → zenml_nightly-0.61.0.dev20240712.dist-info}/METADATA +33 -11
- {zenml_nightly-0.58.2.dev20240623.dist-info → zenml_nightly-0.61.0.dev20240712.dist-info}/RECORD +213 -193
- zenml/zen_server/dashboard/assets/@radix-C9DBgJhe.js +0 -77
- zenml/zen_server/dashboard/assets/@tanstack-CEbkxrhX.js +0 -30
- zenml/zen_server/dashboard/assets/AwarenessChannel-nXGpmj_f.js +0 -1
- zenml/zen_server/dashboard/assets/Cards-nwsvQLVS.js +0 -1
- zenml/zen_server/dashboard/assets/Commands-DuIWKg_Q.js +0 -1
- zenml/zen_server/dashboard/assets/CopyButton-B_YSm-Ds.js +0 -2
- zenml/zen_server/dashboard/assets/DisplayDate-BdguISQF.js +0 -1
- zenml/zen_server/dashboard/assets/EmptyState-BkooiGtL.js +0 -1
- zenml/zen_server/dashboard/assets/Error-B6M0dPph.js +0 -1
- zenml/zen_server/dashboard/assets/Helpbox-BQoqCm04.js +0 -1
- zenml/zen_server/dashboard/assets/Infobox-Ce9mefqU.js +0 -1
- zenml/zen_server/dashboard/assets/InlineAvatar-DGf3dVhV.js +0 -1
- zenml/zen_server/dashboard/assets/PageHeader-DGaemzjc.js +0 -1
- zenml/zen_server/dashboard/assets/Pagination-DVYfBCCc.js +0 -1
- zenml/zen_server/dashboard/assets/PasswordChecker-DSLBp7Vl.js +0 -1
- zenml/zen_server/dashboard/assets/SetPassword-B5s7DJug.js +0 -1
- zenml/zen_server/dashboard/assets/SuccessStep-ZzczaM7g.js +0 -1
- zenml/zen_server/dashboard/assets/cloud-only-Ba_ShBR5.js +0 -1
- zenml/zen_server/dashboard/assets/index-CWJ3xbIf.css +0 -1
- zenml/zen_server/dashboard/assets/index-QORVVTMN.js +0 -55
- zenml/zen_server/dashboard/assets/index.esm-F7nqy9zY.js +0 -1
- zenml/zen_server/dashboard/assets/not-found-Dh2la7kh.js +0 -1
- zenml/zen_server/dashboard/assets/page-B-5jAKoO.js +0 -1
- zenml/zen_server/dashboard/assets/page-B-vWk8a6.js +0 -1
- zenml/zen_server/dashboard/assets/page-B0BrqfS8.js +0 -1
- zenml/zen_server/dashboard/assets/page-BQxVFlUl.js +0 -1
- zenml/zen_server/dashboard/assets/page-ByrHy6Ss.js +0 -1
- zenml/zen_server/dashboard/assets/page-CPtY4Kv_.js +0 -1
- zenml/zen_server/dashboard/assets/page-CmmukLsl.js +0 -1
- zenml/zen_server/dashboard/assets/page-D2D-7qyr.js +0 -9
- zenml/zen_server/dashboard/assets/page-DAQQyLxT.js +0 -1
- zenml/zen_server/dashboard/assets/page-DHkUMl_E.js +0 -1
- zenml/zen_server/dashboard/assets/page-DZCbwOEs.js +0 -2
- zenml/zen_server/dashboard/assets/page-DdaIt20-.js +0 -1
- zenml/zen_server/dashboard/assets/page-LqLs24Ot.js +0 -1
- zenml/zen_server/dashboard/assets/page-lebv0c7C.js +0 -1
- {zenml_nightly-0.58.2.dev20240623.dist-info → zenml_nightly-0.61.0.dev20240712.dist-info}/LICENSE +0 -0
- {zenml_nightly-0.58.2.dev20240623.dist-info → zenml_nightly-0.61.0.dev20240712.dist-info}/WHEEL +0 -0
- {zenml_nightly-0.58.2.dev20240623.dist-info → zenml_nightly-0.61.0.dev20240712.dist-info}/entry_points.txt +0 -0
@@ -24,20 +24,21 @@ from zenml.actions.base_action import (
|
|
24
24
|
from zenml.config.global_config import GlobalConfiguration
|
25
25
|
from zenml.config.pipeline_run_configuration import PipelineRunConfiguration
|
26
26
|
from zenml.enums import PluginSubType
|
27
|
+
from zenml.logger import get_logger
|
27
28
|
from zenml.models import (
|
29
|
+
ActionRequest,
|
30
|
+
ActionResponse,
|
31
|
+
ActionUpdate,
|
28
32
|
TriggerExecutionResponse,
|
29
|
-
TriggerRequest,
|
30
|
-
TriggerResponse,
|
31
|
-
TriggerUpdate,
|
32
33
|
)
|
33
34
|
from zenml.models.v2.base.base import BaseResponse
|
34
35
|
from zenml.zen_server.auth import AuthContext
|
35
36
|
from zenml.zen_server.pipeline_deployment.utils import run_pipeline
|
36
|
-
from zenml.zen_server.rbac.models import
|
37
|
-
ResourceType,
|
38
|
-
)
|
37
|
+
from zenml.zen_server.rbac.models import ResourceType
|
39
38
|
from zenml.zen_server.utils import server_config
|
40
39
|
|
40
|
+
logger = get_logger(__name__)
|
41
|
+
|
41
42
|
# -------------------- Configuration Models ----------------------------------
|
42
43
|
|
43
44
|
|
@@ -95,7 +96,7 @@ class PipelineRunActionHandler(BaseActionHandler):
|
|
95
96
|
assert isinstance(config, PipelineRunActionConfiguration)
|
96
97
|
|
97
98
|
deployment = zen_store().get_deployment(config.pipeline_deployment_id)
|
98
|
-
|
99
|
+
logger.debug("Running deployment:", deployment)
|
99
100
|
run_pipeline(
|
100
101
|
deployment=deployment,
|
101
102
|
run_config=config.run_config,
|
@@ -121,13 +122,13 @@ class PipelineRunActionHandler(BaseActionHandler):
|
|
121
122
|
except KeyError:
|
122
123
|
raise ValueError(f"No deployment found with id {deployment_id}.")
|
123
124
|
|
124
|
-
def
|
125
|
-
self,
|
125
|
+
def _validate_action_request(
|
126
|
+
self, action: ActionRequest, config: ActionConfig
|
126
127
|
) -> None:
|
127
|
-
"""Validate
|
128
|
+
"""Validate an action request before it is created in the database.
|
128
129
|
|
129
130
|
Args:
|
130
|
-
|
131
|
+
action: Action request.
|
131
132
|
config: Action configuration instantiated from the request.
|
132
133
|
"""
|
133
134
|
assert isinstance(config, PipelineRunActionConfiguration)
|
@@ -135,25 +136,25 @@ class PipelineRunActionHandler(BaseActionHandler):
|
|
135
136
|
self._validate_configuration(config)
|
136
137
|
|
137
138
|
# If an expiration window is not set, we set it to the default value
|
138
|
-
if
|
139
|
-
|
139
|
+
if action.auth_window is None:
|
140
|
+
action.auth_window = server_config().pipeline_run_auth_window
|
140
141
|
|
141
|
-
def
|
142
|
+
def _validate_action_update(
|
142
143
|
self,
|
143
|
-
|
144
|
+
action: ActionResponse,
|
144
145
|
config: ActionConfig,
|
145
|
-
|
146
|
+
action_update: ActionUpdate,
|
146
147
|
config_update: ActionConfig,
|
147
148
|
) -> None:
|
148
|
-
"""Validate
|
149
|
+
"""Validate an action update before it is reflected in the database.
|
149
150
|
|
150
151
|
Args:
|
151
|
-
|
152
|
+
action: Original action before the update.
|
152
153
|
config: Action configuration instantiated from the original
|
153
|
-
|
154
|
-
|
154
|
+
action.
|
155
|
+
action_update: Action update request.
|
155
156
|
config_update: Action configuration instantiated from the
|
156
|
-
updated
|
157
|
+
updated action.
|
157
158
|
"""
|
158
159
|
assert isinstance(config, PipelineRunActionConfiguration)
|
159
160
|
|
@@ -162,12 +163,14 @@ class PipelineRunActionHandler(BaseActionHandler):
|
|
162
163
|
def extract_resources(
|
163
164
|
self,
|
164
165
|
action_config: ActionConfig,
|
166
|
+
hydrate: bool = False,
|
165
167
|
) -> Dict[ResourceType, BaseResponse[Any, Any, Any]]:
|
166
168
|
"""Extract related resources for this action.
|
167
169
|
|
168
170
|
Args:
|
169
171
|
action_config: Action configuration from which to extract related
|
170
172
|
resources.
|
173
|
+
hydrate: Flag deciding whether to hydrate the resources.
|
171
174
|
|
172
175
|
Returns:
|
173
176
|
List of resources related to the action.
|
@@ -181,7 +184,9 @@ class PipelineRunActionHandler(BaseActionHandler):
|
|
181
184
|
zen_store = GlobalConfiguration().zen_store
|
182
185
|
|
183
186
|
try:
|
184
|
-
deployment = zen_store.get_deployment(
|
187
|
+
deployment = zen_store.get_deployment(
|
188
|
+
deployment_id=deployment_id, hydrate=hydrate
|
189
|
+
)
|
185
190
|
except KeyError:
|
186
191
|
raise ValueError(f"No deployment found with id {deployment_id}.")
|
187
192
|
|
@@ -191,7 +196,7 @@ class PipelineRunActionHandler(BaseActionHandler):
|
|
191
196
|
|
192
197
|
if deployment.pipeline is not None:
|
193
198
|
pipeline = zen_store.get_pipeline(
|
194
|
-
pipeline_id=deployment.pipeline.id
|
199
|
+
pipeline_id=deployment.pipeline.id, hydrate=hydrate
|
195
200
|
)
|
196
201
|
resources[ResourceType.PIPELINE] = pipeline
|
197
202
|
|
zenml/analytics/enums.py
CHANGED
@@ -85,6 +85,9 @@ class AnalyticsEvent(str, Enum):
|
|
85
85
|
DEPLOY_STACK_COMPONENT = "Stack component deployed"
|
86
86
|
DESTROY_STACK_COMPONENT = "Stack component destroyed"
|
87
87
|
|
88
|
+
# Full stack infrastructure deployment
|
89
|
+
DEPLOY_FULL_STACK = "Full stack deployed"
|
90
|
+
|
88
91
|
# Tag created
|
89
92
|
CREATED_TAG = "Tag created"
|
90
93
|
|
@@ -14,6 +14,7 @@
|
|
14
14
|
"""The base interface to extend the ZenML artifact store."""
|
15
15
|
|
16
16
|
import inspect
|
17
|
+
import os
|
17
18
|
import textwrap
|
18
19
|
from abc import abstractmethod
|
19
20
|
from pathlib import Path
|
@@ -34,6 +35,7 @@ from typing import (
|
|
34
35
|
|
35
36
|
from pydantic import model_validator
|
36
37
|
|
38
|
+
from zenml.constants import ENV_ZENML_SERVER
|
37
39
|
from zenml.enums import StackComponentType
|
38
40
|
from zenml.exceptions import ArtifactStoreInterfaceError
|
39
41
|
from zenml.io import fileio
|
@@ -433,7 +435,11 @@ class BaseArtifactStore(StackComponent):
|
|
433
435
|
**kwargs: The keyword arguments to pass to the Pydantic object.
|
434
436
|
"""
|
435
437
|
super(BaseArtifactStore, self).__init__(*args, **kwargs)
|
436
|
-
|
438
|
+
|
439
|
+
# If running in a ZenML server environment, we don't register
|
440
|
+
# the filesystems. We always use the artifact stores directly.
|
441
|
+
if ENV_ZENML_SERVER not in os.environ:
|
442
|
+
self._register()
|
437
443
|
|
438
444
|
def _register(self) -> None:
|
439
445
|
"""Create and register a filesystem within the filesystem registry."""
|
zenml/artifacts/utils.py
CHANGED
@@ -436,18 +436,21 @@ def load_artifact_visualization(
|
|
436
436
|
artifact_store = _load_artifact_store(
|
437
437
|
artifact_store_id=artifact.artifact_store_id, zen_store=zen_store
|
438
438
|
)
|
439
|
-
|
440
|
-
|
441
|
-
|
442
|
-
|
443
|
-
|
444
|
-
|
439
|
+
try:
|
440
|
+
mode = "rb" if visualization.type == VisualizationType.IMAGE else "r"
|
441
|
+
value = _load_file_from_artifact_store(
|
442
|
+
uri=visualization.uri,
|
443
|
+
artifact_store=artifact_store,
|
444
|
+
mode=mode,
|
445
|
+
)
|
445
446
|
|
446
|
-
|
447
|
-
|
448
|
-
|
447
|
+
# Encode image visualizations if requested
|
448
|
+
if visualization.type == VisualizationType.IMAGE and encode_image:
|
449
|
+
value = base64.b64encode(bytes(value))
|
449
450
|
|
450
|
-
|
451
|
+
return LoadedVisualization(type=visualization.type, value=value)
|
452
|
+
finally:
|
453
|
+
artifact_store.cleanup()
|
451
454
|
|
452
455
|
|
453
456
|
def load_artifact_from_response(artifact: "ArtifactVersionResponse") -> Any:
|
zenml/cli/__init__.py
CHANGED
@@ -1411,6 +1411,34 @@ zenml stack register STACK_NAME \
|
|
1411
1411
|
Each corresponding argument should be the name, id or even the first few letters
|
1412
1412
|
of the id that uniquely identify the artifact store or orchestrator.
|
1413
1413
|
|
1414
|
+
To create a new stack using the new service connector with a set of minimal components,
|
1415
|
+
use the following command:
|
1416
|
+
|
1417
|
+
```bash
|
1418
|
+
zenml stack register STACK_NAME \
|
1419
|
+
-p CLOUD_PROVIDER
|
1420
|
+
```
|
1421
|
+
|
1422
|
+
To create a new stack using the existing service connector with a set of minimal components,
|
1423
|
+
use the following command:
|
1424
|
+
|
1425
|
+
```bash
|
1426
|
+
zenml stack register STACK_NAME \
|
1427
|
+
-sc SERVICE_CONNECTOR_NAME
|
1428
|
+
```
|
1429
|
+
|
1430
|
+
To create a new stack using the existing service connector with existing components (
|
1431
|
+
important, that the components are already registered in the service connector), use the
|
1432
|
+
following command:
|
1433
|
+
|
1434
|
+
```bash
|
1435
|
+
zenml stack register STACK_NAME \
|
1436
|
+
-sc SERVICE_CONNECTOR_NAME \
|
1437
|
+
-a ARTIFACT_STORE_NAME \
|
1438
|
+
-o ORCHESTRATOR_NAME \
|
1439
|
+
...
|
1440
|
+
```
|
1441
|
+
|
1414
1442
|
If you want to immediately set this newly created stack as your active stack,
|
1415
1443
|
simply pass along the `--set` flag.
|
1416
1444
|
|
zenml/cli/artifact.py
CHANGED
@@ -13,7 +13,6 @@
|
|
13
13
|
# permissions and limitations under the License.
|
14
14
|
"""CLI functionality to interact with artifacts."""
|
15
15
|
|
16
|
-
from functools import partial
|
17
16
|
from typing import Any, Dict, List, Optional
|
18
17
|
|
19
18
|
import click
|
@@ -258,7 +257,7 @@ def prune_artifacts(
|
|
258
257
|
"""
|
259
258
|
client = Client()
|
260
259
|
unused_artifact_versions = depaginate(
|
261
|
-
|
260
|
+
client.list_artifact_versions, only_unused=True
|
262
261
|
)
|
263
262
|
|
264
263
|
if not unused_artifact_versions:
|
zenml/cli/integration.py
CHANGED
@@ -263,13 +263,6 @@ def install(
|
|
263
263
|
# no integrations specified, use all registered integrations
|
264
264
|
integrations = set(integration_registry.integrations.keys())
|
265
265
|
|
266
|
-
# TODO: remove once python 3.11 gcp integration issue is resolved
|
267
|
-
if sys.version_info >= (3, 11) and "gcp" in integrations:
|
268
|
-
warning(
|
269
|
-
"We are aware of dependency resolution issues when using "
|
270
|
-
"Python 3.11.x with the GCP integration. For now, please use "
|
271
|
-
"Python 3.10 or lower instead while we work on a fix."
|
272
|
-
)
|
273
266
|
for i in ignore_integration:
|
274
267
|
try:
|
275
268
|
integrations.remove(i)
|
@@ -278,6 +271,14 @@ def install(
|
|
278
271
|
f"Integration {i} does not exist. Available integrations: "
|
279
272
|
f"{list(integration_registry.integrations.keys())}"
|
280
273
|
)
|
274
|
+
# TODO: remove once python 3.8 is deprecated
|
275
|
+
if sys.version_info.minor == 8 and "tensorflow" in integrations:
|
276
|
+
warning(
|
277
|
+
"Python 3.8 with TensorFlow is not fully compatible with "
|
278
|
+
"Pydantic 2 requirements. Consider upgrading to a "
|
279
|
+
"higher Python version if you would like to use the "
|
280
|
+
"Tensorflow integration."
|
281
|
+
)
|
281
282
|
|
282
283
|
requirements = []
|
283
284
|
integrations_to_install = []
|
@@ -360,7 +361,7 @@ def uninstall(
|
|
360
361
|
try:
|
361
362
|
if integration_registry.is_installed(integration_name):
|
362
363
|
requirements += (
|
363
|
-
integration_registry.
|
364
|
+
integration_registry.select_uninstall_requirements(
|
364
365
|
integration_name
|
365
366
|
)
|
366
367
|
)
|
zenml/cli/server.py
CHANGED
@@ -170,6 +170,12 @@ def up(
|
|
170
170
|
else:
|
171
171
|
pass
|
172
172
|
provider = ServerProviderType.LOCAL
|
173
|
+
if cli_utils.requires_mac_env_var_warning():
|
174
|
+
cli_utils.error(
|
175
|
+
"The `OBJC_DISABLE_INITIALIZE_FORK_SAFETY` environment variable "
|
176
|
+
"is recommended to run the ZenML server locally on a Mac. "
|
177
|
+
"Please set it to `YES` and try again."
|
178
|
+
)
|
173
179
|
|
174
180
|
os.environ[ENV_ZENML_LOCAL_SERVER] = str(True)
|
175
181
|
|