agl 42.2.2 → 43.0.1
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/changelog.md +24 -0
- package/dist_serve/bundle.js +6697 -5287
- package/dist_serve/bundle.js.map +2 -2
- package/dist_serve/bundle.js.third-party-notices.json +29 -29
- package/dist_serve/bundle.js.third-party-notices.txt +29 -29
- package/dist_serve/third-party-notices.md +597 -8
- package/dist_ts/00_commitinfo_data.js +1 -1
- package/dist_ts/aglapi/aglapisurface.document.js +114 -16
- package/dist_ts/aglapi/interfaces.d.ts +30 -0
- package/dist_ts/aglapi/interfaces.js +7 -1
- package/dist_ts/classes.authstore.d.ts +7 -0
- package/dist_ts/classes.authstore.js +12 -1
- package/dist_ts/classes.browserpainttransport.d.ts +2 -2
- package/dist_ts/classes.browserpainttransport.js +9 -8
- package/dist_ts/classes.browserresourcehost.js +30 -20
- package/dist_ts/classes.cli.js +10 -1
- package/dist_ts/classes.controller.d.ts +41 -11
- package/dist_ts/classes.controller.js +232 -52
- package/dist_ts/classes.harnessoperationmanager.d.ts +44 -0
- package/dist_ts/classes.harnessoperationmanager.js +15 -10
- package/dist_ts/classes.mcpclient.d.ts +5 -0
- package/dist_ts/classes.mcpclient.js +15 -3
- package/dist_ts/classes.mcpcontrollerhost.d.ts +3 -0
- package/dist_ts/classes.mcpcontrollerhost.js +17 -3
- package/dist_ts/classes.mcptools.d.ts +4 -3
- package/dist_ts/classes.mcptools.js +20 -1
- package/dist_ts/classes.mcpvalidation.js +4 -1
- package/dist_ts/classes.ticketstore.d.ts +71 -3
- package/dist_ts/classes.ticketstore.js +299 -12
- package/dist_ts/classes.validation.d.ts +2 -0
- package/dist_ts/classes.validation.js +27 -5
- package/dist_ts/driver/classes.directreports.d.ts +23 -3
- package/dist_ts/driver/classes.directreports.js +59 -2
- package/dist_ts/driver/classes.drivereventrelay.js +3 -2
- package/dist_ts/driver/functions.driverinstructions.d.ts +1 -1
- package/dist_ts/driver/functions.driverinstructions.js +12 -3
- package/dist_ts/driver/functions.drivertools.d.ts +4 -0
- package/dist_ts/driver/functions.drivertools.js +8 -2
- package/dist_ts/fleet/classes.boardpump.d.ts +53 -3
- package/dist_ts/fleet/classes.boardpump.js +237 -32
- package/dist_ts/fleet/classes.claudeworkers.d.ts +10 -3
- package/dist_ts/fleet/classes.claudeworkers.js +43 -19
- package/dist_ts/fleet/classes.codexworkers.d.ts +5 -3
- package/dist_ts/fleet/classes.codexworkers.js +26 -9
- package/dist_ts/fleet/classes.deploymonitor.d.ts +253 -0
- package/dist_ts/fleet/classes.deploymonitor.js +821 -0
- package/dist_ts/fleet/classes.gitfacts.d.ts +61 -0
- package/dist_ts/fleet/classes.gitfacts.js +125 -0
- package/dist_ts/fleet/classes.releasereconciler.d.ts +51 -0
- package/dist_ts/fleet/classes.releasereconciler.js +101 -0
- package/dist_ts/fleet/classes.service.d.ts +13 -1
- package/dist_ts/fleet/classes.service.js +76 -7
- package/dist_ts/fleet/classes.ticketeffects.d.ts +13 -0
- package/dist_ts/fleet/classes.ticketeffects.js +42 -8
- package/dist_ts/fleet/classes.workers.d.ts +10 -3
- package/dist_ts/fleet/classes.workers.js +18 -3
- package/dist_ts/fleet/functions.controllerbuild.d.ts +23 -0
- package/dist_ts/fleet/functions.controllerbuild.js +75 -0
- package/dist_ts/fleet/functions.deployprobes.d.ts +39 -0
- package/dist_ts/fleet/functions.deployprobes.js +82 -0
- package/dist_ts/fleet/functions.deployvalidation.d.ts +27 -0
- package/dist_ts/fleet/functions.deployvalidation.js +43 -0
- package/dist_ts/fleet/functions.release.d.ts +2 -1
- package/dist_ts/fleet/functions.release.js +32 -5
- package/dist_ts/fleet/functions.releasefacts.d.ts +42 -0
- package/dist_ts/fleet/functions.releasefacts.js +46 -0
- package/dist_ts/fleet/functions.validation.d.ts +3 -3
- package/dist_ts/fleet/functions.validation.js +4 -7
- package/dist_ts/fleet/functions.watchprobes.js +7 -9
- package/dist_ts/fleet/functions.workervalidation.js +4 -3
- package/dist_ts/fleet/interfaces.workers.d.ts +30 -3
- package/dist_ts/fleet/interfaces.workers.js +14 -1
- package/dist_ts/functions.deploycli.d.ts +36 -0
- package/dist_ts/functions.deploycli.js +157 -0
- package/dist_ts/functions.mcpdeploytools.d.ts +13 -0
- package/dist_ts/functions.mcpdeploytools.js +16 -0
- package/dist_ts/functions.mcptickettools.d.ts +54 -0
- package/dist_ts/functions.mcptickettools.js +8 -7
- package/dist_ts/functions.ticketautolabels.d.ts +2 -0
- package/dist_ts/functions.ticketautolabels.js +9 -3
- package/dist_ts/functions.ticketcli.d.ts +16 -2
- package/dist_ts/functions.ticketcli.js +105 -27
- package/dist_ts/functions.ticketvalidation.d.ts +55 -0
- package/dist_ts/functions.ticketvalidation.js +26 -8
- package/dist_ts_interfaces/deployments.d.ts +241 -0
- package/dist_ts_interfaces/deployments.js +5 -6
- package/dist_ts_interfaces/fleet.d.ts +12 -0
- package/dist_ts_interfaces/fleetworkers.d.ts +21 -1
- package/dist_ts_interfaces/functions.fleetversion.d.ts +4 -0
- package/dist_ts_interfaces/functions.fleetversion.js +25 -0
- package/dist_ts_interfaces/interfaces.d.ts +4 -2
- package/dist_ts_interfaces/interfaces.js +4 -2
- package/dist_ts_interfaces/mcprequests.d.ts +3 -2
- package/dist_ts_interfaces/mcprequests.js +3 -1
- package/dist_ts_interfaces/requests.d.ts +3 -2
- package/dist_ts_interfaces/requests.directreports.d.ts +58 -6
- package/dist_ts_interfaces/requests.js +1 -1
- package/dist_ts_interfaces/requests.tickets.d.ts +25 -5
- package/dist_ts_interfaces/requests.tickets.js +2 -2
- package/dist_ts_interfaces/tickets.d.ts +71 -6
- package/dist_ts_interfaces/tickets.js +34 -6
- package/dist_ts_migration/classes.documentmigrationrunner.d.ts +7 -0
- package/dist_ts_migration/classes.documentmigrationrunner.js +14 -1
- package/dist_ts_migration/index.d.ts +2 -0
- package/dist_ts_migration/index.js +3 -1
- package/dist_ts_migration/v41_ticketclosedcolumn.d.ts +20 -0
- package/dist_ts_migration/v41_ticketclosedcolumn.js +118 -0
- package/dist_ts_migration/v41_ticketlinkrepos.d.ts +24 -0
- package/dist_ts_migration/v41_ticketlinkrepos.js +101 -0
- package/package.json +6 -2
- package/readme.md +308 -36
- package/third-party-notices.md +597 -8
- package/ts/00_commitinfo_data.ts +1 -1
- package/ts/aglapi/aglapisurface.document.ts +113 -15
- package/ts/aglapi/interfaces.ts +6 -0
- package/ts/classes.authstore.ts +13 -0
- package/ts/classes.browserpainttransport.ts +8 -7
- package/ts/classes.browserresourcehost.ts +38 -14
- package/ts/classes.cli.ts +9 -0
- package/ts/classes.controller.ts +244 -61
- package/ts/classes.harnessoperationmanager.ts +20 -14
- package/ts/classes.mcpclient.ts +17 -2
- package/ts/classes.mcpcontrollerhost.ts +18 -2
- package/ts/classes.mcptools.ts +21 -2
- package/ts/classes.mcpvalidation.ts +2 -0
- package/ts/classes.ticketstore.ts +312 -13
- package/ts/classes.validation.ts +28 -4
- package/ts/driver/classes.directreports.ts +58 -3
- package/ts/driver/classes.drivereventrelay.ts +2 -1
- package/ts/driver/functions.driverinstructions.ts +11 -2
- package/ts/driver/functions.drivertools.ts +10 -2
- package/ts/fleet/classes.boardpump.ts +235 -28
- package/ts/fleet/classes.claudeworkers.ts +36 -15
- package/ts/fleet/classes.codexworkers.ts +24 -7
- package/ts/fleet/classes.deploymonitor.ts +854 -0
- package/ts/fleet/classes.gitfacts.ts +135 -0
- package/ts/fleet/classes.releasereconciler.ts +103 -0
- package/ts/fleet/classes.service.ts +81 -8
- package/ts/fleet/classes.ticketeffects.ts +38 -6
- package/ts/fleet/classes.workers.ts +19 -5
- package/ts/fleet/functions.controllerbuild.ts +84 -0
- package/ts/fleet/functions.deployprobes.ts +84 -0
- package/ts/fleet/functions.deployvalidation.ts +50 -0
- package/ts/fleet/functions.release.ts +32 -3
- package/ts/fleet/functions.releasefacts.ts +74 -0
- package/ts/fleet/functions.validation.ts +3 -6
- package/ts/fleet/functions.watchprobes.ts +6 -8
- package/ts/fleet/functions.workervalidation.ts +3 -2
- package/ts/fleet/interfaces.workers.ts +23 -3
- package/ts/functions.deploycli.ts +156 -0
- package/ts/functions.mcpdeploytools.ts +18 -0
- package/ts/functions.mcptickettools.ts +7 -6
- package/ts/functions.ticketautolabels.ts +10 -2
- package/ts/functions.ticketcli.ts +100 -24
- package/ts/functions.ticketvalidation.ts +26 -7
- package/ts_interfaces/deployments.ts +194 -0
- package/ts_interfaces/fleet.ts +17 -2
- package/ts_interfaces/fleetworkers.ts +20 -0
- package/ts_interfaces/functions.fleetversion.ts +20 -0
- package/ts_interfaces/interfaces.ts +3 -1
- package/ts_interfaces/mcprequests.ts +3 -0
- package/ts_interfaces/requests.directreports.ts +52 -8
- package/ts_interfaces/requests.tickets.ts +20 -4
- package/ts_interfaces/requests.ts +6 -1
- package/ts_interfaces/tickets.ts +53 -6
- package/ts_migration/classes.documentmigrationrunner.ts +15 -0
- package/ts_migration/index.ts +2 -0
- package/ts_migration/v41_ticketclosedcolumn.ts +106 -0
- package/ts_migration/v41_ticketlinkrepos.ts +91 -0
- package/ts_web/00_commitinfo_data.ts +1 -1
- package/ts_web/elements.deployments.ts +1066 -0
- package/ts_web/elements.directreport.ts +2 -2
- package/ts_web/elements.directreportsession.ts +5 -5
- package/ts_web/elements.harnesscontrollerapp.ts +179 -13
- package/ts_web/elements.makedirectreport.ts +444 -0
- package/ts_web/elements.nativesession.ts +29 -1
- package/ts_web/elements.ticketboard.ts +74 -18
- package/ts_web/functions.deployments.ts +231 -0
- package/ts_web/functions.sessionchat.ts +2 -0
|
@@ -48,8 +48,8 @@ const namedQuestionLimit = 3;
|
|
|
48
48
|
/**
|
|
49
49
|
* A direct report in its modal: what the Driver view knows of it (status, newest result and the questions open for
|
|
50
50
|
* the owner) over its conversation. A report the fleet runs shows its fleet worker's transcript and a composer that
|
|
51
|
-
* steers it through the report's driver ticket. A Codex thread the fleet does not run shows
|
|
52
|
-
* the
|
|
51
|
+
* steers it through the report's driver ticket. A Codex thread the fleet does not run shows its turns, read through
|
|
52
|
+
* the shared Codex server outside every project, and takes the owner's agent messages. A Claude Code session the fleet does
|
|
53
53
|
* not run has no channel AGL reads or steers through without a second writer, so it shows read-only, with the way to
|
|
54
54
|
* change that.
|
|
55
55
|
*/
|
|
@@ -15,7 +15,7 @@ const { html, css } = plugins.deesElement;
|
|
|
15
15
|
|
|
16
16
|
/** The report's newest conversation page, with the messages the chat shows. */
|
|
17
17
|
interface ISessionPage extends ITranscript {
|
|
18
|
-
readonly
|
|
18
|
+
readonly cwd: string;
|
|
19
19
|
readonly nativeId: string;
|
|
20
20
|
readonly earlier: boolean;
|
|
21
21
|
/** The turn the thread runs, which a message steers. */
|
|
@@ -24,7 +24,7 @@ interface ISessionPage extends ITranscript {
|
|
|
24
24
|
|
|
25
25
|
/**
|
|
26
26
|
* A direct report that is a Codex thread the fleet does not run, in the report's modal: its newest conversation turns,
|
|
27
|
-
* read
|
|
27
|
+
* read through the shared Codex server that owns it, outside every project, and a composer that sends the owner's message
|
|
28
28
|
* as MCP `session_message` delivers an agent message, steered into the running turn or else the next one. Whoever
|
|
29
29
|
* runs the thread stops it; the modal does not. The conversation is read again on `refresh()` and every few seconds
|
|
30
30
|
* while a turn runs.
|
|
@@ -151,11 +151,11 @@ export class AglDirectReportSession extends plugins.deesElement.DeesElement {
|
|
|
151
151
|
abortDisabledReason: 'Whoever runs this Codex thread stops it.',
|
|
152
152
|
disabled: !page || this.sending,
|
|
153
153
|
composerValue: this.draft,
|
|
154
|
-
// A Codex thread report takes text only
|
|
154
|
+
// A Codex thread report takes text only.
|
|
155
155
|
attachmentsEnabled: false,
|
|
156
156
|
showSessionSidebar: false,
|
|
157
157
|
heading: this.name,
|
|
158
|
-
subheading: page ? `Codex thread · ${page.
|
|
158
|
+
subheading: page ? `Codex thread · ${page.cwd} · ${page.nativeId}` : 'Codex thread',
|
|
159
159
|
on: { send: this.handleSend, input: this.handleInput },
|
|
160
160
|
})}
|
|
161
161
|
</div>
|
|
@@ -186,7 +186,7 @@ export class AglDirectReportSession extends plugins.deesElement.DeesElement {
|
|
|
186
186
|
if (generationArg !== this.generation) return;
|
|
187
187
|
if (response.kind !== 'session') throw new Error(`${name} is no longer a Codex thread report.`);
|
|
188
188
|
this.page = {
|
|
189
|
-
|
|
189
|
+
cwd: response.cwd,
|
|
190
190
|
nativeId: response.sessionId.nativeId,
|
|
191
191
|
earlier: response.earlier,
|
|
192
192
|
...(response.turnId === undefined ? {} : { turnId: response.turnId }),
|
|
@@ -30,6 +30,8 @@ import { AglConfigurationPane, type IConfigurationOpenSettingsDetail,
|
|
|
30
30
|
type TConfigurationSectionRequest } from './elements.configurationpane.js';
|
|
31
31
|
import { AglTicketBoard } from './elements.ticketboard.js';
|
|
32
32
|
import { AglMetricsBoard } from './elements.metricsboard.js';
|
|
33
|
+
import { AglDeployments } from './elements.deployments.js';
|
|
34
|
+
import { deploymentsAttentionCount, deploymentsHref } from './functions.deployments.js';
|
|
33
35
|
import { AglFleetWorker } from './elements.fleetworker.js';
|
|
34
36
|
import { AglNativeSession } from './elements.nativesession.js';
|
|
35
37
|
import type { ISessionIntelligenceRemedyDetail } from './classes.nativesessionstate.js';
|
|
@@ -41,6 +43,11 @@ import {
|
|
|
41
43
|
} from './functions.sessionchat.js';
|
|
42
44
|
import { ConversationModal } from './classes.conversationmodal.js';
|
|
43
45
|
import { AglDirectReport, directReportMeta, directReportQuestionCounts } from './elements.directreport.js';
|
|
46
|
+
import {
|
|
47
|
+
showMakeDirectReportDialog,
|
|
48
|
+
type IMakeDirectReportCandidate,
|
|
49
|
+
type IMakeDirectReportRequestDetail,
|
|
50
|
+
} from './elements.makedirectreport.js';
|
|
44
51
|
import {
|
|
45
52
|
WorkspaceSelectionSender,
|
|
46
53
|
workspaceSelectionTargets,
|
|
@@ -266,6 +273,8 @@ interface IConversationChatView extends Pick<
|
|
|
266
273
|
readonly started: boolean;
|
|
267
274
|
/** The direct reports its session panel lists; only the driver's conversation lists them. */
|
|
268
275
|
readonly workers: plugins.deesCatalog.IHarnessSessionMeta[] | undefined;
|
|
276
|
+
/** The chat toolbar's actions; the driver's conversation offers Make direct report. */
|
|
277
|
+
readonly toolbarActions?: plugins.deesCatalog.IHarnessChatToolbarAction[];
|
|
269
278
|
readonly attachedResources: plugins.deesCatalog.IHarnessResourceMeta[];
|
|
270
279
|
/** Notices above the chat. */
|
|
271
280
|
readonly notices: ReadonlyArray<plugins.deesElement.TemplateResult | ''>;
|
|
@@ -831,6 +840,15 @@ const sessionHarnessLabel = (harnessIdArg: TBrowserSessionHarnessId): string =>
|
|
|
831
840
|
: harnessIdArg === 'claude' ? 'Claude Code' : harnessIdArg === 'flex' ? 'Flex' : 'OpenCode'
|
|
832
841
|
);
|
|
833
842
|
|
|
843
|
+
/** The native session a session feed row opens. */
|
|
844
|
+
const nativeSessionRefOf = (
|
|
845
|
+
openArg: Extract<interfaces.TControllerSessionFeedOpen, { kind: 'native' }>,
|
|
846
|
+
): interfaces.IControllerNativeSessionRef => ({
|
|
847
|
+
harness: openArg.harness,
|
|
848
|
+
nativeId: openArg.nativeId,
|
|
849
|
+
...(openArg.profileId === undefined ? {} : { profileId: openArg.profileId }),
|
|
850
|
+
});
|
|
851
|
+
|
|
834
852
|
/** The tool a harness asks the owner questions with; question cards stand for its calls in the transcript. */
|
|
835
853
|
const questionToolName = (harnessIdArg: TBrowserSessionHarnessId): string => (
|
|
836
854
|
harnessIdArg === 'claude' ? 'AskUserQuestion' : 'question'
|
|
@@ -2627,6 +2645,14 @@ export class HarnessControllerApp extends plugins.deesElement.DeesElement {
|
|
|
2627
2645
|
@plugins.deesElement.state()
|
|
2628
2646
|
accessor metricsSelected = false;
|
|
2629
2647
|
|
|
2648
|
+
/** Whether the main pane shows the Deployments view. */
|
|
2649
|
+
@plugins.deesElement.state()
|
|
2650
|
+
accessor deploymentsSelected = false;
|
|
2651
|
+
|
|
2652
|
+
/** How many deploy targets run less than their newest release, rolled back or do not answer: the header badge. */
|
|
2653
|
+
@plugins.deesElement.state()
|
|
2654
|
+
accessor deploymentsAttention = 0;
|
|
2655
|
+
|
|
2630
2656
|
/** The owner's active direct reports as the controller last listed them; undefined while it lists none. */
|
|
2631
2657
|
@plugins.deesElement.state()
|
|
2632
2658
|
accessor directReportViews: interfaces.IDirectReportView[] | undefined;
|
|
@@ -4529,6 +4555,7 @@ export class HarnessControllerApp extends plugins.deesElement.DeesElement {
|
|
|
4529
4555
|
this.selectedConfigurationResource = undefined;
|
|
4530
4556
|
this.boardSelected = false;
|
|
4531
4557
|
this.metricsSelected = false;
|
|
4558
|
+
this.deploymentsSelected = false;
|
|
4532
4559
|
this.fleetWorkerSelected = '';
|
|
4533
4560
|
this.nativeSessionSelected = undefined;
|
|
4534
4561
|
this.directReportViews = undefined;
|
|
@@ -5234,12 +5261,18 @@ export class HarnessControllerApp extends plugins.deesElement.DeesElement {
|
|
|
5234
5261
|
this.refreshProviderManagement(),
|
|
5235
5262
|
this.reconcileControllerStatus(),
|
|
5236
5263
|
this.refreshDriverStatus(),
|
|
5264
|
+
this.refreshDeploymentsAttention(),
|
|
5237
5265
|
this.refreshDirectReports(),
|
|
5238
5266
|
this.refreshSessionFeed(),
|
|
5239
5267
|
]);
|
|
5240
5268
|
void this.retryStaleDraftSessionCleanup();
|
|
5241
5269
|
void this.refreshModelCatalog();
|
|
5242
5270
|
await this.refreshSessions();
|
|
5271
|
+
// A link to the Deployments view, as the board's "Open in Deployments" opens in a new tab, shows it once.
|
|
5272
|
+
if (globalThis.location?.hash === deploymentsHref) {
|
|
5273
|
+
globalThis.history.replaceState(globalThis.history.state, '', `${globalThis.location.pathname}${globalThis.location.search}`);
|
|
5274
|
+
await this.openDeployments();
|
|
5275
|
+
}
|
|
5243
5276
|
}
|
|
5244
5277
|
|
|
5245
5278
|
private scheduleSystemMetricsRefresh(delayMsArg: number): void {
|
|
@@ -8340,7 +8373,7 @@ export class HarnessControllerApp extends plugins.deesElement.DeesElement {
|
|
|
8340
8373
|
);
|
|
8341
8374
|
const standaloneResourceSelected = this.selectedSessionId === undefined
|
|
8342
8375
|
&& (isNonEmptyString(this.selectedResourceId) || this.selectedConfigurationResource !== undefined
|
|
8343
|
-
|| this.boardSelected || this.metricsSelected || this.fleetWorkerSelected !== ''
|
|
8376
|
+
|| this.boardSelected || this.metricsSelected || this.deploymentsSelected || this.fleetWorkerSelected !== ''
|
|
8344
8377
|
|| this.nativeSessionSelected !== undefined);
|
|
8345
8378
|
if (
|
|
8346
8379
|
!selectedStillExists
|
|
@@ -10596,6 +10629,7 @@ export class HarnessControllerApp extends plugins.deesElement.DeesElement {
|
|
|
10596
10629
|
this.selectedConfigurationResource = undefined;
|
|
10597
10630
|
this.boardSelected = false;
|
|
10598
10631
|
this.metricsSelected = false;
|
|
10632
|
+
this.deploymentsSelected = false;
|
|
10599
10633
|
this.fleetWorkerSelected = '';
|
|
10600
10634
|
this.nativeSessionSelected = undefined;
|
|
10601
10635
|
this.resourceViewSelected = false;
|
|
@@ -15924,7 +15958,7 @@ ${entry.detail.stack}`}</pre>`}
|
|
|
15924
15958
|
|
|
15925
15959
|
/**
|
|
15926
15960
|
* The menu of a sidebar row: Rename and Terminate for a terminal, the conversation actions for a
|
|
15927
|
-
* conversation AGL tracks, and copying its id or directory for a native session, which AGL does not
|
|
15961
|
+
* conversation AGL tracks, and copying its id or directory and making it a direct report for a native session, which AGL does not
|
|
15928
15962
|
* own. A failed row of any kind leads with Acknowledge and remove. An action on a row of another
|
|
15929
15963
|
* project moves the workspace there first.
|
|
15930
15964
|
*/
|
|
@@ -15956,6 +15990,12 @@ ${entry.detail.stack}`}</pre>`}
|
|
|
15956
15990
|
...(open.cwd
|
|
15957
15991
|
? [{ name: 'Copy directory', iconName: 'lucide:FolderOpen', action: async () => this.copyToClipboard('directory', open.cwd) }]
|
|
15958
15992
|
: []),
|
|
15993
|
+
{ divider: true },
|
|
15994
|
+
{
|
|
15995
|
+
name: 'Make direct report…',
|
|
15996
|
+
iconName: 'lucide:UserPlus',
|
|
15997
|
+
action: async () => this.openMakeDirectReport(nativeSessionRefOf(open)),
|
|
15998
|
+
},
|
|
15959
15999
|
]);
|
|
15960
16000
|
return;
|
|
15961
16001
|
}
|
|
@@ -16965,9 +17005,16 @@ ${entry.detail.stack}`}</pre>`}
|
|
|
16965
17005
|
// Tickets change only an open board and the open questions of the direct reports the driver lists.
|
|
16966
17006
|
if (eventArg.type === 'tickets.changed') {
|
|
16967
17007
|
void this.ticketBoard()?.refresh();
|
|
17008
|
+
void this.deploymentsView()?.refresh();
|
|
16968
17009
|
if (this.driverShown()) void this.refreshDirectReports();
|
|
16969
17010
|
return;
|
|
16970
17011
|
}
|
|
17012
|
+
if (eventArg.type === 'deployments.changed') {
|
|
17013
|
+
void this.deploymentsView()?.refresh();
|
|
17014
|
+
void this.ticketBoard()?.refreshDetailSections();
|
|
17015
|
+
void this.refreshDeploymentsAttention();
|
|
17016
|
+
return;
|
|
17017
|
+
}
|
|
16971
17018
|
// A direct report's status is its worker's.
|
|
16972
17019
|
if (eventArg.type === 'fleet.workers.changed') {
|
|
16973
17020
|
void this.refreshDirectReports();
|
|
@@ -17287,6 +17334,7 @@ ${entry.detail.stack}`}</pre>`}
|
|
|
17287
17334
|
this.selectedConfigurationResource = undefined;
|
|
17288
17335
|
this.boardSelected = false;
|
|
17289
17336
|
this.metricsSelected = false;
|
|
17337
|
+
this.deploymentsSelected = false;
|
|
17290
17338
|
this.fleetWorkerSelected = '';
|
|
17291
17339
|
this.nativeSessionSelected = undefined;
|
|
17292
17340
|
this.resourceViewSelected = false;
|
|
@@ -19949,6 +19997,22 @@ ${entry.detail.stack}`}</pre>`}
|
|
|
19949
19997
|
<dees-icon icon="lucide:SquareKanban" iconSize="14"></dees-icon>
|
|
19950
19998
|
Board
|
|
19951
19999
|
</dees-button>
|
|
20000
|
+
<dees-button
|
|
20001
|
+
class="deploymentsButton headerNavButton"
|
|
20002
|
+
type="ghost"
|
|
20003
|
+
size=${this.compactHeader ? 'icon' : 'sm'}
|
|
20004
|
+
title=${this.deploymentsAttention > 0
|
|
20005
|
+
? `Deployments: ${this.deploymentsAttention} target${this.deploymentsAttention === 1 ? '' : 's'} behind, not answering or waiting for your go`
|
|
20006
|
+
: 'Deployments'}
|
|
20007
|
+
.pressed=${current === 'deployments'}
|
|
20008
|
+
aria-current=${current === 'deployments' ? 'page' : 'false'}
|
|
20009
|
+
.badge=${this.deploymentsAttention > 0 ? this.deploymentsAttention : undefined}
|
|
20010
|
+
.badgeVariant=${'warning'}
|
|
20011
|
+
@clicked=${() => this.openDeployments()}
|
|
20012
|
+
>
|
|
20013
|
+
<dees-icon icon="lucide:Rocket" iconSize="14"></dees-icon>
|
|
20014
|
+
Deployments
|
|
20015
|
+
</dees-button>
|
|
19952
20016
|
<dees-button
|
|
19953
20017
|
class="metricsButton headerNavButton"
|
|
19954
20018
|
type="ghost"
|
|
@@ -20074,6 +20138,8 @@ ${entry.detail.stack}`}</pre>`}
|
|
|
20074
20138
|
? this.renderBoard()
|
|
20075
20139
|
: this.metricsSelected
|
|
20076
20140
|
? this.renderMetrics()
|
|
20141
|
+
: this.deploymentsSelected
|
|
20142
|
+
? this.renderDeployments()
|
|
20077
20143
|
: this.selectedConfigurationResource
|
|
20078
20144
|
? this.renderConfigurationPane()
|
|
20079
20145
|
: this.resourceViewShown()
|
|
@@ -20352,9 +20418,10 @@ ${entry.detail.stack}`}</pre>`}
|
|
|
20352
20418
|
* The header entry whose view the main pane shows, in the main pane's own precedence: a fleet
|
|
20353
20419
|
* worker, a native session or a configuration resource is no header view.
|
|
20354
20420
|
*/
|
|
20355
|
-
private headerNavCurrent(): 'driver' | 'board' | 'metrics' | interfaces.TControllerResourceKind | undefined {
|
|
20421
|
+
private headerNavCurrent(): 'driver' | 'board' | 'deployments' | 'metrics' | interfaces.TControllerResourceKind | undefined {
|
|
20356
20422
|
if (this.fleetWorkerSelected || this.nativeSessionSelected) return undefined;
|
|
20357
20423
|
if (this.boardSelected) return 'board';
|
|
20424
|
+
if (this.deploymentsSelected) return 'deployments';
|
|
20358
20425
|
if (this.metricsSelected) return 'metrics';
|
|
20359
20426
|
if (this.selectedConfigurationResource) return undefined;
|
|
20360
20427
|
if (this.resourceViewShown()) return this.shownResourceViewKind();
|
|
@@ -20659,6 +20726,11 @@ ${entry.detail.stack}`}</pre>`}
|
|
|
20659
20726
|
return board instanceof AglTicketBoard ? board : undefined;
|
|
20660
20727
|
}
|
|
20661
20728
|
|
|
20729
|
+
private deploymentsView(): AglDeployments | undefined {
|
|
20730
|
+
const view = this.shadowRoot?.querySelector('agl-deployments');
|
|
20731
|
+
return view instanceof AglDeployments ? view : undefined;
|
|
20732
|
+
}
|
|
20733
|
+
|
|
20662
20734
|
private metricsBoard(): AglMetricsBoard | undefined {
|
|
20663
20735
|
const board = this.shadowRoot?.querySelector('agl-metrics-board');
|
|
20664
20736
|
return board instanceof AglMetricsBoard ? board : undefined;
|
|
@@ -20688,6 +20760,30 @@ ${entry.detail.stack}`}</pre>`}
|
|
|
20688
20760
|
});
|
|
20689
20761
|
}
|
|
20690
20762
|
|
|
20763
|
+
/** Shows the Deployments view, which the header button opens. */
|
|
20764
|
+
private openDeployments(): Promise<void> {
|
|
20765
|
+
if (this.deploymentsSelected) return Promise.resolve();
|
|
20766
|
+
return this.leaveWorkspaceThen(() => {
|
|
20767
|
+
this.beginWorkspaceSelection();
|
|
20768
|
+
this.selectedResourceId = '';
|
|
20769
|
+
this.deselectConversationForStandaloneResource();
|
|
20770
|
+
void this.closeBrowserView();
|
|
20771
|
+
this.closeTerminalView();
|
|
20772
|
+
this.deploymentsSelected = true;
|
|
20773
|
+
});
|
|
20774
|
+
}
|
|
20775
|
+
|
|
20776
|
+
/** Reads the deploy status for the header badge; `deployments.changed` reads it again. */
|
|
20777
|
+
private async refreshDeploymentsAttention(): Promise<void> {
|
|
20778
|
+
const generation = this.connectionGeneration;
|
|
20779
|
+
try {
|
|
20780
|
+
const status = await this.socketClient.fire<interfaces.TControllerDeployRequest<'status'>>('controller.deploy.status', {});
|
|
20781
|
+
if (this.isCurrentConnection(generation)) this.deploymentsAttention = deploymentsAttentionCount(status);
|
|
20782
|
+
} catch {
|
|
20783
|
+
// The badge keeps its count until the next change reports one.
|
|
20784
|
+
}
|
|
20785
|
+
}
|
|
20786
|
+
|
|
20691
20787
|
/** Shows the metrics board, which the header button opens. */
|
|
20692
20788
|
private openMetrics(): Promise<void> {
|
|
20693
20789
|
if (this.metricsSelected) return Promise.resolve();
|
|
@@ -20742,6 +20838,63 @@ ${entry.detail.stack}`}</pre>`}
|
|
|
20742
20838
|
if (isNonEmptyString(name)) this.openDirectReportModal(name);
|
|
20743
20839
|
};
|
|
20744
20840
|
|
|
20841
|
+
/** The Driver view's toolbar: making another session a direct report. */
|
|
20842
|
+
private readonly driverToolbarActions: plugins.deesCatalog.IHarnessChatToolbarAction[] = [{
|
|
20843
|
+
id: 'make-direct-report',
|
|
20844
|
+
label: 'Make direct report…',
|
|
20845
|
+
iconName: 'lucide:UserPlus',
|
|
20846
|
+
tooltip: 'Make a session a direct report of the driver',
|
|
20847
|
+
action: () => this.openMakeDirectReport(),
|
|
20848
|
+
}];
|
|
20849
|
+
|
|
20850
|
+
/** A native session view asks to make its session a direct report. */
|
|
20851
|
+
private readonly handleMakeDirectReport = (eventArg: CustomEvent<IMakeDirectReportRequestDetail>): void => {
|
|
20852
|
+
const session = eventArg.detail?.session;
|
|
20853
|
+
if (session) this.openMakeDirectReport(session);
|
|
20854
|
+
};
|
|
20855
|
+
|
|
20856
|
+
/**
|
|
20857
|
+
* Opens the Make direct report dialog for the native session `sessionArg`, or, without one, with the choice of
|
|
20858
|
+
* every native session the session feed lists that is no active report yet, newest first. A report made reads the
|
|
20859
|
+
* Direct reports list again.
|
|
20860
|
+
*/
|
|
20861
|
+
private openMakeDirectReport(sessionArg?: interfaces.IControllerNativeSessionRef): void {
|
|
20862
|
+
const listed = this.sessionFeedRows
|
|
20863
|
+
.flatMap((rowArg) => (rowArg.open.kind === 'native' ? [{ row: rowArg, open: rowArg.open }] : []))
|
|
20864
|
+
.sort((leftArg, rightArg) => rightArg.row.updatedAt - leftArg.row.updatedAt)
|
|
20865
|
+
.map(({ row, open }): IMakeDirectReportCandidate => ({
|
|
20866
|
+
key: row.id,
|
|
20867
|
+
label: `${row.name} (${sessionHarnessLabel(open.harness)})`,
|
|
20868
|
+
session: nativeSessionRefOf(open),
|
|
20869
|
+
ticketKeys: (row.tickets ?? []).map((ticketArg) => ticketArg.key),
|
|
20870
|
+
}));
|
|
20871
|
+
let candidates: IMakeDirectReportCandidate[];
|
|
20872
|
+
if (sessionArg) {
|
|
20873
|
+
const candidate = listed.find((candidateArg) => (
|
|
20874
|
+
candidateArg.session.harness === sessionArg.harness
|
|
20875
|
+
&& candidateArg.session.nativeId === sessionArg.nativeId
|
|
20876
|
+
&& candidateArg.session.profileId === sessionArg.profileId
|
|
20877
|
+
));
|
|
20878
|
+
candidates = [candidate ?? {
|
|
20879
|
+
key: `${sessionArg.harness}:${sessionArg.nativeId}`, label: sessionArg.nativeId, session: { ...sessionArg }, ticketKeys: [],
|
|
20880
|
+
}];
|
|
20881
|
+
} else {
|
|
20882
|
+
const reported = new Set((this.directReportViews ?? []).map((viewArg) => viewArg.report.sessionId));
|
|
20883
|
+
candidates = listed.filter((candidateArg) => !reported.has(`${candidateArg.session.harness}:${candidateArg.session.nativeId}`));
|
|
20884
|
+
}
|
|
20885
|
+
void showMakeDirectReportDialog({
|
|
20886
|
+
sender: this.socketClient,
|
|
20887
|
+
candidates,
|
|
20888
|
+
onMade: (reportArg) => {
|
|
20889
|
+
void plugins.deesCatalog.DeesToast.show({
|
|
20890
|
+
message: `${reportArg.report.name} is now a direct report of the driver.`,
|
|
20891
|
+
type: 'success',
|
|
20892
|
+
});
|
|
20893
|
+
void this.refreshDirectReports();
|
|
20894
|
+
},
|
|
20895
|
+
});
|
|
20896
|
+
}
|
|
20897
|
+
|
|
20745
20898
|
/**
|
|
20746
20899
|
* Opens the direct report `nameArg` in the conversation modal subagents open in, over the driver's conversation.
|
|
20747
20900
|
* Leaving the driver closes it.
|
|
@@ -20917,13 +21070,17 @@ ${entry.detail.stack}`}</pre>`}
|
|
|
20917
21070
|
): void => {
|
|
20918
21071
|
const key = eventArg.detail?.ticket?.key;
|
|
20919
21072
|
if (!isNonEmptyString(key)) return;
|
|
20920
|
-
void this.
|
|
20921
|
-
if (!this.boardSelected) return;
|
|
20922
|
-
await this.updateComplete;
|
|
20923
|
-
await this.ticketBoard()?.openTicket(key);
|
|
20924
|
-
});
|
|
21073
|
+
void this.openTicketOnBoard(key);
|
|
20925
21074
|
};
|
|
20926
21075
|
|
|
21076
|
+
/** Opens the board and the ticket's detail on it. */
|
|
21077
|
+
private async openTicketOnBoard(keyArg: string): Promise<void> {
|
|
21078
|
+
await this.openBoard();
|
|
21079
|
+
if (!this.boardSelected) return;
|
|
21080
|
+
await this.updateComplete;
|
|
21081
|
+
await this.ticketBoard()?.openTicket(keyArg);
|
|
21082
|
+
}
|
|
21083
|
+
|
|
20927
21084
|
/**
|
|
20928
21085
|
* Opens what a feed row names, whatever project it belongs to: its AGL conversation, which a conversation AGL does
|
|
20929
21086
|
* not track yet becomes first, its terminal, the fleet worker bound to a native session, or the native session
|
|
@@ -20933,11 +21090,7 @@ ${entry.detail.stack}`}</pre>`}
|
|
|
20933
21090
|
const open = rowArg.open;
|
|
20934
21091
|
if (open.kind === 'native') {
|
|
20935
21092
|
if (open.workerName) return this.openFleetWorker(open.workerName);
|
|
20936
|
-
return this.openNativeSession(
|
|
20937
|
-
harness: open.harness,
|
|
20938
|
-
nativeId: open.nativeId,
|
|
20939
|
-
...(open.profileId === undefined ? {} : { profileId: open.profileId }),
|
|
20940
|
-
});
|
|
21093
|
+
return this.openNativeSession(nativeSessionRefOf(open));
|
|
20941
21094
|
}
|
|
20942
21095
|
const sessionId = open.kind === 'conversation' && isSessionRuntimeId(open.sessionId) ? open.sessionId : undefined;
|
|
20943
21096
|
if (open.kind === 'conversation' && !sessionId) {
|
|
@@ -21288,10 +21441,21 @@ ${entry.detail.stack}`}</pre>`}
|
|
|
21288
21441
|
.sender=${this.socketClient}
|
|
21289
21442
|
.projects=${this.projects}
|
|
21290
21443
|
.conversations=${this.conversations}
|
|
21444
|
+
@deploy-open=${() => void this.openDeployments()}
|
|
21291
21445
|
></agl-ticket-board>
|
|
21292
21446
|
`;
|
|
21293
21447
|
}
|
|
21294
21448
|
|
|
21449
|
+
private renderDeployments(): plugins.deesElement.TemplateResult {
|
|
21450
|
+
return plugins.deesElement.html`
|
|
21451
|
+
<agl-deployments
|
|
21452
|
+
.sender=${this.socketClient}
|
|
21453
|
+
.projects=${this.projects}
|
|
21454
|
+
@deploy-open-ticket=${(eventArg: CustomEvent<{ key: string }>) => void this.openTicketOnBoard(eventArg.detail.key)}
|
|
21455
|
+
></agl-deployments>
|
|
21456
|
+
`;
|
|
21457
|
+
}
|
|
21458
|
+
|
|
21295
21459
|
private renderMetrics(): plugins.deesElement.TemplateResult {
|
|
21296
21460
|
return plugins.deesElement.html`<agl-metrics-board .sender=${this.socketClient}></agl-metrics-board>`;
|
|
21297
21461
|
}
|
|
@@ -21312,6 +21476,7 @@ ${entry.detail.stack}`}</pre>`}
|
|
|
21312
21476
|
.sender=${this.socketClient}
|
|
21313
21477
|
.ref=${refArg}
|
|
21314
21478
|
@agl-session-intelligence-remedy=${this.handleSessionIntelligenceRemedy}
|
|
21479
|
+
@agl-make-direct-report=${this.handleMakeDirectReport}
|
|
21315
21480
|
></agl-native-session>
|
|
21316
21481
|
`;
|
|
21317
21482
|
}
|
|
@@ -21944,6 +22109,7 @@ ${entry.detail.stack}`}</pre>`}
|
|
|
21944
22109
|
)}</div>`
|
|
21945
22110
|
: '',
|
|
21946
22111
|
workers: this.driverShown() ? this.directReportMetas() : undefined,
|
|
22112
|
+
toolbarActions: this.driverShown() ? this.driverToolbarActions : undefined,
|
|
21947
22113
|
notices: [
|
|
21948
22114
|
this.selectedDetailLoadFailure()
|
|
21949
22115
|
? this.renderDetailLoadFailure(this.selectedDetailLoadFailure()!, true)
|