mage-ai 0.9.66__py3-none-any.whl → 0.9.68__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/monitors/BaseMonitor.py +1 -2
- mage_ai/api/policies/PipelinePolicy.py +2 -0
- mage_ai/api/resources/BlockLayoutItemResource.py +2 -2
- mage_ai/api/resources/BlockResource.py +4 -3
- mage_ai/api/resources/CacheItemResource.py +1 -1
- mage_ai/api/resources/GitBranchResource.py +3 -5
- mage_ai/api/resources/PageBlockLayoutResource.py +2 -2
- mage_ai/api/resources/PipelineResource.py +13 -0
- mage_ai/api/resources/PipelineRunResource.py +10 -1
- mage_ai/cache/tag.py +3 -0
- mage_ai/cluster_manager/manage.py +4 -1
- mage_ai/data_preparation/decorators.py +15 -0
- mage_ai/data_preparation/executors/k8s_block_executor.py +8 -1
- mage_ai/data_preparation/executors/k8s_pipeline_executor.py +12 -1
- mage_ai/data_preparation/executors/streaming_pipeline_executor.py +22 -12
- mage_ai/data_preparation/git/api.py +3 -0
- mage_ai/data_preparation/git/clients/gitlab.py +3 -2
- mage_ai/data_preparation/logging/gcs_logger_manager.py +7 -4
- mage_ai/data_preparation/models/block/__init__.py +45 -86
- mage_ai/data_preparation/models/block/block_factory.py +77 -0
- mage_ai/data_preparation/models/block/dbt/block.py +5 -7
- mage_ai/data_preparation/models/block/global_data_product/__init__.py +9 -3
- mage_ai/data_preparation/models/block/integration/__init__.py +12 -8
- mage_ai/data_preparation/models/block/platform/mixins.py +1 -1
- mage_ai/data_preparation/models/pipeline.py +80 -13
- mage_ai/data_preparation/storage/gcs_storage.py +28 -3
- mage_ai/data_preparation/storage/local_storage.py +18 -3
- mage_ai/data_preparation/storage/s3_storage.py +7 -2
- mage_ai/data_preparation/templates/constants.py +7 -0
- mage_ai/data_preparation/templates/data_loaders/streaming/generic_python.py +23 -0
- mage_ai/data_preparation/templates/template.py +6 -2
- mage_ai/data_preparation/variable_manager.py +2 -1
- mage_ai/io/bigquery.py +2 -0
- mage_ai/io/export_utils.py +3 -0
- mage_ai/io/oracledb.py +152 -5
- mage_ai/io/sql.py +4 -0
- mage_ai/orchestration/db/__init__.py +2 -2
- mage_ai/orchestration/db/models/schedules.py +2 -2
- mage_ai/orchestration/job_manager.py +6 -1
- mage_ai/orchestration/notification/sender.py +8 -0
- mage_ai/orchestration/pipeline_scheduler_original.py +10 -1
- mage_ai/server/constants.py +1 -1
- mage_ai/server/frontend_dist/404.html +2 -2
- mage_ai/server/frontend_dist/_next/static/chunks/3548-961ff79ca70038c7.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/{4241-ccd0126f5750cc35.js → 4241-4499461184ba0d23.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/5627-237a3de578538022.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/{7966-5c1786fb7e7a48f5.js → 7966-f07b2913f7326b50.js} +1 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/_app-08790743315de36a.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/index-13760bb72d823b69.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/manage/users/[user]-8bbfa0c19b5e4cb3.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/manage-852d403c7bda21b3.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/overview-597b74828bf105db.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills-a8b61d8d239fd16f.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/edit-bd0aff5a5ed8888c.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/logs-3f5c14076ddde20e.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/runs/[run]-1417ad1c821d720a.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/settings-d1ee961387c58b7f.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/syncs-90abafc7ed61c582.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers-cb88fd075a357fcf.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines-ceb06e1616ee9610.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/platform/preferences-8ff16ef9566e911a.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/preferences-d7a8bc51bb7a1082.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/sign-in-f59d34429fe022ee.js +1 -0
- mage_ai/server/frontend_dist/_next/static/chunks/pages/triggers-9cba3211434a8966.js +1 -0
- mage_ai/server/{frontend_dist_base_path_template/_next/static/wxqkF4diPqRxUfP6Ac6ai → frontend_dist/_next/static/i8pymuJDTVHdWjUP1QSh1}/_buildManifest.js +1 -1
- 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 +3 -3
- 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 +5 -5
- 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 +2 -2
- mage_ai/server/{frontend_dist/_next/static/rtugsJoijF2SsCCB5_yKS → frontend_dist_base_path_template/_next/static/CKCvjsYCf2imD2X8zAOBf}/_buildManifest.js +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3548-961ff79ca70038c7.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/{4241-ccd0126f5750cc35.js → 4241-4499461184ba0d23.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/5627-237a3de578538022.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/{7966-5c1786fb7e7a48f5.js → 7966-f07b2913f7326b50.js} +1 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/_app-08790743315de36a.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/index-13760bb72d823b69.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/manage/users/[user]-8bbfa0c19b5e4cb3.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/manage-852d403c7bda21b3.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/overview-597b74828bf105db.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills-a8b61d8d239fd16f.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/edit-bd0aff5a5ed8888c.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/logs-3f5c14076ddde20e.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/runs/[run]-1417ad1c821d720a.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/settings-d1ee961387c58b7f.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/syncs-90abafc7ed61c582.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/triggers-cb88fd075a357fcf.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines-ceb06e1616ee9610.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/platform/preferences-8ff16ef9566e911a.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/preferences-d7a8bc51bb7a1082.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/sign-in-f59d34429fe022ee.js +1 -0
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/triggers-9cba3211434a8966.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 +3 -3
- 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 +5 -5
- 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/services/aws/s3/s3.py +8 -2
- mage_ai/services/k8s/job_manager.py +8 -0
- mage_ai/services/slack/slack.py +10 -1
- mage_ai/services/spark/spark.py +9 -2
- mage_ai/settings/backends.py +8 -8
- mage_ai/settings/models/configuration_option.py +10 -9
- mage_ai/settings/server.py +6 -1
- mage_ai/shared/files.py +19 -1
- mage_ai/shared/logger.py +12 -6
- mage_ai/shared/path_fixer.py +3 -0
- mage_ai/streaming/sources/base.py +5 -0
- mage_ai/streaming/sources/base_python.py +30 -0
- mage_ai/streaming/sources/kafka.py +2 -1
- mage_ai/streaming/sources/mongodb.py +4 -0
- mage_ai/streaming/sources/source_factory.py +25 -0
- mage_ai/tests/data_preparation/models/block/dbt/test_block.py +2 -2
- mage_ai/tests/data_preparation/models/block/dbt/test_block_sql.py +1 -1
- mage_ai/tests/data_preparation/models/block/dbt/test_block_yaml.py +1 -1
- mage_ai/tests/data_preparation/models/test_block.py +41 -3
- mage_ai/tests/orchestration/test_pipeline_scheduler.py +2 -0
- mage_ai/tests/settings/models/test_configuration_option.py +2 -2
- {mage_ai-0.9.66.dist-info → mage_ai-0.9.68.dist-info}/METADATA +3 -3
- {mage_ai-0.9.66.dist-info → mage_ai-0.9.68.dist-info}/RECORD +225 -222
- mage_ai/server/frontend_dist/_next/static/chunks/181-e61915415a976861.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/3548-13563a1ff815f922.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/_app-913116aa749f7ca6.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/index-64851458dde54ad9.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/manage/users/[user]-d3a5fd3119fdb1e4.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/manage-42789d698d28a92f.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/overview-d05040edba41b2ac.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/backfills-aaf393c86fc1bda3.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/edit-d84556cefbe31a1a.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/logs-cf656cbe37ecaacc.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/runs/[run]-1b688d61f8efe07a.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/settings-ed3331d22d5cff7d.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/syncs-d94e48bad89ba1e0.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines/[pipeline]/triggers-f508c2f261297724.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/pipelines-f99e99aa8f45529c.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/platform/preferences-6826000cdffc36b8.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/settings/workspace/preferences-dde29a463495cebb.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/sign-in-7d38b2f7c3e918a1.js +0 -1
- mage_ai/server/frontend_dist/_next/static/chunks/pages/triggers-ab98a7b3a678669e.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/181-e61915415a976861.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/3548-13563a1ff815f922.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/_app-913116aa749f7ca6.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/index-64851458dde54ad9.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/manage/users/[user]-d3a5fd3119fdb1e4.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/manage-42789d698d28a92f.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/overview-d05040edba41b2ac.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/backfills-aaf393c86fc1bda3.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/edit-d84556cefbe31a1a.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/logs-cf656cbe37ecaacc.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/runs/[run]-1b688d61f8efe07a.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/settings-ed3331d22d5cff7d.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/syncs-d94e48bad89ba1e0.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines/[pipeline]/triggers-f508c2f261297724.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/pipelines-f99e99aa8f45529c.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/platform/preferences-6826000cdffc36b8.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/settings/workspace/preferences-dde29a463495cebb.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/sign-in-7d38b2f7c3e918a1.js +0 -1
- mage_ai/server/frontend_dist_base_path_template/_next/static/chunks/pages/triggers-ab98a7b3a678669e.js +0 -1
- /mage_ai/server/frontend_dist/_next/static/{rtugsJoijF2SsCCB5_yKS → i8pymuJDTVHdWjUP1QSh1}/_ssgManifest.js +0 -0
- /mage_ai/server/frontend_dist_base_path_template/_next/static/{wxqkF4diPqRxUfP6Ac6ai → CKCvjsYCf2imD2X8zAOBf}/_ssgManifest.js +0 -0
- {mage_ai-0.9.66.dist-info → mage_ai-0.9.68.dist-info}/LICENSE +0 -0
- {mage_ai-0.9.66.dist-info → mage_ai-0.9.68.dist-info}/WHEEL +0 -0
- {mage_ai-0.9.66.dist-info → mage_ai-0.9.68.dist-info}/entry_points.txt +0 -0
- {mage_ai-0.9.66.dist-info → mage_ai-0.9.68.dist-info}/top_level.txt +0 -0
|
@@ -19,12 +19,27 @@ class LocalStorage(BaseStorage):
|
|
|
19
19
|
def isdir(self, path: str) -> bool:
|
|
20
20
|
return os.path.isdir(path)
|
|
21
21
|
|
|
22
|
-
def listdir(
|
|
22
|
+
def listdir(
|
|
23
|
+
self,
|
|
24
|
+
path: str,
|
|
25
|
+
suffix: str = None,
|
|
26
|
+
max_results: int = None,
|
|
27
|
+
) -> List[str]:
|
|
28
|
+
paths = []
|
|
23
29
|
if not os.path.exists(path):
|
|
24
|
-
return
|
|
25
|
-
|
|
30
|
+
return paths
|
|
31
|
+
|
|
32
|
+
if max_results is not None:
|
|
33
|
+
with os.scandir(path) as it:
|
|
34
|
+
for idx, entry in enumerate(it):
|
|
35
|
+
paths.append(entry.name)
|
|
36
|
+
if idx >= max_results - 1:
|
|
37
|
+
break
|
|
38
|
+
else:
|
|
39
|
+
paths = os.listdir(path)
|
|
26
40
|
if suffix is not None:
|
|
27
41
|
paths = [p for p in paths if p.endswith(suffix)]
|
|
42
|
+
|
|
28
43
|
return paths
|
|
29
44
|
|
|
30
45
|
def makedirs(self, path: str, **kwargs) -> None:
|
|
@@ -30,11 +30,16 @@ class S3Storage(BaseStorage):
|
|
|
30
30
|
path += '/'
|
|
31
31
|
return self.path_exists(path)
|
|
32
32
|
|
|
33
|
-
def listdir(
|
|
33
|
+
def listdir(
|
|
34
|
+
self,
|
|
35
|
+
path: str,
|
|
36
|
+
suffix: str = None,
|
|
37
|
+
max_results: int = None,
|
|
38
|
+
) -> List[str]:
|
|
34
39
|
if not path.endswith('/'):
|
|
35
40
|
path += '/'
|
|
36
41
|
path = s3_url_path(path)
|
|
37
|
-
keys = self.client.listdir(path, suffix=suffix)
|
|
42
|
+
keys = self.client.listdir(path, suffix=suffix, max_results=max_results)
|
|
38
43
|
return [k[len(path):].rstrip('/') for k in keys]
|
|
39
44
|
|
|
40
45
|
def makedirs(self, path: str, **kwargs) -> None:
|
|
@@ -608,6 +608,13 @@ TEMPLATES_ONLY_FOR_V2 = [
|
|
|
608
608
|
name='MySQL',
|
|
609
609
|
path='data_exporters/mysql.py',
|
|
610
610
|
),
|
|
611
|
+
dict(
|
|
612
|
+
block_type=BlockType.DATA_EXPORTER,
|
|
613
|
+
groups=[GROUP_DATABASES],
|
|
614
|
+
language=BlockLanguage.PYTHON,
|
|
615
|
+
name='OracleDB',
|
|
616
|
+
path='data_exporters/oracledb.py',
|
|
617
|
+
),
|
|
611
618
|
dict(
|
|
612
619
|
block_type=BlockType.DATA_EXPORTER,
|
|
613
620
|
groups=[GROUP_DATABASES],
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
from mage_ai.streaming.sources.base_python import BasePythonSource
|
|
2
|
+
from typing import Callable
|
|
3
|
+
|
|
4
|
+
if 'streaming_source' not in globals():
|
|
5
|
+
from mage_ai.data_preparation.decorators import streaming_source
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
@streaming_source
|
|
9
|
+
class CustomSource(BasePythonSource):
|
|
10
|
+
def init_client(self):
|
|
11
|
+
"""
|
|
12
|
+
Implement the logic of initializing the client.
|
|
13
|
+
"""
|
|
14
|
+
|
|
15
|
+
def batch_read(self, handler: Callable):
|
|
16
|
+
"""
|
|
17
|
+
Batch read the messages from the source and use handler to process the messages.
|
|
18
|
+
"""
|
|
19
|
+
while True:
|
|
20
|
+
records = []
|
|
21
|
+
# Implement the logic of fetching the records
|
|
22
|
+
if len(records) > 0:
|
|
23
|
+
handler(records)
|
|
@@ -140,19 +140,23 @@ def __fetch_data_loader_templates(
|
|
|
140
140
|
pipeline_type: PipelineType = PipelineType.PYTHON,
|
|
141
141
|
) -> str:
|
|
142
142
|
data_source = config.get('data_source')
|
|
143
|
+
default_template_name = None
|
|
143
144
|
file_extension = 'py'
|
|
144
145
|
if pipeline_type == PipelineType.PYSPARK:
|
|
145
146
|
template_folder = 'data_loaders/pyspark'
|
|
146
147
|
elif pipeline_type == PipelineType.STREAMING:
|
|
147
148
|
template_folder = 'data_loaders/streaming'
|
|
148
|
-
|
|
149
|
+
if language == BlockLanguage.YAML:
|
|
150
|
+
file_extension = 'yaml'
|
|
151
|
+
else:
|
|
152
|
+
default_template_name = 'generic_python.py'
|
|
149
153
|
elif language == BlockLanguage.R:
|
|
150
154
|
template_folder = 'data_loaders/r'
|
|
151
155
|
file_extension = 'r'
|
|
152
156
|
else:
|
|
153
157
|
template_folder = 'data_loaders'
|
|
154
158
|
|
|
155
|
-
default_template = template_folder + '/' + 'default.jinja'
|
|
159
|
+
default_template = template_folder + '/' + (default_template_name or 'default.jinja')
|
|
156
160
|
if data_source is None:
|
|
157
161
|
template_path = default_template
|
|
158
162
|
else:
|
|
@@ -271,6 +271,7 @@ class VariableManager:
|
|
|
271
271
|
block_uuid: str,
|
|
272
272
|
partition: str = None,
|
|
273
273
|
clean_block_uuid: bool = True,
|
|
274
|
+
max_results: int = None,
|
|
274
275
|
) -> List[str]:
|
|
275
276
|
variable_dir_path = os.path.join(
|
|
276
277
|
self.pipeline_path(pipeline_uuid),
|
|
@@ -280,7 +281,7 @@ class VariableManager:
|
|
|
280
281
|
)
|
|
281
282
|
if not self.storage.path_exists(variable_dir_path):
|
|
282
283
|
return []
|
|
283
|
-
variables = self.storage.listdir(variable_dir_path)
|
|
284
|
+
variables = self.storage.listdir(variable_dir_path, max_results=max_results)
|
|
284
285
|
return sorted([v.split('.')[0] for v in variables])
|
|
285
286
|
|
|
286
287
|
def pipeline_path(self, pipeline_uuid: str) -> str:
|
mage_ai/io/bigquery.py
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
from typing import Dict, List, Mapping, Union
|
|
2
2
|
|
|
3
|
+
import numpy as np
|
|
3
4
|
from google.cloud.bigquery import (
|
|
4
5
|
Client,
|
|
5
6
|
LoadJobConfig,
|
|
@@ -295,6 +296,7 @@ WHERE table_id = '{table_name}'
|
|
|
295
296
|
column_types = self.get_column_types(schema, table_name)
|
|
296
297
|
|
|
297
298
|
if df is not None:
|
|
299
|
+
df.fillna(value=np.NaN, inplace=True)
|
|
298
300
|
for col in df.columns:
|
|
299
301
|
col_type = column_types.get(col)
|
|
300
302
|
if not col_type:
|
mage_ai/io/export_utils.py
CHANGED
|
@@ -108,6 +108,7 @@ def gen_table_creation_query(
|
|
|
108
108
|
case_sensitive: bool = False,
|
|
109
109
|
unique_constraints: List[str] = None,
|
|
110
110
|
overwrite_types: Dict = None,
|
|
111
|
+
skip_semicolon_at_end: bool = False,
|
|
111
112
|
) -> str:
|
|
112
113
|
"""
|
|
113
114
|
Generates a database table creation query from a data frame.
|
|
@@ -157,4 +158,6 @@ def gen_table_creation_query(
|
|
|
157
158
|
query.append(
|
|
158
159
|
f"CONSTRAINT {index_name} UNIQUE ({', '.join(unique_constraints_escaped)})",
|
|
159
160
|
)
|
|
161
|
+
if skip_semicolon_at_end:
|
|
162
|
+
return f'CREATE TABLE {full_table_name} (' + ','.join(query) + ')'
|
|
160
163
|
return f'CREATE TABLE {full_table_name} (' + ','.join(query) + ');'
|
mage_ai/io/oracledb.py
CHANGED
|
@@ -1,12 +1,19 @@
|
|
|
1
1
|
import warnings
|
|
2
|
-
from typing import Union
|
|
2
|
+
from typing import IO, Any, List, Union
|
|
3
3
|
|
|
4
|
+
import numpy as np
|
|
4
5
|
import oracledb
|
|
5
|
-
|
|
6
|
+
import simplejson
|
|
7
|
+
from pandas import DataFrame, Series, read_sql
|
|
6
8
|
|
|
7
|
-
from mage_ai.io.base import QUERY_ROW_LIMIT
|
|
9
|
+
from mage_ai.io.base import QUERY_ROW_LIMIT, ExportWritePolicy
|
|
8
10
|
from mage_ai.io.config import BaseConfigLoader, ConfigKey
|
|
11
|
+
from mage_ai.io.export_utils import PandasTypes
|
|
9
12
|
from mage_ai.io.sql import BaseSQL
|
|
13
|
+
from mage_ai.server.logger import Logger
|
|
14
|
+
from mage_ai.shared.parsers import encode_complex
|
|
15
|
+
|
|
16
|
+
logger = Logger().new_server_logger(__name__)
|
|
10
17
|
|
|
11
18
|
|
|
12
19
|
class OracleDB(BaseSQL):
|
|
@@ -40,8 +47,17 @@ class OracleDB(BaseSQL):
|
|
|
40
47
|
)
|
|
41
48
|
|
|
42
49
|
def open(self) -> None:
|
|
43
|
-
|
|
44
|
-
|
|
50
|
+
if self.settings['mode'] and self.settings['mode'].lower() == 'thick':
|
|
51
|
+
logger.info('Initializing Oracle thick mode.')
|
|
52
|
+
oracledb.init_oracle_client()
|
|
53
|
+
with self.printer.print_msg(f'Opening connection to OracleDB database \
|
|
54
|
+
({self.settings["mode"]} mode)'):
|
|
55
|
+
connection_dsn = "{}:{}/{}".format(
|
|
56
|
+
self.settings['host'],
|
|
57
|
+
self.settings['port'],
|
|
58
|
+
self.settings['service_name'])
|
|
59
|
+
self._ctx = oracledb.connect(
|
|
60
|
+
user=self.settings['user'], password=self.settings['password'], dsn=connection_dsn)
|
|
45
61
|
|
|
46
62
|
def load(
|
|
47
63
|
self,
|
|
@@ -110,3 +126,134 @@ SELECT *
|
|
|
110
126
|
FROM subquery
|
|
111
127
|
FETCH FIRST {limit} ROWS ONLY
|
|
112
128
|
"""
|
|
129
|
+
|
|
130
|
+
def table_exists(self, schema_name: str, table_name: str) -> bool:
|
|
131
|
+
with self.conn.cursor() as cur:
|
|
132
|
+
try:
|
|
133
|
+
cur.execute(f"select * from {table_name} where rownum=1")
|
|
134
|
+
except Exception as exc:
|
|
135
|
+
logger.info(f"Table not existing: {table_name}. Exception: {exc}")
|
|
136
|
+
return False
|
|
137
|
+
return True
|
|
138
|
+
|
|
139
|
+
def get_type(self, column: Series, dtype: str) -> str:
|
|
140
|
+
if dtype in (
|
|
141
|
+
PandasTypes.MIXED,
|
|
142
|
+
PandasTypes.UNKNOWN_ARRAY,
|
|
143
|
+
PandasTypes.COMPLEX,
|
|
144
|
+
):
|
|
145
|
+
return 'CHAR(255)'
|
|
146
|
+
elif dtype in (PandasTypes.DATETIME, PandasTypes.DATETIME64):
|
|
147
|
+
try:
|
|
148
|
+
if column.dt.tz:
|
|
149
|
+
return 'TIMESTAMP'
|
|
150
|
+
except AttributeError:
|
|
151
|
+
pass
|
|
152
|
+
return 'TIMESTAMP'
|
|
153
|
+
elif dtype == PandasTypes.TIME:
|
|
154
|
+
try:
|
|
155
|
+
if column.dt.tz:
|
|
156
|
+
return 'TIMESTAMP'
|
|
157
|
+
except AttributeError:
|
|
158
|
+
pass
|
|
159
|
+
return 'TIMESTAMP'
|
|
160
|
+
elif dtype == PandasTypes.DATE:
|
|
161
|
+
return 'DATE'
|
|
162
|
+
elif dtype == PandasTypes.STRING:
|
|
163
|
+
return 'CHAR(255)'
|
|
164
|
+
elif dtype == PandasTypes.CATEGORICAL:
|
|
165
|
+
return 'CHAR(255)'
|
|
166
|
+
elif dtype == PandasTypes.BYTES:
|
|
167
|
+
return 'CHAR(255)'
|
|
168
|
+
elif dtype in (PandasTypes.FLOATING, PandasTypes.DECIMAL, PandasTypes.MIXED_INTEGER_FLOAT):
|
|
169
|
+
return 'NUMBER'
|
|
170
|
+
elif dtype == PandasTypes.INTEGER:
|
|
171
|
+
max_int, min_int = column.max(), column.min()
|
|
172
|
+
if np.int16(max_int) == max_int and np.int16(min_int) == min_int:
|
|
173
|
+
return 'NUMBER'
|
|
174
|
+
elif np.int32(max_int) == max_int and np.int32(min_int) == min_int:
|
|
175
|
+
return 'NUMBER'
|
|
176
|
+
else:
|
|
177
|
+
return 'NUMBER'
|
|
178
|
+
elif dtype == PandasTypes.BOOLEAN:
|
|
179
|
+
return 'CHAR(52)'
|
|
180
|
+
elif dtype in (PandasTypes.TIMEDELTA, PandasTypes.TIMEDELTA64, PandasTypes.PERIOD):
|
|
181
|
+
return 'NUMBER'
|
|
182
|
+
elif dtype == PandasTypes.EMPTY:
|
|
183
|
+
return 'CHAR(255)'
|
|
184
|
+
else:
|
|
185
|
+
print(f'Invalid datatype provided: {dtype}')
|
|
186
|
+
|
|
187
|
+
return 'CHAR(255)'
|
|
188
|
+
|
|
189
|
+
def export(
|
|
190
|
+
self,
|
|
191
|
+
df: DataFrame,
|
|
192
|
+
table_name: str = None,
|
|
193
|
+
if_exists: ExportWritePolicy = ExportWritePolicy.REPLACE,
|
|
194
|
+
**kwargs,
|
|
195
|
+
) -> None:
|
|
196
|
+
super().export(
|
|
197
|
+
df,
|
|
198
|
+
**kwargs,
|
|
199
|
+
table_name=table_name,
|
|
200
|
+
if_exists=if_exists,
|
|
201
|
+
# Oracle cursor execute will automatically add a semicolon at the end of the query.
|
|
202
|
+
skip_semicolon_at_end=True
|
|
203
|
+
)
|
|
204
|
+
|
|
205
|
+
def upload_dataframe(
|
|
206
|
+
self,
|
|
207
|
+
cursor: Any,
|
|
208
|
+
df: DataFrame,
|
|
209
|
+
db_dtypes: List[str],
|
|
210
|
+
dtypes: List[str],
|
|
211
|
+
full_table_name: str,
|
|
212
|
+
buffer: Union[IO, None] = None,
|
|
213
|
+
**kwargs,
|
|
214
|
+
) -> None:
|
|
215
|
+
def serialize_obj(val):
|
|
216
|
+
if type(val) is dict or type(val) is np.ndarray:
|
|
217
|
+
return simplejson.dumps(
|
|
218
|
+
val,
|
|
219
|
+
default=encode_complex,
|
|
220
|
+
ignore_nan=True,
|
|
221
|
+
)
|
|
222
|
+
elif type(val) is list and len(val) >= 1 and type(val[0]) is dict:
|
|
223
|
+
return simplejson.dumps(
|
|
224
|
+
val,
|
|
225
|
+
default=encode_complex,
|
|
226
|
+
ignore_nan=True,
|
|
227
|
+
)
|
|
228
|
+
return val
|
|
229
|
+
|
|
230
|
+
# Create values
|
|
231
|
+
df_ = df.copy()
|
|
232
|
+
columns = df_.columns
|
|
233
|
+
for col in columns:
|
|
234
|
+
dtype = df_[col].dtype
|
|
235
|
+
if dtype == PandasTypes.OBJECT:
|
|
236
|
+
df_[col] = df_[col].apply(lambda x: serialize_obj(x))
|
|
237
|
+
elif dtype in (
|
|
238
|
+
PandasTypes.MIXED,
|
|
239
|
+
PandasTypes.UNKNOWN_ARRAY,
|
|
240
|
+
PandasTypes.COMPLEX,
|
|
241
|
+
):
|
|
242
|
+
df_[col] = df_[col].astype('string')
|
|
243
|
+
|
|
244
|
+
# Remove extraneous surrounding double quotes
|
|
245
|
+
# that get added while performing conversion to string.
|
|
246
|
+
df_[col] = df_[col].apply(lambda x: x.strip('"') if x and isinstance(x, str) else x)
|
|
247
|
+
df_.replace({np.NaN: None}, inplace=True)
|
|
248
|
+
values = []
|
|
249
|
+
for i in range(0, len(df_)):
|
|
250
|
+
values.append(tuple(df_.fillna('').values[i]))
|
|
251
|
+
|
|
252
|
+
# Create values placeholder
|
|
253
|
+
colmn_names = df.columns.tolist()
|
|
254
|
+
values_placeholder = ""
|
|
255
|
+
for i in range(0, len(colmn_names)):
|
|
256
|
+
values_placeholder += f':{str(i + 1)},'
|
|
257
|
+
|
|
258
|
+
insert_sql = f'INSERT INTO {full_table_name} VALUES({values_placeholder.rstrip(",")})'
|
|
259
|
+
cursor.executemany(insert_sql, values)
|
mage_ai/io/sql.py
CHANGED
|
@@ -56,6 +56,7 @@ class BaseSQL(BaseSQLConnection):
|
|
|
56
56
|
case_sensitive: bool = False,
|
|
57
57
|
unique_constraints: List[str] = None,
|
|
58
58
|
overwrite_types: Dict = None,
|
|
59
|
+
skip_semicolon_at_end: bool = False,
|
|
59
60
|
**kwargs,
|
|
60
61
|
) -> str:
|
|
61
62
|
if unique_constraints is None:
|
|
@@ -68,6 +69,7 @@ class BaseSQL(BaseSQLConnection):
|
|
|
68
69
|
case_sensitive=case_sensitive,
|
|
69
70
|
unique_constraints=unique_constraints,
|
|
70
71
|
overwrite_types=overwrite_types,
|
|
72
|
+
skip_semicolon_at_end=skip_semicolon_at_end,
|
|
71
73
|
)
|
|
72
74
|
|
|
73
75
|
def build_create_table_as_command(
|
|
@@ -234,6 +236,7 @@ class BaseSQL(BaseSQLConnection):
|
|
|
234
236
|
query_string: Union[str, None] = None,
|
|
235
237
|
unique_conflict_method: str = None,
|
|
236
238
|
unique_constraints: List[str] = None,
|
|
239
|
+
skip_semicolon_at_end: bool = False,
|
|
237
240
|
**kwargs,
|
|
238
241
|
) -> None:
|
|
239
242
|
"""
|
|
@@ -350,6 +353,7 @@ class BaseSQL(BaseSQLConnection):
|
|
|
350
353
|
case_sensitive=case_sensitive,
|
|
351
354
|
unique_constraints=unique_constraints,
|
|
352
355
|
overwrite_types=overwrite_types,
|
|
356
|
+
skip_semicolon_at_end=skip_semicolon_at_end,
|
|
353
357
|
)
|
|
354
358
|
cur.execute(query)
|
|
355
359
|
self.upload_dataframe(
|
|
@@ -13,7 +13,7 @@ from mage_ai.orchestration.db.setup import get_postgres_connection_url
|
|
|
13
13
|
from mage_ai.orchestration.db.utils import get_user_info_from_db_connection_url
|
|
14
14
|
from mage_ai.settings import OTEL_EXPORTER_OTLP_ENDPOINT
|
|
15
15
|
from mage_ai.settings.repo import get_variables_dir
|
|
16
|
-
from mage_ai.shared.environments import
|
|
16
|
+
from mage_ai.shared.environments import is_debug, is_test
|
|
17
17
|
|
|
18
18
|
DB_RETRY_COUNT = 2
|
|
19
19
|
TEST_DB = 'test.db'
|
|
@@ -170,5 +170,5 @@ def safe_db_query(func):
|
|
|
170
170
|
|
|
171
171
|
logging.basicConfig()
|
|
172
172
|
|
|
173
|
-
if
|
|
173
|
+
if is_debug() and not os.getenv('DISABLE_DATABASE_TERMINAL_OUTPUT'):
|
|
174
174
|
logging.getLogger('sqlalchemy.engine').setLevel(logging.INFO)
|
|
@@ -934,9 +934,9 @@ class PipelineRun(PipelineRunProjectPlatformMixin, BaseModel):
|
|
|
934
934
|
|
|
935
935
|
@property
|
|
936
936
|
def pipeline_tags(self):
|
|
937
|
-
|
|
937
|
+
pipeline_config = Pipeline.get_config(self.pipeline_uuid)
|
|
938
938
|
|
|
939
|
-
return
|
|
939
|
+
return pipeline_config.get('tags') if pipeline_config is not None else []
|
|
940
940
|
|
|
941
941
|
def executable_block_runs(
|
|
942
942
|
self,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import traceback
|
|
1
2
|
from enum import Enum
|
|
2
3
|
from typing import Callable, Dict, Union
|
|
3
4
|
|
|
@@ -89,4 +90,8 @@ class JobManager:
|
|
|
89
90
|
return f'{job_type}_{uid}'
|
|
90
91
|
|
|
91
92
|
|
|
92
|
-
|
|
93
|
+
try:
|
|
94
|
+
job_manager = JobManager()
|
|
95
|
+
except Exception:
|
|
96
|
+
traceback.print_exc()
|
|
97
|
+
job_manager = None
|
|
@@ -108,6 +108,7 @@ class NotificationSender:
|
|
|
108
108
|
pipeline,
|
|
109
109
|
pipeline_run,
|
|
110
110
|
error: str = None,
|
|
111
|
+
stacktrace: str = None,
|
|
111
112
|
summary: str = None,
|
|
112
113
|
) -> None:
|
|
113
114
|
if AlertOn.PIPELINE_RUN_FAILURE in self.config.alert_on:
|
|
@@ -122,6 +123,7 @@ class NotificationSender:
|
|
|
122
123
|
pipeline_run,
|
|
123
124
|
error=error,
|
|
124
125
|
message_template=message_template,
|
|
126
|
+
stacktrace=stacktrace,
|
|
125
127
|
summary=summary,
|
|
126
128
|
)
|
|
127
129
|
|
|
@@ -145,6 +147,7 @@ class NotificationSender:
|
|
|
145
147
|
pipeline,
|
|
146
148
|
pipeline_run,
|
|
147
149
|
error: str = None,
|
|
150
|
+
stacktrace: str = None,
|
|
148
151
|
):
|
|
149
152
|
if text is None or pipeline is None or pipeline_run is None:
|
|
150
153
|
return text
|
|
@@ -155,6 +158,7 @@ class NotificationSender:
|
|
|
155
158
|
pipeline_schedule_id=pipeline_run.pipeline_schedule.id,
|
|
156
159
|
pipeline_schedule_name=pipeline_run.pipeline_schedule.name,
|
|
157
160
|
pipeline_uuid=pipeline.uuid,
|
|
161
|
+
stacktrace=stacktrace,
|
|
158
162
|
)
|
|
159
163
|
|
|
160
164
|
def __send_pipeline_run_message(
|
|
@@ -164,6 +168,7 @@ class NotificationSender:
|
|
|
164
168
|
pipeline_run,
|
|
165
169
|
error: str = None,
|
|
166
170
|
message_template: MessageTemplate = None,
|
|
171
|
+
stacktrace: str = None,
|
|
167
172
|
summary: str = None,
|
|
168
173
|
):
|
|
169
174
|
"""Shared method to send pipeline run message of multiple types (success, failure, etc.).
|
|
@@ -207,18 +212,21 @@ class NotificationSender:
|
|
|
207
212
|
pipeline,
|
|
208
213
|
pipeline_run,
|
|
209
214
|
error=error,
|
|
215
|
+
stacktrace=stacktrace,
|
|
210
216
|
),
|
|
211
217
|
summary=self.__interpolate_vars(
|
|
212
218
|
summary or default_summary,
|
|
213
219
|
pipeline,
|
|
214
220
|
pipeline_run,
|
|
215
221
|
error=error,
|
|
222
|
+
stacktrace=stacktrace,
|
|
216
223
|
),
|
|
217
224
|
details=self.__interpolate_vars(
|
|
218
225
|
details or default_details,
|
|
219
226
|
pipeline,
|
|
220
227
|
pipeline_run,
|
|
221
228
|
error=error,
|
|
229
|
+
stacktrace=stacktrace,
|
|
222
230
|
),
|
|
223
231
|
)
|
|
224
232
|
|
|
@@ -320,11 +320,19 @@ class PipelineScheduler:
|
|
|
320
320
|
@safe_db_query
|
|
321
321
|
def on_pipeline_run_failure(self, error_msg: str) -> None:
|
|
322
322
|
failed_block_runs = self.pipeline_run.failed_block_runs
|
|
323
|
+
stacktrace = None
|
|
323
324
|
for br in failed_block_runs:
|
|
324
325
|
if br.metrics:
|
|
325
326
|
message = br.metrics.get('error', {}).get('message')
|
|
326
327
|
if message:
|
|
327
|
-
|
|
328
|
+
message_split = message.split('\n')
|
|
329
|
+
# Truncate the error message if it has too many lines, set max
|
|
330
|
+
# lines at 50
|
|
331
|
+
if len(message_split) > 50:
|
|
332
|
+
message_split = message_split[-50:]
|
|
333
|
+
message_split.insert(0, '... (error truncated)')
|
|
334
|
+
message = '\n'.join(message_split)
|
|
335
|
+
stacktrace = f'Error for block {br.block_uuid}:\n{message}'
|
|
328
336
|
break
|
|
329
337
|
|
|
330
338
|
asyncio.run(UsageStatisticLogger().pipeline_run_ended(self.pipeline_run))
|
|
@@ -332,6 +340,7 @@ class PipelineScheduler:
|
|
|
332
340
|
pipeline=self.pipeline,
|
|
333
341
|
pipeline_run=self.pipeline_run,
|
|
334
342
|
error=error_msg,
|
|
343
|
+
stacktrace=stacktrace,
|
|
335
344
|
)
|
|
336
345
|
# Cancel block runs that are still in progress for the pipeline run.
|
|
337
346
|
cancel_block_runs_and_jobs(self.pipeline_run, self.pipeline)
|
mage_ai/server/constants.py
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><title>Mage</title><meta content="width=device-width, initial-scale=1.0, maximum-scale=5.0, user-scalable=0" name="viewport"/><meta name="next-head-count" content="3"/><link href="/favicon.ico" rel="icon"/><link rel="preload" href="/_next/static/css/b59541b123fd7191.css" as="style"/><link rel="stylesheet" href="/_next/static/css/b59541b123fd7191.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-d079359c241db804.js" defer=""></script><script src="/_next/static/chunks/framework-22b71764bf44ede4.js" defer=""></script><script src="/_next/static/chunks/main-77fe248a6fbd12d8.js" defer=""></script><script src="/_next/static/chunks/pages/_app-
|
|
1
|
+
<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><title>Mage</title><meta content="width=device-width, initial-scale=1.0, maximum-scale=5.0, user-scalable=0" name="viewport"/><meta name="next-head-count" content="3"/><link href="/favicon.ico" rel="icon"/><link rel="preload" href="/_next/static/css/b59541b123fd7191.css" as="style"/><link rel="stylesheet" href="/_next/static/css/b59541b123fd7191.css" data-n-g=""/><noscript data-n-css=""></noscript><script defer="" nomodule="" src="/_next/static/chunks/polyfills-c67a75d1b6f99dc8.js"></script><script src="/_next/static/chunks/webpack-d079359c241db804.js" defer=""></script><script src="/_next/static/chunks/framework-22b71764bf44ede4.js" defer=""></script><script src="/_next/static/chunks/main-77fe248a6fbd12d8.js" defer=""></script><script src="/_next/static/chunks/pages/_app-08790743315de36a.js" defer=""></script><script src="/_next/static/chunks/pages/404-8ecd93274c427b76.js" defer=""></script><script src="/_next/static/i8pymuJDTVHdWjUP1QSh1/_buildManifest.js" defer=""></script><script src="/_next/static/i8pymuJDTVHdWjUP1QSh1/_ssgManifest.js" defer=""></script><style data-styled="" data-styled-version="5.3.6">html{-webkit-box-sizing:border-box;box-sizing:border-box;-ms-overflow-style:scrollbar;}/*!sc*/
|
|
2
2
|
*,*::before,*::after{-webkit-box-sizing:inherit;box-sizing:inherit;}/*!sc*/
|
|
3
3
|
data-styled.g4[id="sc-global-czSCUT1"]{content:"sc-global-czSCUT1,"}/*!sc*/
|
|
4
4
|
.cAAVhx{margin-top:16px;margin-bottom:16px;}/*!sc*/
|
|
@@ -17,4 +17,4 @@ data-styled.g79[id="Headline__H1Style-sc-12jzt2e-2"]{content:"hkcwCQ,"}/*!sc*/
|
|
|
17
17
|
.kOVcuR .Toastify__toast--success{background:#00A81A !important;color:#FFFFFF !important;}/*!sc*/
|
|
18
18
|
.kOVcuR .Toastify__toast--warning{background:#DD9900 !important;color:#FFFFFF !important;}/*!sc*/
|
|
19
19
|
data-styled.g275[id="ToastWrapper-sc-1a33ph1-0"]{content:"kOVcuR,"}/*!sc*/
|
|
20
|
-
</style></head><body><div id="__next"><div class="" style="position:fixed;top:0;left:0;height:2px;background:transparent;z-index:99999999999;width:100%"><div class="" style="height:100%;background:#FF144D;transition:all 500ms ease;width:0%"><div style="box-shadow:0 0 10px #FF144D, 0 0 10px #FF144D;width:5%;opacity:1;position:absolute;height:100%;transition:all 500ms ease;transform:rotate(3deg) translate(0px, -4px);left:-10rem"></div></div></div><main style="align-items:center;display:flex;flex-direction:column;height:100vh;margin-top:16rem"><svg width="84.70857142857143" height="64" viewBox="0 0 20 14" fill="none" xmlns="http://www.w3.org/2000/svg"><path opacity="0.4" d="M15.3266 0L19.2641 1.82961e-06L11.9687 14L8.03125 14L15.3266 0Z" fill="url(#paint0_linear_1303_5)"></path><path d="M11.9692 1.82961e-06L8.03164 0L0.736328 14L4.67383 14L8.03164 7.55626V14H11.9691V8.38194e-05L11.9692 1.82961e-06Z" fill="url(#paint1_linear_1303_5)"></path><path d="M15.3269 2.57679e-06H19.2644V14H15.3269V2.57679e-06Z" fill="url(#paint2_linear_1303_5)"></path><defs><linearGradient id="paint0_linear_1303_5" x1="8.03125" y1="7" x2="19.2641" y2="7" gradientUnits="userSpaceOnUse"><stop offset="0.28125" stop-color="#7D55EC"></stop><stop offset="1" stop-color="#2AB2FE"></stop></linearGradient><linearGradient id="paint1_linear_1303_5" x1="0.736328" y1="7" x2="19.2644" y2="7" gradientUnits="userSpaceOnUse"><stop offset="0.28125" stop-color="#7D55EC"></stop><stop offset="1" stop-color="#2AB2FE"></stop></linearGradient><linearGradient id="paint2_linear_1303_5" x1="0.736328" y1="7" x2="19.2644" y2="7" gradientUnits="userSpaceOnUse"><stop offset="0.28125" stop-color="#7D55EC"></stop><stop offset="1" stop-color="#2AB2FE"></stop></linearGradient></defs></svg><div class="Spacing__SpacingStyle-sc-1mpmtgj-0 cAAVhx"><div class="Headline__HeadlineContainerStyle-sc-12jzt2e-0 dDWSWx"><h1 class="Headline__H1Style-sc-12jzt2e-2 hkcwCQ">404 - Page Not Found<!-- --></h1></div></div><p class="Text__TextStyle-sc-sl5nur-0 fmHTvj">You will be redirected to the Pipelines dashboard in <!-- -->5<!-- --> seconds.<!-- --></p></main><div id="command-center-root"></div><div></div><div></div><div></div><div class="ToastWrapper-sc-1a33ph1-0 kOVcuR"><div class="Toastify"></div></div></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{},"currentTheme":{"accent":{"alert":"#F6540B","blue":"#4877FF","blueLight":"rgba(72, 119, 255, 0.5)","contentDefaultTransparent":"rgba(174, 174, 174, 0.5)","cyan":"#65E3FF","cyanLight":"rgba(101, 227, 255, 0.3)","cyanTransparent":"rgba(101, 227, 255, 0.12)","dbt":"#fc6949","dbtDark":"rgba(252, 105, 73, 0.3)","dbtLight":"rgba(252, 105, 73, 0.5)","info":"#00ABFF","infoTransparent":"rgba(0, 171, 255, 0.5)","negative":"#FF1E59","negativeTransparent":"rgba(255, 30, 89, 0.3)","pink":"#FF4FF8","pinkLight":"rgb(255, 79, 248, 0.5)","positive":"#00A81A","primaryTransparent":"rgba(155, 108, 167, 0.5)","purple":"#7D55EC","purpleLight":"rgba(125, 85, 236, 0.5)","rose":"#D1A2AB","roseLight":"rgba(209, 162, 171, 0.5)","sky":"#6AA1E0","skyLight":"rgba(106, 161, 224, 0.5)","teal":"#00B4CC","tealLight":"rgba(0, 180, 204, 0.5)","warning":"#DD9900","warningTransparent":"rgba(221, 153, 0, 0.5)","yellow":"#FFCC19","yellowLight":"rgba(255, 204, 25, 0.5)"},"background":{"blackTransparent":"rgba(0, 0, 0, 0.6)","blackTransparentDark":"rgba(0, 0, 0, 0.8)","chartBlock":"#2E3036","codeArea":"#1E1F24","codeTextarea":"#000000","content":"#1B1C20","danger":"#FFD0DB","dark":"#B1B8C3","dashboard":"#18181C","dashboardTransparent":"rgba(24, 24, 28, 0.1)","header":"#1B1B1B","menu":"#0F4CFF","muted":"#F9FAFC","navigation":"#EDEDED","output":"#2E3036","page":"#1E1F24","panel":"#232429","panelTransparent":"rgba(35, 36, 41, 0.7)","popup":"#27292E","row":"#2C2C2C","row2":"#51535C","scrollbarThumb":"rgba(100, 100, 100, 0.5)","scrollbarThumbHover":"rgba(255, 255, 255, 0.3)","scrollbarTrack":"#2E3036","success":"#8ADE00","successLight":"rgb(138, 222, 0, 0.3)","table":"#292A2F","tag":"#3A4550"},"borders":{"button":"#454850","contrast":"#FFFFFF","danger":"#FF144D","dark":"#000000","darkLight":"#2E3036","info":"#FFCC19","light":"#2F3034","medium":"#1C1C1C","medium2":"#141414","success":"#2FCB52"},"brand":{"earth100":"#C6EEDB","earth200":"#9DDFBF","earth300":"#6BBF96","earth400":"#37A46F","earth400Transparent":"rgba(55, 164, 111, 0.4)","earth500":"#00954C","energy100":"#FFF4BA","energy200":"#FFED92","energy300":"#FFE662","energy400":"#FFDA19","energy400Transparent":"rgba(255, 218, 25, 0.04)","energy500":"#F6C000","fire100":"#FFD7E0","fire200":"#FFA3B9","fire300":"#FF547D","fire400":"#FF144D","fire400Transparent":"rgba(255, 20, 77, 0.4)","fire500":"#EB0032","stone100":"#F3E6D7","stone200":"#E3D4C2","stone400":"#BFA78B","stone500":"#AF8859","water100":"#BDCEFF","water200":"#81A1FF","water300":"#517DFF","water400":"#2A60FE","water400Transparent":"rgba(42, 96, 254, 0.4)","water500":"#0F4CFF","wind100":"#EEEAFF","wind200":"#CCC1F4","wind300":"#A698DD","wind400":"#6B50D7","wind400SuperTransparent":"rgba(107, 80, 215, 0.12)","wind400Transparent":"rgba(107, 80, 215, 0.4)","wind500":"#4E32BC"},"chart":{"backgroundPrimary":"#7D55EC","backgroundSecondary":"#FF144D","backgroundTertiary":"#86E2FF","button1":"#4877FF","button2":"#FFCC19","button3":"#8ADE00","button4":"#FF4FF8","button5":"#B98D95","lines":"#9B6CA7","primary":"#6B50D7","secondary":"#FF144D","tertiary":"#2A60FE"},"content":{"active":"#FFFFFF","default":"#AEAEAE","disabled":"rgba(255, 255, 255, 0.3)","inverted":"#2C2C2C","muted":"#787A85"},"elevation":{"visualizationAccent":"#996CFF","visualizationAccentAlt":"#C1ACF7"},"feature":{"active":"rgba(250, 248, 254, 0.14)","disabled":"rgba(201, 206, 218, 0.12)"},"icons":{"neutral":"#787878"},"interactive":{"activeBorder":"#060606","blackBackgroundTransparent":"rgba(0, 0, 0, 0.5)","checked":"#060606","dangerBorder":"#FF144D","defaultBackground":"#36383F","defaultBackgroundTransparent":"rgba(54, 56, 63, 0.5)","defaultBorder":"#ffffff1a","disabledBorder":"#B1B8C3","focusBackground":"#B1B8C3","focusBorder":"#86E2FF","hoverBackground":"#4E4E4E","hoverBackgroundTransparent":"rgba(78, 78, 78, 0.5)","hoverBlackBackgroundTransparent":"rgba(0, 0, 0, 0.7)","hoverBorder":"#B9BFCA","hoverOverlay":"rgba(255, 255, 255, 0.1)","linkPrimary":"#1752FF","linkPrimaryHover":"#4877FF","linkPrimaryLight":"#5982ff","linkSecondary":"#6B50D7","linkSecondaryDisabled":"#C4B9EF","linkText":"#6AA1E0","linkTextLight":"#9ECBFF","purple":"#885EFF","rowHoverBackground":"rgba(0, 0, 0, 0.1)","transparent":"rgba(255, 255, 255, 0)"},"loader":{"color":"#EB0032","colorInverted":"#8ADE00"},"logo":{"color":"#FFFFFF"},"monotone":{"black":"#060606","blackTransparent":"rgba(0, 0, 0, 0.6)","gray":"#B1B8C3","grey100":"#F2F2F2","grey200":"#D5D7DC","grey300":"#B4B8C0","grey400":"#70747C","grey500":"#51535C","purple":"#6B50D7","white":"#FFFFFF","whiteTransparent":"rgba(255, 255, 255, 0.6)"},"neutral":{"n100":"#E7E8EA","n200":"#D8DADE","n300":"#CBCCD0","n400":"#BCBEC4","n500":"#AEB0B6"},"progress":{"negative":"#FF144D","positive":"#6B50D7"},"shadow":{"base":"12px 40px 120px rgba(0, 0, 0, 0.3)","frame":"0px 10px 40px rgba(0, 0, 0, 0.26)","menu":"4px 10px 20px rgba(6, 6, 6, 0.12)","popup":"10px 20px 40px rgba(0, 0, 0, 0.2)","small":"0px, 4px, rgba(0, 0, 0, 0.25)","window":"0px 10px 60px rgba(0, 0, 0, 0.7)"},"status":{"negative":"#FF144D","positive":"#24B400"},"text":{"fileBrowser":"#787A85"}}},"page":"/404","query":{},"buildId":"
|
|
20
|
+
</style></head><body><div id="__next"><div class="" style="position:fixed;top:0;left:0;height:2px;background:transparent;z-index:99999999999;width:100%"><div class="" style="height:100%;background:#FF144D;transition:all 500ms ease;width:0%"><div style="box-shadow:0 0 10px #FF144D, 0 0 10px #FF144D;width:5%;opacity:1;position:absolute;height:100%;transition:all 500ms ease;transform:rotate(3deg) translate(0px, -4px);left:-10rem"></div></div></div><main style="align-items:center;display:flex;flex-direction:column;height:100vh;margin-top:16rem"><svg width="84.70857142857143" height="64" viewBox="0 0 20 14" fill="none" xmlns="http://www.w3.org/2000/svg"><path opacity="0.4" d="M15.3266 0L19.2641 1.82961e-06L11.9687 14L8.03125 14L15.3266 0Z" fill="url(#paint0_linear_1303_5)"></path><path d="M11.9692 1.82961e-06L8.03164 0L0.736328 14L4.67383 14L8.03164 7.55626V14H11.9691V8.38194e-05L11.9692 1.82961e-06Z" fill="url(#paint1_linear_1303_5)"></path><path d="M15.3269 2.57679e-06H19.2644V14H15.3269V2.57679e-06Z" fill="url(#paint2_linear_1303_5)"></path><defs><linearGradient id="paint0_linear_1303_5" x1="8.03125" y1="7" x2="19.2641" y2="7" gradientUnits="userSpaceOnUse"><stop offset="0.28125" stop-color="#7D55EC"></stop><stop offset="1" stop-color="#2AB2FE"></stop></linearGradient><linearGradient id="paint1_linear_1303_5" x1="0.736328" y1="7" x2="19.2644" y2="7" gradientUnits="userSpaceOnUse"><stop offset="0.28125" stop-color="#7D55EC"></stop><stop offset="1" stop-color="#2AB2FE"></stop></linearGradient><linearGradient id="paint2_linear_1303_5" x1="0.736328" y1="7" x2="19.2644" y2="7" gradientUnits="userSpaceOnUse"><stop offset="0.28125" stop-color="#7D55EC"></stop><stop offset="1" stop-color="#2AB2FE"></stop></linearGradient></defs></svg><div class="Spacing__SpacingStyle-sc-1mpmtgj-0 cAAVhx"><div class="Headline__HeadlineContainerStyle-sc-12jzt2e-0 dDWSWx"><h1 class="Headline__H1Style-sc-12jzt2e-2 hkcwCQ">404 - Page Not Found<!-- --></h1></div></div><p class="Text__TextStyle-sc-sl5nur-0 fmHTvj">You will be redirected to the Pipelines dashboard in <!-- -->5<!-- --> seconds.<!-- --></p></main><div id="command-center-root"></div><div></div><div></div><div></div><div class="ToastWrapper-sc-1a33ph1-0 kOVcuR"><div class="Toastify"></div></div></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{},"currentTheme":{"accent":{"alert":"#F6540B","blue":"#4877FF","blueLight":"rgba(72, 119, 255, 0.5)","contentDefaultTransparent":"rgba(174, 174, 174, 0.5)","cyan":"#65E3FF","cyanLight":"rgba(101, 227, 255, 0.3)","cyanTransparent":"rgba(101, 227, 255, 0.12)","dbt":"#fc6949","dbtDark":"rgba(252, 105, 73, 0.3)","dbtLight":"rgba(252, 105, 73, 0.5)","info":"#00ABFF","infoTransparent":"rgba(0, 171, 255, 0.5)","negative":"#FF1E59","negativeTransparent":"rgba(255, 30, 89, 0.3)","pink":"#FF4FF8","pinkLight":"rgb(255, 79, 248, 0.5)","positive":"#00A81A","primaryTransparent":"rgba(155, 108, 167, 0.5)","purple":"#7D55EC","purpleLight":"rgba(125, 85, 236, 0.5)","rose":"#D1A2AB","roseLight":"rgba(209, 162, 171, 0.5)","sky":"#6AA1E0","skyLight":"rgba(106, 161, 224, 0.5)","teal":"#00B4CC","tealLight":"rgba(0, 180, 204, 0.5)","warning":"#DD9900","warningTransparent":"rgba(221, 153, 0, 0.5)","yellow":"#FFCC19","yellowLight":"rgba(255, 204, 25, 0.5)"},"background":{"blackTransparent":"rgba(0, 0, 0, 0.6)","blackTransparentDark":"rgba(0, 0, 0, 0.8)","chartBlock":"#2E3036","codeArea":"#1E1F24","codeTextarea":"#000000","content":"#1B1C20","danger":"#FFD0DB","dark":"#B1B8C3","dashboard":"#18181C","dashboardTransparent":"rgba(24, 24, 28, 0.1)","header":"#1B1B1B","menu":"#0F4CFF","muted":"#F9FAFC","navigation":"#EDEDED","output":"#2E3036","page":"#1E1F24","panel":"#232429","panelTransparent":"rgba(35, 36, 41, 0.7)","popup":"#27292E","row":"#2C2C2C","row2":"#51535C","scrollbarThumb":"rgba(100, 100, 100, 0.5)","scrollbarThumbHover":"rgba(255, 255, 255, 0.3)","scrollbarTrack":"#2E3036","success":"#8ADE00","successLight":"rgb(138, 222, 0, 0.3)","table":"#292A2F","tag":"#3A4550"},"borders":{"button":"#454850","contrast":"#FFFFFF","danger":"#FF144D","dark":"#000000","darkLight":"#2E3036","info":"#FFCC19","light":"#2F3034","medium":"#1C1C1C","medium2":"#141414","success":"#2FCB52"},"brand":{"earth100":"#C6EEDB","earth200":"#9DDFBF","earth300":"#6BBF96","earth400":"#37A46F","earth400Transparent":"rgba(55, 164, 111, 0.4)","earth500":"#00954C","energy100":"#FFF4BA","energy200":"#FFED92","energy300":"#FFE662","energy400":"#FFDA19","energy400Transparent":"rgba(255, 218, 25, 0.04)","energy500":"#F6C000","fire100":"#FFD7E0","fire200":"#FFA3B9","fire300":"#FF547D","fire400":"#FF144D","fire400Transparent":"rgba(255, 20, 77, 0.4)","fire500":"#EB0032","stone100":"#F3E6D7","stone200":"#E3D4C2","stone400":"#BFA78B","stone500":"#AF8859","water100":"#BDCEFF","water200":"#81A1FF","water300":"#517DFF","water400":"#2A60FE","water400Transparent":"rgba(42, 96, 254, 0.4)","water500":"#0F4CFF","wind100":"#EEEAFF","wind200":"#CCC1F4","wind300":"#A698DD","wind400":"#6B50D7","wind400SuperTransparent":"rgba(107, 80, 215, 0.12)","wind400Transparent":"rgba(107, 80, 215, 0.4)","wind500":"#4E32BC"},"chart":{"backgroundPrimary":"#7D55EC","backgroundSecondary":"#FF144D","backgroundTertiary":"#86E2FF","button1":"#4877FF","button2":"#FFCC19","button3":"#8ADE00","button4":"#FF4FF8","button5":"#B98D95","lines":"#9B6CA7","primary":"#6B50D7","secondary":"#FF144D","tertiary":"#2A60FE"},"content":{"active":"#FFFFFF","default":"#AEAEAE","disabled":"rgba(255, 255, 255, 0.3)","inverted":"#2C2C2C","muted":"#787A85"},"elevation":{"visualizationAccent":"#996CFF","visualizationAccentAlt":"#C1ACF7"},"feature":{"active":"rgba(250, 248, 254, 0.14)","disabled":"rgba(201, 206, 218, 0.12)"},"icons":{"neutral":"#787878"},"interactive":{"activeBorder":"#060606","blackBackgroundTransparent":"rgba(0, 0, 0, 0.5)","checked":"#060606","dangerBorder":"#FF144D","defaultBackground":"#36383F","defaultBackgroundTransparent":"rgba(54, 56, 63, 0.5)","defaultBorder":"#ffffff1a","disabledBorder":"#B1B8C3","focusBackground":"#B1B8C3","focusBorder":"#86E2FF","hoverBackground":"#4E4E4E","hoverBackgroundTransparent":"rgba(78, 78, 78, 0.5)","hoverBlackBackgroundTransparent":"rgba(0, 0, 0, 0.7)","hoverBorder":"#B9BFCA","hoverOverlay":"rgba(255, 255, 255, 0.1)","linkPrimary":"#1752FF","linkPrimaryHover":"#4877FF","linkPrimaryLight":"#5982ff","linkSecondary":"#6B50D7","linkSecondaryDisabled":"#C4B9EF","linkText":"#6AA1E0","linkTextLight":"#9ECBFF","purple":"#885EFF","rowHoverBackground":"rgba(0, 0, 0, 0.1)","transparent":"rgba(255, 255, 255, 0)"},"loader":{"color":"#EB0032","colorInverted":"#8ADE00"},"logo":{"color":"#FFFFFF"},"monotone":{"black":"#060606","blackTransparent":"rgba(0, 0, 0, 0.6)","gray":"#B1B8C3","grey100":"#F2F2F2","grey200":"#D5D7DC","grey300":"#B4B8C0","grey400":"#70747C","grey500":"#51535C","purple":"#6B50D7","white":"#FFFFFF","whiteTransparent":"rgba(255, 255, 255, 0.6)"},"neutral":{"n100":"#E7E8EA","n200":"#D8DADE","n300":"#CBCCD0","n400":"#BCBEC4","n500":"#AEB0B6"},"progress":{"negative":"#FF144D","positive":"#6B50D7"},"shadow":{"base":"12px 40px 120px rgba(0, 0, 0, 0.3)","frame":"0px 10px 40px rgba(0, 0, 0, 0.26)","menu":"4px 10px 20px rgba(6, 6, 6, 0.12)","popup":"10px 20px 40px rgba(0, 0, 0, 0.2)","small":"0px, 4px, rgba(0, 0, 0, 0.25)","window":"0px 10px 60px rgba(0, 0, 0, 0.7)"},"status":{"negative":"#FF144D","positive":"#24B400"},"text":{"fileBrowser":"#787A85"}}},"page":"/404","query":{},"buildId":"i8pymuJDTVHdWjUP1QSh1","nextExport":true,"isFallback":false,"appGip":true,"scriptLoader":[]}</script></body></html>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3548],{4015:function(e,n,t){t.d(n,{$b:function(){return s},I5:function(){return l},Nk:function(){return d},gI:function(){return a}});var i=t(25976),r=t(44897),o=t(42631),c=t(70515),d=i.default.div.withConfig({displayName:"indexstyle__ContainerStyle",componentId:"sc-h093u4-0"})([""," ",""],(function(e){return!e.width&&"\n width: ".concat(40*c.iI,"px;\n ")}),(function(e){return e.width&&"\n width: ".concat(e.width,"px;\n ")})),l=i.default.div.withConfig({displayName:"indexstyle__HeaderStyle",componentId:"sc-h093u4-1"})(["padding:","px;"," ",""],2.5*c.iI,(function(e){return"\n background-color: ".concat((e.theme.background||r.Z.background).dashboard,";\n border-left: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n border-right: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n border-top-left-radius: ").concat(o.n_,"px;\n border-top-right-radius: ").concat(o.n_,"px;\n border-top: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n ")}),(function(e){return e.lightBackground&&"\n background-color: ".concat((e.theme.background||r.Z.background).panel,"\n ")})),a=i.default.div.withConfig({displayName:"indexstyle__RowStyle",componentId:"sc-h093u4-2"})(["align-items:center;justify-content:space-between;"," ",""],(function(e){return"\n background-color: ".concat((e.theme.background||r.Z.background).dashboard,";\n border-left: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n border-right: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n border-top: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n display: ").concat((null===e||void 0===e?void 0:e.display)||"flex",";\n padding-bottom: ").concat(1*c.iI+((null===e||void 0===e?void 0:e.paddingVerticalAddition)||0),"px;\n padding-left: ").concat(c.cd*c.iI,"px;\n padding-top: ").concat(1*c.iI+((null===e||void 0===e?void 0:e.paddingVerticalAddition)||0),"px;\n ")}),(function(e){return e.lightBackground&&"\n background-color: ".concat((e.theme.background||r.Z.background).panel,"\n ")})),s=i.default.div.withConfig({displayName:"indexstyle__FooterStyle",componentId:"sc-h093u4-3"})(["padding:","px ","px;"," ",""],2.5*c.iI,2*c.iI,(function(e){return"\n background-color: ".concat((e.theme.background||r.Z.background).panel,";\n border-bottom-left-radius: ").concat(o.n_,"px;\n border-bottom-right-radius: ").concat(o.n_,"px;\n border-bottom: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n border-left: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n border-right: 1px solid ").concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n ")}),(function(e){return e.topBorder&&"\n border-top: 1px solid ".concat((e.theme.interactive||r.Z.interactive).defaultBorder,";\n ")}))},55729:function(e,n,t){t.d(n,{Z:function(){return M}});var i=t(82394),r=t(75582),o=t(82684),c=t(69864),d=t(71180),l=t(15338),a=t(97618),s=t(55485),u=t(85854),p=t(48670),v=t(65956),h=t(82359),f=t(88543),g=t(38276),m=t(30160),x=t(17488),j=t(69650),b=t(12468),Z=t(35686),_=t(77417),y=t(25976),k=t(44897),P=t(42631),w=t(70515),O=y.default.div.withConfig({displayName:"indexstyle__ContainerStyle",componentId:"sc-1b0w59t-0"})(["border-radius:","px;padding:","px;",""],P.n_,w.cd*w.iI,(function(e){return"\n background-color: ".concat((e.theme.background||k.Z.background).codeArea,";\n ")})),C=t(72473),I=t(72191),B=t(70320),E=t(81728),N=t(42122),S=t(72619),A=t(23780),D=t(28598);function L(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);n&&(i=i.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,i)}return t}function H(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?L(Object(t),!0).forEach((function(n){(0,i.Z)(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):L(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var M=function(e){var n,t,y,k=e.cancelButtonText,P=e.contained,L=e.header,M=e.onCancel,V=e.onSaveSuccess,F=e.rootProject,T=(0,A.VI)(null,{},[],{uuid:"settings/workspace/preferences"}),U=(0,r.Z)(T,1)[0],R=(0,o.useState)(null),q=R[0],z=R[1],G=(0,o.useState)(!1),K=G[0],W=G[1],Y=(0,_.Z)(),$=Y.fetchProjects,J=Y.project,Q=Y.projectPlatformActivated,X=Y.rootProject,ee=(0,o.useMemo)((function(){return F?X:J}),[J,X,F]),ne=ee||{},te=ne.name,ie=ne.openai_api_key,re=ne.project_uuid,oe=(0,o.useMemo)((function(){return"demo.mage.ai"===window.location.hostname}),[]);(0,o.useEffect)((function(){q||z(ee)}),[ee,q]);var ce=(0,c.Db)(Z.ZP.projects.useUpdate(te),{onSuccess:function(e){return(0,S.wD)(e,{callback:function(e){var n,t=e.project;$(),z(t),W(!1),(0,B.hY)(null===t||void 0===t||null===(n=t.features)||void 0===n?void 0:n[h.d.LOCAL_TIMEZONE]),V&&(null===V||void 0===V||V(t))},onErrorCallback:function(e,n){return U({errors:n,response:e})}})}}),de=(0,r.Z)(ce,2),le=de[0],ae=de[1].isLoading,se=(0,o.useCallback)((function(e){return le({project:H(H({},e),{},{root_project:F})})}),[F,le]),ue=(0,D.jsxs)(D.Fragment,{children:[L,(0,D.jsxs)(v.Z,{noPadding:!0,children:[(0,D.jsxs)(g.Z,{p:w.cd,children:[(0,D.jsx)(g.Z,{mb:1,children:(0,D.jsx)(u.Z,{level:5,children:"Project name"})}),(0,D.jsx)(m.ZP,{default:!0,monospace:!0,children:te})]}),(0,D.jsx)(l.Z,{light:!0}),(0,D.jsxs)(g.Z,{p:w.cd,children:[(0,D.jsx)(g.Z,{mb:1,children:(0,D.jsx)(u.Z,{level:5,children:"Project UUID"})}),(0,D.jsx)(m.ZP,{default:!!re,monospace:!0,muted:!re,children:re||"Not required"})]}),(0,D.jsx)(l.Z,{light:!0}),(0,D.jsx)(g.Z,{p:w.cd,children:(0,D.jsxs)(s.ZP,{alignItems:"center",justifyContent:"space-between",children:[(0,D.jsxs)(a.Z,{flexDirection:"column",children:[(0,D.jsx)(g.Z,{mb:1,children:(0,D.jsx)(u.Z,{level:5,children:"Help improve Mage"})}),(0,D.jsxs)(m.ZP,{default:!0,children:["Please contribute usage statistics to help improve the developer experience for you and everyone in the community. Learn more ",(0,D.jsx)(p.Z,{href:"https://docs.mage.ai/contributing/statistics/overview",openNewWindow:!0,children:"here"}),"."]})]}),(0,D.jsx)(g.Z,{mr:w.cd}),(0,D.jsx)(j.Z,{compact:!0,checked:null===q||void 0===q?void 0:q.help_improve_mage,onCheck:function(){return z((function(e){return H(H({},e),{},{help_improve_mage:!(null!==q&&void 0!==q&&q.help_improve_mage)})}))}})]})})]}),(0,D.jsx)(g.Z,{mt:w.HN}),(0,D.jsx)(f.Z,{description:"Global settings that are applied to all pipelines in this project.",title:"Pipeline settings",children:(0,D.jsx)(f.S,{description:"Every time a trigger is created or updated in this pipeline, automatically persist it in code.",title:"Save triggers in code automatically",toggleSwitch:{checked:!(null===q||void 0===q||null===(n=q.pipelines)||void 0===n||null===(t=n.settings)||void 0===t||null===(y=t.triggers)||void 0===y||!y.save_in_code_automatically),onCheck:function(e){return z((function(n){var t,i,r,o,c,d;return H(H({},n),{},{pipelines:H(H({},null===n||void 0===n?void 0:n.pipelines),{},{settings:H(H({},null===n||void 0===n||null===(t=n.pipelines)||void 0===t?void 0:t.settings),{},{triggers:H(H({},null===n||void 0===n||null===(i=n.pipelines)||void 0===i||null===(r=i.settings)||void 0===r?void 0:r.triggers),{},{save_in_code_automatically:e(null===n||void 0===n||null===(o=n.pipelines)||void 0===o||null===(c=o.settings)||void 0===c||null===(d=c.triggers)||void 0===d?void 0:d.save_in_code_automatically)})})})})}))}}})}),(0,D.jsx)(g.Z,{mt:w.HN}),(0,D.jsx)(v.Z,{noPadding:!0,overflowVisible:!0,children:(0,D.jsxs)(g.Z,{p:w.cd,children:[(0,D.jsx)(g.Z,{mb:1,children:(0,D.jsx)(u.Z,{level:5,children:"Features"})}),Object.entries((0,N.gR)(null===q||void 0===q?void 0:q.features,[h.d.CODE_BLOCK_V2])||{}).map((function(e,n){var t=(0,r.Z)(e,2),o=t[0],c=t[1],d=Q&&!F&&(null===ee||void 0===ee?void 0:ee.features_override)&&o in(null===ee||void 0===ee?void 0:ee.features_override);return(0,D.jsx)(g.Z,{mt:0===n?0:1,children:(0,D.jsxs)(s.ZP,{alignItems:"center",children:[(0,D.jsxs)(a.Z,{flex:1,children:[(0,D.jsx)(j.Z,{disabled:d,checked:!!c,compact:!0,onCheck:function(){return z((function(e){return H(H({},e),{},{features:H(H({},null===q||void 0===q?void 0:q.features),{},(0,i.Z)({},o,!c))})}))}}),(0,D.jsx)(g.Z,{mr:w.cd}),(0,D.jsxs)(a.Z,{children:[(0,D.jsx)(m.ZP,{default:!c,monospace:!0,children:(0,E.vg)(o)}),o===h.d.LOCAL_TIMEZONE&&(0,D.jsx)(g.Z,{ml:1,children:(0,D.jsx)(b.Z,H({},B.EB))})]})]}),d&&(0,D.jsx)(m.ZP,{monospace:!0,muted:!0,small:!0,children:"overridden"})]})},o)}))]})}),(0,D.jsx)(g.Z,{mt:w.HN}),(0,D.jsx)(v.Z,{noPadding:!0,children:(0,D.jsxs)(g.Z,{p:w.cd,children:[(0,D.jsx)(g.Z,{mb:1,children:(0,D.jsx)(u.Z,{level:5,children:"OpenAI"})}),ie&&!K?(0,D.jsxs)(s.ZP,H(H({},s.A0),{},{children:[(0,D.jsx)(m.ZP,{default:!0,monospace:!0,children:"API key: ********"}),(0,D.jsx)(d.ZP,{iconOnly:!0,onClick:function(){return W(!0)},secondary:!0,title:"Edit",children:(0,D.jsx)(C.Edit,{size:I.bL})})]})):(0,D.jsx)(x.Z,{disabled:oe,label:oe?"Entering API key is disabled on demo":"API key",monospace:!0,onChange:function(e){return z((function(n){return H(H({},n),{},{openai_api_key:e.target.value})}))},primary:!0,setContentOnMount:!0,value:(null===q||void 0===q?void 0:q.openai_api_key)||""})]})}),(0,D.jsx)(g.Z,{mt:w.HN}),(0,D.jsxs)(s.ZP,{alignItems:"center",children:[(0,D.jsx)(d.ZP,{id:"save-project-settings",loading:ae,onClick:function(){se({features:null===q||void 0===q?void 0:q.features,help_improve_mage:null===q||void 0===q?void 0:q.help_improve_mage,openai_api_key:null===q||void 0===q?void 0:q.openai_api_key,pipelines:null===q||void 0===q?void 0:q.pipelines})},primary:!0,children:"Save project settings"}),M&&(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(g.Z,{mr:w.cd}),(0,D.jsx)(d.ZP,{onClick:M,secondary:!0,children:k||"Cancel"})]})]})]});return P?(0,D.jsx)(O,{children:ue}):ue}}}]);
|