@openagt/dashboard 0.13.0 → 0.15.0
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/README.md +2 -1
- package/dist/daemon-runtime.d.ts.map +1 -1
- package/dist/daemon-runtime.js +116 -8
- package/dist/daemon-runtime.js.map +1 -1
- package/dist/dashboard/relay-endpoints.d.ts.map +1 -1
- package/dist/dashboard/relay-endpoints.js +6 -4
- package/dist/dashboard/relay-endpoints.js.map +1 -1
- package/dist/dashboard/remote-run.d.ts +39 -8
- package/dist/dashboard/remote-run.d.ts.map +1 -1
- package/dist/dashboard/remote-run.js +98 -18
- package/dist/dashboard/remote-run.js.map +1 -1
- package/dist/dashboard/rpc-serve.d.ts +18 -1
- package/dist/dashboard/rpc-serve.d.ts.map +1 -1
- package/dist/dashboard/rpc-serve.js.map +1 -1
- package/dist/dashboard/screen.d.ts +2 -2
- package/dist/dashboard/screen.d.ts.map +1 -1
- package/dist/dashboard/screen.js +1 -1
- package/dist/dashboard/screen.js.map +1 -1
- package/dist/dashboard/server.js +1 -1
- package/dist/dashboard/server.js.map +1 -1
- package/dist/dashboard/types.d.ts +5 -2
- package/dist/dashboard/types.d.ts.map +1 -1
- package/dist/dashboard-bundle/assets/main-BtmQIAUe.js +140 -0
- package/dist/dashboard-bundle/assets/main-DbqABoVD.css +2 -0
- package/dist/dashboard-bundle/assets/module-CFB4pxwP.js +24 -0
- package/dist/dashboard-bundle/host/module.js +1 -1
- package/dist/dashboard-bundle/index.html +3 -3
- package/dist/dashboard-rpc/context.js +1 -1
- package/dist/dashboard-rpc/context.js.map +1 -1
- package/dist/dashboard-rpc/events.d.ts.map +1 -1
- package/dist/dashboard-rpc/events.js +4 -1
- package/dist/dashboard-rpc/events.js.map +1 -1
- package/dist/dashboard-rpc/reads.d.ts +24 -0
- package/dist/dashboard-rpc/reads.d.ts.map +1 -1
- package/dist/dashboard-rpc/reads.js +65 -11
- package/dist/dashboard-rpc/reads.js.map +1 -1
- package/dist/dashboard-rpc/relay-agent.d.ts +11 -5
- package/dist/dashboard-rpc/relay-agent.d.ts.map +1 -1
- package/dist/dashboard-rpc/relay-agent.js +38 -8
- package/dist/dashboard-rpc/relay-agent.js.map +1 -1
- package/dist/dashboard-rpc/relay-dispatch.js +2 -1
- package/dist/dashboard-rpc/relay-dispatch.js.map +1 -1
- package/dist/dashboard-rpc/test-context.js +1 -1
- package/dist/dashboard-rpc/test-context.js.map +1 -1
- package/dist/module-types/dashboard/components/SettingsRows.d.ts +1 -1
- package/dist/module-types/dashboard/components/ui/card.d.ts +15 -1
- package/dist/module-types/dashboard/components/ui/confirm-dialog.d.ts +20 -0
- package/dist/module-types/dashboard/components/ui/label.d.ts +2 -0
- package/dist/module-types/dashboard/components/ui/radio-group.d.ts +23 -0
- package/dist/module-types/dashboard/components/ui/select.d.ts +12 -0
- package/dist/module-types/dashboard/components/ui/table.d.ts +7 -0
- package/dist/module-types/dashboard/components/ui/textarea.d.ts +2 -0
- package/dist/module-types/dashboard/lib/data-link.d.ts +14 -0
- package/dist/module-types/dashboard/lib/route.d.ts +6 -0
- package/dist/module-types/dashboard/lib/use-file-names.d.ts +20 -0
- package/dist/module-types/dashboard/lib/use-modules.d.ts +8 -1
- package/dist/module-types/dashboard/lib/use-schedule.d.ts +20 -0
- package/dist/module-types/dashboard/module/index.d.ts +47 -1
- package/dist/module-types/src/dashboard/remote-run.d.ts +39 -8
- package/dist/module-types/src/dashboard/rpc-serve.d.ts +18 -1
- package/dist/module-types/src/dashboard/types.d.ts +5 -2
- package/dist/module-types/src/dashboard-rpc/reads.d.ts +24 -0
- package/dist/module-types/src/dashboard-rpc/relay-agent.d.ts +11 -5
- package/dist/module-types/src/project-hooks.d.ts +4 -1
- package/dist/module-types/src/registry.d.ts +18 -0
- package/dist/project-hooks.d.ts +4 -1
- package/dist/project-hooks.d.ts.map +1 -1
- package/dist/project-hooks.js +4 -3
- package/dist/project-hooks.js.map +1 -1
- package/dist/registry.d.ts +18 -0
- package/dist/registry.d.ts.map +1 -1
- package/dist/registry.js +25 -2
- package/dist/registry.js.map +1 -1
- package/package.json +16 -16
- package/dist/dashboard-bundle/assets/main-Co_A_Ebn.js +0 -140
- package/dist/dashboard-bundle/assets/main-DD99HRP9.css +0 -2
- package/dist/dashboard-bundle/assets/module-ZjyA5WUg.js +0 -21
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { type Route } from './route.js';
|
|
2
|
+
/** A repository path's page segment and the rest: `tickets/a.md` → `{ segment: 'tickets', rest: ['a.md'] }`; nothing for a path with no page-shaped first segment or no rest. */
|
|
3
|
+
export declare function dataLinkParts(href: string): {
|
|
4
|
+
segment: string;
|
|
5
|
+
rest: string[];
|
|
6
|
+
} | undefined;
|
|
7
|
+
/**
|
|
8
|
+
* The route a link into `projectId`'s files opens, when one of `pages` (the mounted module pages,
|
|
9
|
+
* by segment) claims the path's first segment; `undefined` when none does, so the link is shown
|
|
10
|
+
* as text and opens nothing.
|
|
11
|
+
*/
|
|
12
|
+
export declare function dataLinkRoute(projectId: string, href: string, pages: readonly {
|
|
13
|
+
segment: string;
|
|
14
|
+
}[]): Route | undefined;
|
|
@@ -36,3 +36,9 @@ export declare function formatRoute(route: Route): string;
|
|
|
36
36
|
* module's page mirrored there (a list's filters) stays when only the picked project changes.
|
|
37
37
|
*/
|
|
38
38
|
export declare function keepPageQuery(url: string, search: string): string;
|
|
39
|
+
/**
|
|
40
|
+
* The address of a module's page as a link holds it, for a link that must also open in a new
|
|
41
|
+
* tab: the page's segment, with the one project the dashboard is showing when one is picked, so
|
|
42
|
+
* the new tab shows that project too.
|
|
43
|
+
*/
|
|
44
|
+
export declare function pageHref(segment: string, search?: string): string;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/** A path that has a name: what to show for it, and how to open it. */
|
|
2
|
+
export interface NamedFile {
|
|
3
|
+
title: string;
|
|
4
|
+
/** Open the page that shows it. */
|
|
5
|
+
open(): void;
|
|
6
|
+
}
|
|
7
|
+
/** The name of a path into a project's files; `undefined` for one no installed page names. */
|
|
8
|
+
export type FileNames = (projectId: string, path: string) => NamedFile | undefined;
|
|
9
|
+
/**
|
|
10
|
+
* The paths into a project's files a text names: each run of characters with a slash in it whose
|
|
11
|
+
* first segment could be a page's (`tickets/2026-01-01_x.md`), without the brackets or the stop
|
|
12
|
+
* around it. Never a piece of something longer: a web address and an absolute path name no file
|
|
13
|
+
* of the project.
|
|
14
|
+
*/
|
|
15
|
+
export declare function pathsIn(text: string): string[];
|
|
16
|
+
/** The names of the paths asked about, per project, read once a minute. A path whose page is not installed in that project, or does not name it, has no name. */
|
|
17
|
+
export declare function useFileNames(asked: readonly {
|
|
18
|
+
projectId: string;
|
|
19
|
+
paths: readonly string[];
|
|
20
|
+
}[]): FileNames;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { LinkAction, ModuleCard, ModulePage, ModulePanel, ModuleRunSlots, ModuleSettings, ModuleUsageLimit } from '../module/index.js';
|
|
1
|
+
import type { LinkAction, ModuleCard, ModulePage, ModulePanel, ModuleRunSlots, ModuleSchedule, ModuleSettings, ModuleUsageLimit } from '../module/index.js';
|
|
2
2
|
/** A module page as the shell mounts it: the page, plus the package it came from and the projects that have it. */
|
|
3
3
|
export interface MountedPage extends ModulePage {
|
|
4
4
|
package: string;
|
|
@@ -34,6 +34,11 @@ export interface MountedUsageLimit extends ModuleUsageLimit {
|
|
|
34
34
|
package: string;
|
|
35
35
|
projects: string[];
|
|
36
36
|
}
|
|
37
|
+
/** The commands a module starts by itself, as the shell mounts them: the read, plus the package it came from and the projects that have it. */
|
|
38
|
+
export interface MountedSchedule extends ModuleSchedule {
|
|
39
|
+
package: string;
|
|
40
|
+
projects: string[];
|
|
41
|
+
}
|
|
37
42
|
/** What the installed modules bring, once loaded: their pages, their cards and their link actions. */
|
|
38
43
|
export interface MountedModules {
|
|
39
44
|
pages: MountedPage[];
|
|
@@ -48,6 +53,8 @@ export interface MountedModules {
|
|
|
48
53
|
settings: MountedSettings[];
|
|
49
54
|
/** The usage bar's stop line: the first module's that declares one, in package order; absent when none does. */
|
|
50
55
|
usageLimit?: MountedUsageLimit;
|
|
56
|
+
/** What starts by itself: the first module's that declares it, in package order; absent when none does. */
|
|
57
|
+
schedule?: MountedSchedule;
|
|
51
58
|
/** True once the module list was read and every module in it imported or skipped. */
|
|
52
59
|
loaded: boolean;
|
|
53
60
|
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { type ModuleProject, type ModuleScheduledCommand } from '../module/index.js';
|
|
2
|
+
/** What starts by itself, as a page reads it. */
|
|
3
|
+
export interface Schedule {
|
|
4
|
+
/** The page where a person switches a command on: its segment, its sidebar label and its address. Absent when no installed module schedules anything. */
|
|
5
|
+
page?: {
|
|
6
|
+
segment: string;
|
|
7
|
+
label: string;
|
|
8
|
+
href: string;
|
|
9
|
+
};
|
|
10
|
+
/**
|
|
11
|
+
* Each project's commands that can start by themselves, by project id: none for a project no
|
|
12
|
+
* scheduling module is in. A project whose answer is not known, not read yet or a read that
|
|
13
|
+
* failed, has no entry: a page then says nothing of it, since "nothing starts" would be a guess.
|
|
14
|
+
*/
|
|
15
|
+
commands: Record<string, ModuleScheduledCommand[]>;
|
|
16
|
+
/** Open the page where a person switches a command on. */
|
|
17
|
+
open(): void;
|
|
18
|
+
}
|
|
19
|
+
/** The commands that start by themselves in `projects`, read every 10 seconds. */
|
|
20
|
+
export declare function useSchedule(projects: readonly ModuleProject[]): Schedule;
|
|
@@ -38,6 +38,20 @@ export interface ModulePage {
|
|
|
38
38
|
}>;
|
|
39
39
|
/** The page itself. */
|
|
40
40
|
Page: ComponentType<ModulePageProps>;
|
|
41
|
+
/**
|
|
42
|
+
* What the paths into a project's files that this page opens are called: asked by other pages
|
|
43
|
+
* that show such a path (a queue entry that names `tickets/2026-01-01_x.md`), so they can show
|
|
44
|
+
* a name a person reads in place of a file path. Given the paths whose first segment is the
|
|
45
|
+
* page's own; answers the ones it can name, by path. Read through {@link useFileNames}.
|
|
46
|
+
*/
|
|
47
|
+
names?(host: ModuleHost, projectId: string, paths: string[]): Promise<Record<string, ModuleFileName>>;
|
|
48
|
+
}
|
|
49
|
+
/** What a path into a project's files is called, as the page that opens it says. */
|
|
50
|
+
export interface ModuleFileName {
|
|
51
|
+
/** The name a person reads: a ticket's title. */
|
|
52
|
+
title: string;
|
|
53
|
+
/** The path that is opened for it, when it is not the path asked about: a plan still to be written opens its ticket. */
|
|
54
|
+
href?: string;
|
|
41
55
|
}
|
|
42
56
|
/**
|
|
43
57
|
* A link a dashboard page shows (#1774): the name of some work and where it points. What a
|
|
@@ -140,6 +154,27 @@ export interface ModuleUsageLimit {
|
|
|
140
154
|
/** Save the offset the handle was dragged to, within ±{@link MAX_SPEND_OFFSET}. */
|
|
141
155
|
save(host: ModuleHost, projects: ModuleProject[], points: number): Promise<UsageLimitSaved>;
|
|
142
156
|
}
|
|
157
|
+
/** A command that starts by itself in a project, as the module that schedules it says it. */
|
|
158
|
+
export interface ModuleScheduledCommand {
|
|
159
|
+
/** The command as a person types it, without its slash: `work-queue`. */
|
|
160
|
+
command: string;
|
|
161
|
+
/** Whether it starts by itself on this computer right now. */
|
|
162
|
+
on: boolean;
|
|
163
|
+
/** One line on it, for a person: when it starts next while it is on ("Next start in 3h, if there is work"), or why it does not start though its own switch is on ("The scheduler is off", "Cannot start on Codex: …"). */
|
|
164
|
+
note?: string;
|
|
165
|
+
}
|
|
166
|
+
/**
|
|
167
|
+
* What a module that starts commands by itself tells the other pages: which commands, and whether
|
|
168
|
+
* each is on. A page whose work such a command takes (a queue) says so with it, and links to the
|
|
169
|
+
* module's own page, where a person switches a command on. The first module that declares one
|
|
170
|
+
* (in package order) is asked. Read through {@link useSchedule}.
|
|
171
|
+
*/
|
|
172
|
+
export interface ModuleSchedule {
|
|
173
|
+
/** The module's own page where a person switches a command on, by its segment. */
|
|
174
|
+
page: string;
|
|
175
|
+
/** One project's commands that can start by themselves. Rejects when they cannot be read: the page then says nothing of that project. */
|
|
176
|
+
read(host: ModuleHost, project: ModuleProject): Promise<ModuleScheduledCommand[]>;
|
|
177
|
+
}
|
|
143
178
|
/**
|
|
144
179
|
* The Context as a side-rail tab sees it (#504): the files the next run is pointed at. A tab may
|
|
145
180
|
* show which files are in it and add or remove one.
|
|
@@ -230,6 +265,8 @@ export interface ModuleDefinition {
|
|
|
230
265
|
settings?: ModuleSettings[];
|
|
231
266
|
/** The stop line the module puts on the usage bar. */
|
|
232
267
|
usageLimit?: ModuleUsageLimit;
|
|
268
|
+
/** The commands the module starts by itself, for the other pages to say. */
|
|
269
|
+
schedule?: ModuleSchedule;
|
|
233
270
|
/** A stylesheet to load with the module, relative to the module's browser part's own URL. */
|
|
234
271
|
stylesheet?: string;
|
|
235
272
|
}
|
|
@@ -362,11 +399,16 @@ export declare const ModuleHostContext: import("react").Context<ModuleHost | Mod
|
|
|
362
399
|
export declare function useModuleHost(): ModuleHost;
|
|
363
400
|
export { Button, buttonVariants, type ButtonProps } from '../components/ui/button.js';
|
|
364
401
|
export { Badge } from '../components/ui/badge.js';
|
|
365
|
-
export { Card, CardHeader, CardTitle, CardContent } from '../components/ui/card.js';
|
|
402
|
+
export { Card, CardHeader, CardTitle, CardTitleLink, CardContent } from '../components/ui/card.js';
|
|
366
403
|
export { Skeleton } from '../components/ui/skeleton.js';
|
|
367
404
|
export { Checkbox } from '../components/ui/checkbox.js';
|
|
368
405
|
export { Switch } from '../components/ui/switch.js';
|
|
369
406
|
export { Input } from '../components/ui/input.js';
|
|
407
|
+
export { Textarea } from '../components/ui/textarea.js';
|
|
408
|
+
export { Table, TableBody, TableCell, TableHead, TableHeader, TableRow } from '../components/ui/table.js';
|
|
409
|
+
export { Label } from '../components/ui/label.js';
|
|
410
|
+
export { RadioGroup, RadioGroupItem, RadioGroupOption } from '../components/ui/radio-group.js';
|
|
411
|
+
export { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from '../components/ui/select.js';
|
|
370
412
|
export { Popover, PopoverContent, PopoverTrigger } from '../components/ui/popover.js';
|
|
371
413
|
export { RangeSlider } from '../components/ui/slider.js';
|
|
372
414
|
export { Separator } from '../components/ui/separator.js';
|
|
@@ -386,3 +428,7 @@ export { MAX_SPEND_OFFSET } from '../../src/preference-defaults.js';
|
|
|
386
428
|
export { formatRelative, formatDateTime, formatDuration, formatAge } from '../lib/format-date.js';
|
|
387
429
|
export { usePolled, useLoaded, forgetRemembered } from '../lib/use-async.js';
|
|
388
430
|
export { useAction } from '../lib/use-action.js';
|
|
431
|
+
export { useSchedule, type Schedule } from '../lib/use-schedule.js';
|
|
432
|
+
export { pageHref } from '../lib/route.js';
|
|
433
|
+
export { useFileNames, pathsIn, type FileNames, type NamedFile } from '../lib/use-file-names.js';
|
|
434
|
+
export { ConfirmDialog } from '../components/ui/confirm-dialog.js';
|
|
@@ -47,6 +47,15 @@ export type RelayStartResult = StartAgentResult | {
|
|
|
47
47
|
* the browser's status dots learn reachable from not.
|
|
48
48
|
*/
|
|
49
49
|
export declare function pingRemote(target: MachineAccess): Promise<boolean>;
|
|
50
|
+
/**
|
|
51
|
+
* What a saved machine says of itself in its ping: the OpenAgent it runs, and the computer's own
|
|
52
|
+
* name, which the records of its runs carry. Nothing for a machine that does not answer, or
|
|
53
|
+
* does not say.
|
|
54
|
+
*/
|
|
55
|
+
export declare function remoteFacts(target: MachineAccess): Promise<{
|
|
56
|
+
version?: string;
|
|
57
|
+
host?: string;
|
|
58
|
+
}>;
|
|
50
59
|
/** The OpenAgent a saved machine runs, as its ping tells it; nothing for a machine that does not answer, or does not say. */
|
|
51
60
|
export declare function remoteVersion(target: MachineAccess): Promise<string | undefined>;
|
|
52
61
|
/** What asking to be let in came to: this computer's key there, or why not, in words. */
|
|
@@ -141,21 +150,43 @@ export declare class RelayedAgents {
|
|
|
141
150
|
private readonly agents;
|
|
142
151
|
private readonly targets;
|
|
143
152
|
private readonly metas;
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
153
|
+
private readonly followed;
|
|
154
|
+
/**
|
|
155
|
+
* Open a local stream for a remote agent and start pumping the remote's events into it. `sent`
|
|
156
|
+
* is a run this computer started there. Any other is followed by its record, which someone
|
|
157
|
+
* else may have written: it never stands for a run that is at work ({@link working}), and only
|
|
158
|
+
* so many are followed at once.
|
|
159
|
+
*/
|
|
160
|
+
register(agentId: string, target: RemoteTarget, meta: AgentMeta, projectId: string, sent?: boolean): void;
|
|
161
|
+
/**
|
|
162
|
+
* Whether the run is kept here as a run of that project. A run's id says nothing of its
|
|
163
|
+
* project, and a run of one project is never taken for one of another by its id alone.
|
|
164
|
+
*/
|
|
165
|
+
private of;
|
|
166
|
+
/** The live event stream for a relayed agent of the project, or undefined when this daemon is not relaying it. */
|
|
167
|
+
get(agentId: string | undefined, projectId?: string): EventStream<OpenAgentEvent> | undefined;
|
|
168
|
+
/** The machine a relayed agent of the project runs on, kept past the event stream so post-run push/PR still reach it. */
|
|
169
|
+
target(agentId: string | undefined, projectId?: string): RemoteTarget | undefined;
|
|
170
|
+
/** Whether this daemon follows the project's run now: its events stream. */
|
|
171
|
+
follows(agentId: string, projectId?: string): boolean;
|
|
172
|
+
/**
|
|
173
|
+
* Whether a run this computer sent is still at work on the machine at `url`. A machine's
|
|
174
|
+
* stream stays open after its run ended, for the next message to it, so the run's own state
|
|
175
|
+
* says it and not the stream. A run followed by its record does not count: its state is what
|
|
176
|
+
* a record said, and a machine is not held by a record anyone with the project can write.
|
|
177
|
+
*/
|
|
151
178
|
working(url: string): boolean;
|
|
179
|
+
/** Whether the run is one this computer sent to its machine, not one followed by its record. */
|
|
180
|
+
isSent(agentId: string): boolean;
|
|
181
|
+
/** Stop following a run and forget it: it is read by its record again. */
|
|
182
|
+
private forget;
|
|
152
183
|
/** How the machine at `url` is reached since it was added again, for the runs kept from before: this computer's new key there, and the key the machine is known by. */
|
|
153
184
|
rekey(url: string, key: string, pin?: string): void;
|
|
154
185
|
/** A project's relayed run stubs (#1077), newest-first, so `onAgents` can surface them in the list. */
|
|
155
186
|
list(projectId: string): AgentMeta[];
|
|
156
187
|
/** Fold each relayed event into the agent's list row via the store's own reducer (#1077), so the
|
|
157
188
|
* local stub mirrors the machine: the terminal status on `end`, the waiting flag while it is parked
|
|
158
|
-
* (#785)
|
|
189
|
+
* (#785). Events carry no write time, so this stamps its own. */
|
|
159
190
|
private apply;
|
|
160
191
|
/** Close a relayed agent's event stream (not its target). Idempotent. */
|
|
161
192
|
private endStream;
|
|
@@ -22,13 +22,30 @@ export type EventsSource = (projectId: string, agentId?: string) => AsyncIterabl
|
|
|
22
22
|
* daemon wires this from its live relayed-agent map; a run-scoped RPC uses it to forward a remote agent's
|
|
23
23
|
* read/steer/handoff to that machine instead of resolving a (nonexistent) local checkout. */
|
|
24
24
|
export interface RemoteAgents {
|
|
25
|
-
|
|
25
|
+
/** The machine of a run this daemon follows, in the project when one is named: a run's id alone says nothing of its project. */
|
|
26
|
+
target(agentId: string | undefined, projectId?: string): RemoteTarget | undefined;
|
|
26
27
|
/** A project's relayed run stubs (#1077), so `onAgents` can show a remote agent in the list and re-open it after a reload. */
|
|
27
28
|
list(projectId: string): AgentMeta[];
|
|
29
|
+
/** Whether a followed run is one this computer sent to its machine. Any other is followed by its record, and is listed only while that record is there. */
|
|
30
|
+
sent(agentId: string): boolean;
|
|
28
31
|
/** Whether a run relayed from here is still at work on the machine at `url`. */
|
|
29
32
|
working(url: string): boolean;
|
|
30
33
|
/** How the machine at `url` is reached since it was added again, for the runs kept from before. */
|
|
31
34
|
rekey(url: string, key: string, pin?: string): void;
|
|
35
|
+
/**
|
|
36
|
+
* The saved machine a run of the project runs on, whoever started it there: one this computer
|
|
37
|
+
* sent, or one whose record, come through the project's shared records, names that machine's
|
|
38
|
+
* computer. Undefined for a run of this computer's own, and for one of a computer that is
|
|
39
|
+
* no saved machine.
|
|
40
|
+
*/
|
|
41
|
+
home(projectId: string, agentId: string): Promise<RemoteTarget | undefined>;
|
|
42
|
+
/** Follow a run that runs on a saved machine, when it is not followed yet: its events then stream here, as for a run this computer sent. */
|
|
43
|
+
follow(projectId: string, agentId: string): Promise<void>;
|
|
44
|
+
/**
|
|
45
|
+
* The name a saved machine was given, by its computer's own name, as the records of its runs
|
|
46
|
+
* carry it: asked of the machines first, when one has not said its name yet.
|
|
47
|
+
*/
|
|
48
|
+
machineNames(): Promise<(host: string) => string | undefined>;
|
|
32
49
|
}
|
|
33
50
|
/**
|
|
34
51
|
* What every RPC acts through.
|
|
@@ -96,12 +96,15 @@ export interface StartAgentOptions {
|
|
|
96
96
|
}
|
|
97
97
|
/**
|
|
98
98
|
* The outcome of a Start attempt (#345): the id of the run the project's start hook began, or why
|
|
99
|
-
* there is none. `
|
|
100
|
-
* run
|
|
99
|
+
* there is none. `driver` is the coding agent the hook said runs it: what another computer that
|
|
100
|
+
* follows the run shows, since the run's record stays on this one. `notThere` marks the one
|
|
101
|
+
* refusal a page can do something about: the machine the run was sent to does not have the
|
|
102
|
+
* project yet, and can clone it.
|
|
101
103
|
*/
|
|
102
104
|
export type StartAgentResult = {
|
|
103
105
|
ok: true;
|
|
104
106
|
agentId: string;
|
|
107
|
+
driver?: string;
|
|
105
108
|
} | {
|
|
106
109
|
ok: false;
|
|
107
110
|
error: string;
|
|
@@ -36,6 +36,15 @@ import type { BridgeAnswer, BridgeContact, BridgeVersion } from '../dashboard/br
|
|
|
36
36
|
* instead of losing it.
|
|
37
37
|
*/
|
|
38
38
|
export declare function onAgents(projectId: string): Promise<AgentMeta[]>;
|
|
39
|
+
/**
|
|
40
|
+
* A project's runs with the ones this daemon follows on a machine (#1067), which live in its
|
|
41
|
+
* memory. A run this computer sent that has no record here is listed first, as followed, so a
|
|
42
|
+
* reload re-opens it instead of losing it. One that has a record keeps the record's row, in
|
|
43
|
+
* its place, which holds more (its branch, its pull request, its parent), and takes from the
|
|
44
|
+
* followed one what the machine said since: whether it works, and its session. A run followed
|
|
45
|
+
* by its record is listed only while that record is there: deleted, it is gone from the list.
|
|
46
|
+
*/
|
|
47
|
+
export declare function withFollowed(followed: AgentMeta[], local: AgentMeta[], sent: (agentId: string) => boolean): AgentMeta[];
|
|
39
48
|
/**
|
|
40
49
|
* A web run whose cloud session is waiting on a human — the bridge holds its parked question, or
|
|
41
50
|
* claude.ai's session list shows it awaiting input (#1332) — is marked waiting (#1668), so its row
|
|
@@ -50,6 +59,14 @@ export declare function markCloudWaiting(agent: AgentMeta): AgentMeta;
|
|
|
50
59
|
* with no recorded host predates the field and passes through untouched.
|
|
51
60
|
*/
|
|
52
61
|
export declare function markOtherHost(agent: AgentMeta, thisHost?: string): AgentMeta;
|
|
62
|
+
/**
|
|
63
|
+
* A run whose record names the computer of a saved machine runs on that machine, whoever started
|
|
64
|
+
* it there, and reads like one this computer sent: by the name the machine was given. The record
|
|
65
|
+
* comes through the project's shared records, so it is here for a run started on the machine's
|
|
66
|
+
* own page too, and after this daemon forgot the runs it sent. A run of this computer, and one of
|
|
67
|
+
* a computer that is no saved machine, pass through untouched.
|
|
68
|
+
*/
|
|
69
|
+
export declare function markMachine(agent: AgentMeta, machineOf: (host: string) => string | undefined, thisHost?: string): AgentMeta;
|
|
53
70
|
/**
|
|
54
71
|
* A run that ended clean while the process its card names is still alive on this host is marked
|
|
55
72
|
* saving: the tool that runs it saves the run's record and cleans up its checkout after the card says
|
|
@@ -57,6 +74,13 @@ export declare function markOtherHost(agent: AgentMeta, thisHost?: string): Agen
|
|
|
57
74
|
* run of another host, or with no recorded process, passes through untouched.
|
|
58
75
|
*/
|
|
59
76
|
export declare function markSaving(agent: AgentMeta, thisHost?: string, alive?: (pid: number) => boolean): AgentMeta;
|
|
77
|
+
/**
|
|
78
|
+
* A run as its record may say it. A record is a file anyone with the project can write, and its
|
|
79
|
+
* tool's own words are read into the row as they are, so the words only this daemon gives a row
|
|
80
|
+
* are taken off it first: that it runs on a saved machine and which, that it is another
|
|
81
|
+
* computer's, that it is being saved. A computer's name that is no name is none.
|
|
82
|
+
*/
|
|
83
|
+
export declare function asRecorded(agent: AgentMeta): AgentMeta;
|
|
60
84
|
/**
|
|
61
85
|
* The agent ids that still have a worktree on disk (#737). An agent that failed or was stopped keeps
|
|
62
86
|
* its checkout so you can go look at what it was holding; this is how the dashboard knows which
|
|
@@ -1,8 +1,14 @@
|
|
|
1
|
+
/** Run `call` as one that came in from another computer: nothing in it is passed on to a machine. */
|
|
2
|
+
export declare function asArrived<T>(call: () => Promise<T>): Promise<T>;
|
|
1
3
|
/**
|
|
2
|
-
* Run a run-scoped RPC locally, or relay it to the machine when `agentId` names an agent
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
4
|
+
* Run a run-scoped RPC locally, or relay it to the machine when `agentId` names an agent that runs on a
|
|
5
|
+
* saved one (#1067 slice 2): one this daemon sent there, or one the machine's own page started,
|
|
6
|
+
* known here by its record. For an ordinary local agent the remote lookup is empty and
|
|
7
|
+
* `local()` runs unchanged. For a remote agent the call is forwarded to the machine with this
|
|
8
|
+
* computer's key there. If the machine is unreachable, no longer lets this computer in, or
|
|
9
|
+
* knows nothing of the run, a read
|
|
10
|
+
* is answered from what this computer holds of the run, its record when it has one, and
|
|
11
|
+
* anything that would change the run answers `unreachable`: it is never done here in the
|
|
12
|
+
* machine's place.
|
|
7
13
|
*/
|
|
8
14
|
export declare function relayOr<T>(agentId: string | undefined, fn: string, args: unknown[], local: () => Promise<T>, unreachable: T): Promise<T>;
|
|
@@ -85,9 +85,11 @@ export type ResumeHookInput = {
|
|
|
85
85
|
} | {
|
|
86
86
|
answer: string;
|
|
87
87
|
});
|
|
88
|
+
/** How a `start` or `resume` line went: the run it named, and the coding agent it said runs it, when it said one. */
|
|
88
89
|
export type RunHookResult = {
|
|
89
90
|
ok: true;
|
|
90
91
|
id: string;
|
|
92
|
+
driver?: string;
|
|
91
93
|
} | {
|
|
92
94
|
ok: false;
|
|
93
95
|
error: string;
|
|
@@ -95,7 +97,8 @@ export type RunHookResult = {
|
|
|
95
97
|
/**
|
|
96
98
|
* Run the project's `start` line: the prompt in `PROMPT`, the picks in `DRIVER`, `MODEL`,
|
|
97
99
|
* `PUBLISH` and `BASE` when made, the follow-up in `THEN` when there is one. The line answers one JSON
|
|
98
|
-
* document on stdout whose `id` names the run it started
|
|
100
|
+
* document on stdout whose `id` names the run it started, and whose `driver` may name the coding
|
|
101
|
+
* agent that runs it.
|
|
99
102
|
*/
|
|
100
103
|
export declare function runStartHook(cwd: string, input: StartHookInput, opts?: Omit<RunHooksOptions, 'log'>): Promise<RunHookResult>;
|
|
101
104
|
/**
|
|
@@ -34,6 +34,12 @@ export interface MachineRecord {
|
|
|
34
34
|
door: string;
|
|
35
35
|
/** What the machine's key is known by, when its link said: every call goes only to a machine that shows that key. */
|
|
36
36
|
pin?: string;
|
|
37
|
+
/**
|
|
38
|
+
* The computer's own name, as the machine first said it: what the records of its runs carry,
|
|
39
|
+
* so a run in a project's shared records is known as this machine's. Kept as first said: a
|
|
40
|
+
* machine that later says another name does not get another computer's runs by it.
|
|
41
|
+
*/
|
|
42
|
+
host?: string;
|
|
37
43
|
}
|
|
38
44
|
/**
|
|
39
45
|
* The dashboard's Global options (#410), persisted next to the project list so they
|
|
@@ -189,6 +195,8 @@ export declare function nodeRegistryFs(): RegistryFs;
|
|
|
189
195
|
* and duplicate ids dropped. A malformed entry is skipped, not thrown — a bad registry never breaks the read.
|
|
190
196
|
*/
|
|
191
197
|
export declare function sanitizeCustomPresets(value: unknown): CustomPreset[];
|
|
198
|
+
/** Whether a value reads as a computer's own name: the letters a host name has, at a host name's length. A page shows it. */
|
|
199
|
+
export declare function isHostName(value: unknown): value is string;
|
|
192
200
|
/**
|
|
193
201
|
* Read the whole registry. Forgiving: a missing / unreadable / malformed file — or one in a shape
|
|
194
202
|
* this no longer writes — yields an empty registry, never throws. Projects are deduped by resolved
|
|
@@ -255,6 +263,16 @@ export declare function addMachine(machine: {
|
|
|
255
263
|
record: MachineRecord;
|
|
256
264
|
displaced: MachineRecord[];
|
|
257
265
|
}>;
|
|
266
|
+
/**
|
|
267
|
+
* Keep the computer's own name a saved machine said, the first time it says one. A machine that
|
|
268
|
+
* already has a name keeps it, and one saved again (a new link) starts without one: `key` is
|
|
269
|
+
* the key the machine was asked with, and a machine saved anew since is not named by an answer
|
|
270
|
+
* to the old one. Answers whether the name was written.
|
|
271
|
+
*/
|
|
272
|
+
export declare function nameMachine(machine: {
|
|
273
|
+
id: string;
|
|
274
|
+
key: string;
|
|
275
|
+
}, host: string, fs?: RegistryFs, env?: NodeJS.ProcessEnv): Promise<boolean>;
|
|
258
276
|
/** Take a saved machine off the list, by id. Answers the one that was there. */
|
|
259
277
|
export declare function removeMachine(id: string, fs?: RegistryFs, env?: NodeJS.ProcessEnv): Promise<MachineRecord | undefined>;
|
|
260
278
|
/** A {@link PreferencesStore} bound to the real registry file, wired by the daemon so the
|
package/dist/project-hooks.d.ts
CHANGED
|
@@ -85,9 +85,11 @@ export type ResumeHookInput = {
|
|
|
85
85
|
} | {
|
|
86
86
|
answer: string;
|
|
87
87
|
});
|
|
88
|
+
/** How a `start` or `resume` line went: the run it named, and the coding agent it said runs it, when it said one. */
|
|
88
89
|
export type RunHookResult = {
|
|
89
90
|
ok: true;
|
|
90
91
|
id: string;
|
|
92
|
+
driver?: string;
|
|
91
93
|
} | {
|
|
92
94
|
ok: false;
|
|
93
95
|
error: string;
|
|
@@ -95,7 +97,8 @@ export type RunHookResult = {
|
|
|
95
97
|
/**
|
|
96
98
|
* Run the project's `start` line: the prompt in `PROMPT`, the picks in `DRIVER`, `MODEL`,
|
|
97
99
|
* `PUBLISH` and `BASE` when made, the follow-up in `THEN` when there is one. The line answers one JSON
|
|
98
|
-
* document on stdout whose `id` names the run it started
|
|
100
|
+
* document on stdout whose `id` names the run it started, and whose `driver` may name the coding
|
|
101
|
+
* agent that runs it.
|
|
99
102
|
*/
|
|
100
103
|
export declare function runStartHook(cwd: string, input: StartHookInput, opts?: Omit<RunHooksOptions, 'log'>): Promise<RunHookResult>;
|
|
101
104
|
/**
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e,CAAC,CAuB7I;AAED;;;;;GAKG;AACH,wBAAsB,OAAO,CAAC,GAAG,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,CAAC,UAAU,GAAG,OAAO,CAAC,MAAM,CAAC,UAAU,CAAC,CAE7F"}
|
package/dist/project-hooks.js
CHANGED
|
@@ -112,7 +112,8 @@ export function startLineTakesBase(line) {
|
|
|
112
112
|
/**
|
|
113
113
|
* Run the project's `start` line: the prompt in `PROMPT`, the picks in `DRIVER`, `MODEL`,
|
|
114
114
|
* `PUBLISH` and `BASE` when made, the follow-up in `THEN` when there is one. The line answers one JSON
|
|
115
|
-
* document on stdout whose `id` names the run it started
|
|
115
|
+
* document on stdout whose `id` names the run it started, and whose `driver` may name the coding
|
|
116
|
+
* agent that runs it.
|
|
116
117
|
*/
|
|
117
118
|
export function runStartHook(cwd, input, opts = {}) {
|
|
118
119
|
return runRunHook(cwd, 'start', {
|
|
@@ -147,9 +148,9 @@ async function runRunHook(cwd, kind, vars, opts) {
|
|
|
147
148
|
catch {
|
|
148
149
|
said = undefined;
|
|
149
150
|
}
|
|
150
|
-
const id = said && typeof said === 'object' ? said
|
|
151
|
+
const { id, driver } = (said && typeof said === 'object' ? said : {});
|
|
151
152
|
if (outcome.summary === 'exit 0' && typeof id === 'string' && id !== '')
|
|
152
|
-
return { ok: true, id };
|
|
153
|
+
return { ok: true, id, ...(typeof driver === 'string' && driver !== '' ? { driver } : {}) };
|
|
153
154
|
// The tool's one line for a person is its last on stderr; without one, how the line ended.
|
|
154
155
|
const lastSaid = outcome.stderr.split('\n').map(s => s.trim()).filter(Boolean).at(-1);
|
|
155
156
|
return { ok: false, error: `the ${kind} hook: ${lastSaid ?? (outcome.summary === 'exit 0' ? 'it answered no run id' : outcome.summary)}` };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"project-hooks.js","sourceRoot":"","sources":["../src/project-hooks.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAo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34
|
door: string;
|
|
35
35
|
/** What the machine's key is known by, when its link said: every call goes only to a machine that shows that key. */
|
|
36
36
|
pin?: string;
|
|
37
|
+
/**
|
|
38
|
+
* The computer's own name, as the machine first said it: what the records of its runs carry,
|
|
39
|
+
* so a run in a project's shared records is known as this machine's. Kept as first said: a
|
|
40
|
+
* machine that later says another name does not get another computer's runs by it.
|
|
41
|
+
*/
|
|
42
|
+
host?: string;
|
|
37
43
|
}
|
|
38
44
|
/**
|
|
39
45
|
* The dashboard's Global options (#410), persisted next to the project list so they
|
|
@@ -189,6 +195,8 @@ export declare function nodeRegistryFs(): RegistryFs;
|
|
|
189
195
|
* and duplicate ids dropped. A malformed entry is skipped, not thrown — a bad registry never breaks the read.
|
|
190
196
|
*/
|
|
191
197
|
export declare function sanitizeCustomPresets(value: unknown): CustomPreset[];
|
|
198
|
+
/** Whether a value reads as a computer's own name: the letters a host name has, at a host name's length. A page shows it. */
|
|
199
|
+
export declare function isHostName(value: unknown): value is string;
|
|
192
200
|
/**
|
|
193
201
|
* Read the whole registry. Forgiving: a missing / unreadable / malformed file — or one in a shape
|
|
194
202
|
* this no longer writes — yields an empty registry, never throws. Projects are deduped by resolved
|
|
@@ -255,6 +263,16 @@ export declare function addMachine(machine: {
|
|
|
255
263
|
record: MachineRecord;
|
|
256
264
|
displaced: MachineRecord[];
|
|
257
265
|
}>;
|
|
266
|
+
/**
|
|
267
|
+
* Keep the computer's own name a saved machine said, the first time it says one. A machine that
|
|
268
|
+
* already has a name keeps it, and one saved again (a new link) starts without one: `key` is
|
|
269
|
+
* the key the machine was asked with, and a machine saved anew since is not named by an answer
|
|
270
|
+
* to the old one. Answers whether the name was written.
|
|
271
|
+
*/
|
|
272
|
+
export declare function nameMachine(machine: {
|
|
273
|
+
id: string;
|
|
274
|
+
key: string;
|
|
275
|
+
}, host: string, fs?: RegistryFs, env?: NodeJS.ProcessEnv): Promise<boolean>;
|
|
258
276
|
/** Take a saved machine off the list, by id. Answers the one that was there. */
|
|
259
277
|
export declare function removeMachine(id: string, fs?: RegistryFs, env?: NodeJS.ProcessEnv): Promise<MachineRecord | undefined>;
|
|
260
278
|
/** A {@link PreferencesStore} bound to the real registry file, wired by the daemon so the
|
package/dist/registry.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"registry.d.ts","sourceRoot":"","sources":["../src/registry.ts"],"names":[],"mappings":"AAGA,OAAO,EAAiB,KAAK,WAAW,EAAE,MAAM,qBAAqB,CAAA;AAGrE;;;;;;;GAOG;AAEH,8BAA8B;AAC9B,MAAM,WAAW,aAAa;IAC5B,iDAAiD;IACjD,EAAE,EAAE,MAAM,CAAA;IACV,0BAA0B;IAC1B,IAAI,EAAE,MAAM,CAAA;IACZ,2CAA2C;IAC3C,OAAO,EAAE,MAAM,CAAA;CAChB;AAED;;;;GAIG;AACH,MAAM,WAAW,aAAa;IAC5B,qGAAqG;IACrG,EAAE,EAAE,MAAM,CAAA;IACV,oEAAoE;IACpE,KAAK,EAAE,MAAM,CAAA;IACb,8EAA8E;IAC9E,GAAG,EAAE,MAAM,CAAA;IACX,0EAA0E;IAC1E,GAAG,EAAE,MAAM,CAAA;IACX,uGAAuG;IACvG,IAAI,EAAE,MAAM,CAAA;IACZ,qHAAqH;IACrH,GAAG,CAAC,EAAE,MAAM,CAAA;
|
|
1
|
+
{"version":3,"file":"registry.d.ts","sourceRoot":"","sources":["../src/registry.ts"],"names":[],"mappings":"AAGA,OAAO,EAAiB,KAAK,WAAW,EAAE,MAAM,qBAAqB,CAAA;AAGrE;;;;;;;GAOG;AAEH,8BAA8B;AAC9B,MAAM,WAAW,aAAa;IAC5B,iDAAiD;IACjD,EAAE,EAAE,MAAM,CAAA;IACV,0BAA0B;IAC1B,IAAI,EAAE,MAAM,CAAA;IACZ,2CAA2C;IAC3C,OAAO,EAAE,MAAM,CAAA;CAChB;AAED;;;;GAIG;AACH,MAAM,WAAW,aAAa;IAC5B,qGAAqG;IACrG,EAAE,EAAE,MAAM,C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