@hearsay-tools/squawk 0.19.0-dev.9172 → 0.19.0-dev.9182
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.
- package/dist/contract/hosts.d.ts +925 -0
- package/dist/contract/index.js +104 -2
- package/dist/core/server-hook-registry.d.ts +13 -0
- package/dist/core/server-hook-registry.js.map +1 -1
- package/dist/delegation/transport.d.ts +78 -78
- package/dist/features/automations/automations-routes.d.ts +150 -150
- package/dist/features/hosts/admission.d.ts +52 -0
- package/dist/features/hosts/admission.js +89 -0
- package/dist/features/hosts/admission.js.map +1 -0
- package/dist/features/hosts/gateway.d.ts +14 -3
- package/dist/features/hosts/gateway.js +35 -21
- package/dist/features/hosts/gateway.js.map +1 -1
- package/dist/features/hosts/index.d.ts +7 -3
- package/dist/features/hosts/index.js +41 -7
- package/dist/features/hosts/index.js.map +1 -1
- package/dist/features/hosts/registry-reconciler.d.ts +41 -0
- package/dist/features/hosts/registry-reconciler.js +168 -0
- package/dist/features/hosts/registry-reconciler.js.map +1 -0
- package/dist/features/hosts/routes.d.ts +370 -4
- package/dist/features/hosts/routes.js +72 -62
- package/dist/features/hosts/routes.js.map +1 -1
- package/dist/features/hosts/runs-index-events.d.ts +23 -0
- package/dist/features/hosts/runs-index-events.js +116 -0
- package/dist/features/hosts/runs-index-events.js.map +1 -0
- package/dist/features/hosts/runs-index-patch.d.ts +203 -0
- package/dist/features/hosts/runs-index-patch.js +798 -0
- package/dist/features/hosts/runs-index-patch.js.map +1 -0
- package/dist/features/hosts/runs-index.d.ts +149 -0
- package/dist/features/hosts/runs-index.js +762 -0
- package/dist/features/hosts/runs-index.js.map +1 -0
- package/dist/features/hosts/runs-search.d.ts +28 -0
- package/dist/features/hosts/runs-search.js +151 -0
- package/dist/features/hosts/runs-search.js.map +1 -0
- package/dist/features/hosts/supervisor.d.ts +4 -0
- package/dist/features/hosts/supervisor.js +14 -6
- package/dist/features/hosts/supervisor.js.map +1 -1
- package/dist/plugin/index.d.ts +1 -1
- package/dist/plugin/index.js.map +1 -1
- package/dist/server/repo-routes.d.ts +52 -52
- package/dist/server/server.js +7 -1
- package/dist/server/server.js.map +1 -1
- package/dist/server/workspace-run-feed.d.ts +4 -0
- package/dist/server/workspace-run-feed.js +13 -0
- package/dist/server/workspace-run-feed.js.map +1 -1
- package/package.json +4 -4
- package/scripts/benchmark-hosts-runs-index-probes.ts +242 -0
- package/scripts/benchmark-hosts-runs-index.ts +776 -0
- package/web/dist/assets/accounts-section-DYQC-wSh.js +1 -0
- package/web/dist/assets/activity-motion-XvrmbNgR.js +1 -0
- package/web/dist/assets/{activity-route-C2zP5vVV.js → activity-route-Dj8ltoqG.js} +1 -1
- package/web/dist/assets/{agent-accounts-D_ZKAmaW.js → agent-accounts-C2ILQhZy.js} +1 -1
- package/web/dist/assets/{agent-config-section-CwK_izpU.js → agent-config-section-D16TRCE_.js} +2 -2
- package/web/dist/assets/agent-defaults-section-Dm0khLjs.js +1 -0
- package/web/dist/assets/{appearance-DvoRcoRX.js → appearance-CP6zVctf.js} +1 -1
- package/web/dist/assets/{archive-on-merge-field-DWPtF9dh.js → archive-on-merge-field-BA8aUtRQ.js} +1 -1
- package/web/dist/assets/{ask-card-D-om0EtP.js → ask-card-CLdlwd68.js} +1 -1
- package/web/dist/assets/attention-C7BUdd2s.js +1 -0
- package/web/dist/assets/automations-route-BVDO_Kai.js +2 -0
- package/web/dist/assets/{commit-list-CPJLP4DU.js → commit-list-Bdekr2K7.js} +1 -1
- package/web/dist/assets/{diff-BQJN6jzN.js → diff-Du0FsqAK.js} +2 -2
- package/web/dist/assets/{diff-controls-AsSX7gfO.js → diff-controls-DTC_6oqk.js} +1 -1
- package/web/dist/assets/{diff-view-BW5bbiaq.js → diff-view-TKooupFV.js} +1 -1
- package/web/dist/assets/{discard-changes-dialog-Bv4yc0N1.js → discard-changes-dialog-Bg-3Xbox.js} +1 -1
- package/web/dist/assets/{file-preview-CnrFxbea.js → file-preview-DMJCprVk.js} +1 -1
- package/web/dist/assets/{folder-browser-CFd1U5hn.js → folder-browser-3cBLlnE9.js} +1 -1
- package/web/dist/assets/{git-toolbar-C7iolhIi.js → git-toolbar-COhBdctn.js} +1 -1
- package/web/dist/assets/github-DUTSv2Hs.js +1 -0
- package/web/dist/assets/{global-activity-route-Dijwg4OL.js → global-activity-route-CypEKUv_.js} +1 -1
- package/web/dist/assets/hosts-iUyg8S3j.js +1 -0
- package/web/dist/assets/index-BV3EQb9T.js +21 -0
- package/web/dist/assets/index-Bh7COq0B.css +1 -0
- package/web/dist/assets/{label-CgU9vxuM.js → label-CWlxyeC-.js} +1 -1
- package/web/dist/assets/{markdown-Cljq4S1h.js → markdown-0uCxcToP.js} +1 -1
- package/web/dist/assets/{open-in-menu-BI7mnPPf.js → open-in-menu-Bf8JA2DJ.js} +1 -1
- package/web/dist/assets/{option-select-BcTkv-7t.js → option-select-DQJEHmHf.js} +1 -1
- package/web/dist/assets/{preferences-section-CEKXGhEj.js → preferences-section-Cvl5vyfN.js} +1 -1
- package/web/dist/assets/{preview-EtD19mg1.js → preview-BSFJfN4s.js} +1 -1
- package/web/dist/assets/{preview-pane-connected-CKRBfx7t.js → preview-pane-connected-i3GJtDL3.js} +2 -2
- package/web/dist/assets/{project-location-hufc_p8y.js → project-location-BcjOhqun.js} +1 -1
- package/web/dist/assets/{project-router-Dc6KBQsv.js → project-router-CwD1firw.js} +1 -1
- package/web/dist/assets/{projects-section-vOFZ4lbx.js → projects-section-CAOFPkDQ.js} +1 -1
- package/web/dist/assets/{prompt-templates-section-Caash2nq.js → prompt-templates-section-BXTfLET4.js} +1 -1
- package/web/dist/assets/queries-D9mg7sFY.js +1 -0
- package/web/dist/assets/{read-state-BeVNfGkB.js → read-state-BsTfJki5.js} +1 -1
- package/web/dist/assets/{reference-chip-BjerVjzM.js → reference-chip-CZKBU_Ud.js} +1 -1
- package/web/dist/assets/{remote-settings-notice-fNgh5LdN.js → remote-settings-notice-CUK4ZFYF.js} +1 -1
- package/web/dist/assets/repo-git-Dx85MEuK.js +1 -0
- package/web/dist/assets/{report-reader-CK1WDtEH.js → report-reader-BDdY5kpz.js} +1 -1
- package/web/dist/assets/{report-selection-CZ8eb9QP.js → report-selection-Y2F9NTAs.js} +1 -1
- package/web/dist/assets/{reports-B-GImLAo.js → reports-DWKpm_us.js} +1 -1
- package/web/dist/assets/{resources-section-ApF3gXrw.js → resources-section-D9tzbv9w.js} +1 -1
- package/web/dist/assets/{review-notes-drafts-BdjEFs1G.js → review-notes-drafts-BSkmq3Nj.js} +1 -1
- package/web/dist/assets/{review-panel-D4zmYH8O.js → review-panel-C9UZjWFl.js} +1 -1
- package/web/dist/assets/{review-strip-BpHXklAn.js → review-strip-qTG5JaOw.js} +1 -1
- package/web/dist/assets/{run-detail-refresh-CE0vyYYA.js → run-detail-refresh-SYZM94ch.js} +1 -1
- package/web/dist/assets/{run-diff-ClfLRsHF.js → run-diff-D26PXp6r.js} +1 -1
- package/web/dist/assets/run-header-BrUcSJu6.js +2 -0
- package/web/dist/assets/{select-CwDhRDtw.js → select-BUsS7uOZ.js} +1 -1
- package/web/dist/assets/{session-context-section-C87jx7RB.js → session-context-section-Bgzou-NG.js} +1 -1
- package/web/dist/assets/{settings-agent-picker-Dk8yJ57U.js → settings-agent-picker-CH3CQhOh.js} +1 -1
- package/web/dist/assets/{settings-save-bar-cu8BKCGT.js → settings-save-bar-cyvALSgW.js} +1 -1
- package/web/dist/assets/{settings-shell-mhQfQKf1.js → settings-shell-Cl-cu4r5.js} +1 -1
- package/web/dist/assets/{sidebar-section-DOQ5N1L6.js → sidebar-section-Cj2fDrhV.js} +1 -1
- package/web/dist/assets/{skills-DXJ1gQBD.js → skills-DLMbRR_5.js} +1 -1
- package/web/dist/assets/{status-dot-Bmn4xhch.js → status-dot-DTU7afRv.js} +1 -1
- package/web/dist/assets/{tab-link-6TltE1jl.js → tab-link-BJDe5cT4.js} +1 -1
- package/web/dist/assets/{task-changes-D9Sdmpmw.js → task-changes-ito4fOGh.js} +2 -2
- package/web/dist/assets/{task-commits-A0UIqxpL.js → task-commits-BYOIU9zy.js} +1 -1
- package/web/dist/assets/{task-file-scope-ID220XKo.js → task-file-scope-B8EEJyHp.js} +1 -1
- package/web/dist/assets/{task-files-Id2tuAAG.js → task-files-CF0QKnm-.js} +1 -1
- package/web/dist/assets/{task-github-item-YKUcwp2o.js → task-github-item-C6Fu8MvM.js} +1 -1
- package/web/dist/assets/{task-groups-DCg4iOB9.js → task-groups-BvVfsQKd.js} +1 -1
- package/web/dist/assets/{task-thread-A_vkygGX.js → task-thread-BWrvepxB.js} +2 -2
- package/web/dist/assets/{thread-state-6-BzRrJ_.js → thread-state-8E0eYXGu.js} +1 -1
- package/web/dist/assets/toaster-2ud_VdfV.js +4 -0
- package/web/dist/assets/{use-finish-run-DO-nnAaa.js → use-finish-run-a2qZy6zr.js} +1 -1
- package/web/dist/assets/{use-hand-to-agent-state-CADaL8U8.js → use-hand-to-agent-state-DT1ngmHe.js} +1 -1
- package/web/dist/assets/use-path-bases-CZ6F93wt.js +1 -0
- package/web/dist/assets/use-workspace-config-save-DDI7_WtK.js +1 -0
- package/web/dist/assets/{workflows-DOLG-Rns.js → workflows-2e0Sm6F1.js} +2 -2
- package/web/dist/assets/{workspace-tools-DTCJVDTE.js → workspace-tools-D4DO9w12.js} +1 -1
- package/web/dist/assets/{worktrees-section-BOHDbywt.js → worktrees-section-8-d6zWQ-.js} +5 -5
- package/web/dist/index.html +20 -20
- package/web/dist/assets/accounts-section-Bnr89jmC.js +0 -1
- package/web/dist/assets/activity-motion-BW0tAmYF.js +0 -1
- package/web/dist/assets/agent-defaults-section-RyEogH0g.js +0 -1
- package/web/dist/assets/attention-BI6592lk.js +0 -1
- package/web/dist/assets/automations-route-DfGE4xWT.js +0 -2
- package/web/dist/assets/github-DGElvfMU.js +0 -1
- package/web/dist/assets/hosts-CpDMDiQW.js +0 -1
- package/web/dist/assets/index-BVRdRJAN.css +0 -1
- package/web/dist/assets/index-DPfg7xSB.js +0 -21
- package/web/dist/assets/queries-IlC9MZgh.js +0 -1
- package/web/dist/assets/repo-git-5MK_RAR6.js +0 -1
- package/web/dist/assets/run-header-BUe92WWr.js +0 -2
- package/web/dist/assets/toaster-DNnL8v10.js +0 -4
- package/web/dist/assets/use-path-bases-CFAmFn_E.js +0 -1
- package/web/dist/assets/use-workspace-config-save-DScW6_8J.js +0 -1
package/dist/contract/index.js
CHANGED
|
@@ -6502,11 +6502,21 @@ var agentToolCatalogSchema = z60.object({ tools: z60.array(agentToolMetadataSche
|
|
|
6502
6502
|
import { z as z61 } from "zod";
|
|
6503
6503
|
var HOST_ID_PATTERN = /^[a-z0-9][a-z0-9-]{0,31}$/;
|
|
6504
6504
|
var LOCAL_HOST_ID = "local";
|
|
6505
|
+
var RESERVED_HOST_ROUTE_IDS = ["projects", "runs-index", "runs-search"];
|
|
6506
|
+
var RESERVED_HOST_ROUTE_ID_SET = new Set(RESERVED_HOST_ROUTE_IDS);
|
|
6505
6507
|
var CONTROL_CHARS_PATTERN = /[\u0000-\u001f\u007f]/;
|
|
6506
6508
|
var INVALID_SSH_ALIAS_CHARS = /[\s*?![\]\\'"`]/;
|
|
6507
6509
|
var hostIdSchema = z61.string().regex(HOST_ID_PATTERN, "host id must match ^[a-z0-9][a-z0-9-]{0,31}$").refine((value) => value !== LOCAL_HOST_ID, {
|
|
6508
6510
|
message: `host id "${LOCAL_HOST_ID}" is reserved`
|
|
6509
6511
|
});
|
|
6512
|
+
var createHostIdSchema = hostIdSchema.superRefine((value, ctx) => {
|
|
6513
|
+
if (RESERVED_HOST_ROUTE_ID_SET.has(value)) {
|
|
6514
|
+
ctx.addIssue({
|
|
6515
|
+
code: "custom",
|
|
6516
|
+
message: `host id "${value}" is reserved`
|
|
6517
|
+
});
|
|
6518
|
+
}
|
|
6519
|
+
});
|
|
6510
6520
|
var hostLabelSchema = z61.string().trim().min(1, "label must not be empty").max(255, "label must be at most 255 characters").refine((value) => !CONTROL_CHARS_PATTERN.test(value), {
|
|
6511
6521
|
message: "label must not contain control characters"
|
|
6512
6522
|
});
|
|
@@ -6580,13 +6590,13 @@ var hostRouteParamsSchema = z61.object({
|
|
|
6580
6590
|
});
|
|
6581
6591
|
var createHostInputSchema = z61.object({
|
|
6582
6592
|
sshAlias: hostSshAliasSchema,
|
|
6583
|
-
id:
|
|
6593
|
+
id: createHostIdSchema.optional(),
|
|
6584
6594
|
label: hostLabelSchema.optional(),
|
|
6585
6595
|
port: hostPortSchema.optional()
|
|
6586
6596
|
}).strict().superRefine((data, ctx) => {
|
|
6587
6597
|
if (data.id !== void 0) return;
|
|
6588
6598
|
const derived = slugHostId(data.sshAlias);
|
|
6589
|
-
const parsed =
|
|
6599
|
+
const parsed = createHostIdSchema.safeParse(derived);
|
|
6590
6600
|
if (!parsed.success) {
|
|
6591
6601
|
ctx.addIssue({
|
|
6592
6602
|
code: "custom",
|
|
@@ -6752,6 +6762,79 @@ var hostsProjectsResponseSchema = z61.object({
|
|
|
6752
6762
|
hosts: z61.array(hostProjectsEntrySchema),
|
|
6753
6763
|
warning: z61.string().optional()
|
|
6754
6764
|
});
|
|
6765
|
+
var hostRunIndexEntrySchema = runIndexEntrySchema.extend({
|
|
6766
|
+
hostId: hostIdSchema
|
|
6767
|
+
});
|
|
6768
|
+
var hostRunsIndexStateSchema = z61.object({
|
|
6769
|
+
id: hostIdSchema,
|
|
6770
|
+
label: hostLabelSchema,
|
|
6771
|
+
state: hostStateSchema,
|
|
6772
|
+
/** True while the host is not connected and live-synced; cached rows may be behind the host. */
|
|
6773
|
+
stale: z61.boolean(),
|
|
6774
|
+
/** True once the main server has read the host's task index at least once since starting. */
|
|
6775
|
+
loaded: z61.boolean(),
|
|
6776
|
+
/** Project ids on this host that hit `perProjectLimit` for archived root runs. */
|
|
6777
|
+
truncated: z61.array(z61.string()),
|
|
6778
|
+
/** Cached PR/issue reference statuses per project id from the host's latest snapshot. */
|
|
6779
|
+
referenceStatuses: referenceStatusesByProjectSchema,
|
|
6780
|
+
/** Per-project archived window reported by the host's latest snapshot, when loaded. */
|
|
6781
|
+
perProjectLimit: z61.number().int().nonnegative().optional()
|
|
6782
|
+
});
|
|
6783
|
+
var hostsRunsIndexQuerySchema = z61.object({
|
|
6784
|
+
/** When set, returns rows and state for that single saved host only. */
|
|
6785
|
+
hostId: hostIdSchema.optional()
|
|
6786
|
+
});
|
|
6787
|
+
var hostsRunsIndexResponseSchema = z61.object({
|
|
6788
|
+
runs: z61.array(hostRunIndexEntrySchema),
|
|
6789
|
+
hosts: z61.array(hostRunsIndexStateSchema),
|
|
6790
|
+
generation: z61.string().min(1),
|
|
6791
|
+
eventSeq: z61.number().int().nonnegative(),
|
|
6792
|
+
warning: z61.string().optional()
|
|
6793
|
+
});
|
|
6794
|
+
var HOST_SEARCH_UNANSWERED_REASONS = ["not-connected", "deadline", "error"];
|
|
6795
|
+
var hostSearchUnansweredReasonSchema = z61.enum(HOST_SEARCH_UNANSWERED_REASONS);
|
|
6796
|
+
var hostSearchUnansweredSchema = z61.object({
|
|
6797
|
+
hostId: hostIdSchema,
|
|
6798
|
+
label: hostLabelSchema,
|
|
6799
|
+
state: hostStateSchema,
|
|
6800
|
+
reason: hostSearchUnansweredReasonSchema
|
|
6801
|
+
});
|
|
6802
|
+
var hostTruncatedProjectSchema = z61.object({
|
|
6803
|
+
hostId: hostIdSchema,
|
|
6804
|
+
projectId: z61.string()
|
|
6805
|
+
});
|
|
6806
|
+
var hostsRunsSearchResponseSchema = z61.object({
|
|
6807
|
+
runs: z61.array(hostRunIndexEntrySchema),
|
|
6808
|
+
truncated: z61.array(hostTruncatedProjectSchema),
|
|
6809
|
+
unanswered: z61.array(hostSearchUnansweredSchema),
|
|
6810
|
+
warning: z61.string().optional()
|
|
6811
|
+
});
|
|
6812
|
+
var HOSTS_CHANGED_EVENT = "hosts-changed";
|
|
6813
|
+
var hostsChangedEventSchema = z61.object({
|
|
6814
|
+
hostIds: z61.array(hostIdSchema).min(1),
|
|
6815
|
+
stateChanged: z61.boolean(),
|
|
6816
|
+
indexChanged: z61.boolean()
|
|
6817
|
+
});
|
|
6818
|
+
var HOST_RUN_SUMMARY_EVENT = "host-run-summary";
|
|
6819
|
+
var hostRunSummaryEventSchema = z61.object({
|
|
6820
|
+
hostId: hostIdSchema,
|
|
6821
|
+
project: z61.string().min(1),
|
|
6822
|
+
seq: z61.number().int().positive(),
|
|
6823
|
+
run: runSummarySchema
|
|
6824
|
+
});
|
|
6825
|
+
var HOST_RUN_DELETED_EVENT = "host-run-deleted";
|
|
6826
|
+
var hostRunDeletedEventSchema = z61.object({
|
|
6827
|
+
hostId: hostIdSchema,
|
|
6828
|
+
project: z61.string().min(1),
|
|
6829
|
+
seq: z61.number().int().positive(),
|
|
6830
|
+
id: z61.string().min(1)
|
|
6831
|
+
});
|
|
6832
|
+
var HOST_USAGE_EVENT = "host-usage";
|
|
6833
|
+
var hostUsageEventSchema = z61.object({
|
|
6834
|
+
hostId: hostIdSchema,
|
|
6835
|
+
project: z61.string().min(1),
|
|
6836
|
+
usage: z61.record(z61.string(), processUsageSchema)
|
|
6837
|
+
});
|
|
6755
6838
|
export {
|
|
6756
6839
|
ACTIVITY_CHECKS_MAX,
|
|
6757
6840
|
ACTIVITY_CHECK_NAME_MAX,
|
|
@@ -6788,10 +6871,15 @@ export {
|
|
|
6788
6871
|
HANDOFF_AUTOSAVE_RECORDS_MAX,
|
|
6789
6872
|
HOME_FILE_PATTERN,
|
|
6790
6873
|
HOME_RECOVERY_REASONS,
|
|
6874
|
+
HOSTS_CHANGED_EVENT,
|
|
6791
6875
|
HOST_GATEWAY_ERROR_CODES,
|
|
6792
6876
|
HOST_ID_PATTERN,
|
|
6793
6877
|
HOST_NOT_CONNECTED_REASON,
|
|
6878
|
+
HOST_RUN_DELETED_EVENT,
|
|
6879
|
+
HOST_RUN_SUMMARY_EVENT,
|
|
6880
|
+
HOST_SEARCH_UNANSWERED_REASONS,
|
|
6794
6881
|
HOST_STATES,
|
|
6882
|
+
HOST_USAGE_EVENT,
|
|
6795
6883
|
HUMAN_ASK_EVENT_TYPES,
|
|
6796
6884
|
ISOLATED_BASELINE_REFUSAL,
|
|
6797
6885
|
LAST_WAITS_LIMIT,
|
|
@@ -6830,6 +6918,7 @@ export {
|
|
|
6830
6918
|
REFERENCE_STATUS_MAX,
|
|
6831
6919
|
RENEW_MS,
|
|
6832
6920
|
REPORTS_QUERY_MAX,
|
|
6921
|
+
RESERVED_HOST_ROUTE_IDS,
|
|
6833
6922
|
RETENTION_RUN_RULE,
|
|
6834
6923
|
RUNS_SEARCH_PER_PROJECT_MAX,
|
|
6835
6924
|
RUN_HISTORY_PAGE_ITEMS,
|
|
@@ -7016,6 +7105,7 @@ export {
|
|
|
7016
7105
|
createAgentProfileInputSchema,
|
|
7017
7106
|
createAgentProfileSchema,
|
|
7018
7107
|
createAutomationInputSchema,
|
|
7108
|
+
createHostIdSchema,
|
|
7019
7109
|
createHostInputSchema,
|
|
7020
7110
|
createPrResponseSchema,
|
|
7021
7111
|
createProjectInputSchema,
|
|
@@ -7118,6 +7208,12 @@ export {
|
|
|
7118
7208
|
hostProjectsEntrySchema,
|
|
7119
7209
|
hostResponseSchema,
|
|
7120
7210
|
hostRouteParamsSchema,
|
|
7211
|
+
hostRunDeletedEventSchema,
|
|
7212
|
+
hostRunIndexEntrySchema,
|
|
7213
|
+
hostRunSummaryEventSchema,
|
|
7214
|
+
hostRunsIndexStateSchema,
|
|
7215
|
+
hostSearchUnansweredReasonSchema,
|
|
7216
|
+
hostSearchUnansweredSchema,
|
|
7121
7217
|
hostServerActiveTasksResultSchema,
|
|
7122
7218
|
hostServerClaimPhaseSchema,
|
|
7123
7219
|
hostServerClaimSummarySchema,
|
|
@@ -7132,9 +7228,15 @@ export {
|
|
|
7132
7228
|
hostStarterInstallIdSchema,
|
|
7133
7229
|
hostStateSchema,
|
|
7134
7230
|
hostSummarySchema,
|
|
7231
|
+
hostTruncatedProjectSchema,
|
|
7232
|
+
hostUsageEventSchema,
|
|
7233
|
+
hostsChangedEventSchema,
|
|
7135
7234
|
hostsListResponseSchema,
|
|
7136
7235
|
hostsProjectsResponseSchema,
|
|
7137
7236
|
hostsRegistryFileSchema,
|
|
7237
|
+
hostsRunsIndexQuerySchema,
|
|
7238
|
+
hostsRunsIndexResponseSchema,
|
|
7239
|
+
hostsRunsSearchResponseSchema,
|
|
7138
7240
|
humanAskClosedEventSchema,
|
|
7139
7241
|
humanInputDeliveredEventSchema,
|
|
7140
7242
|
humanWaitEntrySchema,
|
|
@@ -55,6 +55,18 @@ export interface ServerWorkspaceEventsPort {
|
|
|
55
55
|
emit(event: string, data: unknown): void;
|
|
56
56
|
on(listener: (event: string, data: unknown) => void): () => void;
|
|
57
57
|
}
|
|
58
|
+
/**
|
|
59
|
+
* Structural port for publishing summary-mode SSE frames to `GET /api/v1/workspace/events?runs=summary`
|
|
60
|
+
* subscribers only, without touching the local run feed's sequence counter.
|
|
61
|
+
*/
|
|
62
|
+
export interface ServerWorkspaceSummaryFeedPort {
|
|
63
|
+
/** Process-wide generation id matching `ready.generation` on `/api/v1/workspace/events`. */
|
|
64
|
+
readonly generation: string;
|
|
65
|
+
/** Write one pre-serialized SSE frame to every `?runs=summary` subscriber only. */
|
|
66
|
+
emitSummary(event: string, data: string): void;
|
|
67
|
+
/** True when at least one `?runs=summary` client is currently connected. */
|
|
68
|
+
hasSummarySubscribers(): boolean;
|
|
69
|
+
}
|
|
58
70
|
/** Structural port over a resolved forge driver's availability probe. */
|
|
59
71
|
export interface ServerForgePort {
|
|
60
72
|
readonly kind: string;
|
|
@@ -83,6 +95,7 @@ export interface ServerPluginContext {
|
|
|
83
95
|
refresh?: boolean;
|
|
84
96
|
}) => Promise<ProviderStatusResponse>;
|
|
85
97
|
readonly workspaceEvents: ServerWorkspaceEventsPort;
|
|
98
|
+
readonly workspaceSummaryFeed: ServerWorkspaceSummaryFeedPort;
|
|
86
99
|
readonly projects: {
|
|
87
100
|
/** Boot project handle, or `undefined` on a server started with no boot project. */
|
|
88
101
|
readonly boot?: ServerProjectHandle | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"server-hook-registry.js","sourceRoot":"","sources":["../../src/core/server-hook-registry.ts"],"names":[],"mappings":"AAYA,OAAO,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC;AAUpD,MAAM,UAAU,wBAAwB,CAAC,OAA2C;IAClF,MAAM,KAAK,GAAG,IAAI,GAAG,CAAkB,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC;IACtF,OAAO;QACL,GAAG,EAAE,CAAc,GAAW,EAAE,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,CAAkB;QAClE,GAAG,EAAE,CAAc,GAAW,EAAE,KAAQ,EAAE,EAAE,GAAG,KAAK,CAAC,GAAG,CAAC,GAAG,EAAE,KAAK,CAAC,CAAC,CAAC,CAAC;QACvE,MAAM,EAAE,CAAC,GAAW,EAAE,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC;KAC3C,CAAC;AACJ,CAAC;
|
|
1
|
+
{"version":3,"file":"server-hook-registry.js","sourceRoot":"","sources":["../../src/core/server-hook-registry.ts"],"names":[],"mappings":"AAYA,OAAO,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC;AAUpD,MAAM,UAAU,wBAAwB,CAAC,OAA2C;IAClF,MAAM,KAAK,GAAG,IAAI,GAAG,CAAkB,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC;IACtF,OAAO;QACL,GAAG,EAAE,CAAc,GAAW,EAAE,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,CAAkB;QAClE,GAAG,EAAE,CAAc,GAAW,EAAE,KAAQ,EAAE,EAAE,GAAG,KAAK,CAAC,GAAG,CAAC,GAAG,EAAE,KAAK,CAAC,CAAC,CAAC,CAAC;QACvE,MAAM,EAAE,CAAC,GAAW,EAAE,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC;KAC3C,CAAC;AACJ,CAAC;AA4GD,MAAM,cAAc,GAAG;IACrB,cAAc;IACd,cAAc;IACd,sBAAsB;IACtB,uBAAuB;IACvB,0BAA0B;IAC1B,iBAAiB;CACT,CAAC;AAEX,MAAM,KAAK,GAAG,mBAAmB,CAA+B;IAC9D,IAAI,EAAE,cAAc;IACpB,QAAQ,EAAE,oIAAoI;CAC/I,CAAC,CAAC;AAEH,SAAS,UAAU,CAAC,IAA0B;IAC5C,IAAI,OAAO,IAAI,KAAK,QAAQ,IAAI,IAAI,KAAK,IAAI;QAAE,MAAM,IAAI,KAAK,CAAC,oDAAoD,CAAC,CAAC;IACrH,IAAI,OAAO,IAAI,CAAC,EAAE,KAAK,QAAQ,IAAI,IAAI,CAAC,EAAE,CAAC,MAAM,KAAK,CAAC;QAAE,MAAM,IAAI,KAAK,CAAC,4BAA4B,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC;IACjI,KAAK,MAAM,GAAG,IAAI,cAAc,EAAE,CAAC;QACjC,MAAM,EAAE,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC;QACrB,IAAI,EAAE,KAAK,SAAS;YAAE,SAAS;QAC/B,IAAI,OAAO,EAAE,KAAK,UAAU;YAAE,MAAM,IAAI,KAAK,CAAC,kBAAkB,IAAI,CAAC,EAAE,KAAK,GAAG,sBAAsB,CAAC,CAAC;QACvG,IAAI,EAAE,CAAC,WAAW,EAAE,IAAI,KAAK,eAAe,EAAE,CAAC;YAC7C,MAAM,IAAI,KAAK,CAAC,kBAAkB,IAAI,CAAC,EAAE,KAAK,GAAG,uBAAuB,CAAC,CAAC;QAC5E,CAAC;IACH,CAAC;IACD,IAAI,IAAI,CAAC,aAAa,KAAK,SAAS,IAAI,OAAO,IAAI,CAAC,aAAa,KAAK,UAAU,EAAE,CAAC;QACjF,MAAM,IAAI,KAAK,CAAC,kBAAkB,IAAI,CAAC,EAAE,qCAAqC,CAAC,CAAC;IAClF,CAAC;AACH,CAAC;AAED,qEAAqE;AACrE,MAAM,UAAU,2BAA2B,CAAC,IAA0B;IACpE,UAAU,CAAC,IAAI,CAAC,CAAC;IACjB,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,EAAE,EAAE,IAAI,CAAC,CAAC;AAC7B,CAAC;AAED,MAAM,UAAU,kBAAkB,CAAC,IAA0B;IAC3D,2BAA2B,CAAC,IAAI,CAAC,CAAC;IAClC,KAAK,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAE,EAAE,IAAI,CAAC,CAAC;AAChC,CAAC;AAED,MAAM,UAAU,eAAe,KAAW,KAAK,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC;AAEzD,oDAAoD;AACpD,MAAM,UAAU,iBAAiB,KAAc,OAAO,KAAK,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC;AAEzE,0EAA0E;AAC1E,MAAM,UAAU,qBAAqB;IACnC,OAAO,KAAK,CAAC,MAAM,EAAE,CAAC;AACxB,CAAC"}
|
|
@@ -2,18 +2,6 @@ import type { DelegationRoutes } from './routes.ts';
|
|
|
2
2
|
export declare function createDelegationApp(routes: DelegationRoutes): import("hono/hono-base").HonoBase<import("hono/types").BlankEnv, import("hono/types").BlankSchema | import("hono/types").MergeSchemaPath<{
|
|
3
3
|
"/list": {
|
|
4
4
|
$get: {
|
|
5
|
-
output: {
|
|
6
|
-
error: string;
|
|
7
|
-
code?: "invalid_input" | undefined;
|
|
8
|
-
};
|
|
9
|
-
outputFormat: "json";
|
|
10
|
-
status: 400;
|
|
11
|
-
input: {
|
|
12
|
-
query: {
|
|
13
|
-
offset?: string | undefined;
|
|
14
|
-
};
|
|
15
|
-
};
|
|
16
|
-
} | {
|
|
17
5
|
output: {
|
|
18
6
|
workers: {
|
|
19
7
|
workerId: string;
|
|
@@ -66,6 +54,18 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
66
54
|
offset?: string | undefined;
|
|
67
55
|
};
|
|
68
56
|
};
|
|
57
|
+
} | {
|
|
58
|
+
output: {
|
|
59
|
+
error: string;
|
|
60
|
+
code?: "invalid_input" | undefined;
|
|
61
|
+
};
|
|
62
|
+
outputFormat: "json";
|
|
63
|
+
status: 400;
|
|
64
|
+
input: {
|
|
65
|
+
query: {
|
|
66
|
+
offset?: string | undefined;
|
|
67
|
+
};
|
|
68
|
+
};
|
|
69
69
|
};
|
|
70
70
|
};
|
|
71
71
|
} & {
|
|
@@ -652,18 +652,6 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
652
652
|
} & {
|
|
653
653
|
"/:workerId": {
|
|
654
654
|
$get: {
|
|
655
|
-
output: {
|
|
656
|
-
error: string;
|
|
657
|
-
code?: "invalid_input" | undefined;
|
|
658
|
-
};
|
|
659
|
-
outputFormat: "json";
|
|
660
|
-
status: 400;
|
|
661
|
-
input: {
|
|
662
|
-
param: {
|
|
663
|
-
workerId: string;
|
|
664
|
-
};
|
|
665
|
-
};
|
|
666
|
-
} | {
|
|
667
655
|
output: {
|
|
668
656
|
workerId: string;
|
|
669
657
|
settled: boolean;
|
|
@@ -788,11 +776,7 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
788
776
|
workerId: string;
|
|
789
777
|
};
|
|
790
778
|
};
|
|
791
|
-
}
|
|
792
|
-
};
|
|
793
|
-
} & {
|
|
794
|
-
"/:workerId/collect": {
|
|
795
|
-
$post: {
|
|
779
|
+
} | {
|
|
796
780
|
output: {
|
|
797
781
|
error: string;
|
|
798
782
|
code?: "invalid_input" | undefined;
|
|
@@ -803,10 +787,12 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
803
787
|
param: {
|
|
804
788
|
workerId: string;
|
|
805
789
|
};
|
|
806
|
-
} & {
|
|
807
|
-
json: Record<string, never>;
|
|
808
790
|
};
|
|
809
|
-
}
|
|
791
|
+
};
|
|
792
|
+
};
|
|
793
|
+
} & {
|
|
794
|
+
"/:workerId/collect": {
|
|
795
|
+
$post: {
|
|
810
796
|
output: {
|
|
811
797
|
workerId: string;
|
|
812
798
|
parentRunId: string;
|
|
@@ -931,11 +917,7 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
931
917
|
} & {
|
|
932
918
|
json: Record<string, never>;
|
|
933
919
|
};
|
|
934
|
-
}
|
|
935
|
-
};
|
|
936
|
-
} & {
|
|
937
|
-
"/:workerId/steer": {
|
|
938
|
-
$post: {
|
|
920
|
+
} | {
|
|
939
921
|
output: {
|
|
940
922
|
error: string;
|
|
941
923
|
code?: "invalid_input" | undefined;
|
|
@@ -947,11 +929,13 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
947
929
|
workerId: string;
|
|
948
930
|
};
|
|
949
931
|
} & {
|
|
950
|
-
json:
|
|
951
|
-
text: string;
|
|
952
|
-
};
|
|
932
|
+
json: Record<string, never>;
|
|
953
933
|
};
|
|
954
|
-
}
|
|
934
|
+
};
|
|
935
|
+
};
|
|
936
|
+
} & {
|
|
937
|
+
"/:workerId/steer": {
|
|
938
|
+
$post: {
|
|
955
939
|
output: {
|
|
956
940
|
workerId: string;
|
|
957
941
|
state: "delivered" | "queued";
|
|
@@ -967,11 +951,7 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
967
951
|
text: string;
|
|
968
952
|
};
|
|
969
953
|
};
|
|
970
|
-
}
|
|
971
|
-
};
|
|
972
|
-
} & {
|
|
973
|
-
"/:workerId/stop": {
|
|
974
|
-
$post: {
|
|
954
|
+
} | {
|
|
975
955
|
output: {
|
|
976
956
|
error: string;
|
|
977
957
|
code?: "invalid_input" | undefined;
|
|
@@ -983,9 +963,15 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
983
963
|
workerId: string;
|
|
984
964
|
};
|
|
985
965
|
} & {
|
|
986
|
-
json:
|
|
966
|
+
json: {
|
|
967
|
+
text: string;
|
|
968
|
+
};
|
|
987
969
|
};
|
|
988
|
-
}
|
|
970
|
+
};
|
|
971
|
+
};
|
|
972
|
+
} & {
|
|
973
|
+
"/:workerId/stop": {
|
|
974
|
+
$post: {
|
|
989
975
|
output: {
|
|
990
976
|
workerId: string;
|
|
991
977
|
state: "stopping" | "terminated";
|
|
@@ -999,11 +985,7 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
999
985
|
} & {
|
|
1000
986
|
json: Record<string, never>;
|
|
1001
987
|
};
|
|
1002
|
-
}
|
|
1003
|
-
};
|
|
1004
|
-
} & {
|
|
1005
|
-
"/:workerId/destroy": {
|
|
1006
|
-
$post: {
|
|
988
|
+
} | {
|
|
1007
989
|
output: {
|
|
1008
990
|
error: string;
|
|
1009
991
|
code?: "invalid_input" | undefined;
|
|
@@ -1015,11 +997,13 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
1015
997
|
workerId: string;
|
|
1016
998
|
};
|
|
1017
999
|
} & {
|
|
1018
|
-
json:
|
|
1019
|
-
discardWork?: true | undefined;
|
|
1020
|
-
};
|
|
1000
|
+
json: Record<string, never>;
|
|
1021
1001
|
};
|
|
1022
|
-
}
|
|
1002
|
+
};
|
|
1003
|
+
};
|
|
1004
|
+
} & {
|
|
1005
|
+
"/:workerId/destroy": {
|
|
1006
|
+
$post: {
|
|
1023
1007
|
output: {
|
|
1024
1008
|
workerId: string;
|
|
1025
1009
|
state: "complete" | "incomplete";
|
|
@@ -1048,6 +1032,22 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
1048
1032
|
discardWork?: true | undefined;
|
|
1049
1033
|
};
|
|
1050
1034
|
};
|
|
1035
|
+
} | {
|
|
1036
|
+
output: {
|
|
1037
|
+
error: string;
|
|
1038
|
+
code?: "invalid_input" | undefined;
|
|
1039
|
+
};
|
|
1040
|
+
outputFormat: "json";
|
|
1041
|
+
status: 400;
|
|
1042
|
+
input: {
|
|
1043
|
+
param: {
|
|
1044
|
+
workerId: string;
|
|
1045
|
+
};
|
|
1046
|
+
} & {
|
|
1047
|
+
json: {
|
|
1048
|
+
discardWork?: true | undefined;
|
|
1049
|
+
};
|
|
1050
|
+
};
|
|
1051
1051
|
} | {
|
|
1052
1052
|
output: {
|
|
1053
1053
|
workerId: string;
|
|
@@ -1083,11 +1083,18 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
1083
1083
|
"/:workerId/summary": {
|
|
1084
1084
|
$post: {
|
|
1085
1085
|
output: {
|
|
1086
|
-
|
|
1087
|
-
|
|
1086
|
+
workerId: string;
|
|
1087
|
+
revision: number;
|
|
1088
|
+
source: "assistant" | "failure";
|
|
1089
|
+
seq: number;
|
|
1090
|
+
totalLines: number;
|
|
1091
|
+
offset: number;
|
|
1092
|
+
lineCount: number;
|
|
1093
|
+
text: string;
|
|
1094
|
+
nextOffset?: number | undefined;
|
|
1088
1095
|
};
|
|
1089
1096
|
outputFormat: "json";
|
|
1090
|
-
status:
|
|
1097
|
+
status: 200;
|
|
1091
1098
|
input: {
|
|
1092
1099
|
param: {
|
|
1093
1100
|
workerId: string;
|
|
@@ -1100,18 +1107,11 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
1100
1107
|
};
|
|
1101
1108
|
} | {
|
|
1102
1109
|
output: {
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
source: "assistant" | "failure";
|
|
1106
|
-
seq: number;
|
|
1107
|
-
totalLines: number;
|
|
1108
|
-
offset: number;
|
|
1109
|
-
lineCount: number;
|
|
1110
|
-
text: string;
|
|
1111
|
-
nextOffset?: number | undefined;
|
|
1110
|
+
error: string;
|
|
1111
|
+
code?: "invalid_input" | undefined;
|
|
1112
1112
|
};
|
|
1113
1113
|
outputFormat: "json";
|
|
1114
|
-
status:
|
|
1114
|
+
status: 400;
|
|
1115
1115
|
input: {
|
|
1116
1116
|
param: {
|
|
1117
1117
|
workerId: string;
|
|
@@ -1128,11 +1128,13 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
1128
1128
|
"/:workerId/diff": {
|
|
1129
1129
|
$get: {
|
|
1130
1130
|
output: {
|
|
1131
|
-
|
|
1132
|
-
|
|
1131
|
+
workerId: string;
|
|
1132
|
+
baselineSha: string;
|
|
1133
|
+
diff: string;
|
|
1134
|
+
truncated: boolean;
|
|
1133
1135
|
};
|
|
1134
1136
|
outputFormat: "json";
|
|
1135
|
-
status:
|
|
1137
|
+
status: 200;
|
|
1136
1138
|
input: {
|
|
1137
1139
|
param: {
|
|
1138
1140
|
workerId: string;
|
|
@@ -1140,13 +1142,11 @@ export declare function createDelegationApp(routes: DelegationRoutes): import("h
|
|
|
1140
1142
|
};
|
|
1141
1143
|
} | {
|
|
1142
1144
|
output: {
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
diff: string;
|
|
1146
|
-
truncated: boolean;
|
|
1145
|
+
error: string;
|
|
1146
|
+
code?: "invalid_input" | undefined;
|
|
1147
1147
|
};
|
|
1148
1148
|
outputFormat: "json";
|
|
1149
|
-
status:
|
|
1149
|
+
status: 400;
|
|
1150
1150
|
input: {
|
|
1151
1151
|
param: {
|
|
1152
1152
|
workerId: string;
|