dirigent-server 0.21.0__tar.gz → 0.22.0__tar.gz
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.
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/PKG-INFO +5 -5
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/THIRD_PARTY_NOTICES.md +1 -1
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/pyproject.toml +5 -5
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/pyproject.toml.orig +5 -5
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/app.py +12 -11
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/health.py +2 -1
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/__init__.py +3 -0
- dirigent_server-0.22.0/src/dirigent_server/routes/labels.py +16 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/runs.py +29 -9
- dirigent_server-0.22.0/src/dirigent_server/static/assets/AdminOnly-Di7pCILM.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/Alerting-CNkD2kQW.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/Blocks-IZvOSgQU.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/Breadcrumb-CctFxp-h.js +1 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/CodeEditor-B9sClhqO.js → dirigent_server-0.22.0/src/dirigent_server/static/assets/CodeEditor-DsxK1EAQ.js +2 -2
- dirigent_server-0.22.0/src/dirigent_server/static/assets/Connections-D7XEspuJ.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/Dashboard-BIRNuuqI.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/Description-C-byz7P3.js +2 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/ExamplePanel-B8fMMGHT.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/Examples-p3LtYgUq.js +2 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Instant-mr1E5jAK.js → dirigent_server-0.22.0/src/dirigent_server/static/assets/Instant-9fAZuDCc.js +1 -1
- dirigent_server-0.22.0/src/dirigent_server/static/assets/JsonBlock-DLW6eaGe.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/ListTable-vD3vfJJc.js +1 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Markdown-roa7jpVu.js → dirigent_server-0.22.0/src/dirigent_server/static/assets/Markdown-D4x5xD_I.js +1 -1
- dirigent_server-0.22.0/src/dirigent_server/static/assets/Overview-BA7fmDg4.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/PageState-Dqk77uol.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/Panel-CdiywbkF.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/Picker-DdukB8mz.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/PipelineEditor-Cci7EXN8.js +2 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/PipelineGraph-D_Hoq5jt.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/PipelinePreview-DnTtggz_.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/PipelineTab-DibWKiQR.js +105 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/ProgramReference-BDstV6zZ.js +1 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Refusal-B8-kOQlC.js → dirigent_server-0.22.0/src/dirigent_server/static/assets/Refusal-CkWHMyRD.js +1 -1
- dirigent_server-0.22.0/src/dirigent_server/static/assets/RunDetail-DXrFy7RR.js +3 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/RunGraph-B_ptUBM0.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/SchemaForm-DfQmkkf6.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/Schemas-DwI-TOMn.js +10 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/SettingsDialog-2ku_zJjo.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/StarterPicker-BJw1pafi.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/StepPorts-DUfs-QPy.js +7 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/TileCard-XVHftgGm.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/Triggers-CTV54kJX.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/Users-DoAN95TI.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/WindowedPane-r-8QnCb_.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/Workers-oOWO1UN0.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/WorkersTable-BXjGStKj.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/api-BE2JXton.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/auth-DdhSYe4e.js +1 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/badge-BovCxjd1.js → dirigent_server-0.22.0/src/dirigent_server/static/assets/badge-D5itJPkc.js +1 -1
- dirigent_server-0.22.0/src/dirigent_server/static/assets/blocks-Ch7prU7B.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/chevron-down-BEKQnX9p.js +1 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/chunk-OB3PAWPO-DOp4K52_.js → dirigent_server-0.22.0/src/dirigent_server/static/assets/chunk-OB3PAWPO-m4Sckj1b.js +1 -1
- dirigent_server-0.22.0/src/dirigent_server/static/assets/connections-C45cNbZS.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/copy-Bu7JXtPR.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/dist-CvOdB3Md.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/dropdown-menu-DV7wG0Bs.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/examples-BPba0gMX.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/file-braces-C7psBXD2.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/format-BtF8uNWf.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/glyphs-Cc7B_n1T.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/index-BATxGpHo.css +2 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/index-C1i6SZjT.js +53 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/input-CjUmiL3f.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-cyrillic-400-normal-BEIGL1Tu.woff2 +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-cyrillic-400-normal-ugxPyKxw.woff +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-cyrillic-500-normal-DJqRU3vO.woff +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-cyrillic-500-normal-DmUKJPL_.woff2 +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-cyrillic-600-normal-8K4wrrwR.woff +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-cyrillic-600-normal-EVf6-Yzo.woff2 +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-greek-400-normal-B9oWc5Lo.woff +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-greek-400-normal-C190GLew.woff2 +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-greek-500-normal-D7SFKleX.woff +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-greek-500-normal-JpySY46c.woff2 +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-greek-600-normal-H7WoG9Et.woff2 +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-greek-600-normal-mc2nkWzM.woff +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-latin-400-normal-6-qcROiO.woff +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-latin-400-normal-V6pRDFza.woff2 +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-latin-500-normal-BWZEU5yA.woff2 +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-latin-500-normal-CJOVTJB7.woff +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-latin-600-normal-BfsvjouI.woff +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-latin-600-normal-C8RAYTDA.woff2 +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-latin-ext-400-normal-Bc8Ftmh3.woff2 +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-latin-ext-400-normal-fXTG6kC5.woff +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-latin-ext-500-normal-Cut-4mMH.woff2 +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-latin-ext-500-normal-ckzbgY84.woff +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-latin-ext-600-normal-BfB_LPfz.woff2 +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-latin-ext-600-normal-DObL3zCW.woff +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-vietnamese-400-normal-CqNFfHCs.woff +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-vietnamese-500-normal-DNRqzVM1.woff +0 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/jetbrains-mono-vietnamese-600-normal-OWROknRo.woff +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/jsonMode-C2rhmYxE.js → dirigent_server-0.22.0/src/dirigent_server/static/assets/jsonMode-DzxZa00C.js +1 -1
- dirigent_server-0.22.0/src/dirigent_server/static/assets/labels-D4COsPsJ.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/nav-OVPYHMkU.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/paging-DoahVifb.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/panels-D1Fnei43.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/pipelines-BO9VNBsW.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/play-BR8D4K_V.js +1 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/preferences-CEibwN5K.js → dirigent_server-0.22.0/src/dirigent_server/static/assets/preferences-SNZNX5Se.js +1 -1
- dirigent_server-0.22.0/src/dirigent_server/static/assets/resolveAriaLabelledBy-P_cvqa1_.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/schemas-C-PU1-EJ.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/select-C8A0wT7K.js +1 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/starters-CgC7I45V.js → dirigent_server-0.22.0/src/dirigent_server/static/assets/starters-DexsdOaG.js +2 -2
- dirigent_server-0.22.0/src/dirigent_server/static/assets/status-BnsNd2jz.js +1 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/react-CQOZoUwg.js → dirigent_server-0.22.0/src/dirigent_server/static/assets/store-D-5yFBN1.js +1 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/textarea-ljIbN_md.js → dirigent_server-0.22.0/src/dirigent_server/static/assets/textarea-D86x5ut1.js +1 -1
- dirigent_server-0.22.0/src/dirigent_server/static/assets/tooltip-BUMTCKGt.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/triggers-BNxqzLIW.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/use-heartbeat-C3WWagro.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/use-store-CZcp6jmY.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/users-7jLF2mM8.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/workers-BHK2ZmId.js +1 -0
- dirigent_server-0.22.0/src/dirigent_server/static/assets/x-CIbrmauw.js +1 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/yaml-CLSOANGG.js → dirigent_server-0.22.0/src/dirigent_server/static/assets/yaml-D-Hjyunz.js +1 -1
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/index.html +27 -27
- dirigent_server-0.21.0/src/dirigent_server/static/assets/AdminOnly-CWzFAkRQ.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Alerting-D3KAVTv0.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Blocks-B_BEIvwW.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Breadcrumb-x6p00HyX.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Connections-CmN2b7Dw.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Dashboard-DTmnXmfY.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Description-MmXUnb-9.js +0 -2
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ExamplePanel-B-ZuMODN.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Examples-CbmS9l2a.js +0 -2
- dirigent_server-0.21.0/src/dirigent_server/static/assets/JsonBlock-DwIVIGWh.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ListTable-D-mI8v9Y.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Overview-BpjDksB7.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/PageState-BLuobMye.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Panel-CqrOYByl.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Picker-jTaWHWGB.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/PipelineEditor-DLGzheqJ.js +0 -2
- dirigent_server-0.21.0/src/dirigent_server/static/assets/PipelineGraph-Dn18zCoZ.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/PipelinePreview-BPyUvdOo.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/PipelineTab-BYrALqeE.js +0 -105
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ProgramReference-DF37mMAT.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/RunDetail-B_q6JL9s.js +0 -3
- dirigent_server-0.21.0/src/dirigent_server/static/assets/RunGraph-BGK0Xv2D.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/SchemaForm-DLj4I7id.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Schemas-cuyuiN7C.js +0 -10
- dirigent_server-0.21.0/src/dirigent_server/static/assets/SettingsDialog-3fpnWZxX.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/StarterPicker-DZ-cG3dS.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/StepPorts-Tn2lFNQr.js +0 -7
- dirigent_server-0.21.0/src/dirigent_server/static/assets/TileCard-CGUQmmKn.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Triggers-Bv1YP__i.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Users-Cbz-vtKl.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/WindowedPane-li0CnoR2.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/Workers-B8-mU9eH.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/WorkersTable-DUHvNQ1T.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/api-Bm1JZLuC.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/auth-CHgfcdt9.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/blocks-CclbVd8c.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/chevron-down-DAO3SUWv.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/connections-Cp5WCruj.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/copy-BeBwg8IR.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/dist-DD8kpv1W.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/dropdown-menu-B-6CcHKw.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/examples-DB467CTN.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/file-braces-Ep8AP5Yq.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/format-B5YbYOY-.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/glyphs-C1sjljkh.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-cyrillic-400-normal-BSMlKf0J.woff2 +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-cyrillic-400-normal-CEL4l2ZJ.woff +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-cyrillic-500-normal-Ael50iVv.woff +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-cyrillic-500-normal-Bq9vWWag.woff2 +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-cyrillic-600-normal-CTOM6hUh.woff2 +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-cyrillic-600-normal-fLZuRloM.woff +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-cyrillic-ext-400-normal-DMdlQ8Kv.woff +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-cyrillic-ext-400-normal-xuaO2J-f.woff2 +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-cyrillic-ext-500-normal-BIfNGwUT.woff +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-cyrillic-ext-500-normal-BqneJy0T.woff2 +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-cyrillic-ext-600-normal-9HEixskS.woff +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-cyrillic-ext-600-normal-V-xxqcpd.woff2 +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-latin-400-normal-CvHOgSBP.woff +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-latin-400-normal-DMJ8VG8y.woff2 +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-latin-500-normal-CB9ihrfo.woff +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-latin-500-normal-DSY6xOcd.woff2 +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-latin-600-normal-BgSNZQsw.woff2 +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-latin-600-normal-DWFSQ4vo.woff +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-latin-ext-400-normal-BmRBH3aV.woff2 +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-latin-ext-400-normal-D3D2R8hC.woff +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-latin-ext-500-normal-CAhNIIs5.woff2 +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-latin-ext-500-normal-CZ70TYgx.woff +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-latin-ext-600-normal-D38SheWl.woff2 +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-latin-ext-600-normal-DmB0ttJJ.woff +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-vietnamese-400-normal-BulugwFq.woff2 +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-vietnamese-400-normal-DDuiU_S-.woff +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-vietnamese-500-normal-C8zxqsMH.woff +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-vietnamese-500-normal-DZ4AoWbu.woff2 +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-vietnamese-600-normal-D2EvbN8M.woff2 +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/ibm-plex-mono-vietnamese-600-normal-iLQfcSjf.woff +0 -0
- dirigent_server-0.21.0/src/dirigent_server/static/assets/index-CgkcXl1G.css +0 -2
- dirigent_server-0.21.0/src/dirigent_server/static/assets/index-Dpu5aiIb.js +0 -53
- dirigent_server-0.21.0/src/dirigent_server/static/assets/input-1fShkFXn.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/nav-i7bJ0lrA.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/paging-CpRIkEky.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/pipelines-BXPe0IzI.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/play-CPVSEWx6.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/resolveAriaLabelledBy-ClHvyYLK.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/schemas-7KY_7aIc.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/select-Ck-1BZPw.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/status-Ctx8x8Mf.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/store-C2zgoyrT.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/tooltip-D7_KwbOU.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/triggers-Dim48dZY.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/use-heartbeat-CBT8848s.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/use-store-CfRquqZF.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/users-CTGHiHMA.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/with-selector-BXYKoaOE.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/workers-BH2Za19E.js +0 -1
- dirigent_server-0.21.0/src/dirigent_server/static/assets/x-Dltw6Vbs.js +0 -1
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/LICENSE +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/README.md +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/__init__.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/dependencies.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/errors.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/logging.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/messages.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/pagination.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/py.typed +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/alerts.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/auth.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/blocks.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/connections.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/examples.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/hooks.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/pipelines.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/playground.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/schema.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/schemas.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/system.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/trigger_documents.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/triggers.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/users.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/routes/workers.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/security.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/.gitkeep +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/CodeEditor-C4OnjBMt.css +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/KindChip-CwU_Xxdy.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/Mark-DQR2php6.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/Segmented-KaDiGiyr.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/codicon-DCmgc-ay.ttf +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/docs-CCoB3shg.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/editor.worker-CIvRzd4O.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/elk-engine-Bm7I_NRI.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/elk-worker.min-DfmSo98M.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/ibm-plex-sans-cyrillic-ext-wght-normal-d45eAU9y.woff2 +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/ibm-plex-sans-cyrillic-wght-normal-BAAhND-U.woff2 +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/ibm-plex-sans-greek-wght-normal-CmyJS8uq.woff2 +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/ibm-plex-sans-latin-ext-wght-normal-CIII54If.woff2 +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/ibm-plex-sans-latin-wght-normal-IvpUvPa2.woff2 +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/ibm-plex-sans-vietnamese-wght-normal-Dg1JeJN0.woff2 +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/identity-BNZxCf_y.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/idle-DnO3aHK7.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/json.worker-fczZDBja.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/preload-helper-BZ1Pz5am.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/rolldown-runtime-Dd_uD5pT.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/shell-CC2rA5mh.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/sql-NEE52Syq.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/twig-De2hgUGE.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/utils-CT7ZGLfR.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/assets/yaml.worker-B2SaT_wA.js +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/favicon-32.png +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/static/logo.png +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/transactions.py +0 -0
- {dirigent_server-0.21.0 → dirigent_server-0.22.0}/src/dirigent_server/ui.py +0 -0
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: dirigent-server
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.22.0
|
|
4
4
|
Summary: Dirigent FastAPI server: the REST API, its authentication, and the health probes.
|
|
5
5
|
License-Expression: LicenseRef-Proprietary
|
|
6
6
|
License-File: LICENSE
|
|
7
7
|
License-File: THIRD_PARTY_NOTICES.md
|
|
8
8
|
Classifier: Programming Language :: Python :: 3
|
|
9
9
|
Classifier: Programming Language :: Python :: 3.13
|
|
10
|
-
Requires-Dist: dirigent-client==0.
|
|
11
|
-
Requires-Dist: dirigent-common==0.
|
|
12
|
-
Requires-Dist: dirigent-core==0.
|
|
13
|
-
Requires-Dist: dirigent-examples==0.
|
|
10
|
+
Requires-Dist: dirigent-client==0.22.0
|
|
11
|
+
Requires-Dist: dirigent-common==0.22.0
|
|
12
|
+
Requires-Dist: dirigent-core==0.22.0
|
|
13
|
+
Requires-Dist: dirigent-examples==0.22.0
|
|
14
14
|
Requires-Dist: fastapi>=0.141.1
|
|
15
15
|
Requires-Python: >=3.13
|
|
16
16
|
Description-Content-Type: text/markdown
|
|
@@ -540,7 +540,7 @@ in the Eclipse Public License, v. 2.0 are satisfied: GNU General Public License
|
|
|
540
540
|
## SIL Open Font License 1.1
|
|
541
541
|
|
|
542
542
|
- `@fontsource-variable/ibm-plex-sans` -- IBM Plex Sans, Copyright 2019 IBM Corp. All rights reserved.
|
|
543
|
-
- `@fontsource/
|
|
543
|
+
- `@fontsource/jetbrains-mono` -- JetBrains Mono, Copyright 2020 The JetBrains Mono Project Authors, SIL Open Font License 1.1.
|
|
544
544
|
|
|
545
545
|
```
|
|
546
546
|
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "dirigent-server"
|
|
3
|
-
version = "0.
|
|
3
|
+
version = "0.22.0"
|
|
4
4
|
description = "Dirigent FastAPI server: the REST API, its authentication, and the health probes."
|
|
5
5
|
readme = "README.md"
|
|
6
6
|
requires-python = ">=3.13"
|
|
@@ -14,10 +14,10 @@ classifiers = [
|
|
|
14
14
|
"Programming Language :: Python :: 3.13",
|
|
15
15
|
]
|
|
16
16
|
dependencies = [
|
|
17
|
-
"dirigent-client==0.
|
|
18
|
-
"dirigent-common==0.
|
|
19
|
-
"dirigent-core==0.
|
|
20
|
-
"dirigent-examples==0.
|
|
17
|
+
"dirigent-client==0.22.0",
|
|
18
|
+
"dirigent-common==0.22.0",
|
|
19
|
+
"dirigent-core==0.22.0",
|
|
20
|
+
"dirigent-examples==0.22.0",
|
|
21
21
|
"fastapi>=0.141.1",
|
|
22
22
|
]
|
|
23
23
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "dirigent-server"
|
|
3
|
-
version = "0.
|
|
3
|
+
version = "0.22.0"
|
|
4
4
|
description = "Dirigent FastAPI server: the REST API, its authentication, and the health probes."
|
|
5
5
|
readme = "README.md"
|
|
6
6
|
requires-python = ">=3.13"
|
|
@@ -11,10 +11,10 @@ classifiers = [
|
|
|
11
11
|
"Programming Language :: Python :: 3.13",
|
|
12
12
|
]
|
|
13
13
|
dependencies = [
|
|
14
|
-
"dirigent-client==0.
|
|
15
|
-
"dirigent-common==0.
|
|
16
|
-
"dirigent-core==0.
|
|
17
|
-
"dirigent-examples==0.
|
|
14
|
+
"dirigent-client==0.22.0",
|
|
15
|
+
"dirigent-common==0.22.0",
|
|
16
|
+
"dirigent-core==0.22.0",
|
|
17
|
+
"dirigent-examples==0.22.0",
|
|
18
18
|
"fastapi>=0.141.1",
|
|
19
19
|
]
|
|
20
20
|
|
|
@@ -7,7 +7,7 @@ from contextlib import asynccontextmanager
|
|
|
7
7
|
|
|
8
8
|
from fastapi import FastAPI
|
|
9
9
|
|
|
10
|
-
from dirigent_core import __version__
|
|
10
|
+
from dirigent_core import __version__, wakeups
|
|
11
11
|
from dirigent_core.auth import BOOTSTRAP_PASSWORD_ENV, bootstrap_admin
|
|
12
12
|
from dirigent_core.config import Settings, get_settings
|
|
13
13
|
from dirigent_core.database import create_engine, create_session_factory, session_scope
|
|
@@ -73,16 +73,17 @@ def create_app(
|
|
|
73
73
|
app.state.scheduler = None
|
|
74
74
|
clock: asyncio.Task[None] | None = None
|
|
75
75
|
try:
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
76
|
+
async with wakeups.listening(resolved.database_url):
|
|
77
|
+
await _bootstrap(app)
|
|
78
|
+
await _apply_startup_directory(app)
|
|
79
|
+
clock = await _start_scheduler(app, embed=embed)
|
|
80
|
+
_logger.info(
|
|
81
|
+
"server starting",
|
|
82
|
+
database="sqlite" if resolved.is_sqlite else "postgresql",
|
|
83
|
+
blocks=len(app.state.services.host.block_ids),
|
|
84
|
+
scheduler=embed,
|
|
85
|
+
)
|
|
86
|
+
yield
|
|
86
87
|
finally:
|
|
87
88
|
await _stop_scheduler(app, clock)
|
|
88
89
|
await engine.dispose()
|
|
@@ -9,6 +9,7 @@ from fastapi import APIRouter, Request, Response, status
|
|
|
9
9
|
from sqlalchemy.ext.asyncio import AsyncEngine
|
|
10
10
|
|
|
11
11
|
from dirigent_client.schemas import CheckResult, CheckStatus, Health, Readiness
|
|
12
|
+
from dirigent_common import raised_detail
|
|
12
13
|
from dirigent_core.database import ping
|
|
13
14
|
|
|
14
15
|
router = APIRouter(tags=["health"])
|
|
@@ -73,7 +74,7 @@ async def run_checks(registry: HealthCheckRegistry) -> dict[str, CheckResult]:
|
|
|
73
74
|
try:
|
|
74
75
|
return await check.check()
|
|
75
76
|
except Exception as error:
|
|
76
|
-
return CheckResult(status=CheckStatus.UNHEALTHY, detail=
|
|
77
|
+
return CheckResult(status=CheckStatus.UNHEALTHY, detail=raised_detail(error))
|
|
77
78
|
|
|
78
79
|
names = list(registry)
|
|
79
80
|
results = await asyncio.gather(*(run(registry[name]) for name in names))
|
|
@@ -15,6 +15,7 @@ from dirigent_server.routes import (
|
|
|
15
15
|
connections,
|
|
16
16
|
examples,
|
|
17
17
|
hooks,
|
|
18
|
+
labels,
|
|
18
19
|
pipelines,
|
|
19
20
|
playground,
|
|
20
21
|
runs,
|
|
@@ -38,6 +39,7 @@ TAGS: list[dict[str, str]] = [
|
|
|
38
39
|
{"name": "hooks", "description": "Webhook intake, authenticated by its own token."},
|
|
39
40
|
{"name": "connections", "description": "Named credential records of contributed kinds."},
|
|
40
41
|
{"name": "blocks", "description": "The catalog every plugin contributes to."},
|
|
42
|
+
{"name": "labels", "description": "The wording every installed pack refuses in."},
|
|
41
43
|
{"name": "examples", "description": "The documents every installed plugin ships."},
|
|
42
44
|
{"name": "schema", "description": "The shape a document is written against."},
|
|
43
45
|
{"name": "schemas", "description": "Named JSON Schemas the instance holds."},
|
|
@@ -72,6 +74,7 @@ def build_router(settings: Settings | None = None) -> APIRouter:
|
|
|
72
74
|
alerts,
|
|
73
75
|
connections,
|
|
74
76
|
blocks,
|
|
77
|
+
labels,
|
|
75
78
|
examples,
|
|
76
79
|
schema,
|
|
77
80
|
schemas,
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"""The wording every installed pack refuses in, for a surface that renders its own sentences."""
|
|
2
|
+
|
|
3
|
+
from fastapi import APIRouter
|
|
4
|
+
|
|
5
|
+
from dirigent_client.schemas import Labels
|
|
6
|
+
from dirigent_server.dependencies import ServicesDep
|
|
7
|
+
from dirigent_server.security import PrincipalDep
|
|
8
|
+
from dirigent_server.transactions import Transactional
|
|
9
|
+
|
|
10
|
+
router = APIRouter(route_class=Transactional, tags=["labels"])
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
@router.get("/labels", operation_id="getLabels", summary="Contributed refusal wording", response_model=Labels)
|
|
14
|
+
async def get_labels(services: ServicesDep, principal: PrincipalDep) -> Labels:
|
|
15
|
+
"""Serve every code an installed pack can refuse under, with the template it renders from."""
|
|
16
|
+
return Labels(templates={code: message.text for code, message in services.host.labels.items()})
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"""Runs: the list, the detail with its DAG view model, cancellation, retry, logs, events, and a report."""
|
|
2
2
|
|
|
3
3
|
import asyncio
|
|
4
|
+
import time
|
|
4
5
|
from collections.abc import AsyncGenerator, Generator, Mapping, Sequence
|
|
5
6
|
from contextlib import contextmanager
|
|
6
7
|
from datetime import UTC, datetime, timedelta
|
|
@@ -12,7 +13,7 @@ from fastapi import APIRouter, Header, Query, Request, Response, status
|
|
|
12
13
|
from fastapi.responses import PlainTextResponse, StreamingResponse
|
|
13
14
|
from sqlalchemy.ext.asyncio import AsyncSession, async_sessionmaker
|
|
14
15
|
|
|
15
|
-
from dirigent_client.enums import AttemptStatus, LogLevel, RunItemStatus, RunStatus
|
|
16
|
+
from dirigent_client.enums import AttemptStatus, LogLevel, RunItemStatus, RunStatus, TriggerKind
|
|
16
17
|
from dirigent_client.schemas import (
|
|
17
18
|
TERMINAL_RUN_STATUSES,
|
|
18
19
|
ArtifactOut,
|
|
@@ -29,12 +30,13 @@ from dirigent_client.schemas import (
|
|
|
29
30
|
StepReport,
|
|
30
31
|
)
|
|
31
32
|
from dirigent_common.durations import DurationError, parse_duration
|
|
32
|
-
from dirigent_core import telemetry
|
|
33
|
+
from dirigent_core import telemetry, wakeups
|
|
33
34
|
from dirigent_core.artifacts import JSON_CONTENT_TYPE, TEXT_KEY, canonical_json, open_artifact
|
|
34
35
|
from dirigent_core.database import session_scope
|
|
35
36
|
from dirigent_core.engine.definition import PipelineDefinition, load_definition
|
|
36
37
|
from dirigent_core.engine.runs import cancel_run, retry_step
|
|
37
38
|
from dirigent_core.engine.state import StepCounts, attempt_counts, item_counts, step_states
|
|
39
|
+
from dirigent_core.messages import CANCELLED_BY
|
|
38
40
|
from dirigent_core.models import (
|
|
39
41
|
ArtifactRef,
|
|
40
42
|
LogEntry,
|
|
@@ -119,10 +121,12 @@ def _render_run(run: Run, pipeline: Pipeline, version: PipelineVersion, failed:
|
|
|
119
121
|
priority=run.priority,
|
|
120
122
|
params=dict(run.params),
|
|
121
123
|
triggered_by_kind=run.triggered_by_kind,
|
|
124
|
+
parent_run_id=run.triggered_by_id if run.triggered_by_kind is TriggerKind.PIPELINE else None,
|
|
122
125
|
triggered_by_label=run.triggered_by_label,
|
|
123
126
|
trace_id=telemetry.trace_id_of(run.traceparent),
|
|
124
127
|
error=run.error or (failed.error if failed is not None else None),
|
|
125
128
|
error_code=run.error_code or (failed.code if failed is not None else None),
|
|
129
|
+
error_params=run.error_params or (failed.params if failed is not None else None),
|
|
126
130
|
failed_step=failed.step if failed is not None else None,
|
|
127
131
|
started_at=run.started_at,
|
|
128
132
|
finished_at=run.finished_at,
|
|
@@ -161,6 +165,7 @@ def _dag(
|
|
|
161
165
|
depends_on=list(step.depends_on),
|
|
162
166
|
rule=step.rule.value,
|
|
163
167
|
fan_out=step.is_fan_out,
|
|
168
|
+
grid_source=definition.grid_source(name),
|
|
164
169
|
items_total=sum(of_step.values()),
|
|
165
170
|
items_failed=of_step.get(RunItemStatus.FAILED, 0),
|
|
166
171
|
attempts=attempts[name].total if name in attempts else 0,
|
|
@@ -387,7 +392,7 @@ async def cancel(run_id: UUID, session: SessionDep, services: ServicesDep, princ
|
|
|
387
392
|
async def cancel_once() -> RunOut:
|
|
388
393
|
run = await _run_row(session, run_id)
|
|
389
394
|
pipeline, version, _ = await _context(session, run)
|
|
390
|
-
await cancel_run(session, services, run,
|
|
395
|
+
await cancel_run(session, services, run, CANCELLED_BY, principal=principal.label)
|
|
391
396
|
return _render_run(run, pipeline, version)
|
|
392
397
|
|
|
393
398
|
return await retried_on_deadlock(session, cancel_once)
|
|
@@ -484,6 +489,19 @@ def next_interval(current: float) -> float:
|
|
|
484
489
|
return min(current * FOLLOW_BACKOFF, FOLLOW_MAX_INTERVAL_SECONDS)
|
|
485
490
|
|
|
486
491
|
|
|
492
|
+
async def quiet_wait(mark: wakeups.Mark, waited: float, interval: float) -> tuple[float, float]:
|
|
493
|
+
"""Wait out one quiet interval, or less when the run moves, and say how long and what next.
|
|
494
|
+
|
|
495
|
+
A run that moved sends the stream back to its shortest interval.
|
|
496
|
+
"""
|
|
497
|
+
started = time.monotonic()
|
|
498
|
+
moved = await wakeups.wait_settled(mark, timeout=interval)
|
|
499
|
+
elapsed = time.monotonic() - started
|
|
500
|
+
if moved:
|
|
501
|
+
return waited + elapsed, FOLLOW_INTERVAL_SECONDS
|
|
502
|
+
return waited + elapsed, next_interval(interval)
|
|
503
|
+
|
|
504
|
+
|
|
487
505
|
def _claim(user_id: UUID) -> str:
|
|
488
506
|
"""Name the principal a stream is opened by, refusing one that already holds the cap.
|
|
489
507
|
|
|
@@ -551,6 +569,7 @@ async def _tail(
|
|
|
551
569
|
waited = 0.0
|
|
552
570
|
interval = FOLLOW_INTERVAL_SECONDS
|
|
553
571
|
while waited < FOLLOW_MAX_SECONDS:
|
|
572
|
+
moved = wakeups.settled_mark(run_id)
|
|
554
573
|
page, settled = await asyncio.shield(_tail_read(sessions, run_id, cursor, step))
|
|
555
574
|
for entry in page.items:
|
|
556
575
|
yield f"id: {entry.id}\nevent: log\ndata: {entry.model_dump_json()}\n\n"
|
|
@@ -561,9 +580,7 @@ async def _tail(
|
|
|
561
580
|
if settled:
|
|
562
581
|
yield "event: end\ndata: {}\n\n"
|
|
563
582
|
return
|
|
564
|
-
await
|
|
565
|
-
waited += interval
|
|
566
|
-
interval = next_interval(interval)
|
|
583
|
+
waited, interval = await quiet_wait(moved, waited, interval)
|
|
567
584
|
yield "event: expired\ndata: {}\n\n"
|
|
568
585
|
|
|
569
586
|
|
|
@@ -739,6 +756,7 @@ async def _story(
|
|
|
739
756
|
waited = 0.0
|
|
740
757
|
interval = FOLLOW_INTERVAL_SECONDS
|
|
741
758
|
while waited < FOLLOW_MAX_SECONDS:
|
|
759
|
+
changed = wakeups.settled_mark(run_id)
|
|
742
760
|
# Shielded for the same reason _tail_read is: a disconnect lands between polls,
|
|
743
761
|
# never inside a driver await holding the pooled connection.
|
|
744
762
|
attempts, spilled, page, rendered, read_labels = await asyncio.shield(
|
|
@@ -782,9 +800,7 @@ async def _story(
|
|
|
782
800
|
return
|
|
783
801
|
drained = True
|
|
784
802
|
continue
|
|
785
|
-
await
|
|
786
|
-
waited += interval
|
|
787
|
-
interval = next_interval(interval)
|
|
803
|
+
waited, interval = await quiet_wait(changed, waited, interval)
|
|
788
804
|
yield "event: expired\ndata: {}\n\n"
|
|
789
805
|
|
|
790
806
|
|
|
@@ -818,10 +834,14 @@ async def report(run_id: UUID, session: SessionDep, principal: PrincipalDep) ->
|
|
|
818
834
|
warnings=step.warnings,
|
|
819
835
|
duration_ms=step.duration_ms,
|
|
820
836
|
error=step.error,
|
|
837
|
+
error_code=step.error_code,
|
|
838
|
+
error_params=step.error_params,
|
|
821
839
|
)
|
|
822
840
|
for step in facts.steps
|
|
823
841
|
],
|
|
824
842
|
items_total=facts.items_total,
|
|
825
843
|
items_failed=facts.items_failed,
|
|
826
844
|
error=run.error,
|
|
845
|
+
error_code=run.error_code,
|
|
846
|
+
error_params=run.error_params,
|
|
827
847
|
)
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{t as e}from"./labels-D4COsPsJ.js";import{n as t}from"./PageState-Dqk77uol.js";import{r as n}from"./utils-CT7ZGLfR.js";import{t as r}from"./use-store-CZcp6jmY.js";import{n as i,t as a}from"./auth-DdhSYe4e.js";var o=n(),s={status:403,title:e.refusal.admin_only,code:`server.forbidden`,params:{},detail:e.refusal.shut,problems:[],instance:null};function c({children:e}){let n=r(a);return i(n)?(0,o.jsx)(o.Fragment,{children:e}):(0,o.jsx)(t,{loading:!1,problem:s,empty:!1,children:null})}export{c as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{n as t}from"./store-D-5yFBN1.js";import{a as n,t as r}from"./labels-D4COsPsJ.js";import{n as i}from"./chunk-OB3PAWPO-m4Sckj1b.js";import{i as a,r as o}from"./api-BE2JXton.js";import{N as s}from"./dropdown-menu-DV7wG0Bs.js";import{r as c}from"./glyphs-Cc7B_n1T.js";import{l,n as u,t as d,u as f}from"./PageState-Dqk77uol.js";import{i as p,t as m}from"./ListTable-vD3vfJJc.js";import{t as h}from"./WindowedPane-r-8QnCb_.js";import{r as g,t as _}from"./utils-CT7ZGLfR.js";import{i as v,n as y,t as b}from"./tooltip-BUMTCKGt.js";import{d as x,h as S}from"./paging-DoahVifb.js";import{t as C}from"./input-CjUmiL3f.js";import{a as w,o as T,r as ee}from"./panels-D1Fnei43.js";import{l as E}from"./format-BtF8uNWf.js";import{t as D}from"./identity-BNZxCf_y.js";import{r as O,t as k,u as A}from"./pipelines-BO9VNBsW.js";import{A as j,At as M,E as N,Ft as P,It as F,Lt as te,Mt as I,Nt as ne,Pt as re,S as ie,b as L,ct as R,ft as z,gt as ae,it as B,jt as oe,rt as se,v as ce,x as V}from"./index-C1i6SZjT.js";import{t as le}from"./Description-C-byz7P3.js";import{l as ue,p as de,r as fe,s as pe}from"./connections-C45cNbZS.js";import{n as me,t as he}from"./Refusal-CkWHMyRD.js";import{t as H}from"./Instant-9fAZuDCc.js";import{t as U}from"./Segmented-KaDiGiyr.js";import{t as W}from"./Mark-DQR2php6.js";import{t as ge}from"./ProgramReference-BDstV6zZ.js";import{t as _e}from"./Picker-DdukB8mz.js";import{t as ve}from"./AdminOnly-Di7pCILM.js";var ye={name:`bell-plus`,size:24,node:[[`path`,{d:`M10.268 21a2 2 0 0 0 3.464 0`,key:`vwvbt9`}],[`path`,{d:`M15 8h6`,key:`8ybuxh`}],[`path`,{d:`M18 5v6`,key:`g5ayrv`}],[`path`,{d:`M20.002 14.464a9 9 0 0 0 .738.863A1 1 0 0 1 20 17H4a1 1 0 0 1-.74-1.673C4.59 13.956 6 12.499 6 8a6 6 0 0 1 8.75-5.332`,key:`1abcvy`}]]};ye.node;var be=n(ye),xe={name:`send`,size:24,node:[[`path`,{d:`M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z`,key:`1ffxy3`}],[`path`,{d:`m21.854 2.147-10.94 10.939`,key:`12cjpa`}]]};xe.node;var Se=n(xe),G=e(t(),1),Ce=[`run_failed`,`run_completed_with_errors`,`run_succeeded`,`run_stuck`],we=[`pending`,`sending`,`sent`,`failed`],Te=`0s`;function Ee(e){return e===Te?r.word.none:e}function De(e){return e.scope===`pipeline`&&e.pipeline!==null?e.pipeline:r.alerting.every_pipeline}function Oe(e){return e===null?null:r.alerting.importance_floor(e)}function ke(e){return e.active&&!e.paused}function Ae(e){return e===`sent`||e===`failed`}function je(e,t=50){let n=new URLSearchParams({limit:String(t)});return e!==null&&n.set(`after`,e),`/alert-rules?${n.toString()}`}function Me(e){return o(je(e))}function Ne(e){return a(`/alert-rules`,`POST`,e)}function Pe(e,t){return a(`/alert-rules/${encodeURIComponent(e)}`,`PATCH`,t)}function Fe(e,t){return Pe(e,{paused:t})}function Ie(e){return o(`/alert-rules/${encodeURIComponent(e)}`,{method:`DELETE`})}var Le={status:``,notifier:``};function Re(e,t,n=50){let r=new URLSearchParams({limit:String(n)});return e.status!==``&&r.set(`status`,e.status),e.notifier!==``&&r.set(`notifier`,e.notifier),t!==null&&r.set(`after`,t),`/notifications?${r.toString()}`}function ze(e,t){return o(Re(e,t))}function Be(e){return o(`/notifications/${encodeURIComponent(e)}`)}function Ve(e){return a(`/notifications/${encodeURIComponent(e)}/$retry`,`POST`,{})}function He(e){return a(`/alert-rules/$test`,`POST`,e)}async function Ue(){return(await o(`/blocks`)).notifiers.map(e=>e.id)}function We(e,t){let n=[];for(let r of e){if(r===`log`){n.push({id:r,notifier:r,connection:null,reachable:!0,last_check_at:null,last_check_healthy:null,last_check_detail:null});continue}let e=t.filter(e=>e.kind===r);if(e.length===0){n.push({id:r,notifier:r,connection:null,reachable:!1,last_check_at:null,last_check_healthy:null,last_check_detail:null});continue}for(let t of e)n.push({id:`${r}:${t.code}`,notifier:r,connection:t.code,reachable:!0,last_check_at:t.last_check_at,last_check_healthy:t.last_check_healthy,last_check_detail:t.last_check_detail})}return Je(n)}function Ge(e){return e.connection??e.notifier}function Ke(e){return e.connection===null?e.notifier===`log`?null:ue(e.notifier):fe(e.connection)}function K(e){if(e.notifier===`log`)return{tone:`good`,label:r.alerting.channel.ready,detail:null};if(!e.reachable)return{tone:`quiet`,label:r.alerting.channel.not_set_up,detail:null};let t=pe(e);return{tone:t.tone??`quiet`,label:t.label,detail:t.detail}}var qe={good:0,critical:1,quiet:2};function Je(e){return e.toSorted((e,t)=>{let n=qe[K(e).tone]-qe[K(t).tone];if(n!==0)return n;let r=e.notifier.localeCompare(t.notifier);return r===0?(e.connection??``).localeCompare(t.connection??``):r})}var Ye=/^[a-z0-9]+(?:[-_][a-z0-9]+)*$/u,Xe=/^(?:\d+(?:ms|s|m|h|d|w))+$/u,Ze=r.alerting.subject_references,Qe=r.alerting.subject_hint(Ze),$e=r.alerting.body_hint,q=`text/x-jinja`;function J(e){let t=e.trim();return t===``?null:t}var et=[{value:`global`,label:r.alerting.scope.global},{value:`pipeline`,label:r.alerting.scope.pipeline}],tt=[{value:``,label:r.alerting.importance_any},...k.map(e=>({value:e,label:e[0].toUpperCase()+e.slice(1)}))];function nt(e){return e===``?null:e}function rt(e){return e===``?null:e}var it=r.alerting.log_target;function at(e,t){let n=t.filter(t=>t.kind!==`log`&&e.includes(t.kind)).map(e=>({row:e,heading:D(e)})).toSorted((e,t)=>e.row.kind.localeCompare(t.row.kind)||e.heading.title.localeCompare(t.heading.title));return[{value:``,label:it,aside:``,mark:c(`log`)},...n.map(({row:e,heading:t})=>({value:e.code,label:`${t.title} · ${e.kind}`,aside:t.code??``,mark:c(e.kind)}))]}function ot(e){if(e.code.trim()===``)return r.alerting.unready.code_missing;if(!Ye.test(e.code.trim()))return r.alerting.unready.code_shape;if(e.scope===`pipeline`&&e.pipeline===``)return r.alerting.unready.pipeline_missing;if(!Xe.test(e.throttle.trim()))return r.alerting.unready.throttle_shape}var Y=g();function st({rule:e,onChanged:t,onDeleted:n,onTest:i}){let[a,o]=(0,G.useState)(!1),[s,c]=(0,G.useState)(null),u=s===e.code,d=V(),f=Oe(e.importance),p=(0,G.useCallback)(e=>ze(Le,e),[]),{state:m}=L(p,ut),h=m.rows.filter(t=>t.rule===e.code);return(0,Y.jsxs)(`div`,{className:`space-y-4 p-4`,children:[(0,Y.jsxs)(ht,{thing:e,children:[e.paused&&(0,Y.jsx)(mt,{children:r.state.armed.paused}),!e.active&&(0,Y.jsx)(mt,{children:r.state.armed.off})]}),(0,Y.jsx)(le,{text:e.description}),(0,Y.jsxs)(`dl`,{className:`space-y-1.5`,children:[(0,Y.jsx)(X,{label:r.word.event,children:r.alerting.event[e.event]}),(0,Y.jsx)(X,{label:r.word.scope,children:(0,Y.jsxs)(`span`,{className:`flex flex-wrap items-baseline gap-x-1.5`,children:[De(e),f!==null&&(0,Y.jsx)(`span`,{className:`text-xs text-muted-foreground`,children:f})]})}),(0,Y.jsx)(X,{label:r.word.delivers_through,children:(0,Y.jsx)(dt,{notifier:e.notifier,connection:e.connection})}),(0,Y.jsx)(X,{label:r.word.throttle,children:Ee(e.throttle)}),u?(0,Y.jsx)(ct,{rule:e,onDone:()=>{c(null)},onSaved:e=>{t(e),c(null)}},e.code):(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(X,{label:r.word.subject,children:(0,Y.jsxs)(`span`,{className:`flex flex-wrap items-baseline gap-2`,children:[e.template===null?(0,Y.jsx)(`span`,{className:`text-muted-foreground`,children:r.word.none}):(0,Y.jsx)(`span`,{className:`font-mono text-xs break-all`,children:e.template}),(0,Y.jsx)(l,{why:d.why,children:(0,Y.jsx)(S,{variant:`ghost`,size:`xs`,disabled:!d.may,title:d.why,onClick:()=>{c(e.code)},children:r.action.edit})})]})}),e.body!==null&&(0,Y.jsx)(X,{label:r.word.body,children:(0,Y.jsx)(`span`,{className:`line-clamp-3 font-mono text-xs break-words whitespace-pre-wrap`,children:e.body})})]}),(0,Y.jsx)(X,{label:r.alerting.last_sent,children:e.last_sent_at===null?(0,Y.jsx)(`span`,{className:`text-muted-foreground`,children:r.word.never}):(0,Y.jsx)(H,{at:e.last_sent_at})})]}),(0,Y.jsxs)(`div`,{className:`flex flex-wrap gap-2`,children:[(0,Y.jsx)(l,{why:d.why,children:(0,Y.jsx)(S,{variant:`outline`,size:`sm`,disabled:a||!d.may,title:d.why,onClick:()=>{o(!0),Fe(e.code,!e.paused).then(t,me).finally(()=>{o(!1)})},children:e.paused?r.action.resume:r.action.pause})}),(0,Y.jsx)(l,{why:d.why,children:(0,Y.jsx)(S,{variant:`outline`,size:`sm`,disabled:!d.may,title:d.why,onClick:i,children:r.action.send_test})}),(0,Y.jsx)(l,{why:d.why,children:(0,Y.jsx)(S,{variant:`outline`,size:`sm`,className:`destructive-action ml-auto`,disabled:a||!d.may,title:d.why,onClick:()=>{o(!0),Ie(e.code).then(n,me).finally(()=>{o(!1)})},children:r.action.delete.verb})})]}),(0,Y.jsxs)(`div`,{className:`space-y-2`,children:[(0,Y.jsx)(`p`,{className:`text-xs text-muted-foreground`,children:r.alerting.recent_deliveries}),!m.read&&(0,Y.jsx)(`p`,{className:`text-xs text-faint`,children:r.shell.reading}),m.read&&h.length===0&&(0,Y.jsx)(`p`,{className:`text-xs text-faint`,children:r.alerting.deliveries_empty}),(0,Y.jsx)(`ul`,{className:`divide-y divide-border`,children:h.map(e=>(0,Y.jsxs)(`li`,{className:`row-hover -mx-4 flex items-center gap-2 px-4 py-2`,children:[(0,Y.jsx)(N,{status:e.status}),(0,Y.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-xs`,children:e.subject}),(0,Y.jsx)(H,{className:`shrink-0 text-xs text-faint`,at:e.created_at})]},e.id))})]})]})}function ct({rule:e,onDone:t,onSaved:n}){let[i,a]=(0,G.useState)(e.template??``),[o,s]=(0,G.useState)(e.body??``),[c,l]=(0,G.useState)(null),[u,d]=(0,G.useState)(!1),f=`alert-rule/${e.code}/body`,p=`rule-${e.code}-subject`;return(0,Y.jsxs)(`div`,{className:`space-y-3 rounded-lg border border-border bg-secondary/30 p-3`,children:[(0,Y.jsxs)(`div`,{className:`space-y-2`,children:[(0,Y.jsx)(j,{htmlFor:p,children:r.word.subject}),(0,Y.jsx)(C,{id:p,className:`font-mono`,spellCheck:!1,autoComplete:`off`,value:i,placeholder:r.alerting.subject_placeholder,onChange:e=>{a(e.target.value)}}),(0,Y.jsx)(`p`,{className:`text-xs text-faint`,children:Qe})]}),(0,Y.jsxs)(`div`,{className:`space-y-2`,children:[(0,Y.jsx)(j,{children:r.word.body}),(0,Y.jsx)(`p`,{className:`text-xs text-faint`,children:$e}),(0,Y.jsx)(h,{name:r.alerting.body_pane,className:`overflow-hidden rounded-md border border-border bg-background`,aside:(0,Y.jsx)(ge,{mediaType:q}),windowed:(0,Y.jsx)(R,{value:o,mediaType:q,path:f,label:r.alerting.body_pane_windowed(r.alerting.body_pane),className:`min-h-0 flex-1`,onChange:s}),children:(0,Y.jsx)(R,{value:o,mediaType:q,path:f,label:r.alerting.body_pane,placeholder:r.alerting.body_placeholder,className:`h-40 min-h-32`,onChange:s})})]}),c!==null&&(0,Y.jsx)(he,{problem:c}),(0,Y.jsxs)(`div`,{className:`flex justify-end gap-2`,children:[(0,Y.jsx)(S,{variant:`ghost`,size:`sm`,onClick:t,children:r.action.cancel}),(0,Y.jsx)(S,{size:`sm`,disabled:u,onClick:()=>{let r={};if(J(i)!==e.template&&(r.template=J(i)),J(o)!==e.body&&(r.body=J(o)),Object.keys(r).length===0){t();return}d(!0),l(null),Pe(e.code,r).then(n,e=>{l(x(e))}).finally(()=>{d(!1)})},children:u?r.action.save.busy:r.action.save.verb})]})]})}function lt({notification:e,onChanged:t}){let[n,a]=(0,G.useState)(!1),o=V();return(0,Y.jsxs)(`div`,{className:`space-y-4 p-4`,children:[(0,Y.jsx)(`div`,{className:`space-y-1`,children:(0,Y.jsxs)(`p`,{className:`flex flex-wrap items-center gap-2`,children:[(0,Y.jsx)(N,{status:e.status}),(0,Y.jsx)(`span`,{className:`text-sm font-semibold`,children:e.subject})]})}),(0,Y.jsxs)(`dl`,{className:`space-y-1.5`,children:[e.rule===null?(0,Y.jsx)(X,{label:r.alerting.raised_by,children:(0,Y.jsx)(`span`,{className:`text-muted-foreground`,children:r.alerting.raised_by_test})}):(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(X,{label:r.word.event,children:r.alerting.event[e.event]}),(0,Y.jsx)(X,{label:r.word.rule.label,children:(0,Y.jsx)(`span`,{className:`font-mono text-xs`,children:e.rule})})]}),(0,Y.jsx)(X,{label:r.word.delivers_through,children:(0,Y.jsx)(ft,{notifier:e.notifier,connection:e.connection})}),(0,Y.jsx)(X,{label:r.word.run.label,children:(0,Y.jsx)(pt,{notification:e})}),(0,Y.jsx)(X,{label:r.alerting.queued_at,children:(0,Y.jsx)(H,{at:e.created_at})}),e.status===`sent`?(0,Y.jsx)(X,{label:r.alerting.sent_at,children:(0,Y.jsx)(H,{at:e.sent_at})}):(0,Y.jsx)(X,{label:r.alerting.next_try,children:(0,Y.jsx)(H,{at:e.available_at})}),(0,Y.jsx)(X,{label:r.word.attempt.heading,children:r.alerting.attempts_of.bare(e.attempt,e.max_attempts)})]}),e.error!==null&&(0,Y.jsxs)(`div`,{className:`space-y-1`,children:[(0,Y.jsx)(`p`,{className:`text-xs text-muted-foreground`,children:r.alerting.channel_said}),(0,Y.jsx)(`p`,{className:`text-xs break-words text-critical`,children:e.error}),(0,Y.jsx)(`p`,{className:`text-xs text-faint`,children:r.alerting.latest_refusal_only})]}),(0,Y.jsxs)(`div`,{className:`flex flex-wrap gap-2`,children:[(0,Y.jsx)(l,{why:o.why,children:(0,Y.jsx)(S,{variant:`outline`,size:`sm`,disabled:n||!o.may,title:o.why,onClick:()=>{a(!0),Ve(e.id).then(t,me).finally(()=>{a(!1)})},children:r.action.retry_now})}),e.run_id!==null&&(0,Y.jsx)(S,{variant:`outline`,size:`sm`,render:(0,Y.jsx)(i,{to:`/runs/${e.run_id}`}),children:r.alerting.open_run})]})]})}var ut=e=>e.id;function dt({notifier:e,connection:t}){return(0,Y.jsxs)(`span`,{className:`flex items-center gap-1.5`,children:[(0,Y.jsx)(W,{glyph:c(e)}),(0,Y.jsx)(`span`,{className:t===null?`text-sm`:`font-mono text-xs`,children:t??e})]})}function ft({notifier:e,connection:t}){return(0,Y.jsxs)(`span`,{className:`flex flex-wrap items-baseline gap-1.5`,children:[(0,Y.jsx)(`span`,{className:`text-sm`,children:e}),t!==null&&(0,Y.jsx)(`span`,{className:`font-mono text-xs text-muted-foreground`,children:t})]})}function pt({notification:e}){if(e.run_id===null)return(0,Y.jsx)(`span`,{className:`text-muted-foreground`,children:r.alerting.no_run});let t=e.run_pipeline??r.alerting.a_run;return(0,Y.jsxs)(i,{className:`text-primary-ink hover:underline`,to:`/runs/${e.run_id}`,children:[(0,Y.jsx)(`span`,{className:`text-sm`,children:t}),e.run_started_at!==null&&(0,Y.jsx)(H,{className:`ml-1.5 text-xs text-muted-foreground`,at:e.run_started_at})]})}function mt({children:e}){return(0,Y.jsx)(`span`,{className:`rounded-sm border border-border px-1.5 text-xs text-muted-foreground`,children:e})}function ht({thing:e,children:t}){let n=D(e);return(0,Y.jsxs)(`p`,{className:`flex flex-wrap items-center gap-2`,children:[(0,Y.jsx)(`span`,{className:n.named?`text-sm font-semibold`:`font-mono text-sm font-semibold`,children:n.title}),t,n.code!==null&&(0,Y.jsx)(`span`,{className:`font-mono text-xs text-muted-foreground`,children:n.code})]})}function X({label:e,children:t}){return(0,Y.jsxs)(`div`,{className:`flex flex-wrap items-baseline gap-2`,children:[(0,Y.jsx)(`dt`,{className:`w-32 shrink-0 text-xs text-muted-foreground`,children:e}),(0,Y.jsx)(`dd`,{className:`min-w-0 text-sm`,children:t})]})}var gt={good:`var(--good)`,critical:`var(--critical)`,quiet:`var(--faint)`},_t=`flex min-h-9 items-center gap-2 rounded-full border border-border bg-card py-1 pr-3 pl-2.5 transition-colors`,Z=`hover:bg-muted focus-visible:ring-[3px] focus-visible:ring-ring/50 focus-visible:outline-none`;function vt({channels:e,read:t}){let n=f(),i=yt(e.length,t);return n?(0,Y.jsx)(St,{channels:e,note:i}):(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(`h2`,{className:`text-sm font-semibold`,children:r.alerting.channels_heading}),i===null?(0,Y.jsx)(`ul`,{className:`flex flex-wrap gap-2`,children:e.map(e=>(0,Y.jsx)(`li`,{className:`flex`,children:(0,Y.jsx)(bt,{channel:e})},e.id))}):(0,Y.jsx)(`p`,{className:i.tone,children:i.text})]})}function yt(e,t){return t?e===0?{text:r.alerting.channels_none,tone:`text-sm text-muted-foreground`}:null:{text:r.shell.reading,tone:`text-sm text-faint`}}function bt({channel:e}){let t=K(e),n=Ke(e),r=(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(W,{glyph:c(e.notifier)}),(0,Y.jsx)(`span`,{className:`truncate font-mono text-xs font-semibold`,children:Ge(e)}),(0,Y.jsx)(Q,{tone:t.tone})]}),a=n===null?(0,Y.jsx)(`button`,{type:`button`,className:_(_t,Z),children:r}):(0,Y.jsx)(i,{to:n,className:_(_t,Z),children:r});return(0,Y.jsxs)(b,{children:[(0,Y.jsx)(v,{render:a}),(0,Y.jsx)(y,{className:`flex-col items-start gap-1`,side:`bottom`,children:(0,Y.jsx)(xt,{channel:e,view:t})})]})}function xt({channel:e,view:t}){return(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsxs)(`span`,{className:`font-medium`,children:[e.notifier,` · `,t.label,e.last_check_at!==null&&(0,Y.jsxs)(`span`,{className:`font-normal opacity-70`,children:[` `,E(e.last_check_at)]})]}),e.connection!==null&&(0,Y.jsx)(`span`,{className:`font-mono`,children:e.connection}),t.detail!==null&&(0,Y.jsx)(`span`,{className:`opacity-70`,children:t.detail})]})}function St({channels:e,note:t}){let[n,i]=(0,G.useState)(!1);return(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsxs)(`button`,{type:`button`,"aria-expanded":n,onClick:()=>{i(!n)},className:_(`flex min-h-finger w-full items-center gap-2.5 border-b border-border px-1 text-left`,Z),children:[(0,Y.jsx)(s,{className:_(`size-4 shrink-0 text-muted-foreground`,n&&`rotate-90`),"aria-hidden":!0}),(0,Y.jsx)(`span`,{className:`text-sm font-semibold`,children:r.alerting.channels_heading}),(0,Y.jsx)(`span`,{className:`ml-auto flex items-center gap-1.5`,"aria-hidden":!0,children:e.map(e=>(0,Y.jsx)(Q,{tone:K(e).tone},e.id))})]}),n&&(t===null?(0,Y.jsx)(`table`,{className:`w-full text-sm`,children:(0,Y.jsx)(`tbody`,{children:e.map(e=>(0,Y.jsx)(Ct,{channel:e},e.id))})}):(0,Y.jsx)(`p`,{className:t.tone,children:t.text}))]})}function Ct({channel:e}){let t=K(e),n=Ke(e),a=(0,Y.jsxs)(`span`,{className:`flex items-center gap-2.5`,children:[(0,Y.jsx)(W,{glyph:c(e.notifier)}),(0,Y.jsx)(`span`,{className:`truncate font-mono text-xs font-semibold`,children:Ge(e)})]});return(0,Y.jsxs)(`tr`,{className:`border-b border-border last:border-b-0`,children:[(0,Y.jsx)(`td`,{className:`w-0 py-2 pr-2 align-middle`,children:(0,Y.jsx)(Q,{tone:t.tone})}),(0,Y.jsx)(`td`,{className:`min-w-0 py-2 align-middle`,children:e.connection===null||n===null?a:(0,Y.jsx)(i,{to:n,className:_(`control-link flex items-center rounded-md px-1`,Z),children:a})}),(0,Y.jsx)(`td`,{className:`w-0 py-2 pl-2 text-right align-middle whitespace-nowrap`,children:t.label===r.alerting.channel.not_set_up&&n!==null?(0,Y.jsx)(i,{to:n,className:_(`control-link inline-flex items-center rounded-md text-xs text-primary-ink`,Z),children:r.alerting.set_up_channel(e.notifier)}):e.last_check_at!==null&&(0,Y.jsx)(`span`,{className:`text-xs text-faint`,children:E(e.last_check_at)})})]})}function Q({tone:e}){return(0,Y.jsx)(`span`,{className:`status-dot`,style:{"--chip":gt[e]}})}function $({id:e,label:t,value:n,onChange:r,placeholder:i,mono:a,hint:o}){return(0,Y.jsxs)(`div`,{className:`space-y-2`,children:[(0,Y.jsx)(j,{htmlFor:e,children:t}),(0,Y.jsx)(C,{id:e,className:a===!0?`font-mono`:void 0,spellCheck:!1,autoComplete:`off`,value:n,placeholder:i,onChange:e=>{r(e.target.value)}}),o!==void 0&&(0,Y.jsx)(`p`,{className:`text-xs text-faint`,children:o})]})}function wt({id:e,options:t,value:n,onChange:i}){return(0,Y.jsxs)(`div`,{className:`space-y-2`,children:[(0,Y.jsx)(j,{htmlFor:e,children:r.word.delivers_through}),(0,Y.jsx)(_e,{id:e,label:r.word.delivers_through,value:n,options:t,placeholder:r.alerting.target_search,onChange:i})]})}var Tt=`0s`,Et=`alert-rule/new/body`,Dt=r.alerting.body_pane;function Ot({open:e,onOpenChange:t,notifiers:n,connections:i,onCreated:a}){let[o,s]=(0,G.useState)(``),[c,u]=(0,G.useState)(``),[d,f]=(0,G.useState)(``),[p,m]=(0,G.useState)(`run_failed`),[g,_]=(0,G.useState)(`global`),[v,y]=(0,G.useState)(``),[b,C]=(0,G.useState)(``),[w,T]=(0,G.useState)(``),[ee,E]=(0,G.useState)(``),[D,O]=(0,G.useState)(``),[k,A]=(0,G.useState)(Tt),[N,te]=(0,G.useState)(null),[ne,L]=(0,G.useState)(!1),z=kt(e),ae=V(),B=ie(ae.why,ot({code:o,scope:g,pipeline:v,throttle:k}));return(0,Y.jsx)(M,{open:e,onOpenChange:t,children:(0,Y.jsxs)(I,{className:`flex max-h-[calc(100vh-4rem)] flex-col sm:max-w-3xl`,showCloseButton:!1,children:[(0,Y.jsx)(P,{children:(0,Y.jsx)(F,{children:r.alerting.new_rule.button})}),(0,Y.jsxs)(`div`,{className:`-mx-1 min-h-0 flex-1 space-y-4 overflow-y-auto px-1`,children:[(0,Y.jsxs)(`div`,{className:`grid grid-cols-1 gap-3 md:grid-cols-2`,children:[(0,Y.jsx)($,{id:`rule-code`,label:r.word.code,value:o,onChange:s,placeholder:r.alerting.code_placeholder,mono:!0}),(0,Y.jsx)($,{id:`rule-name`,label:r.word.name.label,value:c,onChange:u,placeholder:r.alerting.name_placeholder})]}),(0,Y.jsx)($,{id:`rule-description`,label:r.word.description,value:d,onChange:f,placeholder:r.alerting.description_placeholder}),(0,Y.jsxs)(`div`,{className:`space-y-2`,children:[(0,Y.jsx)(j,{children:r.word.event}),(0,Y.jsx)(U,{label:r.word.event,size:`md`,value:p,options:Ce.map(e=>({value:e,label:r.alerting.event[e]})),onChoose:m})]}),(0,Y.jsxs)(`div`,{className:`grid grid-cols-1 gap-3 md:grid-cols-2`,children:[(0,Y.jsxs)(`div`,{className:`space-y-2`,children:[(0,Y.jsx)(j,{children:r.word.scope}),(0,Y.jsx)(U,{label:r.word.scope,size:`md`,value:g,options:et,onChoose:_})]}),g===`pipeline`&&(0,Y.jsxs)(`div`,{className:`space-y-2`,children:[(0,Y.jsx)(j,{htmlFor:`rule-pipeline`,children:r.word.pipeline.label}),(0,Y.jsx)(_e,{id:`rule-pipeline`,label:r.word.pipeline.label,value:v,options:z,placeholder:r.alerting.pipeline_search,onChange:y})]})]}),(0,Y.jsxs)(`div`,{className:`space-y-2`,children:[(0,Y.jsx)(j,{children:r.word.importance}),(0,Y.jsx)(`p`,{className:`text-xs text-faint`,children:r.alerting.importance_hint}),(0,Y.jsx)(U,{label:r.word.importance,size:`md`,value:b,options:tt,onChoose:C})]}),(0,Y.jsx)(`div`,{className:`grid grid-cols-1 gap-3 md:grid-cols-2`,children:(0,Y.jsx)(wt,{id:`rule-connection`,options:at(n,i),value:w,onChange:T})}),(0,Y.jsx)($,{id:`rule-subject`,label:r.word.subject,value:ee,onChange:E,placeholder:r.alerting.subject_placeholder,mono:!0,hint:Qe}),(0,Y.jsxs)(`div`,{className:`space-y-2`,children:[(0,Y.jsx)(j,{children:r.word.body}),(0,Y.jsx)(`p`,{className:`text-xs text-faint`,children:$e}),(0,Y.jsx)(h,{name:Dt,className:`overflow-hidden rounded-md border border-border bg-background`,aside:(0,Y.jsx)(ge,{mediaType:q}),windowed:(0,Y.jsx)(R,{value:D,mediaType:q,path:Et,label:r.alerting.body_pane_windowed(Dt),className:`min-h-0 flex-1`,onChange:O}),children:(0,Y.jsx)(R,{value:D,mediaType:q,path:Et,label:Dt,placeholder:r.alerting.body_placeholder,className:`h-40 min-h-32`,onChange:O})})]}),(0,Y.jsx)(`div`,{className:`grid grid-cols-1 gap-3 md:grid-cols-2`,children:(0,Y.jsx)($,{id:`rule-throttle`,label:r.word.throttle,value:k,onChange:A,placeholder:r.alerting.throttle_placeholder,mono:!0})})]}),N!==null&&(0,Y.jsx)(he,{problem:N}),(0,Y.jsxs)(re,{children:[(0,Y.jsx)(`p`,{className:`mr-auto self-center text-xs text-muted-foreground`,children:r.alerting.declare_only}),(0,Y.jsx)(oe,{render:(0,Y.jsx)(S,{variant:`ghost`}),children:r.action.close}),(0,Y.jsx)(l,{why:B,children:(0,Y.jsx)(S,{disabled:ne||B!==void 0,title:B,onClick:()=>{L(!0),te(null),Ne({code:o.trim(),name:J(c),description:J(d),event:p,scope:g,pipeline:g===`pipeline`?v:null,importance:nt(b),connection:rt(w),template:J(ee),body:J(D),throttle:k.trim()}).then(()=>{a(),s(``),u(``),f(``),E(``),O(``),t(!1)},e=>{te(x(e))}).finally(()=>{L(!1)})},children:ne?r.action.create.busy:r.action.create.verb})})]})]})})}function kt(e){let[t,n]=(0,G.useState)([]);return(0,G.useEffect)(()=>{if(!e)return;let t=!0;return A().then(e=>{t&&n(e.toSorted(O).map(e=>{let t=D(e);return{value:e.code,label:t.title,aside:t.code??``}}))},()=>{t&&n([])}),()=>{t=!1}},[e]),t}var At=1e3,jt=6e4,Mt=`dirigent test alert`,Nt={connection:``,subject:``};function Pt({open:e,draft:t,onOpenChange:n,notifiers:i,connections:a,onQueued:o,onOpenQueue:s}){let[c,u]=(0,G.useState)(t.connection),[d,f]=(0,G.useState)(t.subject),[p,m]=(0,G.useState)(null),[h,g]=(0,G.useState)(null),[_,v]=(0,G.useState)(!1),y=It(p),b=V(),C=y!==null&&Ae(y.status)?y.id:null;(0,G.useEffect)(()=>{C!==null&&o()},[C]);let w=b.why;return(0,Y.jsx)(M,{open:e,onOpenChange:n,children:(0,Y.jsxs)(I,{className:`sm:max-w-lg`,showCloseButton:!1,children:[(0,Y.jsxs)(P,{children:[(0,Y.jsx)(F,{children:r.action.send_test}),(0,Y.jsx)(ne,{children:r.alerting.test_explained})]}),(0,Y.jsx)(wt,{id:`test-connection`,options:at(i,a),value:c,onChange:u}),(0,Y.jsx)($,{id:`test-subject`,label:r.word.subject,value:d,onChange:f,placeholder:Mt}),h!==null&&(0,Y.jsx)(he,{problem:h}),y!==null&&(0,Y.jsx)(Ft,{row:y}),(0,Y.jsxs)(re,{children:[(0,Y.jsx)(oe,{render:(0,Y.jsx)(S,{variant:`ghost`}),children:r.action.close}),p!==null&&(0,Y.jsx)(S,{variant:`outline`,onClick:()=>{s(p)},children:r.alerting.open_in_queue}),(0,Y.jsx)(l,{why:w,children:(0,Y.jsx)(S,{disabled:_||w!==void 0,title:w,onClick:()=>{v(!0),g(null),m(null),He({connection:rt(c),...d.trim()===``?{}:{subject:d.trim()}}).then(e=>{m(e.notification_id),o()},e=>{g(x(e))}).finally(()=>{v(!1)})},children:p===null?r.alerting.send:r.alerting.send_again})})]})]})})}function Ft({row:e}){return(0,Y.jsxs)(`div`,{className:`space-y-2 rounded-lg border border-border bg-secondary/40 p-3`,"data-testid":`test-delivery`,"aria-live":`polite`,children:[(0,Y.jsxs)(`p`,{className:`flex flex-wrap items-center gap-2`,children:[(0,Y.jsx)(N,{status:e.status}),(0,Y.jsx)(`span`,{className:`text-sm`,children:e.subject})]}),(0,Y.jsx)(`p`,{className:`text-xs text-muted-foreground`,children:e.status===`sent`?(0,Y.jsxs)(Y.Fragment,{children:[r.alerting.delivered,` `,(0,Y.jsx)(H,{at:e.sent_at}),`.`]}):e.status===`failed`?r.alerting.given_up(e.attempt,e.max_attempts):e.attempt===0?r.alerting.queued_for_worker:(0,Y.jsxs)(Y.Fragment,{children:[r.alerting.attempt_of(e.attempt,e.max_attempts),` `,(0,Y.jsx)(H,{at:e.available_at}),`.`]})}),e.error!==null&&(0,Y.jsx)(`p`,{className:`text-xs break-words text-critical`,children:e.error})]})}function It(e){let[t,n]=(0,G.useState)(null);return(0,G.useEffect)(()=>{if(e===null)return;let t=!0,r,i=Date.now()+jt,a=()=>{Be(e).then(o=>{t&&(n({id:e,row:o}),!(Ae(o.status)||Date.now()>i)&&(r=setTimeout(a,At)))},()=>{})};return a(),()=>{t=!1,r!==void 0&&clearTimeout(r)}},[e]),t!==null&&t.id===e?t.row:null}var Lt=e=>e.id,Rt=e=>e.id;function zt(){return(0,Y.jsx)(ve,{children:(0,Y.jsx)(Bt,{})})}function Bt(){let[e,t]=(0,G.useState)(!1),[n,i]=(0,G.useState)(null),[a,o]=(0,G.useState)(null),[s,c]=(0,G.useState)(null),[l,f]=(0,G.useState)({status:``,notifier:``}),[h,g]=(0,G.useState)({}),[_,v]=(0,G.useState)({}),y=L((0,G.useCallback)(e=>Me(e),[]),Lt),b=L((0,G.useCallback)(e=>ze(l,e),[l]),Rt),x=Ut(),{reload:S}=y,{reload:C}=b,E=(0,G.useMemo)(()=>y.state.rows.map(e=>h[e.id]??e),[h,y.state.rows]),D=(0,G.useMemo)(()=>b.state.rows.map(e=>_[e.id]??e),[_,b.state.rows]),O=E.find(e=>e.id===a)??null,k=D.find(e=>e.id===s)??null,A=(0,G.useCallback)(e=>{i(t=>({draft:e,opened:(t?.opened??0)+1}))},[]);(0,G.useEffect)(()=>(B({note:null,tone:`quiet`,identifier:null}),se),[]),(0,G.useEffect)(()=>{if(O!==null){let e=O;return w([{id:`rule`,label:r.word.rule.label,render:()=>(0,Y.jsx)(st,{rule:e,onChanged:e=>{g(t=>({...t,[e.id]:e}))},onDeleted:()=>{o(null),S()},onTest:()=>{A({connection:e.connection??``,subject:``})}})}],{screen:`alerting`})}if(k!==null){let e=k;return w([{id:`notification`,label:r.word.notification.label,render:()=>(0,Y.jsx)(lt,{notification:e,onChanged:e=>{v(t=>({...t,[e.id]:e}))}})}],{screen:`alerting`})}},[k,O,A,S]);let j=V(`admin`),M=j.may;(0,G.useEffect)(()=>ae([...M?[{id:`alerting:rule`,title:r.alerting.new_rule.palette,group:z,screen:!0,icon:be,keywords:[`alert`,`event`,`create`],run:()=>{t(!0)}},{id:`alerting:test`,title:r.alerting.palette.send_test,group:z,screen:!0,icon:Se,keywords:[`alert`,`notification`,`try`],run:()=>{A(Nt)}}]:[],{id:`alerting:reload`,title:r.alerting.palette.reload,group:z,screen:!0,icon:te,keywords:[`refresh`,`reload`],run:()=>{S(),C()}}]),[M,A,C,S]);let P=e=>{c(null),o(e.id),T()},F=e=>{o(null),c(e.id),T()},I=()=>{o(null),c(null),ee()};return(0,Y.jsxs)(Y.Fragment,{children:[(0,Y.jsx)(d,{title:r.screen.alerting.name,aside:(0,Y.jsx)(p,{tag:`alerts`}),actions:[{id:`test`,label:r.action.send_test,icon:Se,variant:`outline`,disabled:!j.may,why:j.why,onClick:()=>{A(Nt)}},{id:`rule`,label:r.alerting.new_rule.button,icon:be,disabled:!j.may,why:j.why,onClick:()=>{t(!0)}}]}),(0,Y.jsx)(`section`,{className:`mb-6 space-y-2`,children:(0,Y.jsx)(vt,{channels:x.rows,read:x.read})}),(0,Y.jsxs)(`section`,{className:`space-y-2`,children:[(0,Y.jsx)(`h2`,{className:`text-sm font-semibold`,children:r.word.rule.heading}),(0,Y.jsx)(u,{loading:!y.state.read,problem:y.state.problem,empty:E.length===0,emptyMessage:r.alerting.rules_empty,children:(0,Y.jsx)(m,{columns:Gt,rows:E,rowKey:Lt,rowClassName:e=>ke(e)?void 0:`opacity-60`,reading:y.state.reading,next:y.state.next,onMore:y.more,noun:r.word.rule.count,onSelect:P,selected:e=>e.id===a,onClose:I})})]}),(0,Y.jsxs)(`section`,{className:`mt-8 space-y-2`,children:[(0,Y.jsxs)(`div`,{className:`flex flex-wrap items-center justify-between gap-2`,children:[(0,Y.jsx)(`h2`,{className:`text-sm font-semibold`,children:r.word.notification.heading}),(0,Y.jsxs)(`div`,{className:`flex flex-wrap gap-2`,children:[(0,Y.jsx)(ce,{label:r.word.status,value:l.status,anything:r.alerting.any_status,options:we.map(e=>({value:e,label:e,mark:(0,Y.jsx)(N,{status:e})})),onChange:e=>{f(t=>({...t,status:e}))}}),(0,Y.jsx)(ce,{label:r.alerting.notifier,value:l.notifier,anything:r.alerting.any_notifier,options:Ht(x.rows),onChange:e=>{f(t=>({...t,notifier:e}))}})]})]}),(0,Y.jsx)(u,{loading:!b.state.read,problem:b.state.problem,empty:D.length===0,emptyMessage:r.alerting.notifications_empty,children:(0,Y.jsx)(m,{columns:Kt,rows:D,rowKey:Rt,reading:b.state.reading,next:b.state.next,onMore:b.more,noun:r.word.notification.count,onSelect:F,selected:e=>e.id===s,onClose:I})})]}),(0,Y.jsx)(Ot,{open:e,onOpenChange:t,notifiers:Vt(x.rows),connections:x.connections,onCreated:S}),(0,Y.jsx)(Pt,{open:n!==null,draft:n?.draft??Nt,onOpenChange:e=>{e||i(null)},notifiers:Vt(x.rows),connections:x.connections,onQueued:C,onOpenQueue:e=>{i(null),o(null),c(e),C(),T()}},n?.opened??0)]})}function Vt(e){return[...new Set(e.map(e=>e.notifier))]}function Ht(e){return Vt(e).map(e=>({value:e,label:e}))}function Ut(){let[e,t]=(0,G.useState)(null),[n,r]=(0,G.useState)(null);return(0,G.useEffect)(()=>{let e=!0;return Ue().then(n=>{e&&t(n)},()=>{e&&t([])}),de().then(t=>{e&&r(t.items)},()=>{e&&r([])}),()=>{e=!1}},[]),{rows:(0,G.useMemo)(()=>We(e??[],n??[]),[n,e]),connections:n??[],read:e!==null&&n!==null}}function Wt({rule:e}){let t=Oe(e.importance);return(0,Y.jsxs)(`span`,{className:`flex flex-wrap items-baseline gap-x-1.5`,children:[(0,Y.jsx)(`span`,{className:e.scope===`pipeline`?`font-mono text-xs`:`text-sm`,children:De(e)}),t!==null&&(0,Y.jsx)(`span`,{className:`text-xs text-muted-foreground`,children:t})]})}var Gt=[{id:`rule`,header:r.word.rule.label,kind:`title`,cell:e=>{let t=D(e);return(0,Y.jsxs)(`span`,{className:`flex min-w-0 flex-col`,children:[(0,Y.jsx)(`span`,{className:_(`truncate`,t.named?`text-sm font-medium`:`font-mono text-sm font-medium`),title:t.title,children:t.title}),t.code!==null&&(0,Y.jsx)(`span`,{className:`truncate font-mono text-xs text-muted-foreground`,title:t.code,children:t.code})]})}},{id:`event`,header:r.word.event,cell:e=>(0,Y.jsx)(`span`,{className:`text-sm`,children:r.alerting.event[e.event]})},{id:`scope`,header:r.word.scope,cell:e=>(0,Y.jsx)(Wt,{rule:e})},{id:`delivers`,header:r.word.delivers_through,cell:e=>(0,Y.jsx)(dt,{notifier:e.notifier,connection:e.connection})},{id:`throttle`,header:r.word.throttle,className:`font-mono text-xs`,cell:e=>(0,Y.jsx)(`span`,{className:`text-muted-foreground`,children:Ee(e.throttle)})},{id:`sent`,header:r.alerting.last_sent,className:`text-xs`,cell:e=>e.last_sent_at===null?(0,Y.jsx)(`span`,{className:`text-muted-foreground`,children:r.word.never}):(0,Y.jsx)(H,{className:`text-muted-foreground`,at:e.last_sent_at})},{id:`live`,header:r.word.state,cell:e=>e.paused?(0,Y.jsx)(`span`,{className:`text-xs text-muted-foreground`,children:r.state.armed.paused}):e.active?(0,Y.jsx)(`span`,{className:`text-xs text-good`,children:r.state.armed.active}):(0,Y.jsx)(`span`,{className:`text-xs text-muted-foreground`,children:r.state.armed.off})}],Kt=[{id:`status`,header:r.word.status,cell:e=>(0,Y.jsx)(N,{status:e.status})},{id:`subject`,header:r.word.subject,kind:`prose`,cell:e=>(0,Y.jsxs)(`span`,{className:`flex min-w-0 flex-col`,children:[(0,Y.jsx)(`span`,{className:`truncate text-sm`,title:e.subject,children:e.subject}),e.error!==null&&(0,Y.jsx)(`span`,{className:`truncate text-xs text-critical`,title:e.error,children:e.error})]})},{id:`delivers`,header:r.word.delivers_through,cell:e=>(0,Y.jsx)(ft,{notifier:e.notifier,connection:e.connection})},{id:`run`,header:r.word.run.label,cell:e=>(0,Y.jsx)(pt,{notification:e})},{id:`queued`,header:r.alerting.queued_at,className:`text-xs`,cell:e=>(0,Y.jsx)(H,{className:`text-muted-foreground`,at:e.created_at})},{id:`sent`,header:r.alerting.sent_at,className:`text-xs`,cell:e=>e.status===`sent`?(0,Y.jsx)(H,{className:`text-muted-foreground`,at:e.sent_at}):e.attempt>0?(0,Y.jsx)(`span`,{className:`text-faint`,children:r.alerting.attempts_of.counted(e.attempt,e.max_attempts)}):null}];export{zt as AdminAlerting};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{n as t}from"./store-D-5yFBN1.js";import{t as n}from"./labels-D4COsPsJ.js";import{n as r}from"./chunk-OB3PAWPO-m4Sckj1b.js";import{n as i,t as a}from"./PageState-Dqk77uol.js";import{i as o,t as s}from"./ListTable-vD3vfJJc.js";import{r as c}from"./utils-CT7ZGLfR.js";import{a as l,o as u,r as d}from"./panels-D1Fnei43.js";import{T as f,it as p,rt as m,y as h}from"./index-C1i6SZjT.js";import{t as g}from"./Markdown-D4x5xD_I.js";import{n as _,r as v}from"./Panel-CdiywbkF.js";import{a as y,c as b,l as x,n as S,o as C,r as w,t as T}from"./blocks-Ch7prU7B.js";import{x as E}from"./connections-C45cNbZS.js";import{l as D,r as O}from"./examples-BPba0gMX.js";import{t as k}from"./KindChip-CwU_Xxdy.js";var A=e(t(),1),j=c(),M=e=>e.id,N=[{key:`scheme`,title:n.blocks.registry.scheme.title,noun:n.blocks.registry.scheme.noun},{key:`notifier`,title:n.blocks.registry.notifier.title,noun:n.blocks.registry.notifier.noun},{key:`connection`,title:n.blocks.registry.connection.title,noun:n.blocks.registry.connection.noun}],P=e=>t=>`${e}:${t.id}`,F=()=>{};function I(){let[e,t]=(0,A.useState)(``),[r,c]=(0,A.useState)(null),{value:g,problem:_,read:v}=h(b),x=h(D),S=(0,A.useMemo)(()=>O(x.value??[]),[x.value]),w=(0,A.useMemo)(()=>g?.blocks??[],[g]),E=(0,A.useMemo)(()=>y(w,e),[w,e]),k=(0,A.useMemo)(()=>T(E),[E]),I=(0,A.useMemo)(()=>C(g?.storage_schemes??[],e),[g,e]),R=(0,A.useMemo)(()=>C(g?.notifiers??[],e),[g,e]),H=(0,A.useMemo)(()=>C(g?.connection_kinds??[],e),[g,e]),U=(0,A.useMemo)(()=>L(S),[S]),W=w.find(e=>`block:${e.id}`===r)??null,G={scheme:I,notifier:R,connection:H},K=N.flatMap(e=>G[e.key].map(t=>({registry:e,entry:t}))).find(({registry:e,entry:t})=>P(e.key)(t)===r)??null;(0,A.useEffect)(()=>{if(v)return p({note:null,tone:`quiet`,identifier:null}),m},[w,v,g]),(0,A.useEffect)(()=>{if(W!==null)return l([{id:`block`,label:n.word.block.label,render:()=>(0,j.jsx)(V,{entry:W})}],{screen:`blocks`});if(K!==null){let{registry:e,entry:t}=K;return l([{id:`entry`,label:e.title,render:()=>(0,j.jsx)(B,{entry:t})}],{screen:`blocks`})}},[W,K]);let q=(0,A.useCallback)(e=>{c(`block:${e.id}`),u()},[]),J=(0,A.useCallback)(()=>{c(null),d()},[]);return(0,j.jsxs)(j.Fragment,{children:[(0,j.jsx)(a,{title:n.screen.blocks.name,aside:(0,j.jsx)(o,{tag:`blocks`})}),(0,j.jsx)(`div`,{className:`mb-4 flex flex-wrap items-center gap-2`,children:(0,j.jsx)(f,{value:e,label:n.blocks.search,onChange:t})}),(0,j.jsx)(i,{loading:!v,problem:_,empty:E.length===0&&I.length===0&&R.length===0&&H.length===0,emptyMessage:w.length===0?n.blocks.empty:n.blocks.empty_filtered,children:(0,j.jsxs)(`div`,{className:`flex flex-col gap-6`,children:[k.map(([e,t])=>(0,j.jsxs)(`section`,{children:[(0,j.jsx)(`h2`,{className:`mb-1.5 font-mono text-xs font-semibold tracking-wide text-faint uppercase`,children:e}),(0,j.jsx)(s,{chrome:{footer:!1},columns:U,rows:t,rowKey:M,reading:!1,next:null,onMore:F,noun:n.word.block.count,onSelect:q,selected:e=>`block:${e.id}`===r,onClose:J})]},e)),N.map(e=>{let t=G[e.key];return t.length===0?null:(0,j.jsxs)(`section`,{children:[(0,j.jsx)(`h2`,{className:`mb-1.5 font-mono text-xs font-semibold tracking-wide text-faint uppercase`,children:e.title}),(0,j.jsx)(s,{chrome:{footer:!1},columns:z(e.key),rows:t,rowKey:P(e.key),reading:!1,next:null,onMore:F,noun:e.noun,onSelect:t=>{c(P(e.key)(t)),u()},selected:t=>P(e.key)(t)===r,onClose:J})]},e.key)})]})})]})}function L(e){return[{id:`block`,header:n.word.block.label,kind:`title`,cell:e=>(0,j.jsxs)(`div`,{className:`min-w-0`,children:[(0,j.jsx)(`span`,{className:`font-mono text-sm font-semibold`,children:e.id}),(0,j.jsx)(`p`,{className:`truncate text-xs text-muted-foreground`,title:e.summary,children:e.summary})]})},{id:`kind`,header:n.word.kind.label,className:`min-w-32 whitespace-nowrap`,cell:e=>(0,j.jsx)(k,{kind:e.kind})},{id:`examples`,header:n.word.example.heading,className:`min-w-28 whitespace-nowrap`,cell:t=>(0,j.jsx)(R,{id:t.id,many:e.get(t.id)??0})},{id:`plugin`,header:n.word.plugin.label,className:`min-w-36 font-mono text-xs whitespace-nowrap`,cell:e=>(0,j.jsx)(`span`,{className:`text-muted-foreground`,children:e.plugin})}]}function R({id:e,many:t}){if(t===0)return(0,j.jsx)(`span`,{className:`text-xs text-faint`,children:n.word.none});let i=(t===1?n.blocks.example_count.one:n.blocks.example_count.many)(String(t));return(0,j.jsx)(r,{className:`text-xs text-primary-ink hover:underline`,to:`/examples?block=${encodeURIComponent(e)}`,title:n.blocks.example_link(e),onClick:e=>{e.stopPropagation()},children:i})}function z(e){let t=e===`scheme`?`storage`:e;return[{id:`entry`,header:n.blocks.entry_header,kind:`title`,cell:e=>{let t=typeof e.config_schema.description==`string`?e.config_schema.description:``;return(0,j.jsxs)(`div`,{className:`min-w-0`,children:[(0,j.jsx)(`span`,{className:`font-mono text-sm font-semibold`,children:e.id}),(0,j.jsx)(`p`,{className:`truncate text-xs text-muted-foreground`,title:t,children:t})]})}},{id:`kind`,header:n.word.kind.label,className:`min-w-32 whitespace-nowrap`,cell:()=>(0,j.jsx)(k,{kind:t})},{id:`plugin`,header:n.word.plugin.label,className:`min-w-36 font-mono text-xs whitespace-nowrap`,cell:e=>(0,j.jsx)(`span`,{className:`text-muted-foreground`,children:e.plugin})}]}function B({entry:e}){let t=(0,A.useMemo)(()=>E(e.config_schema),[e]),r=typeof e.config_schema.description==`string`?e.config_schema.description:null;return(0,j.jsxs)(`div`,{className:`flex flex-col gap-4 p-4`,children:[(0,j.jsxs)(`div`,{className:`space-y-1`,children:[(0,j.jsx)(`h2`,{className:`font-mono text-sm font-semibold`,children:e.id}),r!==null&&(0,j.jsx)(`p`,{className:`text-sm text-muted-foreground`,children:r}),(0,j.jsx)(`dl`,{className:`grid grid-cols-[auto_1fr] gap-x-3 gap-y-1 text-xs`,children:(0,j.jsx)(_,{term:n.blocks.fact.term.plugin,detail:e.plugin})})]}),(0,j.jsx)(v,{title:n.word.config,children:t.length===0?(0,j.jsx)(`p`,{className:`text-sm text-muted-foreground`,children:n.form.no_configuration}):(0,j.jsx)(`div`,{className:`flex flex-col gap-4`,children:t.map(e=>(0,j.jsx)(H,{field:e},e.name))})})]})}function V({entry:e}){let t=(0,A.useMemo)(()=>E(e.config_schema),[e]),r=w(e);return(0,j.jsxs)(`div`,{className:`flex flex-col gap-4 p-4`,children:[(0,j.jsxs)(`div`,{className:`space-y-1`,children:[(0,j.jsx)(`h2`,{className:`font-mono text-sm font-semibold`,children:e.id}),(0,j.jsx)(`p`,{children:(0,j.jsx)(k,{kind:e.kind})}),(0,j.jsx)(`p`,{className:`text-sm text-muted-foreground`,children:e.summary})]}),(0,j.jsx)(v,{title:n.blocks.facts_section,children:(0,j.jsx)(`dl`,{className:`grid grid-cols-[auto_1fr] gap-x-3 gap-y-1 text-xs`,children:r.map(e=>(0,j.jsx)(_,{term:e.term,detail:e.detail},e.term))})}),(0,j.jsx)(v,{title:n.word.config,children:t.length===0?(0,j.jsx)(`p`,{className:`text-sm text-muted-foreground`,children:n.form.no_configuration}):(0,j.jsx)(`div`,{className:`flex flex-col gap-4`,children:t.map(e=>(0,j.jsx)(H,{field:e},e.name))})})]})}function H({field:e}){let t=S(e);return(0,j.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[(0,j.jsxs)(`div`,{className:`flex flex-wrap items-baseline gap-x-2`,children:[(0,j.jsx)(`span`,{className:`font-mono text-sm font-medium`,children:e.name}),(0,j.jsx)(`span`,{className:`text-xs text-muted-foreground`,children:x(e)}),e.required&&(0,j.jsx)(`span`,{className:`text-xs text-primary-ink`,children:n.blocks.field_required}),e.hint!==null&&(0,j.jsx)(`span`,{className:`text-xs text-faint`,children:e.hint}),t!==null&&(0,j.jsxs)(`span`,{className:`text-xs text-faint`,children:[n.blocks.field_default,` `,t]})]}),e.options.length>0&&(0,j.jsx)(`p`,{className:`font-mono text-xs text-muted-foreground`,children:e.options.map(e=>e.label).join(` · `)}),e.help!==null&&(0,j.jsx)(`p`,{className:`text-xs text-muted-foreground`,children:(0,j.jsx)(g,{text:e.help})})]})}export{I as Blocks};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{n as t}from"./store-D-5yFBN1.js";import{t as n}from"./labels-D4COsPsJ.js";import{n as r}from"./chunk-OB3PAWPO-m4Sckj1b.js";import{r as i,t as a}from"./utils-CT7ZGLfR.js";var o=e(t(),1),s=i();function c({trail:e,code:t}){return(0,s.jsxs)(`nav`,{className:`flex min-w-0 items-center gap-1.5 text-sm`,"aria-label":n.shell.breadcrumb,title:e.map(e=>e.label).join(` / `),children:[e.map((t,n)=>{let i=n===e.length-1,c=i||t.keep===!0,l=e.slice(0,n).some(e=>e.keep===!0);return(0,s.jsxs)(o.Fragment,{children:[n>0&&(0,s.jsx)(`span`,{className:a(`text-faint`,!(c&&l)&&`hidden md:inline`),"aria-hidden":!0,children:`/`}),t.to===void 0?(0,s.jsx)(`span`,{title:t.title,className:a(`min-w-0 truncate`,i&&`font-medium`,t.mono===!0&&`font-mono`,!c&&`hidden md:inline`),children:t.label}):(0,s.jsx)(r,{to:t.to,title:t.title,className:a(`min-w-0 truncate text-muted-foreground hover:text-foreground`,t.mono===!0&&`font-mono`,!c&&`hidden md:inline`),children:t.label})]},`${t.label}-${String(n)}`)}),t!=null&&(0,s.jsx)(`span`,{className:`min-w-0 truncate font-mono text-xs text-muted-foreground`,children:t})]})}export{c as t};
|