abstra 3.24.6__py3-none-any.whl → 3.24.8__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.
- {abstra-3.24.6.dist-info → abstra-3.24.8.dist-info}/METADATA +1 -1
- {abstra-3.24.6.dist-info → abstra-3.24.8.dist-info}/RECORD +176 -175
- abstra_internals/contracts_generated.py +2873 -2735
- abstra_internals/repositories/git/native.py +1 -1
- abstra_internals/repositories/tasks.py +22 -21
- abstra_internals/services/fs.py +25 -0
- abstra_internals/tasks_watcher.py +16 -1
- abstra_internals/tasks_watcher_test.py +254 -0
- abstra_statics/dist/assets/AbstraButton.vue_vue_type_script_setup_true_lang.905e8d9e.js +2 -0
- abstra_statics/dist/assets/AbstraLogo.vue_vue_type_script_setup_true_lang.11067aac.js +2 -0
- abstra_statics/dist/assets/ApiKeys.c2a1c483.js +2 -0
- abstra_statics/dist/assets/App.608af2ed.js +2 -0
- abstra_statics/dist/assets/App.vue_vue_type_style_index_0_lang.8bbdcede.js +2 -0
- abstra_statics/dist/assets/{BaseLayout.fed5adb7.js → BaseLayout.b03df2cd.js} +2 -2
- abstra_statics/dist/assets/Billing.f84cedb5.js +2 -0
- abstra_statics/dist/assets/{Breadcrumb.ae24888f.js → Breadcrumb.9686bc9b.js} +2 -2
- abstra_statics/dist/assets/{Builds.c30d0eb0.js → Builds.c90a1506.js} +2 -2
- abstra_statics/dist/assets/{Card.e1ec3051.js → Card.95a0c7f0.js} +2 -2
- abstra_statics/dist/assets/{CircularLoading.26cebe64.js → CircularLoading.6ab785c3.js} +2 -2
- abstra_statics/dist/assets/CloseCircleOutlined.66e5f1b1.js +2 -0
- abstra_statics/dist/assets/{ConnectorsView.6eae8e1e.js → ConnectorsView.bac282fa.js} +2 -2
- abstra_statics/dist/assets/ConsoleOmniChat.vue_vue_type_script_setup_true_lang.e768f033.js +2 -0
- abstra_statics/dist/assets/ContentLayout.2ae39d29.js +2 -0
- abstra_statics/dist/assets/{CrudView.ca91f805.js → CrudView.391f0e9f.js} +2 -2
- abstra_statics/dist/assets/{DocsButton.vue_vue_type_script_setup_true_lang.c50f6a0a.js → DocsButton.vue_vue_type_script_setup_true_lang.e6d1d3ad.js} +2 -2
- abstra_statics/dist/assets/{EditorLogin.19fe1dcc.js → EditorLogin.feee5e85.js} +2 -2
- abstra_statics/dist/assets/{EditorsView.3f4d1241.js → EditorsView.b9309eb9.js} +2 -2
- abstra_statics/dist/assets/EnvVars.facbb73b.js +2 -0
- abstra_statics/dist/assets/{Error.f38d90e4.js → Error.cec1d9ae.js} +2 -2
- abstra_statics/dist/assets/ExclamationCircleOutlined.81063754.js +2 -0
- abstra_statics/dist/assets/{ExecutionContext.69bc5c09.js → ExecutionContext.8c367ef7.js} +2 -2
- abstra_statics/dist/assets/{ExecutionStatusIcon.vue_vue_type_script_setup_true_lang.a2a7ab75.js → ExecutionStatusIcon.vue_vue_type_script_setup_true_lang.7bd1f43d.js} +2 -2
- abstra_statics/dist/assets/{Files.81259c6b.js → Files.325d463d.js} +2 -2
- abstra_statics/dist/assets/{Form.723342d2.js → Form.48029b6f.js} +2 -2
- abstra_statics/dist/assets/{FormRunner.d1186e5c.js → FormRunner.7e7ce26d.js} +2 -2
- abstra_statics/dist/assets/Home.72bb903d.js +2 -0
- abstra_statics/dist/assets/{Home.bad5d80b.js → Home.fb4fb018.js} +2 -2
- abstra_statics/dist/assets/LoadingContainer.e7fd3862.js +2 -0
- abstra_statics/dist/assets/LoadingOutlined.eb1ab7c7.js +2 -0
- abstra_statics/dist/assets/Login.ab4296a6.js +2 -0
- abstra_statics/dist/assets/{Login.a40bc609.js → Login.f25e3cc8.js} +2 -2
- abstra_statics/dist/assets/{Login.vue_vue_type_script_setup_true_lang.6f146a14.js → Login.vue_vue_type_script_setup_true_lang.c0c3af9a.js} +2 -2
- abstra_statics/dist/assets/Logo.417950ea.js +2 -0
- abstra_statics/dist/assets/{Logs.859d8699.js → Logs.eff00ffa.js} +2 -2
- abstra_statics/dist/assets/Main.9c7e6552.js +2 -0
- abstra_statics/dist/assets/{MockForm.958e1a8b.js → MockForm.a8c36e57.js} +2 -2
- abstra_statics/dist/assets/{Navbar.299ef0ee.js → Navbar.36275768.js} +2 -2
- abstra_statics/dist/assets/{NewEditor.1d3b7038.js → NewEditor.652251d2.js} +2 -2
- abstra_statics/dist/assets/OidcLoginCallback.31318c8c.js +2 -0
- abstra_statics/dist/assets/OidcLogoutCallback.af3bbbed.js +2 -0
- abstra_statics/dist/assets/{OmniChat.fb0615b3.js → OmniChat.6d49a0d2.js} +2 -2
- abstra_statics/dist/assets/{OnboardingView.e2af008f.js → OnboardingView.ec680bc2.js} +2 -2
- abstra_statics/dist/assets/{Organization.1c340a2f.js → Organization.640cf320.js} +2 -2
- abstra_statics/dist/assets/Organizations.be19ecba.js +2 -0
- abstra_statics/dist/assets/{PhArrowCounterClockwise.vue.dbc4fdc7.js → PhArrowCounterClockwise.vue.44a61827.js} +2 -2
- abstra_statics/dist/assets/{PhArrowSquareOut.vue.5a8d2f86.js → PhArrowSquareOut.vue.d71d80fc.js} +2 -2
- abstra_statics/dist/assets/{PhClockCounterClockwise.vue.15ff64b9.js → PhClockCounterClockwise.vue.701e6c6a.js} +2 -2
- abstra_statics/dist/assets/{PhCopy.vue.3f2b76a2.js → PhCopy.vue.5aeb9248.js} +2 -2
- abstra_statics/dist/assets/{PhCopySimple.vue.7cacc0f7.js → PhCopySimple.vue.33922e71.js} +2 -2
- abstra_statics/dist/assets/{PhCube.vue.6a150c53.js → PhCube.vue.3f7281ae.js} +2 -2
- abstra_statics/dist/assets/PhDatabase.vue.09fef09d.js +2 -0
- abstra_statics/dist/assets/{PhDotsThreeVertical.vue.e305b3a2.js → PhDotsThreeVertical.vue.b3fda5f6.js} +2 -2
- abstra_statics/dist/assets/{PhDownloadSimple.vue.2759a067.js → PhDownloadSimple.vue.db22067f.js} +2 -2
- abstra_statics/dist/assets/{PhFileArrowUp.vue.7e13d264.js → PhFileArrowUp.vue.1e3b8493.js} +2 -2
- abstra_statics/dist/assets/{PhFilePlus.vue.537e8e0d.js → PhFilePlus.vue.1b7fc04b.js} +2 -2
- abstra_statics/dist/assets/{PhFolderPlus.vue.53737c9c.js → PhFolderPlus.vue.7b02d45f.js} +2 -2
- abstra_statics/dist/assets/{PhGear.vue.3a3d45d2.js → PhGear.vue.3049f8f5.js} +2 -2
- abstra_statics/dist/assets/{PhKey.vue.07ccc3ef.js → PhKey.vue.3fb1fd34.js} +2 -2
- abstra_statics/dist/assets/{PhPencil.vue.e0099a7f.js → PhPencil.vue.8e94a4bd.js} +2 -2
- abstra_statics/dist/assets/{PhPencilSimple.vue.7ffd0edb.js → PhPencilSimple.vue.c30ff752.js} +2 -2
- abstra_statics/dist/assets/{PhRocket.vue.a2ca27d6.js → PhRocket.vue.1927fd55.js} +2 -2
- abstra_statics/dist/assets/{PhSignOut.vue.4f6997f5.js → PhSignOut.vue.0c10fd8d.js} +2 -2
- abstra_statics/dist/assets/{PhSparkle.vue.e6119d8d.js → PhSparkle.vue.88da054d.js} +2 -2
- abstra_statics/dist/assets/{PhTranslate.vue.d4756feb.js → PhTranslate.vue.5fd55ee3.js} +2 -2
- abstra_statics/dist/assets/{PhUsersThree.vue.50cc946e.js → PhUsersThree.vue.506e9873.js} +2 -2
- abstra_statics/dist/assets/{PhWarningCircle.vue.03a6e5c8.js → PhWarningCircle.vue.139a2f32.js} +2 -2
- abstra_statics/dist/assets/{PhWebhooksLogo.vue.13c489ce.js → PhWebhooksLogo.vue.28d1edea.js} +2 -2
- abstra_statics/dist/assets/{PlayerConfigProvider.d0d5439f.js → PlayerConfigProvider.f7be8491.js} +2 -2
- abstra_statics/dist/assets/{PlayerNavbar.fd53d29e.js → PlayerNavbar.fb3a012d.js} +2 -2
- abstra_statics/dist/assets/{Project.7c3bdd8a.js → Project.6af32e98.js} +2 -2
- abstra_statics/dist/assets/{ProjectLogin.9cec413b.js → ProjectLogin.7f541a88.js} +2 -2
- abstra_statics/dist/assets/ProjectSettings.52805237.js +2 -0
- abstra_statics/dist/assets/{ProjectsView.4d026e78.js → ProjectsView.53e4ed94.js} +2 -2
- abstra_statics/dist/assets/{SaveButton.813aaf8d.js → SaveButton.bf92f582.js} +2 -2
- abstra_statics/dist/assets/{ScrollArea.vue_vue_type_script_setup_true_lang.e8269806.js → ScrollArea.vue_vue_type_script_setup_true_lang.b4f189da.js} +2 -2
- abstra_statics/dist/assets/{Sidebar.08e9b51a.js → Sidebar.af08c680.js} +2 -2
- abstra_statics/dist/assets/{Sql.18a715c6.js → Sql.fd118d60.js} +4 -4
- abstra_statics/dist/assets/Steps.27508a86.js +2 -0
- abstra_statics/dist/assets/{TableCard.2543b684.js → TableCard.0bcd184a.js} +2 -2
- abstra_statics/dist/assets/{TableEditor.ee57cc7f.js → TableEditor.0b14bc7b.js} +2 -2
- abstra_statics/dist/assets/{Tables.a358bf91.js → Tables.8dabe248.js} +2 -2
- abstra_statics/dist/assets/{TablesDiagram.991fc1b3.js → TablesDiagram.547215e0.js} +2 -2
- abstra_statics/dist/assets/{TablesTabs.vue_vue_type_script_setup_true_lang.744da918.js → TablesTabs.vue_vue_type_script_setup_true_lang.9027b106.js} +2 -2
- abstra_statics/dist/assets/Tasks.6d16250c.js +2 -0
- abstra_statics/dist/assets/{UploadOutlined.113850a1.js → UploadOutlined.736aa5bc.js} +2 -2
- abstra_statics/dist/assets/{View.67504c02.js → View.b4fa346f.js} +2 -2
- abstra_statics/dist/assets/{View.vue_vue_type_script_setup_true_lang.f7c2ef15.js → View.vue_vue_type_script_setup_true_lang.d5d3a410.js} +2 -2
- abstra_statics/dist/assets/{Watermark.6e692419.js → Watermark.e6c4654b.js} +2 -2
- abstra_statics/dist/assets/{WebEditor.7a1fcb94.js → WebEditor.49aee538.js} +2 -2
- abstra_statics/dist/assets/{WidgetPreview.0b7ab78b.js → WidgetPreview.e0916bed.js} +2 -2
- abstra_statics/dist/assets/{WorkflowViewer.95d64da4.js → WorkflowViewer.b2b3ee29.js} +2 -2
- abstra_statics/dist/assets/ant-design.805ab95d.js +2 -0
- abstra_statics/dist/assets/{apiKey.975dfeae.js → apiKey.1b1aafc4.js} +2 -2
- abstra_statics/dist/assets/asyncComputed.0308626b.js +2 -0
- abstra_statics/dist/assets/{build.c626214a.js → build.1cc9147c.js} +2 -2
- abstra_statics/dist/assets/colorHelpers.93df70ab.js +2 -0
- abstra_statics/dist/assets/{console.1e432ec7.js → console.c2a83def.js} +2 -2
- abstra_statics/dist/assets/constants.ba2d8460.js +2 -0
- abstra_statics/dist/assets/{contracts.generated.c5043d35.js → contracts.generated.bc42bf02.js} +2 -2
- abstra_statics/dist/assets/{cssMode.75e3c56c.js → cssMode.da3677b5.js} +2 -2
- abstra_statics/dist/assets/datetime.049cd1b4.js +2 -0
- abstra_statics/dist/assets/dayjs.ba8d5e03.js +2 -0
- abstra_statics/dist/assets/editor.4df699e8.js +2 -0
- abstra_statics/dist/assets/editor.main.1441c190.js +2 -0
- abstra_statics/dist/assets/fetch.6b0b8dbd.js +2 -0
- abstra_statics/dist/assets/files.a48976ba.js +2 -0
- abstra_statics/dist/assets/{folder.bd31d9bc.js → folder.1303b3cc.js} +2 -2
- abstra_statics/dist/assets/{freemarker2.400d456f.js → freemarker2.78f622a4.js} +2 -2
- abstra_statics/dist/assets/{handlebars.d8549cd4.js → handlebars.f24ca206.js} +3 -3
- abstra_statics/dist/assets/{html.dcc0e819.js → html.d6232cb7.js} +3 -3
- abstra_statics/dist/assets/{htmlMode.b93d1fe9.js → htmlMode.66845b4f.js} +2 -2
- abstra_statics/dist/assets/{index.a4dc5332.js → index.4073d3ba.js} +2 -2
- abstra_statics/dist/assets/{index.36a090cf.js → index.5654c649.js} +2 -2
- abstra_statics/dist/assets/{index.dfc79bf7.js → index.5eda0243.js} +2 -2
- abstra_statics/dist/assets/{index.5ecb9a37.js → index.680764ed.js} +2 -2
- abstra_statics/dist/assets/{index.ddb89818.js → index.705ce630.js} +2 -2
- abstra_statics/dist/assets/{index.99fb59f0.js → index.aa2603a0.js} +2 -2
- abstra_statics/dist/assets/{index.ab7dc629.js → index.bbb3a202.js} +2 -2
- abstra_statics/dist/assets/index.c25fb6e2.js +2 -0
- abstra_statics/dist/assets/{index.2400150a.js → index.fd17682d.js} +2 -2
- abstra_statics/dist/assets/{javascript.6a1a2db7.js → javascript.1009e690.js} +3 -3
- abstra_statics/dist/assets/{jsonMode.0650153f.js → jsonMode.bd88eaca.js} +2 -2
- abstra_statics/dist/assets/{jwt-decode.cfe2994b.css → jwt-decode.aa5b9ed3.css} +1 -1
- abstra_statics/dist/assets/{jwt-decode.esm.32f71954.js → jwt-decode.esm.4071145e.js} +9 -8
- abstra_statics/dist/assets/{linters.3b9f6de6.js → linters.5d49f0b2.js} +2 -2
- abstra_statics/dist/assets/{liquid.612ef64b.js → liquid.fd06ec69.js} +3 -3
- abstra_statics/dist/assets/{member.91dd2bc0.js → member.d4cf4c10.js} +2 -2
- abstra_statics/dist/assets/{metadata.c5f500d1.js → metadata.bd34dda0.js} +2 -2
- abstra_statics/dist/assets/{omniChatStore.10d769d2.js → omniChatStore.3d16b4ad.js} +4 -4
- abstra_statics/dist/assets/{organization.2c5a9815.js → organization.1b235ed0.js} +2 -2
- abstra_statics/dist/assets/{os.d718583c.js → os.b6b83ab9.js} +2 -2
- abstra_statics/dist/assets/player.9c3751ac.js +2 -0
- abstra_statics/dist/assets/{plotly.min.cdd940d3.js → plotly.min.5ef097da.js} +2 -2
- abstra_statics/dist/assets/polling.cabdf3a3.js +2 -0
- abstra_statics/dist/assets/{project.b14b799c.js → project.794c2cba.js} +2 -2
- abstra_statics/dist/assets/{python.de00ef26.js → python.014e8707.js} +3 -3
- abstra_statics/dist/assets/{razor.7aff1cf0.js → razor.eee706f7.js} +3 -3
- abstra_statics/dist/assets/{record.41c9caee.js → record.daabed01.js} +2 -2
- abstra_statics/dist/assets/redirect.8303afd7.js +2 -0
- abstra_statics/dist/assets/{repository.bfee664a.js → repository.010eeaad.js} +2 -2
- abstra_statics/dist/assets/{repository.e580214f.js → repository.997243c1.js} +2 -2
- abstra_statics/dist/assets/router.e1e467ab.js +2 -0
- abstra_statics/dist/assets/{router.29e08ea4.js → router.ef7a08cf.js} +5 -5
- abstra_statics/dist/assets/{string.ff0b4ef9.js → string.0157e442.js} +2 -2
- abstra_statics/dist/assets/{tables.94d324c3.js → tables.59457dad.js} +2 -2
- abstra_statics/dist/assets/{tasksController.42d22818.js → tasksController.a5bd1328.js} +3 -3
- abstra_statics/dist/assets/{toggleHighContrast.7b4a31db.js → toggleHighContrast.2a096764.js} +7 -7
- abstra_statics/dist/assets/{tsMode.5cdf91a5.js → tsMode.5a841751.js} +2 -2
- abstra_statics/dist/assets/{typescript.53676cd5.js → typescript.a8946c53.js} +3 -3
- abstra_statics/dist/assets/url.4aa6f272.js +2 -0
- abstra_statics/dist/assets/{useCodebaseEvents.5fbf9bc1.js → useCodebaseEvents.c0197501.js} +2 -2
- abstra_statics/dist/assets/useTables.413ae4ce.js +2 -0
- abstra_statics/dist/assets/userStore.1004ebc1.js +2 -0
- abstra_statics/dist/assets/uuid.14c9b73e.js +2 -0
- abstra_statics/dist/assets/{vue-flow-background.7de722ba.js → vue-flow-background.cc5881af.js} +2 -2
- abstra_statics/dist/assets/{vue-flow-core.589f776e.js → vue-flow-core.64ea4397.js} +2 -2
- abstra_statics/dist/assets/{vue-quill.esm-bundler.d3994d88.js → vue-quill.esm-bundler.404d7a1a.js} +2 -2
- abstra_statics/dist/assets/{workspaceStore.5dfe5329.js → workspaceStore.260ac7fc.js} +2 -2
- abstra_statics/dist/assets/{xml.a905d090.js → xml.6d7ee5c8.js} +3 -3
- abstra_statics/dist/assets/{yaml.112096a6.js → yaml.a48b0813.js} +3 -3
- abstra_statics/dist/console.html +15 -15
- abstra_statics/dist/editor.html +14 -14
- abstra_statics/dist/player.html +10 -10
- abstra_statics/dist/assets/AbstraButton.vue_vue_type_script_setup_true_lang.9c0844e1.js +0 -2
- abstra_statics/dist/assets/AbstraLogo.vue_vue_type_script_setup_true_lang.f0472c1e.js +0 -2
- abstra_statics/dist/assets/ApiKeys.e05d1ca1.js +0 -2
- abstra_statics/dist/assets/App.89fb6f4a.js +0 -2
- abstra_statics/dist/assets/App.vue_vue_type_style_index_0_lang.7b340da5.js +0 -2
- abstra_statics/dist/assets/Billing.f1e5c3f8.js +0 -2
- abstra_statics/dist/assets/CloseCircleOutlined.fdea1f27.js +0 -2
- abstra_statics/dist/assets/ConsoleOmniChat.vue_vue_type_script_setup_true_lang.cbe8dd45.js +0 -2
- abstra_statics/dist/assets/ContentLayout.b1b0e8fb.js +0 -2
- abstra_statics/dist/assets/EnvVars.84ca50aa.js +0 -2
- abstra_statics/dist/assets/ExclamationCircleOutlined.380af12e.js +0 -2
- abstra_statics/dist/assets/Home.889db6be.js +0 -2
- abstra_statics/dist/assets/LoadingContainer.395f4c42.js +0 -2
- abstra_statics/dist/assets/LoadingOutlined.6f7bdc44.js +0 -2
- abstra_statics/dist/assets/Login.90ebb0f6.js +0 -2
- abstra_statics/dist/assets/Logo.c75e45a8.js +0 -2
- abstra_statics/dist/assets/Main.6fd4bb0a.js +0 -2
- abstra_statics/dist/assets/OidcLoginCallback.17eeec42.js +0 -2
- abstra_statics/dist/assets/OidcLogoutCallback.b4d1c600.js +0 -2
- abstra_statics/dist/assets/Organizations.96e88f77.js +0 -2
- abstra_statics/dist/assets/PhDatabase.vue.425a706f.js +0 -2
- abstra_statics/dist/assets/ProjectSettings.995a749e.js +0 -2
- abstra_statics/dist/assets/Steps.7b2e867b.js +0 -2
- abstra_statics/dist/assets/Tasks.932349fa.js +0 -2
- abstra_statics/dist/assets/ant-design.a8b36151.js +0 -2
- abstra_statics/dist/assets/asyncComputed.f9fa4c71.js +0 -2
- abstra_statics/dist/assets/colorHelpers.b41220cb.js +0 -2
- abstra_statics/dist/assets/constants.b5d83622.js +0 -2
- abstra_statics/dist/assets/datetime.cf8e211d.js +0 -2
- abstra_statics/dist/assets/dayjs.68053597.js +0 -2
- abstra_statics/dist/assets/editor.a00709d8.js +0 -2
- abstra_statics/dist/assets/editor.main.80ee55a4.js +0 -2
- abstra_statics/dist/assets/fetch.a8fb4ba0.js +0 -2
- abstra_statics/dist/assets/files.e8f04848.js +0 -2
- abstra_statics/dist/assets/index.c59ca45b.js +0 -2
- abstra_statics/dist/assets/player.66868a86.js +0 -2
- abstra_statics/dist/assets/polling.ca800fea.js +0 -2
- abstra_statics/dist/assets/redirect.2f506c19.js +0 -2
- abstra_statics/dist/assets/router.235ae730.js +0 -2
- abstra_statics/dist/assets/url.79cc02c3.js +0 -2
- abstra_statics/dist/assets/useTables.64fe45b0.js +0 -2
- abstra_statics/dist/assets/userStore.339db438.js +0 -2
- abstra_statics/dist/assets/uuid.77e093c3.js +0 -2
- {abstra-3.24.6.dist-info → abstra-3.24.8.dist-info}/WHEEL +0 -0
- {abstra-3.24.6.dist-info → abstra-3.24.8.dist-info}/entry_points.txt +0 -0
- {abstra-3.24.6.dist-info → abstra-3.24.8.dist-info}/top_level.txt +0 -0
|
@@ -647,7 +647,7 @@ class NativeGitRepository(GitRepositoryInterface):
|
|
|
647
647
|
try:
|
|
648
648
|
# Use git check-ignore with stdin for batch processing
|
|
649
649
|
input_data = "\n".join(relative_paths)
|
|
650
|
-
|
|
650
|
+
_, stdout, _ = self._run_git_command(
|
|
651
651
|
["check-ignore", "--stdin"],
|
|
652
652
|
cwd=self.working_directory,
|
|
653
653
|
input=input_data,
|
|
@@ -6,6 +6,11 @@ from uuid import uuid4
|
|
|
6
6
|
|
|
7
7
|
from abstra_internals.cloud_api.http_client import HTTPClient
|
|
8
8
|
from abstra_internals.consts.filepaths import TASKS_DIR_PATH
|
|
9
|
+
from abstra_internals.contracts_generated import (
|
|
10
|
+
CloudApiCliTasksUpdateTaskRequest,
|
|
11
|
+
CloudApiConsoleWorkflowUpdateTaskRequestCompleted,
|
|
12
|
+
CloudApiConsoleWorkflowUpdateTaskRequestLocked,
|
|
13
|
+
)
|
|
9
14
|
from abstra_internals.repositories.multiprocessing import MPContext
|
|
10
15
|
from abstra_internals.services.sql_storage import SqlStorage
|
|
11
16
|
from abstra_internals.utils.datetime import to_utc_iso_string
|
|
@@ -296,16 +301,14 @@ class ProductionTasksRepository(TasksRepository):
|
|
|
296
301
|
) -> None:
|
|
297
302
|
r = self.client.patch(
|
|
298
303
|
endpoint=f"/tasks/{task_id}",
|
|
299
|
-
json=
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
},
|
|
308
|
-
},
|
|
304
|
+
json=CloudApiCliTasksUpdateTaskRequest(
|
|
305
|
+
status="locked",
|
|
306
|
+
locked=CloudApiConsoleWorkflowUpdateTaskRequestLocked(
|
|
307
|
+
at=datetime.datetime.now(datetime.timezone.utc),
|
|
308
|
+
by_execution_id=execution_id,
|
|
309
|
+
by_stage_id=stage_id,
|
|
310
|
+
),
|
|
311
|
+
).to_dict(),
|
|
309
312
|
)
|
|
310
313
|
|
|
311
314
|
if r.status_code == 409:
|
|
@@ -318,16 +321,14 @@ class ProductionTasksRepository(TasksRepository):
|
|
|
318
321
|
) -> None:
|
|
319
322
|
r = self.client.patch(
|
|
320
323
|
endpoint=f"/tasks/{task_id}",
|
|
321
|
-
json=
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
},
|
|
330
|
-
},
|
|
324
|
+
json=CloudApiCliTasksUpdateTaskRequest(
|
|
325
|
+
status="completed",
|
|
326
|
+
completed=CloudApiConsoleWorkflowUpdateTaskRequestCompleted(
|
|
327
|
+
at=datetime.datetime.now(datetime.timezone.utc),
|
|
328
|
+
by_execution_id=execution_id,
|
|
329
|
+
by_stage_id=stage_id,
|
|
330
|
+
),
|
|
331
|
+
).to_dict(),
|
|
331
332
|
)
|
|
332
333
|
|
|
333
334
|
if r.status_code == 409:
|
|
@@ -338,7 +339,7 @@ class ProductionTasksRepository(TasksRepository):
|
|
|
338
339
|
def set_task_to_pending(self, task_id: str) -> None:
|
|
339
340
|
r = self.client.patch(
|
|
340
341
|
endpoint=f"/tasks/{task_id}",
|
|
341
|
-
json=
|
|
342
|
+
json=CloudApiCliTasksUpdateTaskRequest(status="pending").to_dict(),
|
|
342
343
|
)
|
|
343
344
|
|
|
344
345
|
if r.status_code == 409:
|
abstra_internals/services/fs.py
CHANGED
|
@@ -15,6 +15,7 @@ class FileSystemService:
|
|
|
15
15
|
_git_ignore_cache: Dict[Path, bool] = {}
|
|
16
16
|
_git_ignore_cache_lock = threading.Lock()
|
|
17
17
|
_git_repository = None
|
|
18
|
+
_gitignore_mtime: Optional[float] = None
|
|
18
19
|
|
|
19
20
|
# Fallback cache for Python .gitignore parsing (when git unavailable)
|
|
20
21
|
_gitignore_cache: Dict[Path, List[str]] = {}
|
|
@@ -35,12 +36,33 @@ class FileSystemService:
|
|
|
35
36
|
git_repo = FileSystemService._get_git_repository()
|
|
36
37
|
return git_repo.is_git_repository()
|
|
37
38
|
|
|
39
|
+
@staticmethod
|
|
40
|
+
def _check_gitignore_modified():
|
|
41
|
+
"""Check if .gitignore has been modified since last cache, and clear if needed."""
|
|
42
|
+
gitignore_path = Settings.root_path / GITIGNORE_FILEPATH
|
|
43
|
+
if gitignore_path.exists():
|
|
44
|
+
try:
|
|
45
|
+
current_mtime = gitignore_path.stat().st_mtime
|
|
46
|
+
if FileSystemService._gitignore_mtime is None:
|
|
47
|
+
FileSystemService._gitignore_mtime = current_mtime
|
|
48
|
+
elif FileSystemService._gitignore_mtime != current_mtime:
|
|
49
|
+
FileSystemService.clear_gitignore_cache()
|
|
50
|
+
FileSystemService._gitignore_mtime = current_mtime
|
|
51
|
+
except OSError:
|
|
52
|
+
pass
|
|
53
|
+
elif FileSystemService._gitignore_mtime is not None:
|
|
54
|
+
# .gitignore was deleted
|
|
55
|
+
FileSystemService.clear_gitignore_cache()
|
|
56
|
+
FileSystemService._gitignore_mtime = None
|
|
57
|
+
|
|
38
58
|
@staticmethod
|
|
39
59
|
def _check_git_ignore_batch(paths: List[Path]) -> Dict[Path, bool]:
|
|
40
60
|
"""
|
|
41
61
|
Check multiple paths at once using git check-ignore --stdin.
|
|
42
62
|
Much more efficient than checking one at a time.
|
|
43
63
|
"""
|
|
64
|
+
FileSystemService._check_gitignore_modified()
|
|
65
|
+
|
|
44
66
|
if not FileSystemService._is_git_available():
|
|
45
67
|
return {path: False for path in paths}
|
|
46
68
|
|
|
@@ -126,6 +148,9 @@ class FileSystemService:
|
|
|
126
148
|
# Clear git repository cache to avoid using stale repository instances
|
|
127
149
|
FileSystemService._git_repository = None
|
|
128
150
|
|
|
151
|
+
# Reset mtime tracking
|
|
152
|
+
FileSystemService._gitignore_mtime = None
|
|
153
|
+
|
|
129
154
|
@staticmethod
|
|
130
155
|
def venv_path() -> Optional[Path]:
|
|
131
156
|
str_path = os.getenv("VIRTUAL_ENV") or os.getenv("CONDA_PREFIX")
|
|
@@ -42,13 +42,28 @@ class TasksWatcher(FileSystemEventHandler):
|
|
|
42
42
|
if filepath.suffix != ".json" or not filepath.parent.samefile(TASKS_DIR_PATH):
|
|
43
43
|
return
|
|
44
44
|
|
|
45
|
+
# Ignore __schema__.json file created by FileSystemJsonTables
|
|
46
|
+
if filepath.name == "__schema__.json":
|
|
47
|
+
return
|
|
48
|
+
|
|
45
49
|
self._handle_file_event(filepath)
|
|
46
50
|
|
|
47
51
|
def _handle_file_event(self, filepath: Path):
|
|
48
52
|
time.sleep(0.01)
|
|
49
53
|
|
|
54
|
+
# Ignore __schema__.json file created by FileSystemJsonTables
|
|
55
|
+
if filepath.name == "__schema__.json":
|
|
56
|
+
return
|
|
57
|
+
|
|
50
58
|
raw_task = filepath.read_text(encoding="utf-8")
|
|
51
|
-
|
|
59
|
+
parsed_json = json.loads(raw_task)
|
|
60
|
+
|
|
61
|
+
# Ignore files that don't contain valid TaskDTO objects
|
|
62
|
+
# FileSystemJsonTables may create files with empty arrays or invalid data
|
|
63
|
+
if not isinstance(parsed_json, dict):
|
|
64
|
+
return
|
|
65
|
+
|
|
66
|
+
task = TaskDTO(**parsed_json)
|
|
52
67
|
|
|
53
68
|
for handler in self.handlers:
|
|
54
69
|
threading.Thread(target=handler, args=(task,)).start()
|
|
@@ -0,0 +1,254 @@
|
|
|
1
|
+
import json
|
|
2
|
+
import tempfile
|
|
3
|
+
import time
|
|
4
|
+
import unittest
|
|
5
|
+
from pathlib import Path
|
|
6
|
+
from unittest.mock import MagicMock
|
|
7
|
+
|
|
8
|
+
from pydantic import ValidationError
|
|
9
|
+
|
|
10
|
+
from abstra_internals.repositories.tasks import TaskDTO
|
|
11
|
+
from abstra_internals.tasks_watcher import TasksWatcher
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class TestTasksWatcher(unittest.TestCase):
|
|
15
|
+
def setUp(self):
|
|
16
|
+
self.temp_dir = tempfile.mkdtemp()
|
|
17
|
+
self.tasks_dir = Path(self.temp_dir) / "tasks"
|
|
18
|
+
self.tasks_dir.mkdir(parents=True, exist_ok=True)
|
|
19
|
+
|
|
20
|
+
def tearDown(self):
|
|
21
|
+
import shutil
|
|
22
|
+
|
|
23
|
+
shutil.rmtree(self.temp_dir, ignore_errors=True)
|
|
24
|
+
|
|
25
|
+
def test_invalid_task_json_raises_validation_error(self):
|
|
26
|
+
"""
|
|
27
|
+
Test that TasksWatcher raises ValidationError when encountering
|
|
28
|
+
a JSON file that doesn't match TaskDTO schema.
|
|
29
|
+
|
|
30
|
+
This reproduces the error seen when starting an empty project where
|
|
31
|
+
some JSON file in the tasks directory doesn't have the required fields
|
|
32
|
+
(id, type, payload, status, targetStageId, created, locked, completed).
|
|
33
|
+
"""
|
|
34
|
+
# Create a mock handler
|
|
35
|
+
mock_handler = MagicMock()
|
|
36
|
+
watcher = TasksWatcher(handlers=[mock_handler])
|
|
37
|
+
|
|
38
|
+
# Create an invalid JSON file that resembles a schema definition
|
|
39
|
+
# (like the one in the error message)
|
|
40
|
+
invalid_task_json = {
|
|
41
|
+
"a8a61558-625d-483e-82f9": {
|
|
42
|
+
"type": "string",
|
|
43
|
+
"nullable": False,
|
|
44
|
+
"default": None,
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
invalid_file = self.tasks_dir / "invalid_task.json"
|
|
49
|
+
invalid_file.write_text(json.dumps(invalid_task_json))
|
|
50
|
+
|
|
51
|
+
# This should raise a ValidationError when trying to parse as TaskDTO
|
|
52
|
+
with self.assertRaises(ValidationError) as context:
|
|
53
|
+
watcher._handle_file_event(invalid_file)
|
|
54
|
+
|
|
55
|
+
# Verify the error contains the expected missing fields
|
|
56
|
+
error = context.exception
|
|
57
|
+
error_dict = error.errors()
|
|
58
|
+
|
|
59
|
+
# Check that all required fields are reported as missing
|
|
60
|
+
required_fields = [
|
|
61
|
+
"id",
|
|
62
|
+
"type",
|
|
63
|
+
"payload",
|
|
64
|
+
"status",
|
|
65
|
+
"targetStageId",
|
|
66
|
+
"created",
|
|
67
|
+
"locked",
|
|
68
|
+
"completed",
|
|
69
|
+
]
|
|
70
|
+
reported_fields = [e["loc"][0] for e in error_dict]
|
|
71
|
+
|
|
72
|
+
for field in required_fields:
|
|
73
|
+
self.assertIn(
|
|
74
|
+
field, reported_fields, f"Field '{field}' should be reported as missing"
|
|
75
|
+
)
|
|
76
|
+
|
|
77
|
+
def test_valid_task_json_calls_handler(self):
|
|
78
|
+
"""
|
|
79
|
+
Test that TasksWatcher successfully processes a valid TaskDTO JSON
|
|
80
|
+
and calls the registered handlers.
|
|
81
|
+
"""
|
|
82
|
+
mock_handler = MagicMock()
|
|
83
|
+
watcher = TasksWatcher(handlers=[mock_handler])
|
|
84
|
+
|
|
85
|
+
# Create a valid task JSON
|
|
86
|
+
valid_task_json = {
|
|
87
|
+
"id": "test-123",
|
|
88
|
+
"type": "test-type",
|
|
89
|
+
"payload": {"key": "value"},
|
|
90
|
+
"status": "pending",
|
|
91
|
+
"targetStageId": "stage-123",
|
|
92
|
+
"created": {
|
|
93
|
+
"at": "2025-01-01T00:00:00Z",
|
|
94
|
+
"byExecutionId": None,
|
|
95
|
+
"byStageId": None,
|
|
96
|
+
},
|
|
97
|
+
"locked": None,
|
|
98
|
+
"completed": None,
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
valid_file = self.tasks_dir / "valid_task.json"
|
|
102
|
+
valid_file.write_text(json.dumps(valid_task_json))
|
|
103
|
+
|
|
104
|
+
# This should not raise any error
|
|
105
|
+
watcher._handle_file_event(valid_file)
|
|
106
|
+
|
|
107
|
+
# Wait a bit for the thread to process
|
|
108
|
+
time.sleep(0.1)
|
|
109
|
+
|
|
110
|
+
# Handler should have been called
|
|
111
|
+
mock_handler.assert_called_once()
|
|
112
|
+
|
|
113
|
+
# Verify the TaskDTO was correctly parsed
|
|
114
|
+
called_task = mock_handler.call_args[0][0]
|
|
115
|
+
self.assertIsInstance(called_task, TaskDTO)
|
|
116
|
+
self.assertEqual(called_task.id, "test-123")
|
|
117
|
+
self.assertEqual(called_task.type, "test-type")
|
|
118
|
+
self.assertEqual(called_task.status, "pending")
|
|
119
|
+
|
|
120
|
+
def test_task_dto_validation_with_malformed_data(self):
|
|
121
|
+
"""
|
|
122
|
+
Direct test of TaskDTO validation with the exact error pattern
|
|
123
|
+
from the bug report.
|
|
124
|
+
"""
|
|
125
|
+
# This is similar to what was in the JSON file causing the error
|
|
126
|
+
malformed_data = {
|
|
127
|
+
"a8a61558-625d-483e-82f9": {
|
|
128
|
+
"type": "string",
|
|
129
|
+
"nullable": False,
|
|
130
|
+
"default": None,
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
with self.assertRaises(ValidationError) as context:
|
|
135
|
+
TaskDTO(**malformed_data) # type: ignore
|
|
136
|
+
|
|
137
|
+
error = context.exception
|
|
138
|
+
self.assertIn("Field required", str(error))
|
|
139
|
+
|
|
140
|
+
# Verify all 8 validation errors (as shown in the original error)
|
|
141
|
+
error_dict = error.errors()
|
|
142
|
+
self.assertEqual(
|
|
143
|
+
len(error_dict),
|
|
144
|
+
8,
|
|
145
|
+
"Should have 8 validation errors for missing required fields",
|
|
146
|
+
)
|
|
147
|
+
|
|
148
|
+
def test_non_dict_json_files_should_be_ignored(self):
|
|
149
|
+
"""
|
|
150
|
+
Test that TasksWatcher should IGNORE JSON files that don't contain dictionaries.
|
|
151
|
+
|
|
152
|
+
This includes arrays, strings, numbers, null, etc.
|
|
153
|
+
"""
|
|
154
|
+
mock_handler = MagicMock()
|
|
155
|
+
watcher = TasksWatcher(handlers=[mock_handler])
|
|
156
|
+
|
|
157
|
+
# Test various non-dict JSON types
|
|
158
|
+
test_cases = [
|
|
159
|
+
("array.json", "[]"),
|
|
160
|
+
("array_with_data.json", "[1, 2, 3]"),
|
|
161
|
+
("string.json", '"some string"'),
|
|
162
|
+
("number.json", "42"),
|
|
163
|
+
("null.json", "null"),
|
|
164
|
+
("boolean.json", "true"),
|
|
165
|
+
]
|
|
166
|
+
|
|
167
|
+
for filename, content in test_cases:
|
|
168
|
+
file_path = self.tasks_dir / filename
|
|
169
|
+
file_path.write_text(content)
|
|
170
|
+
|
|
171
|
+
try:
|
|
172
|
+
watcher._handle_file_event(file_path)
|
|
173
|
+
mock_handler.assert_not_called()
|
|
174
|
+
except Exception as e:
|
|
175
|
+
self.fail(
|
|
176
|
+
f"TasksWatcher should ignore non-dict JSON in {filename} but raised {type(e).__name__}: {e}"
|
|
177
|
+
)
|
|
178
|
+
|
|
179
|
+
def test_empty_array_json_file_should_be_ignored(self):
|
|
180
|
+
"""
|
|
181
|
+
Test that TasksWatcher should IGNORE JSON files containing empty arrays.
|
|
182
|
+
|
|
183
|
+
The FileSystemJsonTables creates files with [] content that should be ignored.
|
|
184
|
+
This test follows TDD approach - it will FAIL until we implement the fix.
|
|
185
|
+
"""
|
|
186
|
+
mock_handler = MagicMock()
|
|
187
|
+
watcher = TasksWatcher(handlers=[mock_handler])
|
|
188
|
+
|
|
189
|
+
# Create a JSON file with empty array (as created by FileSystemJsonTables)
|
|
190
|
+
empty_array_file = self.tasks_dir / "f910a9f0-6f46-4450-85b4-2373fed7a584.json"
|
|
191
|
+
empty_array_file.write_text("[]")
|
|
192
|
+
|
|
193
|
+
# This should NOT raise any error - the file should be ignored
|
|
194
|
+
try:
|
|
195
|
+
watcher._handle_file_event(empty_array_file)
|
|
196
|
+
# If we get here without error, the handler should NOT have been called
|
|
197
|
+
mock_handler.assert_not_called()
|
|
198
|
+
except (ValidationError, TypeError) as e:
|
|
199
|
+
self.fail(
|
|
200
|
+
f"TasksWatcher should ignore empty array JSON files but raised {type(e).__name__}"
|
|
201
|
+
)
|
|
202
|
+
|
|
203
|
+
def test_schema_json_file_should_be_ignored(self):
|
|
204
|
+
"""
|
|
205
|
+
Test that TasksWatcher should IGNORE the __schema__.json file
|
|
206
|
+
created by FileSystemJsonTables.
|
|
207
|
+
|
|
208
|
+
This test follows TDD approach - it will FAIL until we implement
|
|
209
|
+
the fix to skip __schema__.json files.
|
|
210
|
+
"""
|
|
211
|
+
mock_handler = MagicMock()
|
|
212
|
+
watcher = TasksWatcher(handlers=[mock_handler])
|
|
213
|
+
|
|
214
|
+
# Create a __schema__.json file with the actual structure
|
|
215
|
+
# that FileSystemJsonTables creates
|
|
216
|
+
schema_json = {
|
|
217
|
+
"a8a61558-625d-483e-82f9-0d996ac19367": {
|
|
218
|
+
"table_name": "data",
|
|
219
|
+
"columns": [
|
|
220
|
+
{
|
|
221
|
+
"id": "50def2fe-1731-4467-a936-e5ead2d84a5e",
|
|
222
|
+
"name": "id",
|
|
223
|
+
"schema": {"type": "string"},
|
|
224
|
+
"is_primary_key": True,
|
|
225
|
+
"default": None,
|
|
226
|
+
},
|
|
227
|
+
{
|
|
228
|
+
"id": "ee553b31-4594-45f7-b6c0-c613c5e2548b",
|
|
229
|
+
"name": "type",
|
|
230
|
+
"schema": {"type": "string"},
|
|
231
|
+
"is_primary_key": False,
|
|
232
|
+
"default": None,
|
|
233
|
+
},
|
|
234
|
+
],
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
schema_file = self.tasks_dir / "__schema__.json"
|
|
239
|
+
schema_file.write_text(json.dumps(schema_json))
|
|
240
|
+
|
|
241
|
+
# This should NOT raise any error - the file should be ignored
|
|
242
|
+
# Currently this will FAIL because the watcher tries to parse it
|
|
243
|
+
try:
|
|
244
|
+
watcher._handle_file_event(schema_file)
|
|
245
|
+
# If we get here without error, the handler should NOT have been called
|
|
246
|
+
mock_handler.assert_not_called()
|
|
247
|
+
except ValidationError:
|
|
248
|
+
self.fail(
|
|
249
|
+
"TasksWatcher should ignore __schema__.json files but raised ValidationError"
|
|
250
|
+
)
|
|
251
|
+
|
|
252
|
+
|
|
253
|
+
if __name__ == "__main__":
|
|
254
|
+
unittest.main()
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{d as c,c as b,a as r,b as o,u as n,eG as d,ed as g,o as i,f as l,dj as p,ae as u,h as f,eH as m,bY as y,b0 as _}from"./jwt-decode.esm.4071145e.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},e=new Error().stack;e&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[e]="a1aa7c0d-ea92-4be5-9b04-610a61b8cf63",t._sentryDebugIdIdentifier="sentry-dbid-a1aa7c0d-ea92-4be5-9b04-610a61b8cf63")}catch{}})();const h=c({__name:"AbstraButton",props:{disabledTooltip:{},tooltip:{},prefixCls:{},type:{},htmlType:{},shape:{},size:{},loading:{type:[Boolean,Object]},disabled:{type:Boolean},ghost:{type:Boolean},block:{type:Boolean},danger:{type:Boolean},icon:{},href:{},target:{},title:{},onClick:{type:[Function,Array]},onMousedown:{type:[Function,Array]}},setup(t){const e=t,s=b(()=>e.disabledTooltip&&e.disabled?e.disabledTooltip:e.tooltip);return(a,k)=>s.value?(i(),r(n(_),{key:0,title:s.value},{default:o(()=>[l(n(y),d(m(a.$props)),{default:o(()=>[l(n(p),{style:{display:"flex","align-items":"center","justify-content":"center",gap:"5px"}},{default:o(()=>[a.loading?f("",!0):u(a.$slots,"default",{key:0})]),_:3})]),_:3},16)]),_:3},8,["title"])):(i(),r(n(y),d(g({key:1},a.$props)),{default:o(()=>[l(n(p),{style:{display:"flex","align-items":"center","justify-content":"center",gap:"5px"}},{default:o(()=>[a.loading?f("",!0):u(a.$slots,"default",{key:0})]),_:3})]),_:3},16))}});export{h as _};
|
|
2
|
+
//# sourceMappingURL=AbstraButton.vue_vue_type_script_setup_true_lang.905e8d9e.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{L as t}from"./Logo.417950ea.js";import{d as n,o as r,a as d,u as i}from"./jwt-decode.esm.4071145e.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},a=new Error().stack;a&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[a]="8df65b38-8401-459d-a341-aaa6cc884198",e._sentryDebugIdIdentifier="sentry-dbid-8df65b38-8401-459d-a341-aaa6cc884198")}catch{}})();const f="/assets/logo.0faadfa2.svg",c=n({__name:"AbstraLogo",props:{hideText:{type:Boolean},size:{}},setup(e){return(a,o)=>{var s;return r(),d(t,{"image-url":i(f),"brand-name":"Abstra","hide-text":a.hideText,size:(s=a.size)!=null?s:"small"},null,8,["image-url","hide-text","size"])}}});export{c as _};
|
|
2
|
+
//# sourceMappingURL=AbstraLogo.vue_vue_type_script_setup_true_lang.11067aac.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{C as x}from"./CrudView.391f0e9f.js";import{d as I,r as A,i as e,ei as C,c as h,ac as D,f as p,u as t,b as c,aY as M,o as P,de as T,g as y,t as f,df as j,M as V,ek as B,er as E}from"./jwt-decode.esm.4071145e.js";import{a as N}from"./asyncComputed.0308626b.js";import{A as d}from"./apiKey.1b1aafc4.js";import"./router.ef7a08cf.js";import{M as $}from"./member.d4cf4c10.js";import{a as z}from"./project.794c2cba.js";import"./tables.59457dad.js";import"./DocsButton.vue_vue_type_script_setup_true_lang.e6d1d3ad.js";import"./constants.ba2d8460.js";import"./url.4aa6f272.js";import"./PhDotsThreeVertical.vue.b3fda5f6.js";import"./index.c25fb6e2.js";import"./index.fd17682d.js";import"./record.daabed01.js";import"./string.0157e442.js";(function(){try{var s=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},o=new Error().stack;o&&(s._sentryDebugIds=s._sentryDebugIds||{},s._sentryDebugIds[o]="f6bef780-6505-40be-8ec8-ae21a48e6cc8",s._sentryDebugIdIdentifier="sentry-dbid-f6bef780-6505-40be-8ec8-ae21a48e6cc8")}catch{}})();const te=I({__name:"ApiKeys",setup(s){const o=A(null),_=[{key:"name",label:e.translate("i18n_apikeysview_field_name")}],l=C().params.projectId,w=new $,{loading:v,result:k,refetch:m}=N(async()=>Promise.all([d.list(l),z.get(l).then(a=>w.list(a.organizationId))]).then(([a,n])=>a.map(i=>({apiKey:i,member:n.find(r=>r.authorId===i.ownerId)})))),b=async a=>{const n=await d.create({projectId:l,name:a.name});m(),o.value=n.value},g=h(()=>{var a,n;return{columns:[{title:e.translate("i18n_apikeysview_column_name")},{title:e.translate("i18n_apikeysview_column_creation_date")},{title:e.translate("i18n_apikeysview_column_owner")},{title:"",align:"right"}],rows:(n=(a=k.value)==null?void 0:a.map(({apiKey:i,member:r})=>{var u;return{key:i.id,cells:[{type:"text",text:i.name},{type:"text",text:B(i.createdAt)},{type:"text",text:(u=r==null?void 0:r.email)!=null?u:e.translate("i18n_apikeysview_owner_unknown")},{type:"actions",actions:[{label:e.translate("i18n_apikeysview_action_delete"),icon:E,dangerous:!0,onClick:async()=>{await d.delete(l,i.id),m()}}]}]}}))!=null?n:[]}});return(a,n)=>(P(),D(M,null,[p(x,{"entity-name":t(e).translate("i18n_apikeysview_entity_name"),"create-button-text":t(e).translate("i18n_apikeysview_create_button"),loading:t(v),title:t(e).translate("i18n_apikeysview_title"),description:t(e).translate("i18n_apikeysview_description"),"empty-title":t(e).translate("i18n_apikeysview_empty_title"),table:g.value,fields:_,create:b},null,8,["entity-name","create-button-text","loading","title","description","empty-title","table"]),p(t(V),{open:!!o.value,title:t(e).translate("i18n_apikeysview_modal_title"),onCancel:n[0]||(n[0]=i=>o.value=null)},{footer:c(()=>[]),default:c(()=>[p(t(T),null,{default:c(()=>[y(f(t(e).translate("i18n_apikeysview_modal_description")),1)]),_:1}),p(t(j),{code:"",copyable:""},{default:c(()=>[y(f(o.value),1)]),_:1})]),_:1},8,["open","title"])],64))}});export{te as default};
|
|
2
|
+
//# sourceMappingURL=ApiKeys.c2a1c483.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import"./App.vue_vue_type_style_index_0_lang.8bbdcede.js";import{_ as u}from"./App.vue_vue_type_style_index_0_lang.8bbdcede.js";import"./userStore.1004ebc1.js";import"./jwt-decode.esm.4071145e.js";import"./PlayerConfigProvider.f7be8491.js";import"./colorHelpers.93df70ab.js";import"./workspaceStore.260ac7fc.js";import"./url.4aa6f272.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},d=new Error().stack;d&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[d]="8a935d7a-939d-43df-a639-6ba6c93de425",e._sentryDebugIdIdentifier="sentry-dbid-8a935d7a-939d-43df-a639-6ba6c93de425")}catch{}})();export{u as default};
|
|
2
|
+
//# sourceMappingURL=App.608af2ed.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{u as r}from"./userStore.1004ebc1.js";import{W as n}from"./PlayerConfigProvider.f7be8491.js";import{u as c}from"./workspaceStore.260ac7fc.js";import{d as f,w as i,j as p,u as o,a as u,b as d,h as l,o as m,f as _}from"./jwt-decode.esm.4071145e.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},a=new Error().stack;a&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[a]="3f0a697e-0be1-4132-8732-7afe69fabbbf",t._sentryDebugIdIdentifier="sentry-dbid-3f0a697e-0be1-4132-8732-7afe69fabbbf")}catch{}})();const v=f({__name:"App",setup(t){const a=r(),e=c();return e.actions.fetch(),i(()=>a.jwt,e.actions.fetch),(b,w)=>{const s=p("RouterView");return o(e).state.workspace?(m(),u(n,{key:0,"main-color":o(e).state.workspace.mainColor,background:o(e).state.workspace.theme,"font-family":o(e).state.workspace.fontFamily,locale:o(e).state.workspace.language},{default:d(()=>[_(s,{style:{height:"100vh",width:"100%"}})]),_:1},8,["main-color","background","font-family","locale"])):l("",!0)}}});export{v as _};
|
|
2
|
+
//# sourceMappingURL=App.vue_vue_type_style_index_0_lang.8bbdcede.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{_ as c,o,ac as n,ae as s,e as d,h as a}from"./jwt-decode.esm.
|
|
2
|
-
//# sourceMappingURL=BaseLayout.
|
|
1
|
+
import{_ as c,o,ac as n,ae as s,e as d,h as a}from"./jwt-decode.esm.4071145e.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},t=new Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="1213460a-d379-4453-92d8-a6dfc81740ad",e._sentryDebugIdIdentifier="sentry-dbid-1213460a-d379-4453-92d8-a6dfc81740ad")}catch{}})();const r={},i={class:"base-layout"},_={class:"base-middle"},l={class:"content"},u={class:"left"},f={key:0,class:"base-footer"},y={key:0};function b(e,t){return o(),n("div",i,[s(e.$slots,"sidebar",{},void 0,!0),d("section",_,[s(e.$slots,"navbar",{},void 0,!0),d("section",l,[d("section",u,[s(e.$slots,"content",{},void 0,!0),e.$slots.footer?(o(),n("section",f,[s(e.$slots,"footer",{},void 0,!0)])):a("",!0)]),e.$slots.chat?(o(),n("section",y,[s(e.$slots,"chat",{},void 0,!0)])):a("",!0)])])])}const g=c(r,[["render",b],["__scopeId","data-v-da85ecdc"]]);export{g as B};
|
|
2
|
+
//# sourceMappingURL=BaseLayout.b03df2cd.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a as w}from"./asyncComputed.0308626b.js";import{d as h,ei as k,U as I,u as e,a as l,ac as x,f as n,b as t,h as C,o,A as _,g as c,t as s,i as u,bY as v,dj as f,e as z}from"./jwt-decode.esm.4071145e.js";import{o as m,c as B}from"./router.ef7a08cf.js";import{a as D}from"./organization.1b235ed0.js";import"./tables.59457dad.js";import{L as N}from"./LoadingContainer.e7fd3862.js";import"./index.fd17682d.js";import"./record.daabed01.js";import"./string.0157e442.js";(function(){try{var a=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},i=new Error().stack;i&&(a._sentryDebugIds=a._sentryDebugIds||{},a._sentryDebugIds[i]="397fd8b7-c34f-4c61-88e9-d780f42df530",a._sentryDebugIdIdentifier="sentry-dbid-397fd8b7-c34f-4c61-88e9-d780f42df530")}catch{}})();const U={key:1},j=["src"],O=h({__name:"Billing",setup(a){const p=k().params.organizationId,{loading:y,result:r}=w(async()=>{const d=await D.get(p),g=await d.getUsageReportUrl();return{organization:d,reportUrl:g}});I(()=>{location.search.includes("upgrade")&&m.showNewMessage("I want to upgrade my plan")});const b=()=>m.showNewMessage("I want to upgrade my plan");return(d,g)=>e(y)?(o(),l(N,{key:0})):e(r)?(o(),x("div",U,[n(e(f),{justify:"space-between",align:"center"},{default:t(()=>[n(e(_),{level:3},{default:t(()=>[c(s(e(u).translate("i18n_billing_current_plan"))+" "+s(e(r).organization.coalescedPlan),1)]),_:1}),n(e(v),{type:"primary",onClick:b},{default:t(()=>[c(s(e(u).translate("i18n_billing_upgrade")),1)]),_:1})]),_:1}),n(e(B),{style:{"margin-top":"0"}}),e(r).organization.hasUsageReport?(o(),l(e(f),{key:0,align:"center",justify:"center"},{default:t(()=>[z("iframe",{src:e(r).reportUrl,frameborder:"0",style:{width:"1000px",height:"1700px"}},null,8,j)]),_:1})):(o(),l(e(f),{key:1,align:"center",justify:"center"},{default:t(()=>[n(e(_),{level:4},{default:t(()=>[c(s(e(u).translate("i18n_billing_no_usage_report")),1)]),_:1})]),_:1}))])):C("",!0)}});export{O as default};
|
|
2
|
+
//# sourceMappingURL=Billing.f84cedb5.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import{d as O,an as w,b_ as _,f as c,aq as f,aC as R,az as A,eb as j,bu as D,bW as P,ai as z,aj as E,W as B,au as M,e2 as X,aK as N,aG as H,dF as L,bE as F}from"./jwt-decode.esm.
|
|
1
|
+
import{d as O,an as w,b_ as _,f as c,aq as f,aC as R,az as A,eb as j,bu as D,bW as P,ai as z,aj as E,W as B,au as M,e2 as X,aK as N,aG as H,dF as L,bE as F}from"./jwt-decode.esm.4071145e.js";(function(){try{var r=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},e=new Error().stack;e&&(r._sentryDebugIds=r._sentryDebugIds||{},r._sentryDebugIds[e]="d378c493-a109-48c2-a8fc-585ceeb25a8e",r._sentryDebugIdIdentifier="sentry-dbid-d378c493-a109-48c2-a8fc-585ceeb25a8e")}catch{}})();var U=globalThis&&globalThis.__rest||function(r,e){var a={};for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.indexOf(n)<0&&(a[n]=r[n]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var t=0,n=Object.getOwnPropertySymbols(r);t<n.length;t++)e.indexOf(n[t])<0&&Object.prototype.propertyIsEnumerable.call(r,n[t])&&(a[n[t]]=r[n[t]]);return a};const W=()=>({prefixCls:String,href:String,separator:R.any,dropdownProps:A(),overlay:R.any,onClick:j()}),K=O({compatConfig:{MODE:3},name:"ABreadcrumbItem",inheritAttrs:!1,__ANT_BREADCRUMB_ITEM:!0,props:W(),slots:Object,setup(r,e){let{slots:a,attrs:n,emit:t}=e;const{prefixCls:u}=w("breadcrumb",r),y=(d,h)=>{const b=_(a,r,"overlay");return b?c(P,f(f({},r.dropdownProps),{},{overlay:b,placement:"bottom"}),{default:()=>[c("span",{class:`${h}-overlay-link`},[d,c(D,null,null)])]}):d},I=d=>{t("click",d)};return()=>{var d;const h=(d=_(a,r,"separator"))!==null&&d!==void 0?d:"/",b=_(a,r),{class:l,style:s}=n,o=U(n,["class","style"]);let i;return r.href!==void 0?i=c("a",f({class:`${u.value}-link`,onClick:I},o),[b]):i=c("span",f({class:`${u.value}-link`,onClick:I},o),[b]),i=y(i,u.value),b!=null?c("li",{class:l,style:s},[i,h&&c("span",{class:`${u.value}-separator`},[h])]):null}}}),V=r=>{const{componentCls:e,iconCls:a}=r;return{[e]:B(B({},M(r)),{color:r.breadcrumbBaseColor,fontSize:r.breadcrumbFontSize,[a]:{fontSize:r.breadcrumbIconFontSize},ol:{display:"flex",flexWrap:"wrap",margin:0,padding:0,listStyle:"none"},a:B({color:r.breadcrumbLinkColor,transition:`color ${r.motionDurationMid}`,padding:`0 ${r.paddingXXS}px`,borderRadius:r.borderRadiusSM,height:r.lineHeight*r.fontSize,display:"inline-block",marginInline:-r.marginXXS,"&:hover":{color:r.breadcrumbLinkColorHover,backgroundColor:r.colorBgTextHover}},X(r)),["li:last-child"]:{color:r.breadcrumbLastItemColor,[`& > ${e}-separator`]:{display:"none"}},[`${e}-separator`]:{marginInline:r.breadcrumbSeparatorMargin,color:r.breadcrumbSeparatorColor},[`${e}-link`]:{[`
|
|
2
2
|
> ${a} + span,
|
|
3
3
|
> ${a} + a
|
|
4
4
|
`]:{marginInlineStart:r.marginXXS}},[`${e}-overlay-link`]:{borderRadius:r.borderRadiusSM,height:r.lineHeight*r.fontSize,display:"inline-block",padding:`0 ${r.paddingXXS}px`,marginInline:-r.marginXXS,[`> ${a}`]:{marginInlineStart:r.marginXXS,fontSize:r.fontSizeIcon},"&:hover":{color:r.breadcrumbLinkColorHover,backgroundColor:r.colorBgTextHover,a:{color:r.breadcrumbLinkColorHover}},a:{"&:hover":{backgroundColor:"transparent"}}},[`&${r.componentCls}-rtl`]:{direction:"rtl"}})}},q=z("Breadcrumb",r=>{const e=E(r,{breadcrumbBaseColor:r.colorTextDescription,breadcrumbFontSize:r.fontSize,breadcrumbIconFontSize:r.fontSize,breadcrumbLinkColor:r.colorTextDescription,breadcrumbLinkColorHover:r.colorText,breadcrumbLastItemColor:r.colorText,breadcrumbSeparatorMargin:r.marginXS,breadcrumbSeparatorColor:r.colorTextDescription});return[V(e)]}),G=()=>({prefixCls:String,routes:{type:Array},params:R.any,separator:R.any,itemRender:{type:Function}});function J(r,e){if(!r.breadcrumbName)return null;const a=Object.keys(e).join("|");return r.breadcrumbName.replace(new RegExp(`:(${a})`,"g"),(t,u)=>e[u]||t)}function T(r){const{route:e,params:a,routes:n,paths:t}=r,u=n.indexOf(e)===n.length-1,y=J(e,a);return u?c("span",null,[y]):c("a",{href:`#/${t.join("/")}`},[y])}const Y=O({compatConfig:{MODE:3},name:"ABreadcrumb",inheritAttrs:!1,props:G(),slots:Object,setup(r,e){let{slots:a,attrs:n}=e;const{prefixCls:t,direction:u}=w("breadcrumb",r),[y,I]=q(t),d=(l,s)=>(l=(l||"").replace(/^\//,""),Object.keys(s).forEach(o=>{l=l.replace(`:${o}`,s[o])}),l),h=(l,s,o)=>{const i=[...l],m=d(s||"",o);return m&&i.push(m),i},b=l=>{let{routes:s=[],params:o={},separator:i,itemRender:m=T}=l;const S=[];return s.map(p=>{const C=d(p.path,o);C&&S.push(C);const g=[...S];let v=null;p.children&&p.children.length&&(v=c(F,{items:p.children.map(x=>({key:x.path||x.breadcrumbName,label:m({route:x,params:o,routes:s,paths:h(g,x.path,o)})}))},null));const $={separator:i};return v&&($.overlay=v),c(K,f(f({},$),{},{key:C||p.breadcrumbName}),{default:()=>[m({route:p,params:o,routes:s,paths:g})]})})};return()=>{var l;let s;const{routes:o,params:i={}}=r,m=N(_(a,r)),S=(l=_(a,r,"separator"))!==null&&l!==void 0?l:"/",p=r.itemRender||a.itemRender||T;o&&o.length>0?s=b({routes:o,params:i,separator:S,itemRender:p}):m.length&&(s=m.map((g,v)=>(H(typeof g.type=="object"&&(g.type.__ANT_BREADCRUMB_ITEM||g.type.__ANT_BREADCRUMB_SEPARATOR)),L(g,{separator:S,key:v}))));const C={[t.value]:!0,[`${t.value}-rtl`]:u.value==="rtl",[`${n.class}`]:!!n.class,[I.value]:!0};return y(c("nav",f(f({},n),{},{class:C}),[c("ol",null,[s])]))}}});export{K as A,Y as B};
|
|
5
|
-
//# sourceMappingURL=Breadcrumb.
|
|
5
|
+
//# sourceMappingURL=Breadcrumb.9686bc9b.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{C as F}from"./CrudView.ca91f805.js";import{d as I,at as Z,c as P,o as c,ac as h,ae as K,h as C,ed as H,e as A,f as u,ee as j,f7 as q,ec as U,a as f,b as s,u as e,bW as W,bE as Q,bD as Y,df as k,g as b,t as y,i as g,cC as J,ei as X,U as ee,R as te,r as ae,aY as ne,b0 as le,cS as re,de as ie,ad as se,d9 as oe,S as ue,M as ce,ek as de,_ as pe}from"./jwt-decode.esm.32f71954.js";import{a as V}from"./asyncComputed.f9fa4c71.js";import{g as fe}from"./datetime.cf8e211d.js";import{u as me}from"./polling.ca800fea.js";import{G as ge}from"./PhArrowCounterClockwise.vue.dbc4fdc7.js";import{H as _e}from"./PhCube.vue.6a150c53.js";import{G as be}from"./PhDownloadSimple.vue.2759a067.js";import{f as ye,e as ve,r as he}from"./router.29e08ea4.js";import{a as Ce,B as ke}from"./build.c626214a.js";import{a as Ae}from"./project.b14b799c.js";import"./tables.94d324c3.js";import{G as Oe}from"./PhClockCounterClockwise.vue.15ff64b9.js";import{F as we,a as Se,G as Pe,I as xe}from"./PhWebhooksLogo.vue.13c489ce.js";import{A as M}from"./index.c59ca45b.js";import{E as Ze}from"./ExclamationCircleOutlined.380af12e.js";import{C as Me}from"./CloseCircleOutlined.fdea1f27.js";import{L as $}from"./LoadingOutlined.6f7bdc44.js";import"./DocsButton.vue_vue_type_script_setup_true_lang.c50f6a0a.js";import"./constants.b5d83622.js";import"./url.79cc02c3.js";import"./PhDotsThreeVertical.vue.e305b3a2.js";import"./index.2400150a.js";import"./record.41c9caee.js";import"./string.ff0b4ef9.js";(function(){try{var l=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},t=new Error().stack;t&&(l._sentryDebugIds=l._sentryDebugIds||{},l._sentryDebugIds[t]="e1496116-bd74-495d-a380-b1d033eca9dc",l._sentryDebugIdIdentifier="sentry-dbid-e1496116-bd74-495d-a380-b1d033eca9dc")}catch{}})();var $e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M696 480H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8h368c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8z"}},{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}}]},name:"minus-circle",theme:"outlined"};const Ie=$e;var je={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372zm-88-532h-48c-4.4 0-8 3.6-8 8v304c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V360c0-4.4-3.6-8-8-8zm224 0h-48c-4.4 0-8 3.6-8 8v304c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V360c0-4.4-3.6-8-8-8z"}}]},name:"pause-circle",theme:"outlined"};const ze=je,Be=["width","height","fill","transform"],De={key:0},Ee=A("path",{d:"M128,20A108,108,0,1,0,236,128,108.12,108.12,0,0,0,128,20Zm0,192a84,84,0,1,1,84-84A84.09,84.09,0,0,1,128,212Zm-16-84a16,16,0,1,1-16-16A16,16,0,0,1,112,128Zm64,0a16,16,0,1,1-16-16A16,16,0,0,1,176,128Z"},null,-1),Ve=[Ee],Ne={key:1},Te=A("path",{d:"M224,128a96,96,0,1,1-96-96A96,96,0,0,1,224,128Z",opacity:"0.2"},null,-1),Ge=A("path",{d:"M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm0,192a88,88,0,1,1,88-88A88.1,88.1,0,0,1,128,216Zm56-88a12,12,0,1,1-12-12A12,12,0,0,1,184,128Zm-44,0a12,12,0,1,1-12-12A12,12,0,0,1,140,128Zm-44,0a12,12,0,1,1-12-12A12,12,0,0,1,96,128Z"},null,-1),Le=[Te,Ge],Re={key:2},Fe=A("path",{d:"M128,24A104,104,0,1,0,232,128,104.13,104.13,0,0,0,128,24ZM84,140a12,12,0,1,1,12-12A12,12,0,0,1,84,140Zm44,0a12,12,0,1,1,12-12A12,12,0,0,1,128,140Zm44,0a12,12,0,1,1,12-12A12,12,0,0,1,172,140Z"},null,-1),Ke=[Fe],He={key:3},qe=A("path",{d:"M128,26A102,102,0,1,0,230,128,102.12,102.12,0,0,0,128,26Zm0,192a90,90,0,1,1,90-90A90.1,90.1,0,0,1,128,218Zm10-90a10,10,0,1,1-10-10A10,10,0,0,1,138,128Zm-44,0a10,10,0,1,1-10-10A10,10,0,0,1,94,128Zm88,0a10,10,0,1,1-10-10A10,10,0,0,1,182,128Z"},null,-1),Ue=[qe],We={key:4},Qe=A("path",{d:"M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm0,192a88,88,0,1,1,88-88A88.1,88.1,0,0,1,128,216Zm12-88a12,12,0,1,1-12-12A12,12,0,0,1,140,128Zm44,0a12,12,0,1,1-12-12A12,12,0,0,1,184,128Zm-88,0a12,12,0,1,1-12-12A12,12,0,0,1,96,128Z"},null,-1),Ye=[Qe],Je={key:5},Xe=A("path",{d:"M128,28A100,100,0,1,0,228,128,100.11,100.11,0,0,0,128,28Zm0,192a92,92,0,1,1,92-92A92.1,92.1,0,0,1,128,220Zm8-92a8,8,0,1,1-8-8A8,8,0,0,1,136,128Zm-44,0a8,8,0,1,1-8-8A8,8,0,0,1,92,128Zm88,0a8,8,0,1,1-8-8A8,8,0,0,1,180,128Z"},null,-1),et=[Xe],tt={name:"PhDotsThreeCircle"},at=I({...tt,props:{weight:{type:String},size:{type:[String,Number]},color:{type:String},mirrored:{type:Boolean}},setup(l){const t=l,n=Z("weight","regular"),d=Z("size","1em"),o=Z("color","currentColor"),x=Z("mirrored",!1),p=P(()=>{var m;return(m=t.weight)!=null?m:n}),w=P(()=>{var m;return(m=t.size)!=null?m:d}),v=P(()=>{var m;return(m=t.color)!=null?m:o}),O=P(()=>t.mirrored!==void 0?t.mirrored?"scale(-1, 1)":void 0:x?"scale(-1, 1)":void 0);return(m,E)=>(c(),h("svg",H({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 256 256",width:w.value,height:w.value,fill:v.value,transform:O.value},m.$attrs),[K(m.$slots,"default"),p.value==="bold"?(c(),h("g",De,Ve)):p.value==="duotone"?(c(),h("g",Ne,Le)):p.value==="fill"?(c(),h("g",Re,Ke)):p.value==="light"?(c(),h("g",He,Ue)):p.value==="regular"?(c(),h("g",We,Ye)):p.value==="thin"?(c(),h("g",Je,et)):C("",!0)],16,Be))}});function N(l){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},d=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(d=d.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),d.forEach(function(o){nt(l,o,n[o])})}return l}function nt(l,t,n){return t in l?Object.defineProperty(l,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):l[t]=n,l}var z=function(t,n){var d=N({},t,n.attrs);return u(j,N({},d,{icon:q}),null)};z.displayName="CheckCircleOutlined";z.inheritAttrs=!1;const lt=z;function T(l){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},d=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(d=d.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),d.forEach(function(o){rt(l,o,n[o])})}return l}function rt(l,t,n){return t in l?Object.defineProperty(l,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):l[t]=n,l}var B=function(t,n){var d=T({},t,n.attrs);return u(j,T({},d,{icon:Ie}),null)};B.displayName="MinusCircleOutlined";B.inheritAttrs=!1;const it=B;function G(l){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},d=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(d=d.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),d.forEach(function(o){st(l,o,n[o])})}return l}function st(l,t,n){return t in l?Object.defineProperty(l,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):l[t]=n,l}var D=function(t,n){var d=G({},t,n.attrs);return u(j,G({},d,{icon:ze}),null)};D.displayName="PauseCircleOutlined";D.inheritAttrs=!1;const ot=D,ut={style:{display:"flex","align-items":"center",gap:"5px"}},ct={key:1},dt=I({__name:"BuildInspector",props:{buildSpec:{}},setup(l){const t=l,n=U(),d=o=>{n.push({name:"logs",params:{projectId:t.buildSpec.projectId},query:o.logQuery})};return(o,x)=>o.buildSpec.runtimes.length>0?(c(),f(e(ve),{key:0,"item-layout":"horizontal","data-source":o.buildSpec.runtimes},{renderItem:s(({item:p})=>[u(e(ye),null,{actions:s(()=>[u(e(W),null,{overlay:s(()=>[u(e(Q),null,{default:s(()=>[u(e(Y),{onClick:w=>d(p)},{default:s(()=>[A("div",ut,[u(e(Oe)),u(e(k),null,{default:s(()=>[b(y(e(g).translate("i18n_build_inspector_view_logs",null)),1)]),_:1})])]),_:2},1032,["onClick"])]),_:2},1024)]),default:s(()=>[u(e(at),{style:{cursor:"pointer"}})]),_:2},1024)]),default:s(()=>[p.type=="form"?(c(),f(e(M),{key:0,size:"large"},{default:s(()=>[u(e(we)),u(e(k),{strong:""},{default:s(()=>[b(y(p.title),1)]),_:2},1024),u(e(k),{type:"secondary",code:""},{default:s(()=>[b("/"+y(p.path),1)]),_:2},1024)]),_:2},1024)):C("",!0),p.type=="job"?(c(),f(e(M),{key:1,size:"large"},{default:s(()=>[u(e(Se)),u(e(k),{strong:""},{default:s(()=>[b(y(p.title),1)]),_:2},1024),u(e(k),{type:"secondary",code:""},{default:s(()=>[b(y(p.schedule),1)]),_:2},1024)]),_:2},1024)):C("",!0),p.type=="hook"?(c(),f(e(M),{key:2,size:"large"},{default:s(()=>[u(e(Pe)),u(e(k),{strong:""},{default:s(()=>[b(y(p.title),1)]),_:2},1024),u(e(k),{type:"secondary",code:""},{default:s(()=>[b("/_hooks/"+y(p.path),1)]),_:2},1024)]),_:2},1024)):C("",!0),p.type=="script"?(c(),f(e(M),{key:3,size:"large"},{default:s(()=>[u(e(xe)),u(e(k),{strong:""},{default:s(()=>[b(y(p.title),1)]),_:2},1024)]),_:2},1024)):C("",!0)]),_:2},1024)]),_:1},8,["data-source"])):(c(),h("div",ct,[u(e(J),{description:e(g).translate("i18n_build_inspector_no_runtimes",null)},null,8,["description"])]))}}),pt=I({__name:"Builds",setup(l){const n=X().params.projectId,{loading:d,result:o,refetch:x}=V(async()=>{const[a,r]=await Promise.all([Ce.list(n),Ae.getStatus(n)]);return{b:a.map(_=>({build:_,status:r.filter(S=>S.buildId==_.id).map(S=>S.status)})),status:r}}),{startPolling:p,endPolling:w}=me({task:x,interval:1e4});ee(()=>p()),te(()=>w());const v=ae(null),O=V(async()=>v.value?await ke.get(v.value):null),m=()=>{var i;const a=(i=o.value)==null?void 0:i.b.find(_=>_.build.id===v.value);return`Version ${a==null?void 0:a.build.id.slice(0,8)} - ${a==null?void 0:a.build.createdAt.toLocaleString()}`},E=[{translationKey:"i18n_builds_deploying",tagColor:"blue",check:a=>{var r,i;return(i=a.build.latest&&a.status.some(_=>_=="Running")&&((r=o.value)==null?void 0:r.status.some(_=>_.buildId!==a.build.id)))!=null?i:!1},loading:!0},{translationKey:"i18n_builds_deactivating",tagColor:"orange",check:a=>a.build.status==="success"&&!a.build.latest&&a.status.some(r=>r=="Running"),loading:!0},{translationKey:"i18n_builds_live",tagColor:"green",check:a=>a.build.latest&&a.status.some(r=>r=="Running")},{translationKey:"i18n_builds_sleeping",tagColor:"cyan",check:a=>a.build.latest&&a.status.length===0},{translationKey:"i18n_builds_failed",tagColor:"red",check:a=>a.build.latest&&a.status.some(r=>r=="Failed")},{translationKey:"i18n_builds_inactive",tagColor:"default",check:a=>a.build.status==="success"},{translationKey:"i18n_builds_aborted",tagColor:"default",check:a=>a.build.status==="aborted"||a.build.status==="aborted-by-user"},{translationKey:"i18n_builds_failed",tagColor:"orange",check:a=>a.build.status==="failure"},{translationKey:"i18n_builds_deploying",tagColor:"blue",check:a=>a.build.status==="in-progress",loading:!0},{translationKey:"i18n_builds_uploading",tagColor:"yellow",check:a=>a.build.status==="pending"}];function L(a){var i,_;const r=E.find(S=>S.check(a));return{text:r?g.translate(r.translationKey):"unknown",tagColor:(i=r==null?void 0:r.tagColor)!=null?i:"default",hover:(_=a.build.log)!=null?_:void 0}}const R=P(()=>{const a=[{title:g.translate("i18n_builds_id")},{title:g.translate("i18n_builds_date")},{title:g.translate("i18n_builds_abstra_version")},{title:g.translate("i18n_builds_status")},{title:"",align:"right"}];return o.value?{columns:a,rows:o.value.b.map(r=>{var i;return{key:r.build.id,cells:[{type:"text",text:r.build.id.slice(0,8)},{key:"date",type:"slot",payload:{date:fe(r.build.createdAt,{weekday:void 0}),distance:de(r.build.createdAt)}},{type:"text",text:(i=r.build.abstraVersion)!=null?i:"-"},{key:"status",type:"slot",payload:L(r)},{type:"actions",actions:[{icon:_e,label:g.translate("i18n_builds_inspect_version"),onClick:async()=>{v.value=r.build.id,O.refetch()}},{icon:ge,label:g.translate("i18n_builds_view_application_logs"),onClick:()=>{he.push({name:"logs",params:{projectId:n},query:{buildId:r.build.id}})}},{icon:be,label:g.translate("i18n_builds_download_files"),onClick:()=>r.build.download()}]}]}})}:{columns:a,rows:[]}});return(a,r)=>(c(),h(ne,null,[u(F,{"entity-name":"build",loading:e(d),title:e(g).translate("i18n_builds_version_history"),description:e(g).translate("i18n_builds_description"),"empty-title":e(g).translate("i18n_builds_empty_title"),table:R.value,live:""},{date:s(({payload:i})=>[u(e(le),null,{title:s(()=>[b(y(i.distance),1)]),default:s(()=>[b(y(i.date)+" ",1)]),_:2},1024)]),status:s(({payload:i})=>[u(e(re),{open:i.hover?void 0:!1},{content:s(()=>[u(e(ie),{style:{width:"300px",overflow:"auto","font-family":"monospace"},content:i.hover,copyable:""},null,8,["content"])]),default:s(()=>[i.text!=="unknown"?(c(),f(e(oe),{key:0,color:i.tagColor,style:se({cursor:i.hover?"pointer":"default"})},{default:s(()=>[i.text==="Live"?(c(),f(e(lt),{key:0})):i.text==="Inactive"?(c(),f(e(it),{key:1})):i.text==="Failed"?(c(),f(e(Ze),{key:2})):i.text==="Aborted"?(c(),f(e(Me),{key:3})):i.text==="Sleeping"?(c(),f(e(ot),{key:4})):i.text==="Uploading"?(c(),f(e($),{key:5})):i.text==="Deploying"?(c(),f(e($),{key:6})):i.text==="Deactivating"?(c(),f(e($),{key:7})):C("",!0),b(" "+y(i.text),1)]),_:2},1032,["color","style"])):C("",!0)]),_:2},1032,["open"])]),_:1},8,["loading","title","description","empty-title","table"]),v.value?(c(),f(e(ce),{key:0,footer:null,open:!!v.value,size:"large",width:"80%",title:m(),onCancel:r[0]||(r[0]=i=>v.value=null)},{default:s(()=>[!e(O).result.value||e(O).loading.value?(c(),f(e(ue),{key:0})):e(O).result.value?(c(),f(dt,{key:1,"build-spec":e(O).result.value},null,8,["build-spec"])):C("",!0)]),_:1},8,["open","title"])):C("",!0)],64))}});const Vt=pe(pt,[["__scopeId","data-v-cfc16bae"]]);export{Vt as default};
|
|
2
|
-
//# sourceMappingURL=Builds.
|
|
1
|
+
import{C as F}from"./CrudView.391f0e9f.js";import{d as I,at as Z,c as P,o as c,ac as h,ae as K,h as C,ed as H,e as A,f as u,ee as j,f7 as q,ec as U,a as f,b as s,u as e,bW as W,bE as Q,bD as Y,df as k,g as _,t as y,i as g,cC as J,ei as X,U as ee,R as te,r as ae,aY as ne,b0 as le,cS as re,de as ie,ad as se,d9 as oe,S as ue,M as ce,ek as de,_ as pe}from"./jwt-decode.esm.4071145e.js";import{a as V}from"./asyncComputed.0308626b.js";import{g as fe}from"./datetime.049cd1b4.js";import{u as me}from"./polling.cabdf3a3.js";import{G as ge}from"./PhArrowCounterClockwise.vue.44a61827.js";import{H as be}from"./PhCube.vue.3f7281ae.js";import{G as _e}from"./PhDownloadSimple.vue.db22067f.js";import{f as ye,e as ve,r as he}from"./router.ef7a08cf.js";import{a as Ce,B as ke}from"./build.1cc9147c.js";import{a as Ae}from"./project.794c2cba.js";import"./tables.59457dad.js";import{G as Oe}from"./PhClockCounterClockwise.vue.701e6c6a.js";import{F as we,a as Se,G as Pe,I as xe}from"./PhWebhooksLogo.vue.28d1edea.js";import{A as M}from"./index.c25fb6e2.js";import{E as Ze}from"./ExclamationCircleOutlined.81063754.js";import{C as Me}from"./CloseCircleOutlined.66e5f1b1.js";import{L as $}from"./LoadingOutlined.eb1ab7c7.js";import"./DocsButton.vue_vue_type_script_setup_true_lang.e6d1d3ad.js";import"./constants.ba2d8460.js";import"./url.4aa6f272.js";import"./PhDotsThreeVertical.vue.b3fda5f6.js";import"./index.fd17682d.js";import"./record.daabed01.js";import"./string.0157e442.js";(function(){try{var l=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},t=new Error().stack;t&&(l._sentryDebugIds=l._sentryDebugIds||{},l._sentryDebugIds[t]="0c18ec1f-991b-4fc2-9bb3-5aab61f759c9",l._sentryDebugIdIdentifier="sentry-dbid-0c18ec1f-991b-4fc2-9bb3-5aab61f759c9")}catch{}})();var $e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M696 480H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8h368c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8z"}},{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}}]},name:"minus-circle",theme:"outlined"};const Ie=$e;var je={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372zm-88-532h-48c-4.4 0-8 3.6-8 8v304c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V360c0-4.4-3.6-8-8-8zm224 0h-48c-4.4 0-8 3.6-8 8v304c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V360c0-4.4-3.6-8-8-8z"}}]},name:"pause-circle",theme:"outlined"};const ze=je,Be=["width","height","fill","transform"],De={key:0},Ee=A("path",{d:"M128,20A108,108,0,1,0,236,128,108.12,108.12,0,0,0,128,20Zm0,192a84,84,0,1,1,84-84A84.09,84.09,0,0,1,128,212Zm-16-84a16,16,0,1,1-16-16A16,16,0,0,1,112,128Zm64,0a16,16,0,1,1-16-16A16,16,0,0,1,176,128Z"},null,-1),Ve=[Ee],Ne={key:1},Te=A("path",{d:"M224,128a96,96,0,1,1-96-96A96,96,0,0,1,224,128Z",opacity:"0.2"},null,-1),Ge=A("path",{d:"M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm0,192a88,88,0,1,1,88-88A88.1,88.1,0,0,1,128,216Zm56-88a12,12,0,1,1-12-12A12,12,0,0,1,184,128Zm-44,0a12,12,0,1,1-12-12A12,12,0,0,1,140,128Zm-44,0a12,12,0,1,1-12-12A12,12,0,0,1,96,128Z"},null,-1),Le=[Te,Ge],Re={key:2},Fe=A("path",{d:"M128,24A104,104,0,1,0,232,128,104.13,104.13,0,0,0,128,24ZM84,140a12,12,0,1,1,12-12A12,12,0,0,1,84,140Zm44,0a12,12,0,1,1,12-12A12,12,0,0,1,128,140Zm44,0a12,12,0,1,1,12-12A12,12,0,0,1,172,140Z"},null,-1),Ke=[Fe],He={key:3},qe=A("path",{d:"M128,26A102,102,0,1,0,230,128,102.12,102.12,0,0,0,128,26Zm0,192a90,90,0,1,1,90-90A90.1,90.1,0,0,1,128,218Zm10-90a10,10,0,1,1-10-10A10,10,0,0,1,138,128Zm-44,0a10,10,0,1,1-10-10A10,10,0,0,1,94,128Zm88,0a10,10,0,1,1-10-10A10,10,0,0,1,182,128Z"},null,-1),Ue=[qe],We={key:4},Qe=A("path",{d:"M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm0,192a88,88,0,1,1,88-88A88.1,88.1,0,0,1,128,216Zm12-88a12,12,0,1,1-12-12A12,12,0,0,1,140,128Zm44,0a12,12,0,1,1-12-12A12,12,0,0,1,184,128Zm-88,0a12,12,0,1,1-12-12A12,12,0,0,1,96,128Z"},null,-1),Ye=[Qe],Je={key:5},Xe=A("path",{d:"M128,28A100,100,0,1,0,228,128,100.11,100.11,0,0,0,128,28Zm0,192a92,92,0,1,1,92-92A92.1,92.1,0,0,1,128,220Zm8-92a8,8,0,1,1-8-8A8,8,0,0,1,136,128Zm-44,0a8,8,0,1,1-8-8A8,8,0,0,1,92,128Zm88,0a8,8,0,1,1-8-8A8,8,0,0,1,180,128Z"},null,-1),et=[Xe],tt={name:"PhDotsThreeCircle"},at=I({...tt,props:{weight:{type:String},size:{type:[String,Number]},color:{type:String},mirrored:{type:Boolean}},setup(l){const t=l,n=Z("weight","regular"),d=Z("size","1em"),o=Z("color","currentColor"),x=Z("mirrored",!1),p=P(()=>{var m;return(m=t.weight)!=null?m:n}),w=P(()=>{var m;return(m=t.size)!=null?m:d}),v=P(()=>{var m;return(m=t.color)!=null?m:o}),O=P(()=>t.mirrored!==void 0?t.mirrored?"scale(-1, 1)":void 0:x?"scale(-1, 1)":void 0);return(m,E)=>(c(),h("svg",H({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 256 256",width:w.value,height:w.value,fill:v.value,transform:O.value},m.$attrs),[K(m.$slots,"default"),p.value==="bold"?(c(),h("g",De,Ve)):p.value==="duotone"?(c(),h("g",Ne,Le)):p.value==="fill"?(c(),h("g",Re,Ke)):p.value==="light"?(c(),h("g",He,Ue)):p.value==="regular"?(c(),h("g",We,Ye)):p.value==="thin"?(c(),h("g",Je,et)):C("",!0)],16,Be))}});function N(l){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},d=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(d=d.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),d.forEach(function(o){nt(l,o,n[o])})}return l}function nt(l,t,n){return t in l?Object.defineProperty(l,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):l[t]=n,l}var z=function(t,n){var d=N({},t,n.attrs);return u(j,N({},d,{icon:q}),null)};z.displayName="CheckCircleOutlined";z.inheritAttrs=!1;const lt=z;function T(l){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},d=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(d=d.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),d.forEach(function(o){rt(l,o,n[o])})}return l}function rt(l,t,n){return t in l?Object.defineProperty(l,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):l[t]=n,l}var B=function(t,n){var d=T({},t,n.attrs);return u(j,T({},d,{icon:Ie}),null)};B.displayName="MinusCircleOutlined";B.inheritAttrs=!1;const it=B;function G(l){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},d=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(d=d.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),d.forEach(function(o){st(l,o,n[o])})}return l}function st(l,t,n){return t in l?Object.defineProperty(l,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):l[t]=n,l}var D=function(t,n){var d=G({},t,n.attrs);return u(j,G({},d,{icon:ze}),null)};D.displayName="PauseCircleOutlined";D.inheritAttrs=!1;const ot=D,ut={style:{display:"flex","align-items":"center",gap:"5px"}},ct={key:1},dt=I({__name:"BuildInspector",props:{buildSpec:{}},setup(l){const t=l,n=U(),d=o=>{n.push({name:"logs",params:{projectId:t.buildSpec.projectId},query:o.logQuery})};return(o,x)=>o.buildSpec.runtimes.length>0?(c(),f(e(ve),{key:0,"item-layout":"horizontal","data-source":o.buildSpec.runtimes},{renderItem:s(({item:p})=>[u(e(ye),null,{actions:s(()=>[u(e(W),null,{overlay:s(()=>[u(e(Q),null,{default:s(()=>[u(e(Y),{onClick:w=>d(p)},{default:s(()=>[A("div",ut,[u(e(Oe)),u(e(k),null,{default:s(()=>[_(y(e(g).translate("i18n_build_inspector_view_logs",null)),1)]),_:1})])]),_:2},1032,["onClick"])]),_:2},1024)]),default:s(()=>[u(e(at),{style:{cursor:"pointer"}})]),_:2},1024)]),default:s(()=>[p.type=="form"?(c(),f(e(M),{key:0,size:"large"},{default:s(()=>[u(e(we)),u(e(k),{strong:""},{default:s(()=>[_(y(p.title),1)]),_:2},1024),u(e(k),{type:"secondary",code:""},{default:s(()=>[_("/"+y(p.path),1)]),_:2},1024)]),_:2},1024)):C("",!0),p.type=="job"?(c(),f(e(M),{key:1,size:"large"},{default:s(()=>[u(e(Se)),u(e(k),{strong:""},{default:s(()=>[_(y(p.title),1)]),_:2},1024),u(e(k),{type:"secondary",code:""},{default:s(()=>[_(y(p.schedule),1)]),_:2},1024)]),_:2},1024)):C("",!0),p.type=="hook"?(c(),f(e(M),{key:2,size:"large"},{default:s(()=>[u(e(Pe)),u(e(k),{strong:""},{default:s(()=>[_(y(p.title),1)]),_:2},1024),u(e(k),{type:"secondary",code:""},{default:s(()=>[_("/_hooks/"+y(p.path),1)]),_:2},1024)]),_:2},1024)):C("",!0),p.type=="script"?(c(),f(e(M),{key:3,size:"large"},{default:s(()=>[u(e(xe)),u(e(k),{strong:""},{default:s(()=>[_(y(p.title),1)]),_:2},1024)]),_:2},1024)):C("",!0)]),_:2},1024)]),_:1},8,["data-source"])):(c(),h("div",ct,[u(e(J),{description:e(g).translate("i18n_build_inspector_no_runtimes",null)},null,8,["description"])]))}}),pt=I({__name:"Builds",setup(l){const n=X().params.projectId,{loading:d,result:o,refetch:x}=V(async()=>{const[a,r]=await Promise.all([Ce.list(n),Ae.getStatus(n)]);return{b:a.map(b=>({build:b,status:r.filter(S=>S.buildId==b.id).map(S=>S.status)})),status:r}}),{startPolling:p,endPolling:w}=me({task:x,interval:1e4});ee(()=>p()),te(()=>w());const v=ae(null),O=V(async()=>v.value?await ke.get(v.value):null),m=()=>{var i;const a=(i=o.value)==null?void 0:i.b.find(b=>b.build.id===v.value);return`Version ${a==null?void 0:a.build.id.slice(0,8)} - ${a==null?void 0:a.build.createdAt.toLocaleString()}`},E=[{translationKey:"i18n_builds_deploying",tagColor:"blue",check:a=>{var r,i;return(i=a.build.latest&&a.status.some(b=>b=="Running")&&((r=o.value)==null?void 0:r.status.some(b=>b.buildId!==a.build.id)))!=null?i:!1},loading:!0},{translationKey:"i18n_builds_deactivating",tagColor:"orange",check:a=>a.build.status==="success"&&!a.build.latest&&a.status.some(r=>r=="Running"),loading:!0},{translationKey:"i18n_builds_live",tagColor:"green",check:a=>a.build.latest&&a.status.some(r=>r=="Running")},{translationKey:"i18n_builds_sleeping",tagColor:"cyan",check:a=>a.build.latest&&a.status.length===0},{translationKey:"i18n_builds_failed",tagColor:"red",check:a=>a.build.latest&&a.status.some(r=>r=="Failed")},{translationKey:"i18n_builds_inactive",tagColor:"default",check:a=>a.build.status==="success"},{translationKey:"i18n_builds_aborted",tagColor:"default",check:a=>a.build.status==="aborted"||a.build.status==="aborted-by-user"},{translationKey:"i18n_builds_failed",tagColor:"orange",check:a=>a.build.status==="failure"},{translationKey:"i18n_builds_deploying",tagColor:"blue",check:a=>a.build.status==="in-progress",loading:!0},{translationKey:"i18n_builds_uploading",tagColor:"yellow",check:a=>a.build.status==="pending"}];function L(a){var i,b;const r=E.find(S=>S.check(a));return{text:r?g.translate(r.translationKey):"unknown",tagColor:(i=r==null?void 0:r.tagColor)!=null?i:"default",hover:(b=a.build.log)!=null?b:void 0}}const R=P(()=>{const a=[{title:g.translate("i18n_builds_id")},{title:g.translate("i18n_builds_date")},{title:g.translate("i18n_builds_abstra_version")},{title:g.translate("i18n_builds_status")},{title:"",align:"right"}];return o.value?{columns:a,rows:o.value.b.map(r=>{var i;return{key:r.build.id,cells:[{type:"text",text:r.build.id.slice(0,8)},{key:"date",type:"slot",payload:{date:fe(r.build.createdAt,{weekday:void 0}),distance:de(r.build.createdAt)}},{type:"text",text:(i=r.build.abstraVersion)!=null?i:"-"},{key:"status",type:"slot",payload:L(r)},{type:"actions",actions:[{icon:be,label:g.translate("i18n_builds_inspect_version"),onClick:async()=>{v.value=r.build.id,O.refetch()}},{icon:ge,label:g.translate("i18n_builds_view_application_logs"),onClick:()=>{he.push({name:"logs",params:{projectId:n},query:{buildId:r.build.id}})}},{icon:_e,label:g.translate("i18n_builds_download_files"),onClick:()=>r.build.download()}]}]}})}:{columns:a,rows:[]}});return(a,r)=>(c(),h(ne,null,[u(F,{"entity-name":"build",loading:e(d),title:e(g).translate("i18n_builds_version_history"),description:e(g).translate("i18n_builds_description"),"empty-title":e(g).translate("i18n_builds_empty_title"),table:R.value,live:""},{date:s(({payload:i})=>[u(e(le),null,{title:s(()=>[_(y(i.distance),1)]),default:s(()=>[_(y(i.date)+" ",1)]),_:2},1024)]),status:s(({payload:i})=>[u(e(re),{open:i.hover?void 0:!1},{content:s(()=>[u(e(ie),{style:{width:"300px",overflow:"auto","font-family":"monospace"},content:i.hover,copyable:""},null,8,["content"])]),default:s(()=>[i.text!=="unknown"?(c(),f(e(oe),{key:0,color:i.tagColor,style:se({cursor:i.hover?"pointer":"default"})},{default:s(()=>[i.text==="Live"?(c(),f(e(lt),{key:0})):i.text==="Inactive"?(c(),f(e(it),{key:1})):i.text==="Failed"?(c(),f(e(Ze),{key:2})):i.text==="Aborted"?(c(),f(e(Me),{key:3})):i.text==="Sleeping"?(c(),f(e(ot),{key:4})):i.text==="Uploading"?(c(),f(e($),{key:5})):i.text==="Deploying"?(c(),f(e($),{key:6})):i.text==="Deactivating"?(c(),f(e($),{key:7})):C("",!0),_(" "+y(i.text),1)]),_:2},1032,["color","style"])):C("",!0)]),_:2},1032,["open"])]),_:1},8,["loading","title","description","empty-title","table"]),v.value?(c(),f(e(ce),{key:0,footer:null,open:!!v.value,size:"large",width:"80%",title:m(),onCancel:r[0]||(r[0]=i=>v.value=null)},{default:s(()=>[!e(O).result.value||e(O).loading.value?(c(),f(e(ue),{key:0})):e(O).result.value?(c(),f(dt,{key:1,"build-spec":e(O).result.value},null,8,["build-spec"])):C("",!0)]),_:1},8,["open","title"])):C("",!0)],64))}});const Vt=pe(pt,[["__scopeId","data-v-cfc16bae"]]);export{Vt as default};
|
|
2
|
+
//# sourceMappingURL=Builds.c90a1506.js.map
|