mage-ai 0.9.68__py3-none-any.whl → 0.9.70__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.
Potentially problematic release.
This version of mage-ai might be problematic. Click here for more details.
- mage_ai/api/policies/BackfillPolicy.py +1 -0
- mage_ai/api/policies/PipelinePolicy.py +1 -0
- mage_ai/api/policies/WorkspacePolicy.py +1 -0
- mage_ai/api/presenters/BackfillPresenter.py +1 -0
- mage_ai/api/resources/GitBranchResource.py +56 -23
- mage_ai/api/resources/GitCustomBranchResource.py +29 -1
- mage_ai/api/resources/OauthResource.py +1 -1
- mage_ai/api/resources/PipelineResource.py +11 -5
- mage_ai/api/resources/PipelineRunResource.py +41 -4
- mage_ai/api/resources/PipelineScheduleResource.py +4 -0
- mage_ai/api/resources/PullRequestResource.py +6 -4
- mage_ai/api/resources/SeedResource.py +2 -1
- mage_ai/api/resources/SessionResource.py +13 -1
- mage_ai/api/resources/WorkspaceResource.py +5 -4
- mage_ai/authentication/permissions/constants.py +2 -0
- mage_ai/authentication/permissions/seed.py +32 -21
- mage_ai/authentication/providers/active_directory.py +4 -3
- mage_ai/authentication/providers/okta.py +22 -83
- mage_ai/cache/block_action_object/__init__.py +1 -1
- mage_ai/cluster_manager/kubernetes/workload_manager.py +52 -1
- mage_ai/cluster_manager/workspace/base.py +6 -0
- mage_ai/cluster_manager/workspace/kubernetes.py +22 -1
- mage_ai/command_center/applications/utils.py +2 -2
- mage_ai/command_center/presenters/text.py +1 -1
- mage_ai/data_preparation/executors/k8s_block_executor.py +30 -7
- mage_ai/data_preparation/executors/k8s_pipeline_executor.py +30 -7
- mage_ai/data_preparation/executors/streaming_pipeline_executor.py +78 -8
- mage_ai/data_preparation/git/__init__.py +50 -22
- mage_ai/data_preparation/git/api.py +62 -7
- mage_ai/data_preparation/git/utils.py +45 -21
- mage_ai/data_preparation/models/block/__init__.py +31 -8
- mage_ai/data_preparation/models/block/data_integration/mixins.py +16 -5
- mage_ai/data_preparation/models/block/dynamic/child.py +3 -0
- mage_ai/data_preparation/models/block/dynamic/utils.py +9 -4
- mage_ai/data_preparation/models/block/dynamic/variables.py +2 -2
- mage_ai/data_preparation/models/block/extension/utils.py +1 -0
- mage_ai/data_preparation/models/block/global_data_product/__init__.py +25 -2
- mage_ai/data_preparation/models/block/integration/__init__.py +1 -1
- mage_ai/data_preparation/models/block/remote/__init__.py +0 -0
- mage_ai/data_preparation/models/block/remote/models.py +58 -0
- mage_ai/data_preparation/models/block/sql/__init__.py +1 -1
- mage_ai/data_preparation/models/block/utils.py +38 -0
- mage_ai/data_preparation/models/constants.py +2 -0
- mage_ai/data_preparation/models/global_data_product/__init__.py +12 -0
- mage_ai/data_preparation/models/pipeline.py +31 -11
- mage_ai/data_preparation/models/triggers/__init__.py +4 -2
- mage_ai/data_preparation/models/utils.py +6 -0
- mage_ai/data_preparation/models/variable.py +18 -4
- mage_ai/data_preparation/repo_manager.py +3 -2
- mage_ai/data_preparation/shared/utils.py +1 -1
- mage_ai/data_preparation/storage/local_storage.py +12 -6
- mage_ai/data_preparation/templates/data_exporters/mysql.py +2 -2
- mage_ai/data_preparation/templates/data_exporters/oracledb.py +27 -0
- mage_ai/data_preparation/templates/repo/metadata.yaml +1 -0
- mage_ai/io/bigquery.py +131 -58
- mage_ai/io/mysql.py +38 -6
- mage_ai/io/snowflake.py +152 -29
- mage_ai/orchestration/db/migrations/versions/42a14d6143f1_update_token_column_type.py +54 -0
- mage_ai/orchestration/db/models/oauth.py +14 -13
- mage_ai/orchestration/db/models/schedules.py +30 -2
- mage_ai/orchestration/job_manager.py +6 -0
- mage_ai/orchestration/notification/sender.py +37 -15
- mage_ai/orchestration/pipeline_scheduler_original.py +48 -31
- mage_ai/orchestration/queue/celery_queue.py +8 -1
- mage_ai/orchestration/queue/process_queue.py +67 -4
- mage_ai/orchestration/queue/queue.py +8 -0
- mage_ai/orchestration/triggers/api.py +29 -1
- mage_ai/orchestration/triggers/global_data_product.py +9 -4
- mage_ai/orchestration/triggers/utils.py +10 -1
- mage_ai/orchestration/utils/resources.py +3 -0
- mage_ai/server/api/downloads.py +4 -1
- mage_ai/server/api/runs.py +151 -0
- mage_ai/server/constants.py +1 -1
- mage_ai/server/frontend_dist/404.html +6 -6
- mage_ai/server/frontend_dist/_next/static/{i8pymuJDTVHdWjUP1QSh1 → RhDiJSkcjCsh4xxX4BFBk}/_buildManifest.js +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/1557-b3502f3f1aa92ac7.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/2717-d9200be634dd6766.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/3548-9d26185b3fb663b1.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/5699-6d708c6b2153ea08.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/7361-8a23dd8360593e7a.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/7966-b9b85ba10667e654.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/9624-8b8e100079ab69e1.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/_app-2a69553d8c6eeb53.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/index-4e12783b064c1cfe.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/manage-4bfc84ff07d7656f.js +1 -0
- mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/pipeline-runs-a66b4c7641ae03eb.js → frontend_dist/_next/static/chunks/pages/pipeline-runs-6d183f91a2ff6668.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills/[...slug]-7181b086c93784d2.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills-38e1fbcfbfc1014e.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/edit-b645a6d13ab9fe3a.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/settings-59aca25a5b1d3998.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers/[...slug]-eb11c5390c982b49.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/{triggers-cb88fd075a357fcf.js → triggers-4612d15a65c35912.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines-3591d035bb3bb2b8.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/platform/preferences-32985f3f7c7dd3ab.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/platform/settings-c2e9ef989c8bfa73.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/preferences-349af617d05f001b.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/sync-data-60d01d3887e31136.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/{users-86814e581acaf5db.js → users-a4db8710f703c729.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/sign-in-09414a8b66fb6f06.js +1 -0
- mage_ai/server/{frontend_dist_base_path_template/_next/static/chunks/pages/triggers-9cba3211434a8966.js → frontend_dist/_next/static/chunks/pages/triggers-a599c6ac89be8c8d.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/version-control-3433c8b22e8342aa.js +1 -0
- mage_ai/server/frontend_dist/block-layout.html +2 -2
- mage_ai/server/frontend_dist/compute.html +2 -2
- mage_ai/server/frontend_dist/files.html +2 -2
- mage_ai/server/frontend_dist/global-data-products/[...slug].html +2 -2
- mage_ai/server/frontend_dist/global-data-products.html +2 -2
- mage_ai/server/frontend_dist/global-hooks/[...slug].html +2 -2
- mage_ai/server/frontend_dist/global-hooks.html +2 -2
- mage_ai/server/frontend_dist/index.html +2 -2
- mage_ai/server/frontend_dist/manage/files.html +2 -2
- mage_ai/server/frontend_dist/manage/settings.html +2 -2
- mage_ai/server/frontend_dist/manage/users/[user].html +2 -2
- mage_ai/server/frontend_dist/manage/users/new.html +2 -2
- mage_ai/server/frontend_dist/manage/users.html +2 -2
- mage_ai/server/frontend_dist/manage.html +2 -2
- mage_ai/server/frontend_dist/oauth.html +2 -2
- mage_ai/server/frontend_dist/overview.html +2 -2
- mage_ai/server/frontend_dist/pipeline-runs.html +2 -2
- mage_ai/server/frontend_dist/pipelines/[pipeline]/backfills/[...slug].html +2 -2
- mage_ai/server/frontend_dist/pipelines/[pipeline]/backfills.html +2 -2
- mage_ai/server/frontend_dist/pipelines/[pipeline]/dashboard.html +2 -2
- mage_ai/server/frontend_dist/pipelines/[pipeline]/edit.html +2 -2
- mage_ai/server/frontend_dist/pipelines/[pipeline]/logs.html +2 -2
- mage_ai/server/frontend_dist/pipelines/[pipeline]/monitors/block-runs.html +2 -2
- mage_ai/server/frontend_dist/pipelines/[pipeline]/monitors/block-runtime.html +2 -2
- mage_ai/server/frontend_dist/pipelines/[pipeline]/monitors.html +2 -2
- mage_ai/server/frontend_dist/pipelines/[pipeline]/runs/[run].html +2 -2
- mage_ai/server/frontend_dist/pipelines/[pipeline]/runs.html +2 -2
- mage_ai/server/frontend_dist/pipelines/[pipeline]/settings.html +2 -2
- mage_ai/server/frontend_dist/pipelines/[pipeline]/syncs.html +2 -2
- mage_ai/server/frontend_dist/pipelines/[pipeline]/triggers/[...slug].html +2 -2
- mage_ai/server/frontend_dist/pipelines/[pipeline]/triggers.html +2 -2
- mage_ai/server/frontend_dist/pipelines/[pipeline].html +2 -2
- mage_ai/server/frontend_dist/pipelines.html +2 -2
- mage_ai/server/frontend_dist/platform/global-hooks/[...slug].html +2 -2
- mage_ai/server/frontend_dist/platform/global-hooks.html +2 -2
- mage_ai/server/frontend_dist/settings/account/profile.html +2 -2
- mage_ai/server/frontend_dist/settings/platform/preferences.html +2 -2
- mage_ai/server/frontend_dist/settings/platform/settings.html +2 -2
- mage_ai/server/frontend_dist/settings/workspace/permissions/[...slug].html +2 -2
- mage_ai/server/frontend_dist/settings/workspace/permissions.html +2 -2
- mage_ai/server/frontend_dist/settings/workspace/preferences.html +2 -2
- mage_ai/server/frontend_dist/settings/workspace/roles/[...slug].html +2 -2
- mage_ai/server/frontend_dist/settings/workspace/roles.html +2 -2
- mage_ai/server/frontend_dist/settings/workspace/sync-data.html +2 -2
- mage_ai/server/frontend_dist/settings/workspace/users/[...slug].html +2 -2
- mage_ai/server/frontend_dist/settings/workspace/users.html +2 -2
- mage_ai/server/frontend_dist/settings.html +2 -2
- mage_ai/server/frontend_dist/sign-in.html +6 -6
- mage_ai/server/frontend_dist/templates/[...slug].html +2 -2
- mage_ai/server/frontend_dist/templates.html +2 -2
- mage_ai/server/frontend_dist/terminal.html +2 -2
- mage_ai/server/frontend_dist/test.html +2 -2
- mage_ai/server/frontend_dist/triggers.html +2 -2
- mage_ai/server/frontend_dist/version-control.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/404.html +6 -6
- mage_ai/server/frontend_dist_base_path_template/_next/static/{CKCvjsYCf2imD2X8zAOBf → TdpLLFome13qvM0gXvpHs}/_buildManifest.js +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/1557-b3502f3f1aa92ac7.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/2717-d9200be634dd6766.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3548-9d26185b3fb663b1.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/5699-6d708c6b2153ea08.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/7361-8a23dd8360593e7a.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/7966-b9b85ba10667e654.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/9624-8b8e100079ab69e1.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/_app-2a69553d8c6eeb53.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/index-4e12783b064c1cfe.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/manage-4bfc84ff07d7656f.js +1 -0
- mage_ai/server/{frontend_dist/_next/static/chunks/pages/pipeline-runs-a66b4c7641ae03eb.js → frontend_dist_base_path_template/_next/static/chunks/pages/pipeline-runs-6d183f91a2ff6668.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills/[...slug]-7181b086c93784d2.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills-38e1fbcfbfc1014e.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/edit-b645a6d13ab9fe3a.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/settings-59aca25a5b1d3998.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/triggers/[...slug]-eb11c5390c982b49.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/{triggers-cb88fd075a357fcf.js → triggers-4612d15a65c35912.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines-3591d035bb3bb2b8.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/platform/preferences-32985f3f7c7dd3ab.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/platform/settings-c2e9ef989c8bfa73.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/preferences-349af617d05f001b.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/sync-data-60d01d3887e31136.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/{users-86814e581acaf5db.js → users-a4db8710f703c729.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/sign-in-09414a8b66fb6f06.js +1 -0
- mage_ai/server/{frontend_dist/_next/static/chunks/pages/triggers-9cba3211434a8966.js → frontend_dist_base_path_template/_next/static/chunks/pages/triggers-a599c6ac89be8c8d.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/version-control-3433c8b22e8342aa.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/block-layout.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/compute.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/files.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/global-data-products/[...slug].html +2 -2
- mage_ai/server/frontend_dist_base_path_template/global-data-products.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/global-hooks/[...slug].html +2 -2
- mage_ai/server/frontend_dist_base_path_template/global-hooks.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/index.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/manage/files.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/manage/settings.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/manage/users/[user].html +2 -2
- mage_ai/server/frontend_dist_base_path_template/manage/users/new.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/manage/users.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/manage.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/oauth.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/overview.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipeline-runs.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/backfills/[...slug].html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/backfills.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/dashboard.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/edit.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/logs.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/monitors/block-runs.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/monitors/block-runtime.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/monitors.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/runs/[run].html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/runs.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/settings.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/syncs.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/triggers/[...slug].html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline]/triggers.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines/[pipeline].html +2 -2
- mage_ai/server/frontend_dist_base_path_template/pipelines.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/platform/global-hooks/[...slug].html +2 -2
- mage_ai/server/frontend_dist_base_path_template/platform/global-hooks.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/settings/account/profile.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/settings/platform/preferences.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/settings/platform/settings.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/settings/workspace/permissions/[...slug].html +2 -2
- mage_ai/server/frontend_dist_base_path_template/settings/workspace/permissions.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/settings/workspace/preferences.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/settings/workspace/roles/[...slug].html +2 -2
- mage_ai/server/frontend_dist_base_path_template/settings/workspace/roles.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/settings/workspace/sync-data.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/settings/workspace/users/[...slug].html +2 -2
- mage_ai/server/frontend_dist_base_path_template/settings/workspace/users.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/settings.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/sign-in.html +6 -6
- mage_ai/server/frontend_dist_base_path_template/templates/[...slug].html +2 -2
- mage_ai/server/frontend_dist_base_path_template/templates.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/terminal.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/test.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/triggers.html +2 -2
- mage_ai/server/frontend_dist_base_path_template/version-control.html +2 -2
- mage_ai/server/scheduler_manager.py +9 -0
- mage_ai/server/server.py +47 -17
- mage_ai/server/utils/output_display.py +2 -2
- mage_ai/server/websocket_server.py +1 -0
- mage_ai/services/aws/ecs/ecs.py +1 -0
- mage_ai/services/k8s/config.py +4 -4
- mage_ai/services/k8s/utils.py +97 -0
- mage_ai/settings/keys/auth.py +2 -0
- mage_ai/settings/server.py +1 -1
- mage_ai/shared/parsers.py +6 -1
- mage_ai/streaming/sources/influxdb.py +2 -0
- mage_ai/streaming/sources/kafka.py +1 -1
- mage_ai/tests/api/endpoints/mixins.py +10 -9
- mage_ai/tests/api/endpoints/test_seeds.py +24 -0
- mage_ai/tests/api/operations/base/mixins.py +1 -1
- mage_ai/tests/api/operations/test_sessions.py +53 -2
- mage_ai/tests/api/resources/test_pipeline_resource.py +2 -2
- mage_ai/tests/authentication/oauth/test_utils.py +1 -1
- mage_ai/tests/authentication/providers/test_okta.py +43 -0
- mage_ai/tests/data_preparation/models/block/test_global_data_product.py +2 -0
- mage_ai/tests/orchestration/db/models/test_oauth.py +3 -3
- mage_ai/tests/orchestration/queue/test_process_queue.py +1 -0
- mage_ai/tests/orchestration/triggers/test_global_data_product.py +138 -136
- mage_ai/tests/server/test_server.py +27 -4
- mage_ai/tests/services/k8s/test_job_manager.py +9 -6
- mage_ai/version_control/branch/utils.py +2 -1
- mage_ai/version_control/models.py +3 -2
- {mage_ai-0.9.68.dist-info → mage_ai-0.9.70.dist-info}/METADATA +5 -5
- {mage_ai-0.9.68.dist-info → mage_ai-0.9.70.dist-info}/RECORD +272 -264
- mage_ai/server/frontend_dist/_next/static/chunks/1557-01f0843dc6ac4971.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/2717-b5f9575799b594d5.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/3548-961ff79ca70038c7.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/5699-6efc749f2f8ddd20.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/7361-18d9d8be96e1ce97.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/7966-f07b2913f7326b50.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/9624-59b2f803f9c88cd6.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/_app-08790743315de36a.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/index-13760bb72d823b69.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/manage-852d403c7bda21b3.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills/[...slug]-ff4bd7a8ec3bab40.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills-a8b61d8d239fd16f.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/edit-bd0aff5a5ed8888c.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/settings-d1ee961387c58b7f.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers/[...slug]-f028ef3880ed856c.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines-ceb06e1616ee9610.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/platform/preferences-8ff16ef9566e911a.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/platform/settings-74d76300942dcee8.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/preferences-d7a8bc51bb7a1082.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/sync-data-79a4cf66a623e667.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/sign-in-f59d34429fe022ee.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/version-control-5753fac7c1bfdc88.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/1557-01f0843dc6ac4971.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/2717-b5f9575799b594d5.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3548-961ff79ca70038c7.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/5699-6efc749f2f8ddd20.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/7361-18d9d8be96e1ce97.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/7966-f07b2913f7326b50.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/9624-59b2f803f9c88cd6.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/_app-08790743315de36a.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/index-13760bb72d823b69.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/manage-852d403c7bda21b3.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills/[...slug]-ff4bd7a8ec3bab40.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills-a8b61d8d239fd16f.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/edit-bd0aff5a5ed8888c.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/settings-d1ee961387c58b7f.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/triggers/[...slug]-f028ef3880ed856c.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines-ceb06e1616ee9610.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/platform/preferences-8ff16ef9566e911a.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/platform/settings-74d76300942dcee8.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/preferences-d7a8bc51bb7a1082.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/sync-data-79a4cf66a623e667.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/sign-in-f59d34429fe022ee.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/version-control-5753fac7c1bfdc88.js +0 -1
- /mage_ai/server/frontend_dist/_next/static/{i8pymuJDTVHdWjUP1QSh1 → RhDiJSkcjCsh4xxX4BFBk}/_ssgManifest.js +0 -0
- /mage_ai/server/frontend_dist_base_path_template/_next/static/{CKCvjsYCf2imD2X8zAOBf → TdpLLFome13qvM0gXvpHs}/_ssgManifest.js +0 -0
- {mage_ai-0.9.68.dist-info → mage_ai-0.9.70.dist-info}/LICENSE +0 -0
- {mage_ai-0.9.68.dist-info → mage_ai-0.9.70.dist-info}/WHEEL +0 -0
- {mage_ai-0.9.68.dist-info → mage_ai-0.9.70.dist-info}/entry_points.txt +0 -0
- {mage_ai-0.9.68.dist-info → mage_ai-0.9.70.dist-info}/top_level.txt +0 -0
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5405],{55006:function(n,i,e){"use strict";e.r(i);var u=e(82684),t=e(34376),a=e(40761),o=e(35686),s=e(87432),l=e(66916),r=["/sign-in","/oauth"];i.default=function(){var n,i=(0,t.useRouter)(),e=i.asPath,c=e.split("?")[0],v=o.ZP.statuses.list().data,d=(0,u.useMemo)((function(){var n;return null===v||void 0===v||null===(n=v.statuses)||void 0===n?void 0:n[0]}),[v]),f=o.ZP.pipeline_runs.list({_limit:0}).data,_=0===(0,u.useMemo)((function(){var n;return(null===f||void 0===f||null===(n=f.metadata)||void 0===n?void 0:n.count)||0}),[null===f||void 0===f||null===(n=f.metadata)||void 0===n?void 0:n.count])?"/pipelines":"/overview";(0,u.useEffect)((function(){(0,s.xf)()&&(0,l.a3)()}),[]),(0,u.useEffect)((function(){if(r.includes(c))i.replace(e);else if(d){var n=null===d||void 0===d?void 0:d.require_user_authentication,u=a.Z.isLoggedIn();if(n&&!u)i.replace("/sign-in");else{var t=null===d||void 0===d?void 0:d.is_instance_manager,o=e;"/"===c&&(o=t?"/manage":_),f&&i.replace(o)}}}),[c,e,f,d,_,i])}},48312:function(n,i,e){(window.__NEXT_P=window.__NEXT_P||[]).push(["/",function(){return e(55006)}])}},function(n){n.O(0,[9774,2888,179],(function(){return i=48312,n(n.s=i);var i}));var i=n.O();_N_E=i}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8867],{53779:function(e,n,t){"use strict";t.d(n,{C:function(){return h},X$:function(){return f},eD:function(){return d}});var r=t(25976),i=t(44897),o=t(42631),c=t(70515),s=t(47041),l=t(91437),a=6.25*c.iI,u=100*c.iI,d=r.default.div.withConfig({displayName:"indexstyle__WindowContainerStyle",componentId:"sc-g0cszf-0"})(["border-radius:","px;width:100%;max-width:","px;z-index:101;position:absolute;overflow:hidden;top:50%;left:50%;transform:translate(-50%,-50%);",""],o.n_,u,(function(e){return"\n box-shadow: ".concat((e.theme||i.Z).shadow.window,";\n background-color: ").concat((e.theme||i.Z).background.panel,";\n ")})),p=(0,r.css)(["display:flex;align-items:center;justify-content:space-between;height:","px;padding:","px ","px;",""],a,c.iI,c.cd*c.iI,(function(e){return"\n background-color: ".concat((e.theme||i.Z).background.output,";\n ")})),f=r.default.div.withConfig({displayName:"indexstyle__WindowHeaderStyle",componentId:"sc-g0cszf-1"})([""," border-top-left-radius:","px;border-top-right-radius:","px;",""],p,o.n_,o.n_,(function(e){return"\n border-bottom: ".concat(o.YF,"px ").concat(o.M8," ").concat((e.theme||i.Z).borders.medium,";\n ")})),h=r.default.div.withConfig({displayName:"indexstyle__WindowContentStyle",componentId:"sc-g0cszf-2"})(["overflow:auto;padding:","px 0;"," "," "," ",""],c.iI,s.w5,(0,l.eR)(),(function(e){return e.minMaxHeight&&"\n max-height: ".concat(7*c.iI,"px;\n ")}),(function(e){return!e.minMaxHeight&&"\n max-height: calc(100vh - ".concat(6.5*a,"px);\n ")}))},29480:function(e,n,t){"use strict";t.d(n,{$W:function(){return u},cl:function(){return d},cv:function(){return p},dE:function(){return l},zG:function(){return a}});var r=t(25976),i=t(44897),o=t(42631),c=t(70515),s=t(47041),l=r.default.div.withConfig({displayName:"indexstyle__SectionStyle",componentId:"sc-7a1uhf-0"})(["border-radius:","px;padding:","px;",""],o.n_,c.cd*c.iI,(function(e){return"\n background-color: ".concat((e.theme.background||i.Z.background).popup,";\n ")})),a=r.default.div.withConfig({displayName:"indexstyle__DocsStyle",componentId:"sc-7a1uhf-1"})(["> div{overflow:initial;}> div img{max-width:80%;background:white;padding:1rem;max-height:20vh;}"]),u=r.default.div.withConfig({displayName:"indexstyle__CodeEditorStyle",componentId:"sc-7a1uhf-2"})(["padding-top:","px;",""],c.cd*c.iI,(function(e){return"\n background-color: ".concat((e.theme.background||i.Z.background).codeTextarea,";\n ")})),d=r.default.div.withConfig({displayName:"indexstyle__TableContainerStyle",componentId:"sc-7a1uhf-3"})(["overflow:auto;max-height:90vh;width:100%;"," "," "," "," ",""],s.w5,(function(e){return e.hideHorizontalScrollbar&&"\n overflow-x: hidden;\n "}),(function(e){return e.width&&"\n width: ".concat(e.width,";\n ")}),(function(e){return e.height&&"\n height: ".concat(e.height,";\n ")}),(function(e){return e.maxHeight&&"\n max-height: ".concat(e.maxHeight,";\n ")})),p=r.default.div.withConfig({displayName:"indexstyle__HeaderRowStyle",componentId:"sc-7a1uhf-4"})(["padding:","px;"," "," ",""],2*c.iI,(function(e){return"\n background-color: ".concat((e.theme||i.Z).interactive.defaultBackground,";\n border-bottom: ").concat(o.YF,"px ").concat(o.M8," ").concat((e.theme||i.Z).borders.medium,";\n ")}),(function(e){return e.padding&&"\n padding: ".concat(e.padding,"px;\n ")}),(function(e){return e.rounded&&"\n border-top-left-radius: ".concat(o.n_,"px;\n border-top-right-radius: ").concat(o.n_,"px;\n ")}))},11074:function(e,n,t){"use strict";t.d(n,{Z:function(){return l}});var r=t(25976),i=t(44897),o=t(42631),c=r.default.div.withConfig({displayName:"indexstyle__PanelStyle",componentId:"sc-1rfr5wd-0"})(["border-radius:","px;"," ",""],o.n_,(function(e){return"\n background-color: ".concat((e.theme.background||i.Z.background).panel,";\n ")}),(function(e){return e.fullWidth&&"\n width: 100%;\n "})),s=t(28598);var l=function(e){var n=e.children,t=e.fullWidth,r=void 0===t||t;return(0,s.jsx)(c,{fullWidth:r,children:n})}},42765:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return be}});var r,i=t(77837),o=t(75582),c=t(82394),s=t(38860),l=t.n(s),a=t(82684),u=t(34376),d=t(71180),p=t(69864),f=t(32013),h=t(98777),m=t(89083),x=t(15338),j=t(78650),v=t(97618),g=t(55485),b=t(85854),Z=t(68562),y=t(11074),_=t(44085),w=t(38276),P=t(30160),k=t(17488),C=t(69650),O=t(12468),S=t(35686),I=["ReadWriteOnce","ReadWriteMany","ReadOnlyMany"],D=["Retain","Delete"],E=[{label:"Workspace name",required:!0,uuid:"name"}],N=[{label:"Namespace",labelDescription:"The namespace where the workspace resources will be deployed. Defaults to the value of the KUBE_NAMESPACE environment variable.",uuid:"namespace"},{label:"Service account name",placeholder:"default",uuid:"service_account_name"},{label:"Ingress name",labelDescription:"If you want to add the workspace to an existing ingress, enter the name of the ingress here. Otherwise, the workspace can be accessed through the service.",placeholder:"my-ingress",uuid:"ingress_name"}],M=[{label:"Storage class name",placeholder:"default",uuid:"storage_class_name"},{label:"Storage request size (in GB)",type:"number",uuid:"storage_request_size"}],R=t(44425),F=t(72473);!function(e){e.K8S="k8s",e.ECS="ecs",e.CLOUD_RUN="cloud_run",e.EMR="emr"}(r||(r={}));var A={ingress_name:"Ingress",namespace:"Namespace",pvc_retention_policy:"PVC retention policy",service_account_name:"Service account name",storage_access_mode:"Storage access mode",storage_class_name:"Storage class name",storage_request_size:"Storage request size (in GB)",url:"Access URL"},W={"termination_policy.enable_auto_termination":"Termination policy: auto-terminate","termination_policy.max_idle_seconds":"Termination policy: max idle seconds",pre_start_script_path:"Pre start: script path","post_start.command":"Post start: command","post_start.hook_path":"Post start: path to hook"},T=t(29480),L=t(79633),z=t(53779),B=t(72619),G=t(81728),U=t(89538),q=t(28598);function V(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function H(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?V(Object(t),!0).forEach((function(n){(0,c.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):V(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var K=function(e){var n=e.clusterType,t=e.onCancel,i=e.onCreate,s=e.project,l=(0,a.useState)(),u=l[0],A=l[1],W=(0,a.useState)(),V=W[0],K=W[1],$=(0,a.useState)(null),Q=$[0],X=$[1],Y=(0,a.useState)(null),J=Y[0],ee=Y[1],ne=(0,a.useMemo)((function(){return null===s||void 0===s?void 0:s.workspace_config_defaults}),[s]);(0,a.useEffect)((function(){if(ne&&(J||ee(null===ne||void 0===ne?void 0:ne.lifecycle_config),!Q)){var e=H(H({},null===ne||void 0===ne?void 0:ne.k8s),{},{name:null===ne||void 0===ne?void 0:ne.name});X(e)}}),[ne,J,Q]);var te=(0,p.Db)(S.ZP.workspaces.useCreate(),{onSuccess:function(e){return(0,B.wD)(e,{callback:function(e){e.error_message?A(e.error_message):i()},onErrorCallback:function(e){var n=e.error,t=n.errors,r=n.message;A(r),console.log(t,r)}})}}),re=(0,o.Z)(te,2),ie=re[0],oe=re[1].isLoading,ce=S.ZP.files.list(),se=ce.data,le=ce.mutate,ae=(0,a.useMemo)((function(){return(null===se||void 0===se?void 0:se.files)||[]}),[se]),ue=(0,U.dd)((function(e){return(0,q.jsxs)(z.eD,{children:[(0,q.jsxs)(z.X$,{children:[(0,q.jsx)(v.Z,{alignItems:"center",children:(0,q.jsx)(P.ZP,{disableWordBreak:!0,monospace:!0,children:"Select file"})}),(0,q.jsx)(d.ZP,{iconOnly:!0,onClick:fe,children:(0,q.jsx)(F.Close,{muted:!0})})]}),(0,q.jsx)(z.C,{children:(0,q.jsx)(j.Z,{disableContextMenu:!0,fetchFiles:le,files:ae,isFileDisabled:null===e||void 0===e?void 0:e.isFileDisabled,openFile:e.onFileOpen,uuid:"ConfigureWorkspace/FileBrowser"})})]})}),{},[ae,le],{background:!0,uuid:"file_selector"}),de=(0,o.Z)(ue,2),pe=de[0],fe=de[1],he=(0,a.useCallback)((function(e){var n=e.autoComplete,t=e.disabled,r=e.label,i=e.labelDescription,o=e.placeholder,s=e.required,l=e.type,a=e.uuid;return(0,q.jsxs)("div",{children:[(0,q.jsx)(x.Z,{muted:!0}),(0,q.jsx)(w.Z,{ml:3,mr:2,my:1,children:(0,q.jsxs)(g.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,q.jsxs)(v.Z,{flex:2,flexDirection:"column",children:[(0,q.jsx)(P.ZP,{children:r}),i&&(0,q.jsx)(P.ZP,{muted:!0,children:i})]}),(0,q.jsx)(v.Z,{flex:1}),(0,q.jsx)(v.Z,{flex:1,children:(0,q.jsx)(k.Z,{autoComplete:n,disabled:t,onChange:function(e){X((function(n){return H(H({},n),{},(0,c.Z)({},a,e.target.value))}))},placeholder:o,required:s,setContentOnMount:!0,type:l,value:(null===Q||void 0===Q?void 0:Q[a])||""})})]})})]},a)}),[Q,X]),me=(0,a.useMemo)((function(){return(0,q.jsxs)(q.Fragment,{children:[(0,q.jsx)(g.ZP,{children:(0,q.jsx)(w.Z,{ml:2,my:2,children:(0,q.jsx)(P.ZP,{bold:!0,sky:!0,children:"General"})})}),N.map((function(e){return he(e)})),(0,q.jsx)(x.Z,{muted:!0}),(0,q.jsx)(g.ZP,{children:(0,q.jsx)(w.Z,{ml:2,my:2,children:(0,q.jsx)(P.ZP,{bold:!0,sky:!0,children:"Volume claim params"})})}),M.map((function(e){return he(e)})),(0,q.jsx)(x.Z,{muted:!0}),(0,q.jsx)(w.Z,{ml:3,mr:2,my:1,children:(0,q.jsxs)(g.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,q.jsx)(v.Z,{flex:3,children:(0,q.jsx)(P.ZP,{children:"Access mode"})}),(0,q.jsx)(v.Z,{flex:1,children:(0,q.jsx)(_.Z,{fullWidth:!0,label:"Access mode",onChange:function(e){e.preventDefault(),X((function(n){return H(H({},n),{},{storage_access_mode:e.target.value})}))},placeholder:"Access mode",value:null===Q||void 0===Q?void 0:Q.storage_access_mode,children:I.map((function(e){return(0,q.jsx)("option",{value:e,children:e},e)}))})})]})}),(0,q.jsx)(x.Z,{muted:!0}),(0,q.jsx)(w.Z,{ml:3,mr:2,my:1,children:(0,q.jsxs)(g.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,q.jsx)(v.Z,{flex:3,children:(0,q.jsx)(O.Z,{block:!0,description:(0,q.jsxs)(P.ZP,{default:!0,inline:!0,children:["Configure the retention policy for the stateful set PVC.",(0,q.jsx)("br",{}),"Retain will keep the PVC after the workspace is deleted.",(0,q.jsx)("br",{}),"Delete will delete the PVC when the workspace is deleted."]}),size:null,widthFitContent:!0,children:(0,q.jsx)(P.ZP,{children:"Retention policy (default: Retain)"})})}),(0,q.jsx)(v.Z,{flex:1,children:(0,q.jsx)(_.Z,{fullWidth:!0,label:"Retention policy",onChange:function(e){e.preventDefault(),X((function(n){return H(H({},n),{},{pvc_retention_policy:e.target.value})}))},placeholder:"Retention policy",value:null===Q||void 0===Q?void 0:Q.pvc_retention_policy,children:D.map((function(e){return(0,q.jsx)("option",{value:e,children:e},e)}))})})]})}),(0,q.jsx)(x.Z,{muted:!0}),(0,q.jsx)(w.Z,{ml:2,my:2,children:(0,q.jsxs)(g.ZP,{alignItems:"center",children:[(0,q.jsx)(C.Z,{checked:V,compact:!0,onCheck:function(){return K((function(e){return!e}))}}),(0,q.jsx)(w.Z,{ml:1,children:(0,q.jsx)(P.ZP,{bold:!0,sky:!0,children:"Configure container"})})]})}),(0,q.jsx)(x.Z,{muted:!0}),V&&(0,q.jsx)(w.Z,{ml:3,mr:2,my:1,children:(0,q.jsx)(T.$W,{children:(0,q.jsx)(m.Z,{autoHeight:!0,fontSize:12,language:R.t6.YAML,onChange:function(e){X((function(n){return H(H({},n),{},{container_config:e})}))},tabSize:2,value:null===Q||void 0===Q?void 0:Q.container_config,width:"100%"})})})]})}),[he,V,Q]),xe=(0,a.useMemo)((function(){var e,n,t,r;return(0,q.jsxs)(q.Fragment,{children:[(0,q.jsx)(g.ZP,{children:(0,q.jsx)(w.Z,{ml:2,my:2,children:(0,q.jsx)(P.ZP,{bold:!0,sky:!0,children:"Termination policy"})})}),(0,q.jsx)(x.Z,{muted:!0}),(0,q.jsx)(w.Z,{ml:3,mr:2,my:1,children:(0,q.jsxs)(g.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,q.jsx)(v.Z,{flex:3,children:(0,q.jsx)(P.ZP,{children:"Enable auto termination"})}),(0,q.jsx)(v.Z,{flex:1,children:(0,q.jsxs)(_.Z,{fullWidth:!0,onChange:function(e){e.preventDefault(),ee((function(n){return H(H({},n),{},{termination_policy:H(H({},null===n||void 0===n?void 0:n.termination_policy),{},{enable_auto_termination:"true"===e.target.value})})}))},value:(null===J||void 0===J||null===(e=J.termination_policy)||void 0===e?void 0:e.enable_auto_termination)||"false",children:[(0,q.jsx)("option",{value:"true",children:"True"},"true"),(0,q.jsx)("option",{value:"false",children:"False"},"false")]})})]})}),(0,q.jsx)(x.Z,{muted:!0}),(0,q.jsx)(w.Z,{ml:3,mr:2,my:1,children:(0,q.jsxs)(g.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,q.jsx)(v.Z,{flex:3,children:(0,q.jsx)(P.ZP,{children:"Max idle time (in seconds)"})}),(0,q.jsx)(v.Z,{flex:1,children:(0,q.jsx)(k.Z,{onChange:function(e){ee((function(n){return H(H({},n),{},{termination_policy:H(H({},null===n||void 0===n?void 0:n.termination_policy),{},{max_idle_seconds:e.target.value})})}))},setContentOnMount:!0,type:"number",value:(null===J||void 0===J||null===(n=J.termination_policy)||void 0===n?void 0:n.max_idle_seconds)||""})})]})}),(0,q.jsx)(x.Z,{muted:!0}),(0,q.jsx)(g.ZP,{children:(0,q.jsx)(w.Z,{ml:2,my:2,children:(0,q.jsx)(P.ZP,{bold:!0,sky:!0,children:"Pre start"})})}),(0,q.jsx)(x.Z,{muted:!0}),(0,q.jsx)(w.Z,{ml:3,mr:2,my:1,children:(0,q.jsxs)(g.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,q.jsxs)(v.Z,{flex:3,justifyContent:"space-between",children:[(0,q.jsx)(P.ZP,{children:"Path to pre start script"}),(0,q.jsx)(w.Z,{mr:1,children:(0,q.jsx)(d.ZP,{iconOnly:!0,noBackground:!0,noBorder:!0,onClick:function(){return pe({isFileDisabled:function(e,n){return!n&&!e.endsWith(".py")},onFileOpen:function(e,n){ee((function(n){return H(H({},n),{},{pre_start_script_path:e})})),fe()}})},children:(0,q.jsx)(F.Folder,{})})})]}),(0,q.jsx)(v.Z,{flex:1,children:(0,q.jsx)(k.Z,{onChange:function(e){ee((function(n){return H(H({},n),{},{pre_start_script_path:e.target.value})}))},placeholder:"/",setContentOnMount:!0,value:(null===J||void 0===J?void 0:J.pre_start_script_path)||""})})]})}),(0,q.jsx)(x.Z,{muted:!0}),(0,q.jsx)(g.ZP,{children:(0,q.jsx)(w.Z,{ml:2,my:2,children:(0,q.jsx)(P.ZP,{bold:!0,sky:!0,children:"Post start"})})}),(0,q.jsx)(x.Z,{muted:!0}),(0,q.jsx)(w.Z,{ml:3,mr:2,my:1,children:(0,q.jsxs)(g.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,q.jsx)(v.Z,{flex:3,children:(0,q.jsx)(P.ZP,{children:"Command"})}),(0,q.jsx)(v.Z,{flex:1,children:(0,q.jsx)(k.Z,{monospace:!0,onChange:function(e){ee((function(n){return H(H({},n),{},{post_start:H(H({},null===n||void 0===n?void 0:n.post_start),{},{command:e.target.value})})}))},setContentOnMount:!0,value:(null===J||void 0===J||null===(t=J.post_start)||void 0===t?void 0:t.command)||""})})]})}),(0,q.jsx)(x.Z,{muted:!0}),(0,q.jsx)(w.Z,{ml:3,mr:2,my:1,children:(0,q.jsxs)(g.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,q.jsxs)(v.Z,{flex:3,justifyContent:"space-between",children:[(0,q.jsx)(P.ZP,{children:"Path to hook (optional)"}),(0,q.jsx)(w.Z,{mr:1,children:(0,q.jsx)(d.ZP,{iconOnly:!0,noBackground:!0,noBorder:!0,onClick:function(){return pe({onFileOpen:function(e,n){ee((function(n){return H(H({},n),{},{post_start:H(H({},null===n||void 0===n?void 0:n.post_start),{},{hook_path:e})})})),fe()}})},children:(0,q.jsx)(F.Folder,{})})})]}),(0,q.jsx)(v.Z,{flex:1,children:(0,q.jsx)(k.Z,{onChange:function(e){ee((function(n){return H(H({},n),{},{post_start:H(H({},null===n||void 0===n?void 0:n.post_start),{},{hook_path:e.target.value})})}))},placeholder:"/",setContentOnMount:!0,value:(null===J||void 0===J||null===(r=J.post_start)||void 0===r?void 0:r.hook_path)||""})})]})}),(0,q.jsx)(x.Z,{muted:!0})]})}),[fe,J,ee,pe]);return(0,q.jsx)(y.Z,{children:(0,q.jsx)("div",{style:{width:"750px"},children:(0,q.jsxs)(w.Z,{p:2,children:[(0,q.jsx)(b.Z,{level:4,children:"Create workspace"}),(0,q.jsxs)("form",{children:[E.map((function(e){var n=e.autoComplete,t=e.disabled,r=e.label,i=e.required,o=e.type,s=e.uuid;return(0,q.jsx)(w.Z,{mt:2,children:(0,q.jsx)(k.Z,{autoComplete:n,disabled:t,label:r,onChange:function(e){X((function(n){return H(H({},n),{},(0,c.Z)({},s,e.target.value))}))},required:i,setContentOnMount:!0,type:o,value:(null===Q||void 0===Q?void 0:Q[s])||""})},s)})),(0,q.jsx)(w.Z,{mt:2,children:(0,q.jsxs)(f.Z,{noPaddingContent:!0,children:[n===r.K8S&&(0,q.jsx)(h.Z,{title:"Kubernetes",children:me}),(0,q.jsx)(h.Z,{title:"Lifecycle (optional)",children:xe})]})})]}),oe&&(0,q.jsx)(w.Z,{mt:1,children:(0,q.jsx)(P.ZP,{small:!0,warning:!0,children:"This may take up to a few minutes... Once the service is created, it may take another 5-10 minutes for the service to be accessible."})}),!oe&&u&&(0,q.jsxs)(q.Fragment,{children:[(0,q.jsx)(w.Z,{mt:1,children:(0,q.jsx)(P.ZP,{danger:!0,small:!0,children:"Failed to create instance, see error below."})}),(0,q.jsx)(w.Z,{mt:1,children:(0,q.jsx)(P.ZP,{danger:!0,small:!0,children:u})})]}),(0,q.jsx)(w.Z,{my:2,children:(0,q.jsxs)(g.ZP,{flexDirection:"row-reverse",children:[(0,q.jsx)(Z.ZP,{background:L.a$,bold:!0,inline:!0,loading:oe,onClick:function(){var e=Q||{},t=e.name,r=e.container_config;if(t){var i=H({},Q);i.name=function(e){return"ecs"===n?(0,G.We)(e,"_"):(0,G.We)(e,"-")}(t),i.container_config=V&&r,ie({workspace:H(H({},i),{},{cluster_type:n,lifecycle_config:J})})}else A("Please enter a valid name!")},uuid:"workspaces/create",children:"Create"}),(0,q.jsx)(w.Z,{ml:1}),(0,q.jsx)(Z.ZP,{bold:!0,inline:!0,onClick:t,uuid:"workspaces/cancel",children:"Cancel"})]})})]})})})},$=t(65956),Q=t(93808),X=t(75499),Y=t(85544),J=t(59533),ee=t(25976),ne=t(44897),te=ee.default.div.withConfig({displayName:"indexstyle__ContainerStyle",componentId:"sc-19701zd-0"})(["border:1px solid;border-radius:8px;",""],(function(e){return"\n border-color: ".concat((e.theme.monotone||ne.Z.monotone).grey500,";\n ")})),re=t(70515);function ie(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function oe(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?ie(Object(t),!0).forEach((function(n){(0,c.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):ie(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var ce,se=function(e){var n=e.clusterType,t=e.fetchWorkspaces,i=e.onSuccess,c=e.setErrors,s=e.workspace,l=s.instance,u=s.lifecycle_config,f=(l.ip,l.name),h=l.status,m=(l.type,{cluster_type:n}),j=(0,p.Db)(S.ZP.workspaces.useUpdate(f,m),{onSuccess:function(e){return(0,B.wD)(e,{callback:function(){t(),i()},onErrorCallback:function(e,n){return c({errors:n,response:e})}})}}),Z=(0,o.Z)(j,2),y=Z[0],_=Z[1].isLoading,k=(0,p.Db)(S.ZP.workspaces.useDelete(f,m),{onSuccess:function(e){return(0,B.wD)(e,{callback:function(){t(),i()},onErrorCallback:function(e,n){return c({errors:n,response:e})}})}}),C=(0,o.Z)(k,2),O=C[0],I=C[1].isLoading,D=(0,a.useMemo)((function(){if(u){var e={};return Object.entries(u).map((function(n){var t=(0,o.Z)(n,2),r=t[0],i=t[1];i&&"object"===typeof i?Object.entries(i).map((function(n){var t=(0,o.Z)(n,2),i=t[0],c=t[1];e["".concat(r,".").concat(i)]=c})):e[r]=i})),e}}),[u]),E=(0,a.useMemo)((function(){var e=l.status,t=[];return"ecs"===n&&("STOPPED"===e?t.unshift({label:"Resume instance",onClick:function(){return y({workspace:{action:"resume",cluster_type:n,name:l.name,task_arn:l.task_arn}})},props:{loading:_,primary:!0},uuid:"resume_instance"}):"RUNNING"===e&&t.unshift({label:"Stop instance",onClick:function(){return y({workspace:{action:"stop",cluster_type:n,name:l.name,task_arn:l.task_arn}})},props:{loading:_,warning:!0},uuid:"stop_instance"})),"k8s"===n&&("STOPPED"===e?t.unshift({label:"Resume instance",onClick:function(){return y({workspace:{action:"resume",cluster_type:n,name:l.name}})},props:{loading:_,primary:!0},uuid:"resume_instance"}):"RUNNING"===e&&t.unshift({label:"Stop instance",onClick:function(){return y({workspace:{action:"stop",cluster_type:n,name:l.name}})},props:{loading:_,warning:!0},uuid:"stop_instance"})),null===s||void 0===s||!s.ingress_name||null!==s&&void 0!==s&&s.url||t.push({label:"Add to ingress",onClick:function(){return y({workspace:{action:"add_to_ingress",cluster_type:n,name:l.name}})},props:{default:!0,loading:_},uuid:"re_add_to_ingress"}),t}),[n,l,y,s,_]),N=(0,a.useMemo)((function(){return(0,q.jsx)(d.ZP,{danger:!0,loading:I,onClick:function(){window.confirm("Are you sure you want to delete workspace ".concat(f,"?"))&&O()},children:"Delete workspace"})}),[O,I,f]);return(0,q.jsx)(q.Fragment,{children:(0,q.jsxs)(w.Z,{p:2,children:[(0,q.jsx)(w.Z,{mb:2,children:(0,q.jsxs)(g.ZP,{alignItems:"center",children:[(0,q.jsx)(F.Folder,{size:2*re.iI}),(0,q.jsx)(w.Z,{mr:1}),(0,q.jsx)(b.Z,{level:3,children:null===s||void 0===s?void 0:s.name})]})}),(0,q.jsx)(w.Z,{mb:2,children:(0,q.jsxs)(P.ZP,{children:["Status: ",(0,q.jsx)(P.ZP,{bold:!0,danger:"STOPPED"===h,default:"PROVISIONING"===h,inline:!0,success:"RUNNING"===h,warning:"PENDING"===h,children:h})]})}),!E||0==E.length&&(0,q.jsx)(w.Z,{mb:2,children:N}),E&&E.length>0&&(0,q.jsx)(w.Z,{mb:2,children:(0,q.jsxs)(g.ZP,{justifyContent:"space-between",children:[(0,q.jsx)(v.Z,{children:E.map((function(e){var n=e.label,t=e.onClick,r=e.uuid,i=e.props;return(0,q.jsx)(w.Z,{mr:1,children:(0,q.jsx)(d.ZP,oe(oe({},i),{},{onClick:t,children:n}))},r)}))}),N]})}),n===r.K8S&&(0,q.jsx)(te,{children:Object.entries(A).map((function(e,n){var t=(0,o.Z)(e,2),r=t[0],i=t[1];return(0,q.jsxs)(q.Fragment,{children:[(0,q.jsx)(w.Z,{mx:2,my:2,children:(0,q.jsxs)(g.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,q.jsx)(v.Z,{flex:4,children:(0,q.jsx)(P.ZP,{muted:!0,children:i})}),(0,q.jsx)(v.Z,{flex:2,flexDirection:"row-reverse",children:(0,q.jsx)(P.ZP,{bold:!0,children:(null===s||void 0===s?void 0:s[r])||"N/A"})})]})},r),n!==Object.entries(A).length-1&&(0,q.jsx)(x.Z,{muted:!0})]})}))}),D&&(0,q.jsxs)(q.Fragment,{children:[(0,q.jsx)(w.Z,{my:2,children:(0,q.jsx)(b.Z,{default:!0,level:5,children:"Lifecycle Properties"})}),(0,q.jsx)(te,{children:Object.entries(W).map((function(e,n){var t,r=(0,o.Z)(e,2),i=r[0],c=r[1];return(0,q.jsxs)(q.Fragment,{children:[(0,q.jsx)(w.Z,{mx:2,my:2,children:(0,q.jsxs)(g.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,q.jsx)(v.Z,{flex:3,children:(0,q.jsx)(P.ZP,{muted:!0,children:c})}),(0,q.jsx)(v.Z,{flex:1,flexDirection:"row-reverse",children:(0,q.jsx)(P.ZP,{bold:!0,children:null===(t=D[i])||void 0===t?void 0:t.toString()})})]})},i),n!==Object.entries(W).length-1&&(0,q.jsx)(x.Z,{muted:!0})]})}))})]})]})})};!function(e){e.ALL="__all__",e.NAMESPACE="namespace[]"}(ce||(ce={}));var le=t(42631),ae=t(11498),ue=t(75083),de=t(69419),pe=t(53808),fe="workspace_list_filters";function he(e){return(0,pe.t8)(fe,e),e}var me=t(15610),xe=t(42122);function je(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function ve(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?je(Object(t),!0).forEach((function(n){(0,c.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):je(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function ge(){var e=(0,u.useRouter)(),n=S.ZP.statuses.list().data,t=(0,a.useState)(null),i=t[0],s=t[1],l=(0,de.iV)(),p=(0,a.useMemo)((function(){return ve({},(0,de.DQ)(l,[ce.NAMESPACE]))}),[l]),f=(0,a.useMemo)((function(){var e,t;return(null===n||void 0===n||null===(e=n.statuses)||void 0===e||null===(t=e[0])||void 0===t?void 0:t.instance_type)||"ecs"}),[n]),h=S.ZP.projects.list({},{revalidateOnFocus:!1}).data,m=(0,a.useMemo)((function(){var e;return null===h||void 0===h||null===(e=h.projects)||void 0===e?void 0:e[0]}),[h]),x=S.ZP.workspaces.list(ve(ve({},p),{},{cluster_type:f}),{revalidateOnFocus:!1}),j=x.data,v=x.isValidating,g=x.mutate,b=(0,a.useMemo)((function(){var e;return null===j||void 0===j||null===(e=j.workspaces)||void 0===e?void 0:e.filter((function(e){return e.name}))}),[j]),Z=(0,U.dd)((function(){return(0,q.jsx)(K,{clusterType:f,onCancel:w,onCreate:function(){g(),w()},project:m})}),{},[f,g,m],{background:!0,disableClickOutside:!0,disableEscape:!0,uuid:"configure_workspace"}),y=(0,o.Z)(Z,2),_=y[0],w=y[1],k=(0,U.dd)((function(e){var n=e.workspace;return(0,q.jsx)($.Z,{children:(0,q.jsx)("div",{style:{width:"750px"},children:(0,q.jsx)(se,{clusterType:f,fetchWorkspaces:g,onSuccess:I,setErrors:s,workspace:n})})})}),{},[f,g,s,b],{background:!0,uuid:"workspace_detail"}),C=(0,o.Z)(k,2),O=C[0],I=C[1],D=(0,a.useCallback)((function(e){var n=null===b||void 0===b?void 0:b[e];O({workspace:n})}),[O,b]);(0,a.useEffect)((function(){var e={};if((0,xe.Qr)(p)){var n={},t=(0,pe.U2)(fe,{});t&&Object.entries(t).forEach((function(e){var t=(0,o.Z)(e,2),r=t[0],i=t[1];"undefined"!==typeof i&&null!==i&&(ae.RG.includes(r)?n[r]=i:(n[r]=[],Object.entries(i).forEach((function(e){var t=(0,o.Z)(e,2),i=t[0];t[1]&&n[r].push(i)}))))})),(0,xe.Qr)(n)||(e={},Object.entries(ve(ve({},e),n)||{}).forEach((function(n){var t=(0,o.Z)(n,2),r=t[0],i=t[1];"undefined"!==typeof i&&null!==i&&(e[r]=i)})))}else{var r={};Object.entries(p).forEach((function(e){var n=(0,o.Z)(e,2),t=n[0],i=n[1];r[t]={};var c,s=i;"undefined"!==typeof i&&null!==i&&(ae.RG.includes(t)?r[t]=s:(Array.isArray(s)||(s=[s]),s&&Array.isArray(s)&&(null===(c=s)||void 0===c||c.forEach((function(e){r[t][e]=!0})))))})),he((0,xe.hB)(r))}(0,xe.Qr)(e)||(0,me.u)((0,xe.hB)(e),{pushHistory:!1})}),[p]);var E=(0,a.useMemo)((function(){var n={},t={};return f===r.K8S&&(n={namespace:[ce.ALL]},t={namespace:(0,c.Z)({},ce.ALL,"All namespaces")}),(0,q.jsx)(Y.Z,{addButtonProps:{label:"Create new workspace",onClick:_},extraActionButtonProps:{Icon:F.Refresh,disabled:!1,isLoading:v,onClick:g,tooltip:"Refresh workspaces"},filterOptions:n,filterValueLabelMapping:t,onClickFilterDefaults:function(){he({}),e.push("/manage")},onFilterApply:function(e,n){Object.values(n).every((function(e){return!(null!==e&&void 0!==e&&e.length)}))&&he({})},query:p})}),[f,g,v,p,e,_]);return(0,q.jsx)(J.Z,{breadcrumbs:[{bold:!0,label:function(){return"Workspaces"}}],errors:i,pageName:ue.L6.WORKSPACES,setErrors:s,subheaderChildren:E,children:(0,q.jsx)(X.Z,{columnFlex:[2,4,2,3,1,null],columns:[{uuid:"Status"},{uuid:"Instance Name"},{uuid:"Type"},{uuid:"URL/IP"},{uuid:"Open"}],onClickRow:["ecs","k8s"].includes(f)&&D,rows:null===b||void 0===b?void 0:b.map((function(e){var n=e.instance,t=e.url,r=n.ip,i=n.name,o=n.status,c=n.type,s=t||r,l=s;return s&&!s.includes("http")&&(l="http://".concat(s),"ecs"===f&&(l="http://".concat(s,":6789"))),[(0,q.jsx)(d.ZP,{borderRadius:"".concat(le.D7,"px"),danger:"STOPPED"===o,default:"PROVISIONING"===o,notClickable:!0,padding:"6px",success:"RUNNING"===o,warning:"PENDING"===o,children:(0,G.vg)(o)},"status"),(0,q.jsx)(P.ZP,{children:i},"name"),(0,q.jsx)(P.ZP,{children:(0,G.vg)(c)},"type"),(0,q.jsx)(P.ZP,{children:s||"N/A"},"ip"),(0,q.jsx)(d.ZP,{disabled:!s,iconOnly:!0,onClick:function(){return window.open(l)},children:(0,q.jsx)(F.Expand,{size:2*re.iI})},"open_button")]}))})})}ge.getInitialProps=(0,i.Z)(l().mark((function e(){return l().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",{});case 1:case"end":return e.stop()}}),e)})));var be=(0,Q.Z)(ge)},13157:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/manage",function(){return t(42765)}])}},function(e){e.O(0,[1557,1598,5544,9774,2888,179],(function(){return n=13157,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6780],{74395:function(e,n,t){"use strict";t.d(n,{M:function(){return a},W:function(){return l}});var r=t(25976),i=t(46684),l=34*t(70515).iI,a=r.default.div.withConfig({displayName:"indexstyle__BeforeStyle",componentId:"sc-12ee2ib-0"})(["min-height:calc(100vh - ","px);"],i.Mz)},8955:function(e,n,t){"use strict";t.d(n,{G7:function(){return P},ZP:function(){return O},u$:function(){return x}});var r=t(75582),i=t(82394),l=t(26304),a=t(90299),c=t(9134),u=t(24138),s=t(38276),o=t(30160),d=t(75499),p=t(70515),f=t(16488),v=t(42122),b=t(28598),h=["height","heightOffset","pipeline","selectedRun","selectedTab","setSelectedTab"];function m(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function j(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?m(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):m(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var x=44,g={uuid:"Run details"},Z={uuid:"Dependency tree"},P=[Z,g];function O(e){var n=e.height,t=e.heightOffset,i=e.pipeline,m=e.selectedRun,O=e.selectedTab,y=e.setSelectedTab,k=j({},(0,l.Z)(e,h));m?k.blockStatus=(0,f.IJ)(null===m||void 0===m?void 0:m.block_runs):k.noStatus=!0;var _=(0,v.Kn)(null===m||void 0===m?void 0:m.variables)?j({},null===m||void 0===m?void 0:m.variables):(null===m||void 0===m?void 0:m.variables)||{},w=null===m||void 0===m?void 0:m.event_variables;if(w&&(0,v.Kn)(w)&&!(0,v.Qr)(w))if((0,v.Kn)(_)&&_.hasOwnProperty("event")){var S=(0,v.Kn)(_.event)?_.event:{};_.event=j(j({},S),w)}else _.event=j({},w);var I=[];_&&JSON.stringify(_,null,2).split("\n").forEach((function(e){I.push(" ".concat(e))}));var D=m&&[["Run ID",null===m||void 0===m?void 0:m.id],["Variables",(0,b.jsx)(c.Z,{language:"json",small:!0,source:I.join("\n")},"variable_value")]],C=m&&(0,b.jsx)(s.Z,{pb:p.cd,px:p.cd,children:(0,b.jsx)(d.Z,{alignTop:!0,columnFlex:[null,1],columnMaxWidth:function(e){return 1===e?"100px":null},rows:D.map((function(e,n){var t=(0,r.Z)(e,2),i=t[0],l=t[1];return[(0,b.jsx)(o.ZP,{monospace:!0,muted:!0,children:i},"key_".concat(n)),(0,b.jsx)(o.ZP,{monospace:!0,textOverflow:!0,children:l},"val_".concat(n))]})),uuid:"LogDetail"})}),E=O&&y;return(0,b.jsxs)(b.Fragment,{children:[E&&(0,b.jsx)(a.Z,{onClickTab:y,selectedTabUUID:null===O||void 0===O?void 0:O.uuid,tabs:P,underlineStyle:!0}),(!E||Z.uuid===(null===O||void 0===O?void 0:O.uuid))&&(0,b.jsx)(u.ZP,j(j({},k),{},{height:n,heightOffset:(t||0)+(E?x:0),pipeline:i})),g.uuid===(null===O||void 0===O?void 0:O.uuid)&&C]})}},8916:function(e,n,t){"use strict";t.d(n,{FS:function(){return s},JZ:function(){return p},Tt:function(){return d},e7:function(){return f},wx:function(){return o}});var r=t(75582),i=t(82394),l=t(83784),a=t(30229);function c(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function u(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?c(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):c(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function s(e){return"string"===typeof e?e:JSON.stringify(e)}function o(e,n){var t,r;return null===e||void 0===e||null===(t=e.find((function(e){var t=e.block;return n(t)})))||void 0===t||null===(r=t.variables)||void 0===r?void 0:r.map((function(e){var n=e.value;return u(u({},e),{},{value:s(n)})}))}function d(e){var n;return null===(n=o(e,(function(e){return e.uuid===l.C})))||void 0===n?void 0:n.reduce((function(e,n){var t=n.uuid,r=n.value;return u(u({},e),{},(0,i.Z)({},t,r))}),{})}function p(e,n){return n===a.Xm.TIME?e.push({uuid:"execution_date",value:"<run datetime>"}):n===a.Xm.EVENT&&e.push({uuid:"event",value:"<trigger event>"}),e}function f(e){return e?Object.entries(e).reduce((function(e,n){var t=(0,r.Z)(n,2),l=t[0],a=t[1],c=a;try{c=JSON.parse(a)}catch(s){}return u(u({},e),{},(0,i.Z)({},l,c))}),{}):e}},88785:function(e,n,t){"use strict";t.d(n,{J:function(){return u},U:function(){return c}});var r=t(25976),i=t(44897),l=t(42631),a=t(70515),c=r.default.div.withConfig({displayName:"indexstyle__CardStyle",componentId:"sc-m7tlau-0"})(["border-radius:","px;border-style:solid;border-width:2px;height:","px;margin-right:","px;padding:","px;width:","px;"," ",""],l.TR,14*a.iI,a.cd*a.iI,a.cd*a.iI,40*a.iI,(function(e){return!e.selected&&"\n border-color: ".concat((e.theme.borders||i.Z.borders).light,";\n ")}),(function(e){return e.selected&&"\n border-color: ".concat((e.theme.interactive||i.Z.interactive).linkPrimary,";\n ")})),u=r.default.div.withConfig({displayName:"indexstyle__DateSelectionContainer",componentId:"sc-m7tlau-1"})(["border-radius:","px;padding:","px;"," "," ",""],l.n_,a.tr,(function(e){return"\n background-color: ".concat((e.theme.interactive||i.Z.interactive).defaultBackground,";\n ")}),(function(e){return e.absolute&&"\n position: absolute;\n z-index: 2;\n right: 0;\n top: ".concat(2.5*a.iI,"px;\n ")}),(function(e){return e.topPosition&&"\n top: -".concat(42*a.iI,"px;\n ")}))},37899:function(e,n,t){"use strict";var r=t(82394),i=t(75582),l=t(82684),a=t(71180),c=t(15338),u=t(97618),s=t(55485),o=t(38276),d=t(75499),p=t(30160),f=t(35576),v=t(17488),b=t(72473),h=t(70515),m=t(42122),j=t(81728),x=t(28598);function g(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function Z(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?g(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):g(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}n.Z=function(e){e.borderless,e.compact;var n=e.enableVariablesOverwrite,t=e.originalVariables,g=e.runtimeVariables,P=(e.setEnableVariablesOverwrite,e.setRuntimeVariables),O=(0,l.useState)({}),y=O[0],k=O[1],_=(0,l.useState)(null),w=_[0],S=_[1],I=(0,l.useState)(null),D=I[0],C=I[1];(0,l.useEffect)((function(){var e=Object.entries(g||{}).reduce((function(e,n){var t=(0,i.Z)(n,2),l=t[0],a=t[1],c=(0,j.Pb)(a)&&"object"===typeof JSON.parse(a)&&!Array.isArray(JSON.parse(a))&&null!==JSON.parse(a);return Z(Z({},e),{},(0,r.Z)({},l,c))}),{});k(e)}),[]);var E=function(e,n){var t={borderless:!0,key:"variable_uuid_input_".concat(e),monospace:!0,onChange:function(n){n.preventDefault(),P((function(t){return Z(Z({},t),{},(0,r.Z)({},e,n.target.value))}))},paddingHorizontal:0,placeholder:"Variable value",value:n};return y[e]?(0,x.jsx)(f.Z,Z(Z({},t),{},{rows:1,value:n})):(0,x.jsx)(v.Z,Z({},t))};return(0,x.jsxs)(x.Fragment,{children:[n&&g&&Object.entries(g).length>0&&(0,x.jsx)(d.Z,{columnFlex:[null,1,null],columns:[{uuid:"Variable"},{uuid:"Value"},{label:function(){return""},uuid:"Action"}],rows:Object.entries(g).map((function(e){var n=(0,i.Z)(e,2),r=n[0],l=n[1];return[(0,x.jsx)(p.ZP,{default:!0,monospace:!0,children:r},"variable_".concat(r)),E(r,l),!(null!==t&&void 0!==t&&t[r])&&(0,x.jsx)(a.ZP,{iconOnly:!0,onClick:function(){P((function(e){return(0,m.gR)(e,[r])}))},children:(0,x.jsx)(b.Trash,{default:!0})})]}))}),(0,x.jsx)(o.Z,{p:h.cd,children:(0,x.jsxs)(s.ZP,{alignItems:"center",children:[(0,x.jsx)(u.Z,{flex:1,children:(0,x.jsx)(v.Z,{fullWidth:!0,monospace:!0,onChange:function(e){return S(e.target.value)},placeholder:"New variable UUID",value:w||""})}),(0,x.jsx)(o.Z,{mr:1}),(0,x.jsx)(u.Z,{flex:1,children:(0,x.jsx)(v.Z,{fullWidth:!0,monospace:!0,onChange:function(e){return C(e.target.value)},placeholder:"Variable value",value:D||""})}),(0,x.jsx)(o.Z,{mr:1}),(0,x.jsx)(a.ZP,{beforeIcon:(0,x.jsx)(b.Add,{}),disabled:!w||!D,onClick:function(){P((function(e){return Z(Z({},e),{},(0,r.Z)({},w,D))})),S(null),C(null)},children:"Add runtime variable"})]})}),(0,x.jsx)(c.Z,{light:!0})]})}},55072:function(e,n,t){"use strict";t.d(n,{Et:function(){return p},Q:function(){return d}});t(82684);var r=t(71180),i=t(55485),l=t(38276),a=t(31748),c=t(72473),u=t(79633),s=t(70515),o=t(28598),d=30,p=9;n.ZP=function(e){var n=e.page,t=e.maxPages,d=e.onUpdate,p=e.totalPages,f=[],v=t;if(v>p)f=Array.from({length:p},(function(e,n){return n}));else{var b=Math.floor(v/2),h=n-b;n+b>=p?(h=p-v+2,v-=2):n-b<=0?(h=0,v-=2):(v-=4,h=n-Math.floor(v/2)),f=Array.from({length:v},(function(e,n){return n+h}))}return(0,o.jsx)(o.Fragment,{children:p>0&&(0,o.jsxs)(i.ZP,{alignItems:"center",children:[(0,o.jsx)(r.ZP,{disabled:0===n,onClick:function(){return d(n-1)},children:(0,o.jsx)(c.PaginateArrowLeft,{size:1.5*s.iI,stroke:a.Av})}),!f.includes(0)&&(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(l.Z,{ml:1,children:(0,o.jsx)(r.ZP,{borderLess:!0,noBackground:!0,onClick:function(){return d(0)},children:1})},0),!f.includes(1)&&(0,o.jsx)(l.Z,{ml:1,children:(0,o.jsx)(r.ZP,{noBackground:!0,noPadding:!0,notClickable:!0,children:"..."})},0)]}),f.map((function(e){return(0,o.jsx)(l.Z,{ml:1,children:(0,o.jsx)(r.ZP,{backgroundColor:e===n&&u.a$,borderLess:!0,noBackground:!0,notClickable:e===n,onClick:function(){e!==n&&d(e)},children:e+1})},e)})),!f.includes(p-1)&&(0,o.jsxs)(o.Fragment,{children:[!f.includes(p-2)&&(0,o.jsx)(l.Z,{ml:1,children:(0,o.jsx)(r.ZP,{noBackground:!0,noPadding:!0,notClickable:!0,children:"..."})},0),(0,o.jsx)(l.Z,{ml:1,children:(0,o.jsx)(r.ZP,{borderLess:!0,noBackground:!0,onClick:function(){return d(p-1)},children:p})},p-1)]}),(0,o.jsx)(l.Z,{ml:1}),(0,o.jsx)(r.ZP,{disabled:n===p-1,onClick:function(){return d(n+1)},children:(0,o.jsx)(c.PaginateArrowRight,{size:1.5*s.iI,stroke:a.Av})})]})})}},83641:function(e,n,t){"use strict";t.d(n,{I7:function(){return r},IB:function(){return u},VV:function(){return l},_7:function(){return a},rn:function(){return c}});var r,i=t(41143),l="datetime",a="code",c=i.V;!function(e){e.SECOND="second",e.MINUTE="minute",e.HOUR="hour",e.DAY="day",e.WEEK="week",e.MONTH="month",e.YEAR="year",e.CUSTOM="custom"}(r||(r={}));var u=[r.MINUTE,r.HOUR,r.DAY,r.WEEK,r.MONTH,r.YEAR]},83784:function(e,n,t){"use strict";t.d(n,{C:function(){return r}});var r="global"},14805:function(e,n,t){"use strict";var r=t(82394),i=t(44495),l=t(55485),a=t(44085),c=t(38276),u=t(30160),s=t(88785),o=t(70515),d=t(86735),p=t(28598);function f(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function v(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?f(Object(t),!0).forEach((function(n){(0,r.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):f(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}n.Z=function(e){var n=e.localTime,t=e.selectedDate,r=e.selectedTime,f=e.setSelectedDate,b=e.setSelectedTime,h=e.topPosition;return(0,p.jsxs)(s.J,{absolute:!0,topPosition:h,children:[(0,p.jsx)(i.ZP,{onChange:f,value:t}),(0,p.jsx)(c.Z,{mb:2}),(0,p.jsxs)(l.ZP,{alignItems:"center",children:[(0,p.jsxs)(u.ZP,{default:!0,large:!0,children:["Time (",n?"Local":"UTC","):"]}),(0,p.jsx)(c.Z,{pr:2}),(0,p.jsx)(a.Z,{compact:!0,monospace:!0,onChange:function(e){e.preventDefault(),b((function(n){return v(v({},n),{},{hour:e.target.value})}))},paddingRight:5*o.iI,placeholder:"HH",value:null===r||void 0===r?void 0:r.hour,children:(0,d.m5)(24,0).map((function(e){return String(e).padStart(2,"0")})).map((function(e){return(0,p.jsx)("option",{value:e,children:e},"hour_".concat(e))}))}),(0,p.jsx)(c.Z,{px:1,children:(0,p.jsx)(u.ZP,{bold:!0,large:!0,children:":"})}),(0,p.jsx)(a.Z,{compact:!0,monospace:!0,onChange:function(e){e.preventDefault(),b((function(n){return v(v({},n),{},{minute:e.target.value})}))},paddingRight:5*o.iI,placeholder:"MM",value:null===r||void 0===r?void 0:r.minute,children:(0,d.m5)(60,0).map((function(e){return String(e).padStart(2,"0")})).map((function(e){return(0,p.jsx)("option",{value:e,children:e},"minute_".concat(e))}))})]})]})}},79500:function(e,n,t){"use strict";t.d(n,{a:function(){return l}});var r=t(16488),i=t(3917);function l(e,n){var t,l;if(null!==n&&void 0!==n&&n.localTimezone)t=(0,i.n$)(e),l={hour:(0,i.lJ)(String(t.getHours())),minute:(0,i.lJ)(String(t.getMinutes()))};else{var a=e.split(" ")[1];t=(0,r.eI)(e),l={hour:a.substring(0,2),minute:a.substring(3,5)}}return{date:t,time:l}}},9134:function(e,n,t){"use strict";var r=t(82684),i=t(21124),l=t(68432),a=t(25976),c=t(65292),u=t(44897),s=t(95363),o=t(70515),d=t(28598);n.Z=function(e){var n=e.language,t=e.maxWidth,p=e.showLineNumbers,f=e.small,v=e.source,b=e.wrapLines,h=(0,r.useContext)(a.ThemeContext);function m(e){var r=e.value;return(0,d.jsx)(l.Z,{customStyle:{backgroundColor:(h.background||u.Z.background).popup,border:"none",borderRadius:"none",boxShadow:"none",fontFamily:s.Vp,fontSize:f?12:14,marginBottom:0,marginTop:0,maxWidth:t,paddingBottom:2*o.iI,paddingTop:2*o.iI},language:n,lineNumberStyle:{color:(h.content||u.Z.content).muted},showLineNumbers:p,style:c._4,useInlineStyles:!0,wrapLines:b,children:r})}return(0,d.jsx)(i.D,{components:{code:function(e){var n=e.children;return(0,d.jsx)(m,{value:n})}},children:v})}},51532:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return se}});var r=t(75582),i=t(77837),l=t(82394),a=t(38860),c=t.n(a),u=t(82684),s=t(69864),o=t(34376),d=t(83641),p=t(71180),f=t(15338),v=t(55485),b=t(85854),h=t(55072),m=t(75457),j=t(27966),x=t(44265),g=t(83784),Z=t(44085),P=t(38276),O=t(4190),y=t(75499),k=t(30160),_=t(35686),w=t(8955),S=t(72473),I=t(74395),D=t(70515),C=t(28795),E=t(81728),T=t(16488),M=t(8916),N=t(81655),A=t(15610),L=t(42122),F=t(50178),V=t(72619),R=t(95924),U=t(69419),B=t(70320),H=t(28598);function z(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function J(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?z(Object(t),!0).forEach((function(n){(0,l.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):z(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var Y=function(e){var n=e.backfill,t=e.errors,i=e.fetchBackfill,l=e.pipeline,a=e.setErrors,c=e.variables,z=(0,F.Ct)(),Y=(0,B.qB)(),K=(0,o.useRouter)(),W=n||{},X=W.block_uuid,Q=W.end_datetime,q=W.id,G=W.interval_type,$=W.interval_units,ee=W.name,ne=W.pipeline_run_dates,te=W.start_datetime,re=W.status,ie=W.total_run_count,le=W.variables,ae=void 0===le?{}:le,ce=l.uuid,ue=(0,U.iV)(),se={_limit:40,_offset:40*(null!==ue&&void 0!==ue&&ue.page?ue.page:0)};null!==ue&&void 0!==ue&&ue.status&&(se.status=ue.status);var oe=_.ZP.pipeline_runs.list(J(J({},se),{},{backfill_id:q}),{refreshInterval:3e3,revalidateOnFocus:!0},{pauseFetch:!q}),de=oe.data,pe=oe.mutate,fe=!(te&&Q&&G&&$),ve=!re,be=(0,u.useMemo)((function(){return(ve?ne:null===de||void 0===de?void 0:de.pipeline_runs)||[]}),[de,ne,ve]),he=(0,u.useMemo)((function(){var e;return ve?ie:null===de||void 0===de||null===(e=de.metadata)||void 0===e?void 0:e.count}),[de,ve,ie]),me=(0,u.useState)(null),je=me[0],xe=me[1],ge=(0,u.useMemo)((function(){var e=null!==ue&&void 0!==ue&&ue.page?ue.page:0;return(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(j.Z,{disableRowSelect:ve,emptyMessage:null!==ue&&void 0!==ue&&ue.status||re?"No runs available":'No runs available. Please complete backfill configuration by clicking "Edit backfill" above.',fetchPipelineRuns:pe,onClickRow:function(e){return xe((function(n){var t=be[e];return(null===n||void 0===n?void 0:n.id)!==t.id?t:null}))},pipelineRuns:be,selectedRun:je,setErrors:a,setSelectedRun:xe}),(0,H.jsx)(P.Z,{p:2,children:(0,H.jsx)(h.ZP,{maxPages:9,onUpdate:function(e){var n=Number(e),t=J(J({},ue),{},{page:n>=0?n:0});K.push("/pipelines/[pipeline]/backfills/[...slug]","/pipelines/".concat(ce,"/backfills/").concat(q,"?").concat((0,U.uM)(t)))},page:Number(e),totalPages:Math.ceil(he/40)})})]})}),[pe,q,be,ce,ue,K,je,a,ve,he]),Ze=(0,u.useState)(w.G7[0]),Pe=Ze[0],Oe=Ze[1],ye=(0,s.Db)(_.ZP.backfills.useUpdate(q),{onSuccess:function(e){return(0,V.wD)(e,{callback:function(){i(),pe()},onErrorCallback:function(e,n){return a({errors:n,response:e})}})}}),ke=(0,r.Z)(ye,2),_e=ke[0],we=ke[1].isLoading,Se=(0,u.useMemo)((function(){return!!re&&(d.rn.CANCELLED!==re&&d.rn.FAILED!==re)}),[re]),Ie=(0,u.useMemo)((function(){return re&&d.rn.CANCELLED!==re&&d.rn.FAILED!==re&&d.rn.INITIAL!==re&&d.rn.RUNNING!==re}),[re]),De=(0,u.useMemo)((function(){var e={default:!0,size:1.5*D.iI},n=[[(0,H.jsxs)(v.ZP,{alignItems:"center",children:[(0,H.jsx)(S.MultiShare,J({},e)),(0,H.jsx)(P.Z,{mr:1}),(0,H.jsx)(k.ZP,{default:!0,children:"Backfill type"})]},"backfill_type_label"),(0,H.jsx)(k.ZP,{monospace:!0,children:X?d._7:d.VV},"backfill_type")],[(0,H.jsxs)(v.ZP,{alignItems:"center",children:[(0,H.jsx)(S.Switch,J({},e)),(0,H.jsx)(P.Z,{mr:1}),(0,H.jsx)(k.ZP,{default:!0,children:"Status"})]},"backfill_status_label"),(0,u.createElement)(k.ZP,J(J({},(0,N.NC)(re)),{},{key:"backfill_status"}),re||"inactive")]];return X||n.push.apply(n,[[(0,H.jsxs)(v.ZP,{alignItems:"center",children:[(0,H.jsx)(S.CalendarDate,J({},e)),(0,H.jsx)(P.Z,{mr:1}),(0,H.jsx)(k.ZP,{default:!0,children:"Start date and time"})]},"backfill_start_date_label"),(0,H.jsx)(k.ZP,{monospace:!0,small:!0,children:(0,T.Uc)(te,Y)},"backfill_start_date")],[(0,H.jsxs)(v.ZP,{alignItems:"center",children:[(0,H.jsx)(S.CalendarDate,J({},e)),(0,H.jsx)(P.Z,{mr:1}),(0,H.jsx)(k.ZP,{default:!0,children:"End date and time"})]},"backfill_end_date_label"),(0,H.jsx)(k.ZP,{monospace:!0,small:!0,children:(0,T.Uc)(Q,Y)},"backfill_end_date")],[(0,H.jsxs)(v.ZP,{alignItems:"center",children:[(0,H.jsx)(S.Schedule,J({},e)),(0,H.jsx)(P.Z,{mr:1}),(0,H.jsx)(k.ZP,{default:!0,children:"Interval type"})]},"interval_type_label"),(0,H.jsx)(k.ZP,{monospace:!0,children:G&&(0,E.kC)(G)},"interval_type")],[(0,H.jsxs)(v.ZP,{alignItems:"center",children:[(0,H.jsx)(S.Schedule,J({},e)),(0,H.jsx)(P.Z,{mr:1}),(0,H.jsx)(k.ZP,{default:!0,children:"Interval units"})]},"interval_units_label"),(0,H.jsx)(k.ZP,{monospace:!0,children:$},"interval_units")],[(0,H.jsxs)(v.ZP,{alignItems:"center",children:[(0,H.jsx)(S.NumberHash,J({},e)),(0,H.jsx)(P.Z,{mr:1}),(0,H.jsx)(k.ZP,{default:!0,children:"Total runs"})]},"total_runs_label"),(0,H.jsx)(k.ZP,{monospace:!0,children:ie},"total_runs")]]),(0,H.jsx)(y.Z,{columnFlex:[null,1],rows:n})}),[X,Y,Q,G,$,te,re,ie]),Ce=(0,u.useMemo)((function(){return ae||{}}),[ae]),Ee=(0,u.useMemo)((function(){var e=(0,M.wx)(c,(function(e){return e.uuid===g.C}))||[];return(0,L.Qr)(Ce)||Object.entries(Ce).forEach((function(n){var t=(0,r.Z)(n,2),i=t[0],l=t[1],a=e.findIndex((function(e){return(null===e||void 0===e?void 0:e.uuid)===i}));-1!==a?e.splice(a,1,{uuid:i,value:(0,M.FS)(l)}):e.push({uuid:i,value:(0,M.FS)(l)})})),"undefined"!==typeof e&&null!==e&&void 0!==e&&e.length?(0,H.jsx)(y.Z,{columnFlex:[null,1],rows:e.map((function(e){var n=e.uuid,t=e.value;return[(0,H.jsx)(k.ZP,{default:!0,monospace:!0,small:!0,children:n},"settings_variable_label_".concat(n)),(0,H.jsx)(k.ZP,{monospace:!0,small:!0,children:t},"settings_variable_".concat(n))]}))}):null}),[Ce,c]);return(0,H.jsx)(H.Fragment,{children:(0,H.jsxs)(m.Z,{afterHidden:!je,before:(0,H.jsxs)(I.M,{children:[(0,H.jsxs)(P.Z,{mb:D.HN,pt:D.cd,px:D.cd,children:[(0,H.jsx)(P.Z,{mb:D.cd,children:(0,H.jsx)(S.Backfill,{size:5*D.iI})}),(0,H.jsx)(b.Z,{children:ee})]}),(0,H.jsx)(P.Z,{px:D.cd,children:(0,H.jsx)(b.Z,{level:5,children:"Settings"})}),(0,H.jsx)(f.Z,{light:!0,mt:1,short:!0}),De,Ee&&(0,H.jsxs)(P.Z,{my:D.HN,children:[(0,H.jsx)(P.Z,{px:D.cd,children:(0,H.jsx)(b.Z,{level:5,children:"Runtime variables"})}),(0,H.jsx)(f.Z,{light:!0,mt:1,short:!0}),Ee]})]}),beforeWidth:34*D.iI,breadcrumbs:[{label:function(){return"Backfills"},linkProps:{as:"/pipelines/".concat(ce,"/backfills"),href:"/pipelines/[pipeline]/backfills"}},{label:function(){return ee},linkProps:{as:"/pipelines/".concat(ce,"/backfills/").concat(q),href:"/pipelines/[pipeline]/backfills/[...slug]"}}],buildSidekick:function(e){return(0,w.ZP)(J(J({},e),{},{selectedRun:je,selectedTab:Pe,setSelectedTab:Oe}))},errors:t,pageName:C.M.BACKFILLS,pipeline:l,setErrors:a,subheader:(0,H.jsxs)(v.ZP,{alignItems:"center",children:[!Ie&&(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(p.ZP,{beforeIcon:Se?(0,H.jsx)(S.Pause,{size:2*D.iI}):(0,H.jsx)(S.PlayButtonFilled,{inverted:!(d.rn.CANCELLED===re||d.rn.FAILED===re),size:2*D.iI}),danger:Se,disabled:fe,loading:we,onClick:function(e){(0,R.j)(e),_e({backfill:{status:Se?d.rn.CANCELLED:d.rn.INITIAL}})},outline:!0,success:!Se&&!(d.rn.CANCELLED===re||d.rn.FAILED===re)&&!fe,children:Se?"Cancel backfill":d.rn.CANCELLED===re||d.rn.FAILED===re?"Retry backfill":"Start backfill"}),(0,H.jsx)(P.Z,{mr:D.cd})]}),!z&&(0,H.jsxs)(H.Fragment,{children:[re===x.VO.COMPLETED?(0,H.jsx)(k.ZP,{bold:!0,default:!0,large:!0,children:"Filter runs by status:"}):(0,H.jsx)(p.ZP,{linkProps:{as:"/pipelines/".concat(ce,"/backfills/").concat(q,"/edit"),href:"/pipelines/[pipeline]/backfills/[...slug]"},noHoverUnderline:!0,outline:!0,sameColorAsText:!0,children:"Edit backfill"}),(0,H.jsx)(P.Z,{mr:D.cd})]}),!ve&&(0,H.jsxs)(Z.Z,{compact:!0,defaultColor:!0,onChange:function(e){e.preventDefault(),"all"===e.target.value?K.push("/pipelines/[pipeline]/backfills/[...slug]","/pipelines/".concat(ce,"/backfills/").concat(q)):(0,A.u)({page:0,status:e.target.value})},paddingRight:4*D.iI,placeholder:"Select run status",value:(null===ue||void 0===ue?void 0:ue.status)||"all",children:[(0,H.jsx)("option",{value:"all",children:"All statuses"},"all_statuses"),x.IK.map((function(e){return(0,H.jsx)("option",{value:e,children:x.Do[e]},e)}))]})]}),title:function(){return ee},uuid:"backfill/detail",children:[(0,H.jsx)(P.Z,{mt:D.cd,px:D.cd,children:(0,H.jsx)(b.Z,{level:5,children:"Runs for this backfill"})}),(0,H.jsx)(f.Z,{light:!0,mt:D.cd,short:!0}),de?ge:(0,H.jsx)(P.Z,{m:2,children:(0,H.jsx)(O.Z,{inverted:!0})})]})})},K=t(14805),W=t(50724),X=t(97618),Q=t(37899),q=t(17488),G=[{label:function(){return"Date and time window"},description:function(){return"Backfill between a date and time range."},uuid:d.VV}],$=t(88785),ee=t(79500);function ne(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function te(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?ne(Object(t),!0).forEach((function(n){(0,l.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):ne(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var re=function(e){var n=e.backfill,t=e.errors,i=e.fetchBackfill,l=e.pipeline,a=e.setErrors,c=e.variables,h=(0,o.useRouter)(),j=(0,B.qB)(),x=(0,u.useState)(),g=x[0],O=x[1],w=(0,u.useState)(),I=w[0],N=w[1],A=g||{},F=A.block_uuid,R=A.id,U=A.interval_type,z=A.interval_units,J=A.name,Y=l.uuid,ne=(0,u.useMemo)((function(){return(0,L.Qr)((null===n||void 0===n?void 0:n.variables)||{})?(0,M.Tt)(c)||{}:(0,L.Xc)(n.variables,(function(e){return(0,M.FS)(e)}))}),[null===n||void 0===n?void 0:n.variables,c]),re=(0,u.useState)(!0),ie=re[0],le=re[1],ae=(0,u.useState)(ne),ce=ae[0],ue=ae[1],se=(0,u.useState)(F?d._7:d.VV),oe=se[0],de=se[1],pe=(0,u.useState)(!1),fe=pe[0],ve=pe[1],be=(0,u.useState)(!1),he=be[0],me=be[1],je=(0,u.useState)(null),xe=je[0],ge=je[1],Ze=(0,u.useState)(null),Pe=Ze[0],Oe=Ze[1],ye=(0,u.useState)({hour:"00",minute:"00"}),ke=ye[0],_e=ye[1],we=(0,u.useState)({hour:"00",minute:"00"}),Se=we[0],Ie=we[1];(0,u.useEffect)((function(){if(n){O(n);var e=n.start_datetime;if(e){var t=(0,ee.a)(e,{localTimezone:j});Oe(null===t||void 0===t?void 0:t.date),Ie(t.time)}var r=n.end_datetime;if(r){var i=(0,ee.a)(r,{localTimezone:j});ge(null===i||void 0===i?void 0:i.date),_e(null===i||void 0===i?void 0:i.time)}}}),[j,n]),(0,u.useEffect)((function(){!I&&null!==g&&void 0!==g&&g.settings&&N(g.settings)}),[I,null===g||void 0===g?void 0:g.settings]);var De=(0,u.useMemo)((function(){var e=[[(0,H.jsxs)(v.ZP,{alignItems:"center",children:[(0,H.jsx)(S.Alphabet,{default:!0}),(0,H.jsx)(P.Z,{mr:1}),(0,H.jsx)(k.ZP,{default:!0,children:"Backfill name"})]},"model_name_detail"),(0,H.jsx)(q.Z,{monospace:!0,onChange:function(e){e.preventDefault(),O((function(n){return te(te({},n),{},{name:e.target.value})}))},placeholder:"Name this backfill",value:J},"model_name_input_detail")]];return d.VV===oe&&e.push.apply(e,[[(0,H.jsxs)(v.ZP,{alignItems:"center",children:[(0,H.jsx)(S.CalendarDate,{default:!0}),(0,H.jsx)(P.Z,{mr:1}),(0,H.jsx)(k.ZP,{default:!0,children:"Start date and time"})]},"start_time"),(0,H.jsxs)("div",{style:{minHeight:"".concat(5.75*D.iI,"px")},children:[!fe&&(0,H.jsx)(q.Z,{monospace:!0,onClick:function(){return ve((function(e){return!e}))},onFocus:function(){return ve(!0)},placeholder:"YYYY-MM-DD HH:MM",value:Pe?(0,T.XM)(Pe,Se,{localTimezone:j}):""}),(0,H.jsx)("div",{style:{width:"400px"},children:(0,H.jsx)(W.Z,{disableEscape:!0,onClickOutside:function(){return ve(!1)},open:fe,style:{position:"relative"},children:(0,H.jsx)(K.Z,{localTime:j,selectedDate:Pe,selectedTime:Se,setSelectedDate:Oe,setSelectedTime:Ie,topPosition:!0})})})]},"start_time_input")],[(0,H.jsxs)(v.ZP,{alignItems:"center",children:[(0,H.jsx)(S.CalendarDate,{default:!0}),(0,H.jsx)(P.Z,{mr:1}),(0,H.jsx)(k.ZP,{default:!0,children:"End date and time"})]},"end_time"),(0,H.jsxs)("div",{style:{minHeight:"".concat(5.75*D.iI,"px")},children:[!he&&(0,H.jsx)(q.Z,{monospace:!0,onClick:function(){return me((function(e){return!e}))},onFocus:function(){return me(!0)},placeholder:"YYYY-MM-DD HH:MM",value:xe?(0,T.XM)(xe,ke,{localTimezone:j}):""}),(0,H.jsx)("div",{style:{width:"400px"},children:(0,H.jsx)(W.Z,{disableEscape:!0,onClickOutside:function(){return me(!1)},open:he,style:{position:"relative"},children:(0,H.jsx)(K.Z,{localTime:j,selectedDate:xe,selectedTime:ke,setSelectedDate:ge,setSelectedTime:_e,topPosition:!0})})})]},"end_time_input")],[(0,H.jsxs)(v.ZP,{alignItems:"center",children:[(0,H.jsx)(S.Schedule,{default:!0}),(0,H.jsx)(P.Z,{mr:1}),(0,H.jsx)(k.ZP,{default:!0,children:"Interval type"})]},"interval_type"),(0,H.jsx)(Z.Z,{monospace:!0,onChange:function(e){e.preventDefault(),O((function(n){return te(te({},n),{},{interval_type:e.target.value})}))},placeholder:"Time spacing between each backfill",value:U,children:d.IB.map((function(e){return(0,H.jsx)("option",{value:e,children:(0,E.kC)(e)},e)}))},"interval_type_input")],[(0,H.jsxs)(v.ZP,{alignItems:"center",children:[(0,H.jsx)(S.Schedule,{default:!0}),(0,H.jsx)(P.Z,{mr:1}),(0,H.jsx)(k.ZP,{default:!0,children:"Interval units"})]},"interval_units"),(0,H.jsx)(q.Z,{disabled:!U,minValue:1,monospace:!0,onChange:function(e){e.preventDefault();var n=+e.target.value;O((function(e){return te(te({},e),{},{interval_units:n<1?1:n})}))},placeholder:U?"Number of ".concat(U).concat(U!==d.I7.CUSTOM?"s":""," between each backfill"):"Interval type is required",type:"number",value:z},"interval_unit_input")]]),(0,L.Qr)(ne)||e.push([(0,H.jsxs)(v.ZP,{alignItems:"center",children:[(0,H.jsx)(S.Variables,{default:!0}),(0,H.jsx)(P.Z,{mr:1}),(0,H.jsx)(k.ZP,{default:!0,children:"Runtime variables"})]},"overwrite_runtime_variables"),(0,H.jsx)(Q.Z,{borderless:!0,compact:!0,enableVariablesOverwrite:ie,runtimeVariables:ce,setEnableVariablesOverwrite:le,setRuntimeVariables:ue},"overwrite_runtime_variables_table")]),e.push([(0,H.jsx)(v.ZP,{alignItems:"center",children:(0,H.jsx)(k.ZP,{default:!0,children:"Max concurrent runs"})},"concurrency"),(0,H.jsx)(q.Z,{minValue:1,monospace:!0,onChange:function(e){e.preventDefault(),N((function(n){return te(te({},n),{},{pipeline_run_limit:e.target.value})}))},type:"number",value:null===I||void 0===I?void 0:I.pipeline_run_limit},"concurrency_input")]),(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(P.Z,{mb:2,px:D.cd,children:(0,H.jsx)(b.Z,{children:"Settings"})}),(0,H.jsx)(f.Z,{light:!0,short:!0}),(0,H.jsx)(y.Z,{columnFlex:[null,1],rows:e})]})}),[xe,Pe,j,ie,U,z,J,ce,ne,null===I||void 0===I?void 0:I.pipeline_run_limit,oe,fe,he,ke,Se]),Ce=(0,s.Db)(_.ZP.backfills.useUpdate(R),{onSuccess:function(e){return(0,V.wD)(e,{callback:function(){i(),h.push("/pipelines/[pipeline]/backfills/[...slug]","/pipelines/".concat(Y,"/backfills/").concat(R))},onErrorCallback:function(e,n){return a({errors:n,response:e})}})}}),Ee=(0,r.Z)(Ce,2),Te=Ee[0],Me=Ee[1].isLoading,Ne=(0,u.useCallback)((function(){var e=te(te({},(0,L.GL)(g,["name"])),{},{end_datetime:null,interval_type:null,interval_units:null,settings:I,start_datetime:null,variables:ie?(0,M.e7)(ce):{}});return d._7===oe||(e.interval_type=U,e.interval_units=z,e.end_datetime=xe&&null!==ke&&void 0!==ke&&ke.hour&&null!==ke&&void 0!==ke&&ke.minute?(0,T.XM)(xe,ke,{convertToUtc:j,includeSeconds:!0,localTimezone:j}):null,e.start_datetime=Pe&&null!==Se&&void 0!==Se&&Se.hour&&null!==Se&&void 0!==Se&&Se.minute?(0,T.XM)(Pe,Se,{convertToUtc:j,includeSeconds:!0,localTimezone:j}):null),Te({backfill:e})}),[xe,Pe,j,ie,U,z,g,ce,I,oe,ke,Se,Te]),Ae=(0,u.useMemo)((function(){return d._7===oe?!F:!(xe&&Pe&&U&&z)}),[F,xe,Pe,U,z,oe]);return(0,H.jsxs)(m.Z,{breadcrumbs:[{label:function(){return"Backfills"},linkProps:{as:"/pipelines/".concat(Y,"/backfills"),href:"/pipelines/[pipeline]/backfills"}},{label:function(){return null===g||void 0===g?void 0:g.name},linkProps:{as:"/pipelines/".concat(Y,"/backfills/").concat(R),href:"/pipelines/[pipeline]/backfills/[...slug]"}}],errors:t,pageName:C.M.BACKFILLS,pipeline:l,setErrors:a,subheader:(0,H.jsxs)(v.ZP,{alignItems:"center",children:[(0,H.jsx)(p.ZP,{disabled:Ae,loading:Me,onClick:Ne,outline:!0,primary:!0,children:"Save changes"}),(0,H.jsx)(P.Z,{mr:1}),(0,H.jsx)(p.ZP,{linkProps:{href:"/pipelines/[pipeline]/backfills/[...slug]",as:"/pipelines/".concat(Y,"/backfills/").concat(R)},noHoverUnderline:!0,outline:!0,sameColorAsText:!0,children:"Cancel"})]}),title:function(){return"Edit ".concat(null===g||void 0===g?void 0:g.name)},uuid:"backfill/edit",children:[(0,H.jsxs)(P.Z,{p:D.cd,children:[(0,H.jsxs)(P.Z,{mb:2,children:[(0,H.jsx)(b.Z,{children:"Backfill type"}),(0,H.jsx)(k.ZP,{muted:!0,children:"How would you like this pipeline to be backfilled?"})]}),(0,H.jsx)(v.ZP,{children:G.map((function(e){var n=e.label,t=e.description,r=e.uuid,i=oe===r,l=oe&&!i;return(0,H.jsx)(p.ZP,{noBackground:!0,noBorder:!0,noPadding:!0,onClick:function(){de(r)},children:(0,H.jsx)($.U,{selected:i,children:(0,H.jsxs)(v.ZP,{alignItems:"center",children:[(0,H.jsx)(X.Z,{children:(0,H.jsx)("input",{checked:i,type:"radio"})}),(0,H.jsx)(P.Z,{mr:D.cd}),(0,H.jsxs)(X.Z,{alignItems:"flex-start",flexDirection:"column",children:[(0,H.jsx)(b.Z,{bold:!0,default:!i&&!l,level:5,muted:!i&&l,children:n()}),(0,H.jsx)(k.ZP,{default:!i&&!l,leftAligned:!0,muted:l,children:t()})]})]})})},r)}))})]}),(0,H.jsx)(P.Z,{mt:5,children:De})]})},ie=t(93808),le=t(98464);function ae(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function ce(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?ae(Object(t),!0).forEach((function(n){(0,l.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):ae(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function ue(e){var n=e.backfillId,t=e.pipelineUUID,r=e.subpath,i=(0,u.useState)(null),l=i[0],a=i[1],c=_.ZP.variables.pipelines.list(t,{},{revalidateOnFocus:!1}).data,s=(0,u.useMemo)((function(){return null===c||void 0===c?void 0:c.variables}),[c]),o=_.ZP.pipelines.detail(t,{includes_content:!1,includes_outputs:!1},{revalidateOnFocus:!1}).data,d=(0,u.useMemo)((function(){return ce(ce({},null===o||void 0===o?void 0:o.pipeline),{},{uuid:t})}),[o,t]),p=(0,U.iV)(),f={_limit:40,_offset:40*(null!==p&&void 0!==p&&p.page?p.page:0),include_preview_runs:!0},v=_.ZP.backfills.detail(n,ce({},f),{revalidateOnFocus:!0}),b=v.data,h=v.mutate,m=(0,u.useMemo)((function(){return null===b||void 0===b?void 0:b.backfill}),[b]),j=(0,le.Z)(p);return(0,u.useEffect)((function(){(null===j||void 0===j?void 0:j.page)!==(null===p||void 0===p?void 0:p.page)&&h()}),[h,p,j]),"edit"===r?(0,H.jsx)(re,{backfill:m,errors:l,fetchBackfill:h,pipeline:d,setErrors:a,variables:s}):(0,H.jsx)(Y,{backfill:m,errors:l,fetchBackfill:h,pipeline:d,setErrors:a,variables:s})}ue.getInitialProps=function(){var e=(0,i.Z)(c().mark((function e(n){var t,i,l,a,u,s;return c().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t=n.query,i=t.pipeline,l=t.slug,!Array.isArray(l)){e.next=4;break}return a=(0,r.Z)(l,2),u=a[0],s=a[1],e.abrupt("return",{backfillId:u,pipelineUUID:i,subpath:s});case 4:return e.abrupt("return",{pipelineUUID:i});case 5:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}();var se=(0,ie.Z)(ue)},53664:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/pipelines/[pipeline]/backfills/[...slug]",function(){return t(51532)}])}},function(e){e.O(0,[9161,7674,1557,3782,7966,9774,2888,179],(function(){return n=53664,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8450],{16488:function(e,n,t){"use strict";t.d(n,{IJ:function(){return b},M8:function(){return P},Uc:function(){return j},XM:function(){return E},_U:function(){return v},eI:function(){return k},gU:function(){return y},lO:function(){return T},ri:function(){return h},tL:function(){return _},vJ:function(){return g},xH:function(){return O}});var r,i=t(82394),u=t(92083),o=t.n(u),l=t(3917),c=t(4383),a=t(30229),s=t(42122),f=t(86735);function d(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function p(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?d(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):d(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var v=function(e){return!!e&&!Object.values(a.U5).includes(e)};function b(e){return null===e||void 0===e?void 0:e.reduce((function(e,n){var t=n.block_uuid,r=n.completed_at,u=n.started_at,l=n.status,c=null;u&&r&&(c=o()(r).valueOf()-o()(u).valueOf());return p(p({},e),{},(0,i.Z)({},t,{runtime:c,status:l}))}),{})}var m,h=function(e){var n=[{description:function(){return"This pipeline will run continuously on an interval or just once."},label:function(){return"Schedule"},uuid:a.Xm.TIME},{description:function(){return"This pipeline will run when a specific event occurs."},label:function(){return"Event"},uuid:a.Xm.EVENT},{description:function(){return"Run this pipeline when you make an API call."},label:function(){return"API"},uuid:a.Xm.API}];return e?n.slice(0,1):n};function O(e){var n=(0,s.gR)(e,[a.gm.INTERVAL,a.gm.TYPE]),t=e[a.gm.INTERVAL];t&&(n["schedule_interval[]"]=encodeURIComponent(t));var r=e[a.gm.TYPE];return r&&(n["schedule_type[]"]=r),n}function k(e){return e?new Date(o()(e).valueOf()):null}function j(e,n){return n?(0,l.XG)(e,n):function(e){if("string"!==typeof e)return e;var n=e.split("+")[0];return o()(k(n)).format(l.Nx)}(e)}!function(e){e.DAY="day",e.HOUR="hour",e.MINUTE="minute",e.SECOND="second"}(m||(m={}));var _=(r={},(0,i.Z)(r,m.DAY,86400),(0,i.Z)(r,m.HOUR,3600),(0,i.Z)(r,m.MINUTE,60),(0,i.Z)(r,m.SECOND,1),r);function y(e){var n=m.SECOND,t=e;return e%86400===0?(t/=86400,n=m.DAY):e%3600===0?(t/=3600,n=m.HOUR):e%60===0&&(t/=60,n=m.MINUTE),{time:t,unit:n}}function g(e,n){return e*_[n]}function E(e,n,t){var r,i=o()(e);return i.set("hour",+(null===n||void 0===n?void 0:n.hour)||0),i.set("minute",+(null===n||void 0===n?void 0:n.minute)||0),i.set("second",0),r=i.format(l.TD),null!==t&&void 0!==t&&t.includeSeconds&&(r=r.concat(":00")),null!==t&&void 0!==t&&t.localTimezone&&(r=i.format(l.lE),null!==t&&void 0!==t&&t.convertToUtc&&(r=(0,l.d$)(r,{includeSeconds:null===t||void 0===t?void 0:t.includeSeconds,utcFormat:!0}))),r}function P(e){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],t="",r=!0;if(r){var i=(0,c.XF)();n?t="".concat(i,"/api/pipeline_schedules/").concat(null===e||void 0===e?void 0:e.id,"/api_trigger"):(t="".concat(i,"/api/pipeline_schedules/").concat(null===e||void 0===e?void 0:e.id,"/pipeline_runs"),null!==e&&void 0!==e&&e.token&&(t="".concat(t,"/").concat(e.token)))}return t}function w(e,n,t){return e.match(/[*,-/]/)?{additionalOffset:0,cronValue:e}:function(e,n,t){var r=t.indexOf(e),i=0;if(n<0)for(var u=0;u>n;u--)0===r?(r=t.length-1,i-=1):r-=1;else if(n>0)for(var o=0;o<n;o++)r===t.length-1?(r=0,i+=1):r+=1;var l="number"===typeof t[r]?t[r]:e;return{additionalOffset:i,cronValue:String(l)}}(+e,n,t)}var Z=(0,f.m5)(60),x=(0,f.m5)(24),D=(0,l.Cs)();function T(e,n){if(!e)return e;var t=o()().local().format("Z"),r=t.split(":"),i="-"===t[0],u=3===r[0].length?Number(r[0].slice(1)):Number(r[0]),l=Number(r[1]);(i&&!n||!i&&n)&&(u=-u,l=-l);var c=e.split(" "),a=c[0],s=c[1],f=c[2],d=w(a,l,Z),p=w(s,u+d.additionalOffset,x);if(c[0]=d.cronValue,c[1]=p.cronValue,0!==(null===p||void 0===p?void 0:p.additionalOffset)){var v=w(f,p.additionalOffset,D);c[2]=v.cronValue}return c.join(" ")}},83641:function(e,n,t){"use strict";t.d(n,{I7:function(){return r},IB:function(){return c},VV:function(){return u},_7:function(){return o},rn:function(){return l}});var r,i=t(41143),u="datetime",o="code",l=i.V;!function(e){e.SECOND="second",e.MINUTE="minute",e.HOUR="hour",e.DAY="day",e.WEEK="week",e.MONTH="month",e.YEAR="year",e.CUSTOM="custom"}(r||(r={}));var c=[r.MINUTE,r.HOUR,r.DAY,r.WEEK,r.MONTH,r.YEAR]},4303:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return z}});var r=t(77837),i=t(75582),u=t(38860),o=t.n(u),l=t(82684),c=t(69864),a=t(34376),s=t(82394),f=t(12691),d=t.n(f),p=t(83641),v=t(71180),b=t(55485),m=t(48670),h=t(75499),O=t(30160),k=t(35686),j=t(50724),_=t(89515),y=t(38276),g=t(81655),E=t(72191),P=t(72473),w=t(72619),Z=t(23780),x=t(28598);var D=function(e){var n=e.fetchItems,t=e.mutationFn,r=e.path,u=e.pipelineUUID,o=(0,a.useRouter)(),s=(0,l.useRef)({}),f=(0,l.useState)(null),d=f[0],p=f[1],b=(0,l.useState)(0),m=b[0],h=b[1],O=(0,l.useState)(0),k=O[0],D=O[1],T=(0,Z.VI)(null,{},[],{uuid:"".concat(r,"/").concat(u,"/delete/error")}),C=(0,i.Z)(T,1)[0],N=(0,c.Db)((function(e){return t(e)()}),{onSuccess:function(e){return(0,w.wD)(e,{callback:function(){null===n||void 0===n||n(),u&&o.push("/pipelines/[pipeline]/".concat(r),"/pipelines/".concat(u,"/").concat(r))},onErrorCallback:function(e,n){return C({errors:n,response:e})}})}}),I=(0,i.Z)(N,1)[0];return{deleteButton:function(e,n,t){return s.current[e]=(0,l.createRef)(),(0,x.jsxs)(y.Z,{mr:1,children:[(0,x.jsx)(v.ZP,{default:!0,iconOnly:!0,noBackground:!0,onClick:function(){var n,t,r,i;p(e),h((null===(n=s.current[e])||void 0===n||null===(t=n.current)||void 0===t?void 0:t.offsetTop)||0),D((null===(r=s.current[e])||void 0===r||null===(i=r.current)||void 0===i?void 0:i.offsetLeft)||0)},ref:s.current[e],title:"Delete",children:(0,x.jsx)(P.Trash,{default:!0,size:E.bL})}),(0,x.jsx)(j.Z,{onClickOutside:function(){return p(null)},open:d===e,children:(0,x.jsx)(_.Z,{danger:!0,left:(k||0)-g.nH,onCancel:function(){return p(null)},onClick:function(){p(null),I(e)},title:t,top:(m||0)-(n<=1?g.oz:g.OK),width:g.Xx})})]})}}},T=t(44265),C=t(70515),N=t(16488),I=t(50178),S=t(70320),U=t(3917);function R(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function A(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?R(Object(t),!0).forEach((function(n){(0,s.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):R(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var M=function(e){var n=e.fetchBackfills,t=e.models,r=e.onClickRow,i=e.pipeline,u=e.selectedRow,o=(0,I.Ct)(),c=(0,S.qB)(),a=null===i||void 0===i?void 0:i.uuid,s=c?g.O$:{},f=D({fetchItems:n,mutationFn:k.ZP.backfills.useDelete,path:"backfills",pipelineUUID:a}).deleteButton,j=[{uuid:"Status"},{uuid:"Name"},{uuid:"Type"},{uuid:"Runs"},A(A({},s),{},{uuid:"Backfill"}),A(A({},s),{},{uuid:"Started at"}),A(A({},s),{},{uuid:"Completed at"})];return o||j.push({label:function(){return""},uuid:"edit_delete_backfill"}),(0,x.jsx)(h.Z,{columnFlex:[null,1,null,null,null,1,1,null],columns:j,isSelectedRow:function(e){return t[e].id===(null===u||void 0===u?void 0:u.id)},onClickRow:function(e){return null===r||void 0===r?void 0:r(t[e])},rows:t.map((function(e,n){var t=e.block_uuid,r=e.completed_at,i=e.end_datetime,u=e.id,s=e.name,h=e.start_datetime,k=e.started_at,j=e.status,_=e.total_run_count,y=[(0,l.createElement)(O.ZP,A(A({},(0,g.NC)(j)),{},{key:"status"}),j||"inactive"),(0,x.jsx)(d(),{as:"/pipelines/".concat(a,"/backfills/").concat(u),href:"/pipelines/[pipeline]/backfills/[...slug]",passHref:!0,children:(0,x.jsx)(m.Z,{bold:!0,sameColorAsText:!0,children:s})},"name"),(0,x.jsx)(O.ZP,{default:!0,monospace:!0,children:t?p._7:p.VV},"type"),(0,x.jsx)(O.ZP,{default:!0,monospace:!0,children:_||0},"runs"),(0,x.jsxs)(O.ZP,{default:!0,monospace:!0,small:!0,children:[h&&i&&(0,x.jsxs)(x.Fragment,{children:[(0,N.Uc)(h,c),"\xa0-\xa0",(0,N.Uc)(i,c)]}),!(h&&i)&&(0,x.jsx)(x.Fragment,{children:"\u2014"})]},"backfill"),(0,x.jsx)(O.ZP,{default:!0,monospace:!0,small:!0,title:k?(0,U._6)(k):null,children:k?(0,N.Uc)(k,c):(0,x.jsx)(x.Fragment,{children:"\u2014"})},"started_at"),(0,x.jsx)(O.ZP,{default:!0,monospace:!0,small:!0,title:r?(0,U._6)(r):null,children:r?(0,N.Uc)(r,c):(0,x.jsx)(x.Fragment,{children:"\u2014"})},"completed_at")];return o||y.push((0,x.jsxs)(b.ZP,{children:[(0,x.jsx)(v.ZP,{default:!0,disabled:j===T.VO.COMPLETED,iconOnly:!0,linkProps:{as:"/pipelines/".concat(a,"/backfills/").concat(u,"/edit"),href:"/pipelines/[pipeline]/backfills/[...slug]"},noBackground:!0,title:"Edit",children:(0,x.jsx)(P.Edit,{default:!0,size:2*C.iI})},"".concat(n,"_edit_button")),f(u,n,'Are you sure you want to delete the backfill "'.concat(s,'?"'))]},"edit_delete_backfill_".concat(n))),y})),uuid:"pipeline-runs"})},V=t(68562),B=t(75457),F=t(93808),H=t(28795),L=t(69419),Y=t(81728);function X(e){var n=e.pipeline,t=(0,a.useRouter)(),r=n.uuid,u=k.ZP.backfills.list({_limit:20,_offset:0,include_run_count:!0,pipeline_uuid:r},{refreshInterval:6e4}),o=u.data,s=u.mutate,f=(0,l.useMemo)((function(){return(null===o||void 0===o?void 0:o.backfills)||[]}),[o]),d=(0,L.iV)(),p=(0,l.useState)(null),v=p[0],b=p[1],m=(0,l.useState)(null),h=m[0],j=m[1];(0,l.useEffect)((function(){null!==d&&void 0!==d&&d.backfill_id?b(null===f||void 0===f?void 0:f.find((function(e){return e.id===Number(d.backfill_id)}))):v&&b(null)}),[f,d,v]);var _=(0,l.useMemo)((function(){var e="/pipelines/".concat(r,"/backfills"),n=[{label:function(){return"Backfills"},linkProps:v?{as:e,href:"/pipelines/[pipeline]/backfills"}:null}];return v&&n.push({label:function(){return v.name}}),n}),[r,v]),g=(0,c.Db)(k.ZP.backfills.pipelines.useCreate(r),{onSuccess:function(e){return(0,w.wD)(e,{callback:function(e){var n=e.backfill.id;t.push("/pipelines/[pipeline]/backfills/[...slug]","/pipelines/".concat(r,"/backfills/").concat(n,"/edit"))},onErrorCallback:function(e,n){return j({errors:n,response:e})}})}}),E=(0,i.Z)(g,2),Z=E[0],D=E[1].isLoading;return(0,x.jsxs)(B.Z,{breadcrumbs:_,errors:h,pageName:H.M.BACKFILLS,pipeline:n,setErrors:j,title:function(e){var n=e.name;return"".concat(n," backfills")},uuid:"".concat(H.M.BACKFILLS,"_").concat(r),children:[(0,x.jsx)(y.Z,{p:C.cd,children:(0,x.jsx)(V.ZP,{beforeElement:(0,x.jsx)(P.Add,{size:2.5*C.iI}),blackBorder:!0,inline:!0,loading:D,noHoverUnderline:!0,onClick:function(){return Z({backfill:{name:(0,Y.Y6)()}})},sameColorAsText:!0,uuid:"PipelineDetailPage/Backfills/add_new_backfill",children:"Create new backfill"})}),f&&0===f.length&&(0,x.jsx)(y.Z,{p:C.cd,children:(0,x.jsx)(O.ZP,{bold:!0,default:!0,monospace:!0,muted:!0,children:"No backfills available"})}),(null===f||void 0===f?void 0:f.length)>=1&&(0,x.jsx)(M,{fetchBackfills:s,models:f,pipeline:n,selectedRow:v})]})}X.getInitialProps=function(){var e=(0,r.Z)(o().mark((function e(n){var t;return o().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=n.query.pipeline,e.abrupt("return",{pipeline:{uuid:t}});case 2:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}();var z=(0,F.Z)(X)},37459:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/pipelines/[pipeline]/backfills",function(){return t(4303)}])},80022:function(e,n,t){"use strict";function r(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}t.d(n,{Z:function(){return r}})},15544:function(e,n,t){"use strict";function r(e){return r=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},r(e)}t.d(n,{Z:function(){return r}})},13692:function(e,n,t){"use strict";t.d(n,{Z:function(){return i}});var r=t(61049);function i(e,n){if("function"!==typeof n&&null!==n)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),n&&(0,r.Z)(e,n)}},93189:function(e,n,t){"use strict";t.d(n,{Z:function(){return u}});var r=t(12539),i=t(80022);function u(e,n){if(n&&("object"===r(n)||"function"===typeof n))return n;if(void 0!==n)throw new TypeError("Derived constructors may only return object or undefined");return(0,i.Z)(e)}}},function(e){e.O(0,[1557,3782,9774,2888,179],(function(){return n=37459,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
|