agl 42.1.0 → 42.2.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 +44 -0
- package/dist_serve/bundle.js +797 -785
- package/dist_serve/bundle.js.map +2 -2
- package/dist_ts/00_commitinfo_data.js +1 -1
- package/dist_ts/aglapi/aglapisurface.document.js +124 -10
- package/dist_ts/classes.accountsactions.d.ts +3 -1
- package/dist_ts/classes.accountsactions.js +16 -1
- package/dist_ts/classes.authstore.js +9 -1
- package/dist_ts/classes.cli.js +19 -49
- package/dist_ts/classes.configurationauthority.js +2 -2
- package/dist_ts/classes.controllerservice.d.ts +20 -2
- package/dist_ts/classes.controllerservice.js +42 -6
- package/dist_ts/classes.flexservice.js +8 -3
- package/dist_ts/classes.inferencegateway.d.ts +30 -2
- package/dist_ts/classes.inferencegateway.js +115 -20
- package/dist_ts/classes.inferencerouter.d.ts +16 -0
- package/dist_ts/classes.inferencerouter.js +5 -3
- package/dist_ts/classes.inferenceservice.js +7 -3
- package/dist_ts/classes.ticketmodels.js +4 -3
- package/dist_ts/classes.ticketnotifier.js +9 -2
- package/dist_ts/classes.ticketstore.js +9 -5
- package/dist_ts/classes.upgradecoordinator.d.ts +6 -1
- package/dist_ts/classes.upgradecoordinator.js +9 -2
- package/dist_ts/classes.upgradetransaction.d.ts +27 -1
- package/dist_ts/classes.upgradetransaction.js +92 -2
- package/dist_ts/configuration/functions.master.d.ts +7 -2
- package/dist_ts/configuration/functions.master.js +7 -4
- package/dist_ts/driver/classes.drivereventrelay.d.ts +1 -1
- package/dist_ts/driver/classes.drivereventrelay.js +3 -3
- package/dist_ts/fleet/classes.boardpump.d.ts +1 -1
- package/dist_ts/fleet/classes.boardpump.js +7 -4
- package/dist_ts/fleet/classes.claudeworkers.d.ts +6 -0
- package/dist_ts/fleet/classes.claudeworkers.js +17 -7
- package/dist_ts/fleet/classes.deploymodels.d.ts +19 -0
- package/dist_ts/fleet/classes.deploymodels.js +140 -0
- package/dist_ts/fleet/functions.validation.d.ts +8 -1
- package/dist_ts/fleet/functions.validation.js +65 -3
- package/dist_ts/fleet/interfaces.workers.d.ts +6 -0
- package/dist_ts/fleet/interfaces.workers.js +65 -2
- package/dist_ts/functions.fleetworkercli.d.ts +16 -3
- package/dist_ts/functions.fleetworkercli.js +21 -7
- package/dist_ts/functions.inferencecli.js +4 -2
- package/dist_ts/functions.mcptickettools.d.ts +1 -0
- package/dist_ts/functions.ticketvalidation.d.ts +36 -3
- package/dist_ts/functions.ticketvalidation.js +45 -14
- package/dist_ts/interfaces.auth.d.ts +1 -1
- package/dist_ts/interfaces.auth.js +2 -1
- package/dist_ts_authswitch/authority-contract.d.ts +23 -0
- package/dist_ts_authswitch/authority-contract.js +1 -1
- package/dist_ts_authswitch/classes.authoritybroker.d.ts +12 -0
- package/dist_ts_authswitch/classes.authoritybroker.js +72 -22
- package/dist_ts_authswitch/classes.authoritycli.d.ts +1 -0
- package/dist_ts_authswitch/classes.authoritycli.js +26 -1
- package/dist_ts_authswitch/classes.authorityclient.d.ts +3 -1
- package/dist_ts_authswitch/classes.authorityclient.js +10 -4
- package/dist_ts_authswitch/classes.authoritydaemon.js +7 -1
- package/dist_ts_authswitch/classes.authorityimport.js +2 -2
- package/dist_ts_authswitch/classes.authoritymodels.d.ts +3 -0
- package/dist_ts_authswitch/classes.authoritymodels.js +10 -3
- package/dist_ts_authswitch/classes.authorityusage.js +5 -3
- package/dist_ts_authswitch/classes.claudeauthority.js +2 -2
- package/dist_ts_authswitch/testsupport.js +4 -4
- package/dist_ts_authswitch/ts_migration/0012_account_claude_code.d.ts +11 -0
- package/dist_ts_authswitch/ts_migration/0012_account_claude_code.js +18 -0
- package/dist_ts_authswitch/ts_migration/index.js +3 -1
- package/dist_ts_interfaces/deployments.d.ts +104 -0
- package/dist_ts_interfaces/deployments.js +8 -0
- package/dist_ts_interfaces/fleet.d.ts +2 -0
- package/dist_ts_interfaces/index.d.ts +1 -0
- package/dist_ts_interfaces/index.js +2 -1
- package/dist_ts_interfaces/interfaces.d.ts +1 -1
- package/dist_ts_interfaces/interfaces.js +1 -1
- package/dist_ts_interfaces/requests.accounts.d.ts +18 -0
- package/dist_ts_interfaces/requests.accounts.js +1 -1
- package/dist_ts_interfaces/requests.d.ts +2 -2
- package/dist_ts_interfaces/requests.js +1 -1
- package/dist_ts_interfaces/tickets.d.ts +53 -4
- package/dist_ts_interfaces/tickets.js +6 -2
- package/dist_ts_migration/index.d.ts +1 -0
- package/dist_ts_migration/index.js +2 -1
- package/dist_ts_migration/v41_ticketmigrationmarkers.d.ts +19 -0
- package/dist_ts_migration/v41_ticketmigrationmarkers.js +85 -0
- package/docs/authswitch.md +9 -1
- package/package.json +5 -5
- package/readme.md +48 -12
- package/ts/00_commitinfo_data.ts +1 -1
- package/ts/aglapi/aglapisurface.document.ts +123 -9
- package/ts/classes.accountsactions.ts +24 -0
- package/ts/classes.authstore.ts +8 -0
- package/ts/classes.cli.ts +17 -54
- package/ts/classes.configurationauthority.ts +1 -1
- package/ts/classes.controllerservice.ts +49 -6
- package/ts/classes.flexservice.ts +7 -2
- package/ts/classes.inferencegateway.ts +133 -19
- package/ts/classes.inferencerouter.ts +20 -2
- package/ts/classes.inferenceservice.ts +6 -3
- package/ts/classes.ticketmodels.ts +3 -2
- package/ts/classes.ticketnotifier.ts +8 -1
- package/ts/classes.ticketstore.ts +8 -4
- package/ts/classes.upgradecoordinator.ts +14 -4
- package/ts/classes.upgradetransaction.ts +118 -0
- package/ts/configuration/functions.master.ts +6 -3
- package/ts/driver/classes.drivereventrelay.ts +2 -2
- package/ts/fleet/classes.boardpump.ts +7 -4
- package/ts/fleet/classes.claudeworkers.ts +16 -6
- package/ts/fleet/classes.deploymodels.ts +44 -0
- package/ts/fleet/functions.validation.ts +50 -2
- package/ts/fleet/interfaces.workers.ts +56 -1
- package/ts/functions.fleetworkercli.ts +26 -8
- package/ts/functions.inferencecli.ts +3 -1
- package/ts/functions.ticketvalidation.ts +48 -13
- package/ts/interfaces.auth.ts +1 -0
- package/ts_authswitch/authority-contract.ts +18 -0
- package/ts_authswitch/classes.authoritybroker.ts +67 -19
- package/ts_authswitch/classes.authoritycli.ts +29 -0
- package/ts_authswitch/classes.authorityclient.ts +12 -4
- package/ts_authswitch/classes.authoritydaemon.ts +8 -1
- package/ts_authswitch/classes.authorityimport.ts +1 -1
- package/ts_authswitch/classes.authoritymodels.ts +5 -1
- package/ts_authswitch/classes.authorityusage.ts +5 -2
- package/ts_authswitch/classes.claudeauthority.ts +1 -1
- package/ts_authswitch/native-contracts.md +10 -0
- package/ts_authswitch/testsupport.ts +3 -3
- package/ts_authswitch/ts_migration/0012_account_claude_code.ts +17 -0
- package/ts_authswitch/ts_migration/index.ts +2 -0
- package/ts_interfaces/deployments.ts +98 -0
- package/ts_interfaces/fleet.ts +2 -0
- package/ts_interfaces/index.ts +1 -0
- package/ts_interfaces/interfaces.ts +1 -1
- package/ts_interfaces/requests.accounts.ts +16 -0
- package/ts_interfaces/requests.ts +2 -0
- package/ts_interfaces/tickets.ts +34 -4
- package/ts_migration/index.ts +1 -0
- package/ts_migration/v41_ticketmigrationmarkers.ts +28 -0
- package/ts_web/00_commitinfo_data.ts +1 -1
- package/ts_web/classes.accountsreadmodel.ts +12 -1
- package/ts_web/elements.accounts.ts +44 -0
- package/ts_web/elements.ticketboard.ts +15 -4
|
@@ -1,5 +1,8 @@
|
|
|
1
|
-
|
|
1
|
+
/** `closed` holds work that ships no code: done without a landing or a release. */
|
|
2
|
+
export declare const ticketColumns: readonly ['backlog', 'ready', 'in_progress', 'needs_input', 'review', 'landed', 'released', 'closed'];
|
|
2
3
|
export type TTicketColumn = (typeof ticketColumns)[number];
|
|
4
|
+
/** The columns of finished work; the board folds them. */
|
|
5
|
+
export declare const ticketDoneColumns: readonly TTicketColumn[];
|
|
3
6
|
export type TTicketKind = 'epic' | 'task' | 'subtask';
|
|
4
7
|
export type TTicketPriority = 'none' | 'low' | 'normal' | 'high' | 'urgent';
|
|
5
8
|
export interface ITicketPerson {
|
|
@@ -11,6 +14,11 @@ export interface ITicketPerson {
|
|
|
11
14
|
export interface ITicketActor extends ITicketPerson {
|
|
12
15
|
role: 'owner' | 'driver' | 'worker';
|
|
13
16
|
}
|
|
17
|
+
/**
|
|
18
|
+
* Evidence a ticket carries. A release is a repository's tag `v<version>`: its link names the repository (`org/name`)
|
|
19
|
+
* and the commit the tag points at, and the package it published where there is one; a release linked by hand names
|
|
20
|
+
* the package alone. `affects` records the version of a repository a bug was found in.
|
|
21
|
+
*/
|
|
14
22
|
export type TTicketLink = {
|
|
15
23
|
kind: 'branch';
|
|
16
24
|
repo: string;
|
|
@@ -22,9 +30,44 @@ export type TTicketLink = {
|
|
|
22
30
|
sha: string;
|
|
23
31
|
} | {
|
|
24
32
|
kind: 'release';
|
|
25
|
-
|
|
33
|
+
version: string;
|
|
34
|
+
package?: string;
|
|
35
|
+
repo?: string;
|
|
36
|
+
sha?: string;
|
|
37
|
+
} | {
|
|
38
|
+
kind: 'affects';
|
|
39
|
+
repo: string;
|
|
26
40
|
version: string;
|
|
27
41
|
};
|
|
42
|
+
/**
|
|
43
|
+
* A planned release: the repository (`org/name`, one fleet discovery knows) and, optionally, the version it should
|
|
44
|
+
* reach; without a version it means the next release. A hotfix is the same plan on an urgent ticket.
|
|
45
|
+
*/
|
|
46
|
+
export interface ITicketReleasePlan {
|
|
47
|
+
repo: string;
|
|
48
|
+
version?: string;
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* A maintenance window: between `from` and `to` (ISO 8601 instants, `to` after `from`) the deploy targets it lists may
|
|
52
|
+
* be deployed, which a target whose deploys need a window waits for. A window counts while its ticket is not done.
|
|
53
|
+
* `questionId` is the owner's question on the ticket when the driver proposed the window: it counts once the owner
|
|
54
|
+
* approves it there. The owner's own window has none and counts at once.
|
|
55
|
+
*/
|
|
56
|
+
export interface ITicketMaintenanceWindow {
|
|
57
|
+
from: string;
|
|
58
|
+
to: string;
|
|
59
|
+
targets: string[];
|
|
60
|
+
questionId?: string;
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* A planned deploy: the deploy target should run `version`, a release of its repository, or a newer one. Setting it
|
|
64
|
+
* asks the owner `questionId` on the ticket; the answer is the owner's go.
|
|
65
|
+
*/
|
|
66
|
+
export interface ITicketDeployPlan {
|
|
67
|
+
target: string;
|
|
68
|
+
version: string;
|
|
69
|
+
questionId: string;
|
|
70
|
+
}
|
|
28
71
|
export interface ITicketAttachment {
|
|
29
72
|
name: string;
|
|
30
73
|
url: string;
|
|
@@ -50,6 +93,9 @@ export interface ITicket {
|
|
|
50
93
|
assignee?: ITicketPerson;
|
|
51
94
|
labels: string[];
|
|
52
95
|
links: TTicketLink[];
|
|
96
|
+
releasePlan?: ITicketReleasePlan;
|
|
97
|
+
maintenanceWindow?: ITicketMaintenanceWindow;
|
|
98
|
+
deployPlan?: ITicketDeployPlan;
|
|
53
99
|
source: ITicketSource;
|
|
54
100
|
createdBy: ITicketActor;
|
|
55
101
|
updatedBy: ITicketActor;
|
|
@@ -98,7 +144,7 @@ export interface ITicketActivity {
|
|
|
98
144
|
ticketId: string;
|
|
99
145
|
actor: ITicketActor;
|
|
100
146
|
createdAt: string;
|
|
101
|
-
action: 'created' | 'updated' | 'moved' | 'reordered' | 'commented' | 'linked' | 'asked' | 'answered';
|
|
147
|
+
action: 'created' | 'updated' | 'moved' | 'reordered' | 'commented' | 'linked' | 'unlinked' | 'asked' | 'answered';
|
|
102
148
|
changes: Record<string, {
|
|
103
149
|
before?: unknown;
|
|
104
150
|
after?: unknown;
|
|
@@ -366,8 +412,10 @@ export type TTicketFleetEvent = ITicketFleetEventBase & ({
|
|
|
366
412
|
body?: string | TTicketReferenceContent;
|
|
367
413
|
} | {
|
|
368
414
|
kind: 'released';
|
|
369
|
-
package: string;
|
|
370
415
|
version: string;
|
|
416
|
+
package?: string;
|
|
417
|
+
repo?: string;
|
|
418
|
+
sha?: string;
|
|
371
419
|
body?: string | TTicketReferenceContent;
|
|
372
420
|
} | {
|
|
373
421
|
kind: 'comment';
|
|
@@ -395,6 +443,7 @@ export declare const ticketErrorMessages: {
|
|
|
395
443
|
readonly ticket_label_reserved: 'AutoLabels such as openQuestion are computed by AGL and cannot be set by hand.';
|
|
396
444
|
readonly ticket_ask_forbidden: 'Workers may ask questions only on tickets assigned to their verified session.';
|
|
397
445
|
readonly ticket_answer_forbidden: 'Only the owner or the driver may answer ticket questions.';
|
|
446
|
+
readonly ticket_go_owner_only: 'Only the owner answers the question of a deploy plan or a maintenance window: the answer is the owner\'s go.';
|
|
398
447
|
readonly ticket_question_not_found: 'The requested question does not exist on this ticket.';
|
|
399
448
|
readonly ticket_comment_not_found: 'The requested comment does not exist on this ticket.';
|
|
400
449
|
readonly ticket_question_answered: 'The question already has a different answer; a second answer is refused. Ask a new question instead.';
|
|
@@ -1,6 +1,9 @@
|
|
|
1
|
+
/** `closed` holds work that ships no code: done without a landing or a release. */
|
|
1
2
|
export const ticketColumns = [
|
|
2
|
-
'backlog', 'ready', 'in_progress', 'needs_input', 'review', 'landed', 'released',
|
|
3
|
+
'backlog', 'ready', 'in_progress', 'needs_input', 'review', 'landed', 'released', 'closed',
|
|
3
4
|
];
|
|
5
|
+
/** The columns of finished work; the board folds them. */
|
|
6
|
+
export const ticketDoneColumns = ['released', 'closed'];
|
|
4
7
|
/** Labels AGL computes from a ticket's state. Hand labels may not use these names. */
|
|
5
8
|
export const ticketAutoLabels = ['openQuestion'];
|
|
6
9
|
export const isTicketAutoLabel = (valueArg) => (ticketAutoLabels.includes(valueArg));
|
|
@@ -63,6 +66,7 @@ export const ticketErrorMessages = {
|
|
|
63
66
|
ticket_label_reserved: 'AutoLabels such as openQuestion are computed by AGL and cannot be set by hand.',
|
|
64
67
|
ticket_ask_forbidden: 'Workers may ask questions only on tickets assigned to their verified session.',
|
|
65
68
|
ticket_answer_forbidden: 'Only the owner or the driver may answer ticket questions.',
|
|
69
|
+
ticket_go_owner_only: 'Only the owner answers the question of a deploy plan or a maintenance window: the answer is the owner\'s go.',
|
|
66
70
|
ticket_question_not_found: 'The requested question does not exist on this ticket.',
|
|
67
71
|
ticket_comment_not_found: 'The requested comment does not exist on this ticket.',
|
|
68
72
|
ticket_question_answered: 'The question already has a different answer; a second answer is refused. Ask a new question instead.',
|
|
@@ -70,4 +74,4 @@ export const ticketErrorMessages = {
|
|
|
70
74
|
};
|
|
71
75
|
export const ticketClientErrorMessages = Object.fromEntries(Object.entries(ticketErrorMessages)
|
|
72
76
|
.map(([codeArg, messageArg]) => [codeArg.toUpperCase(), messageArg]));
|
|
73
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
77
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidGlja2V0cy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uL3RzX2ludGVyZmFjZXMvdGlja2V0cy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxtRkFBbUY7QUFDbkYsTUFBTSxDQUFDLE1BQU0sYUFBYSxHQUFHO0lBQzNCLFNBQVMsRUFBRSxPQUFPLEVBQUUsYUFBYSxFQUFFLGFBQWEsRUFBRSxRQUFRLEVBQUUsUUFBUSxFQUFFLFVBQVUsRUFBRSxRQUFRO0NBQ2xGLENBQUM7QUFFWCwwREFBMEQ7QUFDMUQsTUFBTSxDQUFDLE1BQU0saUJBQWlCLEdBQTZCLENBQUMsVUFBVSxFQUFFLFFBQVEsQ0FBQyxDQUFDO0FBMEVsRixzRkFBc0Y7QUFDdEYsTUFBTSxDQUFDLE1BQU0sZ0JBQWdCLEdBQUcsQ0FBQyxjQUFjLENBQVUsQ0FBQztBQUUxRCxNQUFNLENBQUMsTUFBTSxpQkFBaUIsR0FBRyxDQUFDLFFBQWdCLEVBQWdDLEVBQUUsQ0FBQyxDQUNsRixnQkFBc0MsQ0FBQyxRQUFRLENBQUMsUUFBUSxDQUFDLENBQzNELENBQUM7QUFLRix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BQXdCLEVBQUUsaUhBQWlIO0lBQzNJLGdCQUFnQixFQUFFLHNDQUFzQztJQUN4RCxtQkFBbUIsRUFBRSw2RUFBNkU7SUFDbEcsb0JBQW9CLEVBQUUsOEhBQThIO0lBQ3BKLDRCQUE0QixFQUFFLCtDQUErQztJQUM3RSwyQkFBMkIsRUFBRSw4Q0FBOEM7SUFDM0UsNkJBQTZCLEVBQUUsMkRBQTJEO0lBQzFGLHNCQUFzQixFQUFFLG1DQUFtQztJQUMzRCxxQkFBcUIsRUFBRSxrRkFBa0Y7SUFDekcsMEJBQTBCLEVBQUUscUVBQXFFO0lBQ2pHLHFCQUFxQixFQUFFLGdGQUFnRjtJQUN2RyxvQkFBb0IsRUFBRSwrRUFBK0U7SUFDckcsdUJBQXVCLEVBQUUsMkRBQTJEO0lBQ3BGLG9CQUFvQixFQUFFLDhHQUE4RztJQUNwSSx5QkFBeUIsRUFBRSx1REFBdUQ7SUFDbEYsd0JBQXdCLEVBQUUsc0RBQXNEO0lBQ2hGLHdCQUF3QixFQUFFLHNHQUFzRztJQUNoSSxxQkFBcUIsRUFBRSxxSEFBcUg7Q0FDcEksQ0FBQztBQUVYLE1BQU0sQ0FBQyxNQUFNLHlCQUF5QixHQUFHLE1BQU0sQ0FBQyxXQUFXLENBQUMsTUFBTSxDQUFDLE9BQU8sQ0FBQyxtQkFBbUIsQ0FBQztLQUM1RixHQUFHLENBQUMsQ0FBQyxDQUFDLE9BQU8sRUFBRSxVQUFVLENBQUMsRUFBRSxFQUFFLENBQUMsQ0FBQyxPQUFPLENBQUMsV0FBVyxFQUFFLEVBQUUsVUFBVSxDQUFDLENBQUMsQ0FBMkMsQ0FBQyJ9
|
|
@@ -27,4 +27,5 @@ export * from './v38_flextranscripts.js';
|
|
|
27
27
|
export * from './v39_fleetrepositorydiscovery.js';
|
|
28
28
|
export * from './v39_flexcompaction.js';
|
|
29
29
|
export * from './v39_flexpublicheadpointers.js';
|
|
30
|
-
|
|
30
|
+
export * from './v41_ticket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BQztBQUN4QyxjQUFjLGlDQUFpQyxDQUFDO0FBQ2hELGNBQWMsaUNBQWlDLENBQUMifQ==
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import * as plugins from './plugins.js';
|
|
2
|
+
/** A ticket migration that ran: its name, when it finished and the tickets it changed. */
|
|
3
|
+
export interface ITicketMigrationMarkerDocument {
|
|
4
|
+
/** The migration's name, such as `v41_ticketclosedcolumn`. */
|
|
5
|
+
id: string;
|
|
6
|
+
completedAt: string;
|
|
7
|
+
/** The keys of the tickets it changed. */
|
|
8
|
+
tickets: string[];
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* One record per ticket migration that ran, written in the transaction that ran it: a migration with a marker never
|
|
12
|
+
* runs again, whatever the board looks like at a later start.
|
|
13
|
+
*/
|
|
14
|
+
export declare class TicketMigrationMarkerModel extends plugins.nosqldb.SmartDataDbDoc<TicketMigrationMarkerModel, ITicketMigrationMarkerDocument> {
|
|
15
|
+
static exact: plugins.nosqldb.TExact<TicketMigrationMarkerModel>;
|
|
16
|
+
id: string;
|
|
17
|
+
completedAt: string;
|
|
18
|
+
tickets: string[];
|
|
19
|
+
}
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
var __esDecorate = (this && this.__esDecorate) || function (ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {
|
|
2
|
+
function accept(f) { if (f !== void 0 && typeof f !== "function") throw new TypeError("Function expected"); return f; }
|
|
3
|
+
var kind = contextIn.kind, key = kind === "getter" ? "get" : kind === "setter" ? "set" : "value";
|
|
4
|
+
var target = !descriptorIn && ctor ? contextIn["static"] ? ctor : ctor.prototype : null;
|
|
5
|
+
var descriptor = descriptorIn || (target ? Object.getOwnPropertyDescriptor(target, contextIn.name) : {});
|
|
6
|
+
var _, done = false;
|
|
7
|
+
for (var i = decorators.length - 1; i >= 0; i--) {
|
|
8
|
+
var context = {};
|
|
9
|
+
for (var p in contextIn) context[p] = p === "access" ? {} : contextIn[p];
|
|
10
|
+
for (var p in contextIn.access) context.access[p] = contextIn.access[p];
|
|
11
|
+
context.addInitializer = function (f) { if (done) throw new TypeError("Cannot add initializers after decoration has completed"); extraInitializers.push(accept(f || null)); };
|
|
12
|
+
var result = (0, decorators[i])(kind === "accessor" ? { get: descriptor.get, set: descriptor.set } : descriptor[key], context);
|
|
13
|
+
if (kind === "accessor") {
|
|
14
|
+
if (result === void 0) continue;
|
|
15
|
+
if (result === null || typeof result !== "object") throw new TypeError("Object expected");
|
|
16
|
+
if (_ = accept(result.get)) descriptor.get = _;
|
|
17
|
+
if (_ = accept(result.set)) descriptor.set = _;
|
|
18
|
+
if (_ = accept(result.init)) initializers.unshift(_);
|
|
19
|
+
}
|
|
20
|
+
else if (_ = accept(result)) {
|
|
21
|
+
if (kind === "field") initializers.unshift(_);
|
|
22
|
+
else descriptor[key] = _;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
if (target) Object.defineProperty(target, contextIn.name, descriptor);
|
|
26
|
+
done = true;
|
|
27
|
+
};
|
|
28
|
+
var __runInitializers = (this && this.__runInitializers) || function (thisArg, initializers, value) {
|
|
29
|
+
var useValue = arguments.length > 2;
|
|
30
|
+
for (var i = 0; i < initializers.length; i++) {
|
|
31
|
+
value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg);
|
|
32
|
+
}
|
|
33
|
+
return useValue ? value : void 0;
|
|
34
|
+
};
|
|
35
|
+
import * as plugins from './plugins.js';
|
|
36
|
+
const markerSchema = plugins.z.object({
|
|
37
|
+
id: plugins.z.string().regex(/^v[0-9]+_[a-z0-9]+$/u), completedAt: plugins.z.iso.datetime(),
|
|
38
|
+
tickets: plugins.z.array(plugins.z.string().regex(/^AGL-[1-9][0-9]*$/u)).max(100_000),
|
|
39
|
+
}).strict();
|
|
40
|
+
/**
|
|
41
|
+
* One record per ticket migration that ran, written in the transaction that ran it: a migration with a marker never
|
|
42
|
+
* runs again, whatever the board looks like at a later start.
|
|
43
|
+
*/
|
|
44
|
+
let TicketMigrationMarkerModel = (() => {
|
|
45
|
+
let _classDecorators = [plugins.nosqldb.managed({ collectionName: 'agl_ticket_migrations' }), plugins.nosqldb.exactPersistence({ assertDocument: (input) => { markerSchema.parse(input); } })];
|
|
46
|
+
let _classDescriptor;
|
|
47
|
+
let _classExtraInitializers = [];
|
|
48
|
+
let _classThis;
|
|
49
|
+
let _classSuper = plugins.nosqldb.SmartDataDbDoc;
|
|
50
|
+
let _id_decorators;
|
|
51
|
+
let _id_initializers = [];
|
|
52
|
+
let _id_extraInitializers = [];
|
|
53
|
+
let _completedAt_decorators;
|
|
54
|
+
let _completedAt_initializers = [];
|
|
55
|
+
let _completedAt_extraInitializers = [];
|
|
56
|
+
let _tickets_decorators;
|
|
57
|
+
let _tickets_initializers = [];
|
|
58
|
+
let _tickets_extraInitializers = [];
|
|
59
|
+
var TicketMigrationMarkerModel = class extends _classSuper {
|
|
60
|
+
static { _classThis = this; }
|
|
61
|
+
static {
|
|
62
|
+
const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
|
|
63
|
+
_id_decorators = [plugins.nosqldb.unI()];
|
|
64
|
+
_completedAt_decorators = [plugins.nosqldb.svDb()];
|
|
65
|
+
_tickets_decorators = [plugins.nosqldb.svDb()];
|
|
66
|
+
__esDecorate(null, null, _id_decorators, { kind: "field", name: "id", static: false, private: false, access: { has: obj => "id" in obj, get: obj => obj.id, set: (obj, value) => { obj.id = value; } }, metadata: _metadata }, _id_initializers, _id_extraInitializers);
|
|
67
|
+
__esDecorate(null, null, _completedAt_decorators, { kind: "field", name: "completedAt", static: false, private: false, access: { has: obj => "completedAt" in obj, get: obj => obj.completedAt, set: (obj, value) => { obj.completedAt = value; } }, metadata: _metadata }, _completedAt_initializers, _completedAt_extraInitializers);
|
|
68
|
+
__esDecorate(null, null, _tickets_decorators, { kind: "field", name: "tickets", static: false, private: false, access: { has: obj => "tickets" in obj, get: obj => obj.tickets, set: (obj, value) => { obj.tickets = value; } }, metadata: _metadata }, _tickets_initializers, _tickets_extraInitializers);
|
|
69
|
+
__esDecorate(null, _classDescriptor = { value: _classThis }, _classDecorators, { kind: "class", name: _classThis.name, metadata: _metadata }, null, _classExtraInitializers);
|
|
70
|
+
TicketMigrationMarkerModel = _classThis = _classDescriptor.value;
|
|
71
|
+
if (_metadata) Object.defineProperty(_classThis, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
|
|
72
|
+
__runInitializers(_classThis, _classExtraInitializers);
|
|
73
|
+
}
|
|
74
|
+
id = __runInitializers(this, _id_initializers, void 0);
|
|
75
|
+
completedAt = (__runInitializers(this, _id_extraInitializers), __runInitializers(this, _completedAt_initializers, void 0));
|
|
76
|
+
tickets = (__runInitializers(this, _completedAt_extraInitializers), __runInitializers(this, _tickets_initializers, void 0));
|
|
77
|
+
constructor() {
|
|
78
|
+
super(...arguments);
|
|
79
|
+
__runInitializers(this, _tickets_extraInitializers);
|
|
80
|
+
}
|
|
81
|
+
};
|
|
82
|
+
return TicketMigrationMarkerModel = _classThis;
|
|
83
|
+
})();
|
|
84
|
+
export { TicketMigrationMarkerModel };
|
|
85
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidjQxX3RpY2tldG1pZ3JhdGlvbm1hcmtlcnMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi90c19taWdyYXRpb24vdjQxX3RpY2tldG1pZ3JhdGlvbm1hcmtlcnMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7OztBQUFBLE9BQU8sS0FBSyxPQUFPLE1BQU0sY0FBYyxDQUFDO0FBV3hDLE1BQU0sWUFBWSxHQUFHLE9BQU8sQ0FBQyxDQUFDLENBQUMsTUFBTSxDQUFDO0lBQ3BDLEVBQUUsRUFBRSxPQUFPLENBQUMsQ0FBQyxDQU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zs7WUFMWSx1REFBMEI7O1FBRVAsRUFBRSxxREFBVTtRQUNYLFdBQVcsZ0hBQVU7UUFDckIsT0FBTyxxSEFBWTs7Ozs7Ozs7U0FKdkMsMEJBQTBCIn0=
|
package/docs/authswitch.md
CHANGED
|
@@ -328,6 +328,7 @@ authswitch account set <account-id> --lapses-at <date-time> [--json]
|
|
|
328
328
|
authswitch account set <account-id> --clear-lapse [--json]
|
|
329
329
|
authswitch account set <account-id> --spend-limit <dollars> [--json]
|
|
330
330
|
authswitch account set <account-id> --clear-spend-limit [--json]
|
|
331
|
+
authswitch account set <account-id> --claude-code on|off [--json]
|
|
331
332
|
authswitch account operation get <operation-id> [--json]
|
|
332
333
|
authswitch account operation cancel <operation-id> [--json]
|
|
333
334
|
authswitch account operation resume <operation-id> [--json]
|
|
@@ -473,6 +474,11 @@ The login's purpose is `anthropic_api_key` or `openai_api_key`; it backs the `ga
|
|
|
473
474
|
or revokes it. `--spend-limit` takes dollars to the cent (`12.50`, `$50`). The command prints the account, how its key
|
|
474
475
|
ends and its limit; `--json` prints `{ account, loginId }`.
|
|
475
476
|
|
|
477
|
+
`account set --claude-code on|off` sets whether an API key account may serve Claude Code
|
|
478
|
+
(`authswitch.authority.claudecode { accountId, expectedRevision, claudeCode }`, `IAuthSwitchAccount.claudeCode`,
|
|
479
|
+
AGL-1146): `off` keeps AGL's inference proxy from placing a Claude Code request on the key, while every other client
|
|
480
|
+
still uses it. A sign-in always serves Claude Code (`invalid_input`); the value the key already has changes nothing.
|
|
481
|
+
|
|
476
482
|
`account set --spend-limit <dollars>` gives an API key account its monthly spend limit (`authswitch.authority.spendlimit
|
|
477
483
|
{ accountId, expectedRevision, spendLimitMicroUsd }`, `isAuthSwitchSpendLimitMicroUsd`: a whole number of cents from
|
|
478
484
|
$0.01 to $1,000,000, in micro-dollars); `--clear-spend-limit` removes it. A sign-in has none (`invalid_input`), and a key
|
|
@@ -1333,7 +1339,9 @@ handoff verifies the latest native source. Claude Code's own native credential f
|
|
|
1333
1339
|
setup-token grant is a separate grant under the same account.
|
|
1334
1340
|
|
|
1335
1341
|
An inactive Claude grant is refreshed by the daemon only after a durable pre-send marker; pending, native, and
|
|
1336
|
-
quarantined grants cannot enter that exchange.
|
|
1342
|
+
quarantined grants cannot enter that exchange. A marker no renewal of the running daemon holds is over with its outcome
|
|
1343
|
+
unknown, whether the renewal failed past it or a daemon died during it: the next start or 30-second scan moves the login
|
|
1344
|
+
to `needs_reauth` with `exchange_uncertain`, journals it, and never replays the exchange. The daemon renews a Claude grant, and moves one into a container home,
|
|
1337
1345
|
only with a verified import receipt: a migration ledger row that binds the exact source digest to one account and
|
|
1338
1346
|
grant. A Claude sign-in writes one for the login it imports (see "Adding a Claude account"); the host home an import
|
|
1339
1347
|
adopted before 38.0.0, and the logins imported from the retired `~/.authswitch` store until AGL 36, keep the receipt
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "agl",
|
|
3
|
-
"version": "42.1
|
|
3
|
+
"version": "42.2.1",
|
|
4
4
|
"controllerUpgradeManagementVersion": 2,
|
|
5
5
|
"controllerManagementProtocolVersion": 1,
|
|
6
6
|
"controllerGatewaySourcesVersion": 1,
|
|
@@ -35,10 +35,10 @@
|
|
|
35
35
|
"@lossless.org/objectstorage": "10.7.1",
|
|
36
36
|
"@modelcontextprotocol/sdk": "1.30.0",
|
|
37
37
|
"@modelprofile.com/catalog": "^1.1.0",
|
|
38
|
-
"@modelprofile.com/flexharness": "
|
|
39
|
-
"@modelprofile.com/flexharness-agent": "
|
|
40
|
-
"@modelprofile.com/flexharness-models": "
|
|
41
|
-
"@modelprofile.com/flexharness-providers": "
|
|
38
|
+
"@modelprofile.com/flexharness": "18.0.0",
|
|
39
|
+
"@modelprofile.com/flexharness-agent": "18.0.0",
|
|
40
|
+
"@modelprofile.com/flexharness-models": "18.0.0",
|
|
41
|
+
"@modelprofile.com/flexharness-providers": "18.0.0",
|
|
42
42
|
"@modelprofile.com/mcp-crossharness": "5.9.0",
|
|
43
43
|
"@modelprofile.com/mcp-system": "3.1.0",
|
|
44
44
|
"@opencode-ai/sdk": "1.18.15",
|
package/readme.md
CHANGED
|
@@ -94,7 +94,7 @@ Each run of a turn's tool calls, with the reasoning between them, folds into one
|
|
|
94
94
|
- A prebuilt `node-pty` platform package for Linux, macOS, or Windows on x64 or arm64.
|
|
95
95
|
- For FlexHarness, a usable local TPM2, access to its resource-manager device (normally through the `tss` group), and `/usr/bin/systemd-creds` with its TPM2 runtime libraries.
|
|
96
96
|
|
|
97
|
-
FlexHarness currently runs on Linux x64 with Node.js 24 or
|
|
97
|
+
FlexHarness currently runs on Linux x64 with Node.js 24, 25 or 26 and fails closed when its TPM requirements are unavailable. Other supported controller platforms still provide OpenCode and terminal functionality.
|
|
98
98
|
|
|
99
99
|
AGL includes an embedded NoSQLDB engine (`@lossless.org/nosqldb`), so a separate database server is optional. It also pins the official OpenCode SDK and platform binary packages to one tested version.
|
|
100
100
|
|
|
@@ -236,9 +236,19 @@ provider no longer accepts reads **Key rejected** and needs a new key: add one,
|
|
|
236
236
|
authswitch account add openai-api-key --label "Codex key" --spend-limit 50 # asks for the key, not echoed
|
|
237
237
|
authswitch account set <account-id> --spend-limit 80
|
|
238
238
|
authswitch account set <account-id> --clear-spend-limit
|
|
239
|
+
authswitch account set <account-id> --claude-code off # a key whose credit is not for Claude Code
|
|
239
240
|
authswitch account recheck <account-id> # lift a key's payment hold
|
|
240
241
|
```
|
|
241
242
|
|
|
243
|
+
A key serves Claude Code unless you keep it from it. **Keep from Claude Code** under **Clients** on the key's page
|
|
244
|
+
(`authswitch account set <account-id> --claude-code off`) is for a key whose credit its provider grants for API use
|
|
245
|
+
other than Claude Code. AGL's inference proxy then places no Claude Code request on the key: a Claude Code session on
|
|
246
|
+
it moves to another account at its next request, and with every sign-in at its limit Claude Code gets the usual 429
|
|
247
|
+
instead of the key. Every other client (Flex, OpenCode, a client of your own) still uses the key. A request counts as
|
|
248
|
+
Claude Code when it comes through the `claude` or `confined` client, or when its user agent names Claude Code
|
|
249
|
+
(`claude-cli/…`). `agl proxy status` marks such a key **not for Claude Code**, and its **Next new session: Claude** is
|
|
250
|
+
the account Claude Code's next session goes to. **Serve Claude Code** (`--claude-code on`) undoes it.
|
|
251
|
+
|
|
242
252
|
AGL's inference proxy relays requests on keys when no subscription can take them (see [Claude accounts first, then API
|
|
243
253
|
keys](#claude-accounts-first-then-api-keys) and [ChatGPT accounts first, then OpenAI API
|
|
244
254
|
keys](#chatgpt-accounts-first-then-openai-api-keys)), and Flex's Claude models run on the Anthropic keys alone. A key has no
|
|
@@ -287,8 +297,10 @@ month's first spend, when the limit changes and when the key reaches or leaves i
|
|
|
287
297
|
those the figure, and the 80% tone, are those of the last reading. `authswitch list` shows the same month in dollars.
|
|
288
298
|
|
|
289
299
|
A key its provider refuses for billing or spend is held with a payment problem that says why (see [Payment
|
|
290
|
-
problems](#payment-problems)): a billing error,
|
|
291
|
-
|
|
300
|
+
problems](#payment-problems)): a billing error, Anthropic's "credit balance is too low" refusal (HTTP 400) of a key
|
|
301
|
+
whose organization has no credit left, the provider's monthly spend cap (lifted at the start of the next
|
|
302
|
+
month), or a used-up credit or spend limit, its row's status **Spend cap reached** for the cap. After adding credit in
|
|
303
|
+
the Claude Console, re-check the key: AGL cannot see a key's credit balance. **Re-check** on its page
|
|
292
304
|
(`authswitch account recheck <account-id>`) lifts the hold at once, a spend cap's too, without asking the provider; if
|
|
293
305
|
the provider still refuses, the next request moves to another account before a byte reaches the client and the hold is
|
|
294
306
|
set again.
|
|
@@ -672,10 +684,17 @@ header receipt to 10 seconds and request receipt to 60 seconds.
|
|
|
672
684
|
A successful streaming Responses answer must end with `response.completed`, `response.failed` or
|
|
673
685
|
`response.incomplete`. An empty upstream HTTP 200 or a provider failure before any response body byte
|
|
674
686
|
reaches the client becomes a logged JSON HTTP 502, not an empty successful stream. A failure after output
|
|
675
|
-
starts is logged and ends with a
|
|
687
|
+
starts is logged and ends with a `response.failed` event that Codex and the AI SDK Flex runs on both read,
|
|
688
|
+
numbered after the last event the client received (`sequence_number`), never a fabricated completion or
|
|
676
689
|
a replay. Provider SSE `error` events are mapped to explicit failures; `context_length_exceeded` before
|
|
677
690
|
output returns HTTP 400 with that code. Valid provider terminal events and successful output remain unchanged.
|
|
678
691
|
|
|
692
|
+
A request the proxy refuses before it knows the client (a missing, unreadable or unknown credential, or a request
|
|
693
|
+
not addressed to the proxy's own host) is logged with the path it asked for, its user agent and, for a 401, what it
|
|
694
|
+
presented as its credential (`missing`, `malformed`, `unknown` or `other_listener`), never the credential itself. The
|
|
695
|
+
same refusal line is written at most once a minute; the next one says how many like it the minute held, so a client
|
|
696
|
+
that retries in a loop can be found without flooding the journal.
|
|
697
|
+
|
|
679
698
|
`UND_ERR_SOCKET` is not retried by the proxy, even before the first response body byte. Only the existing
|
|
680
699
|
one-time same-account credential renewal on HTTP 401 and pre-output account hand-over on HTTP 429 replay
|
|
681
700
|
requests. A client may retry a transient HTTP 502, but must not repeatedly resend an identical oversized
|
|
@@ -1207,7 +1226,7 @@ agl fleet worker reconfirm lane --ticket AGL-7 --reason "Revival fence; same ses
|
|
|
1207
1226
|
agl fleet worker adopt claude-lane --ticket AGL-7 --profile claude-lane --cwd /srv/repos/example-worktree --native-id SESSION_UUID --relaunch-file /tmp/relaunch.md --json
|
|
1208
1227
|
agl fleet worker adopt claude-lane --ticket AGL-7 --profile claude-lane --cwd /srv/repos/example-worktree --native-id COPY_UUID --rebind --reason "Lane continued as a copy outside AGL" --json
|
|
1209
1228
|
agl fleet worker steer lane --ticket AGL-7 --message-file /tmp/message.md --json
|
|
1210
|
-
agl fleet worker message 0f3c9a1e --
|
|
1229
|
+
agl fleet worker message 0f3c9a1e --message-file /tmp/message.md --json
|
|
1211
1230
|
agl fleet worker native-message 84965d6b --message-file /tmp/message.md --sender drv-agl --json
|
|
1212
1231
|
agl fleet worker report lane --ticket AGL-7 --json
|
|
1213
1232
|
agl fleet worker refresh lane --ticket AGL-7 --next-name lane2 --handoff-file /tmp/handoff.md --json
|
|
@@ -1270,7 +1289,9 @@ from the saved record. Codex workers are not re-bound and fail closed.
|
|
|
1270
1289
|
|
|
1271
1290
|
`message NAME|NATIVE_ID --message-file FILE` steers one worker addressed by its fleet name or by
|
|
1272
1291
|
the native session id it is bound to, or a unique prefix of that id of at least 8 characters; an
|
|
1273
|
-
unbound session must be adopted first.
|
|
1292
|
+
unbound session must be adopted first. It needs no `--ticket`: the worker is steered on its own
|
|
1293
|
+
ticket. A `--ticket` the worker is not on (the ticket the message is about, say) and a worker on
|
|
1294
|
+
no ticket are refused before anything is sent.
|
|
1274
1295
|
|
|
1275
1296
|
`steer --messages-file FILE` accepts a JSON array of `{name,text}` objects for multiple
|
|
1276
1297
|
recipients. File contents are delivered unchanged. Claude starts with `--bg`, obtains its
|
|
@@ -1293,9 +1314,10 @@ prompt, or use a trusted working directory. The preflight never grants trust; Cl
|
|
|
1293
1314
|
authoritative for linked-worktree and other trust checks. A start that exits non-zero without a
|
|
1294
1315
|
`backgrounded` line and whose inventory gained no session of that name and directory was
|
|
1295
1316
|
refused: the worker is `stopped` without a dispatch fence and can be archived. Any other
|
|
1296
|
-
failed start keeps the fence. Relays group recipients by their observed permission mode
|
|
1297
|
-
|
|
1298
|
-
|
|
1317
|
+
failed start keeps the fence. Relays group recipients by their observed permission mode (any
|
|
1318
|
+
mode Claude Code records: `acceptEdits`, `auto`, `bypassPermissions`, `default`, `dontAsk`, `plan`
|
|
1319
|
+
or `manual`), close stdin and pass one `--allowedTools=SendMessage,Read,ToolSearch` argument. A
|
|
1320
|
+
relay addresses each recipient by its session name from `agents --json --all`, which is how SendMessage
|
|
1299
1321
|
resolves a recipient; a name that another live session shares refuses before anything is sent.
|
|
1300
1322
|
Each exact native tool receipt must prove queued delivery (`success: true` with a `msg_id`);
|
|
1301
1323
|
held messages, permission changes, missing or unreachable recipients refuse. A send counts as
|
|
@@ -1336,7 +1358,8 @@ Claude can reap idle background processes while retaining their jobs and convers
|
|
|
1336
1358
|
Fleet uses `agents --json --all`: a live PID/status receives a relay, including when idle;
|
|
1337
1359
|
a retained `done` or `blocked` job without PID/status is reaped. Steering that worker, or one
|
|
1338
1360
|
`claude stop` stopped, runs `--bg --resume` with its full UUID and the message, retaining the
|
|
1339
|
-
native job's saved options. Fleet confirms the original identity
|
|
1361
|
+
native job's saved options. Fleet confirms the original identity, the short id on Claude's
|
|
1362
|
+
`backgrounded · <id>` line (` · <name>` follows only for a named job), and checks all output for copy
|
|
1340
1363
|
notices. Claude Code 2.1.282 hands a woken job to its process a moment after the command exits:
|
|
1341
1364
|
its inventory lists the job `working` without a PID, then with a PID before a status. Fleet
|
|
1342
1365
|
polls it (every 250 ms, up to 30 s) until the same job is live with PID and status, binds its
|
|
@@ -1349,6 +1372,11 @@ place) and the command's credential-redacted output. When the original session c
|
|
|
1349
1372
|
steer, `reconfirm` clears the fence (see below). Failed, recovering or removed jobs require inspection. Reports preserve the last
|
|
1350
1373
|
assistant text and expose `reaped`; watch emits `worker.reaped` once per observed dormant
|
|
1351
1374
|
period, including an initial dormant observation. This reports observed state, not a reap time.
|
|
1375
|
+
A report longer than 32 KiB of UTF-8 keeps its head (where a summary and the first rows stand),
|
|
1376
|
+
its last marker line (its `result:` line, at most 1 KiB) when neither the head nor the end holds
|
|
1377
|
+
it, and its last 4 KiB from a line start. A line `[… N bytes cut; the worker's transcript holds
|
|
1378
|
+
the whole report …]` stands for each part left out, and the report is marked `truncated`; the
|
|
1379
|
+
worker's own transcript keeps the whole message.
|
|
1352
1380
|
|
|
1353
1381
|
Codex attaches the published shared daemon with its existing identity checks. A live turn
|
|
1354
1382
|
uses its exact `turn/steer` identity. Subscribing to that existing thread preserves its native
|
|
@@ -1753,7 +1781,7 @@ question:` and the others the fleet reads as a report), each at most 1 KiB, then
|
|
|
1753
1781
|
in order, with `[… N lines …]` where lines were left out. A note then says where the whole text
|
|
1754
1782
|
is: a ticketed worker's report is the fleet comment of that report id on its ticket, and a
|
|
1755
1783
|
stalled ticket's notice or another's change is on its ticket, all read with `ticket_get`. A
|
|
1756
|
-
report longer than 32 KiB is kept by the fleet
|
|
1784
|
+
report longer than 32 KiB is kept by the fleet as its head, its result line and its end, which the note says. A batch waits 15
|
|
1757
1785
|
seconds for further events and is delivered at most once a minute. It waits while the driver runs a turn, including permission waits, using the current session state.
|
|
1758
1786
|
If a batch is still queued when further events arrive, they merge into that same message,
|
|
1759
1787
|
keeping its position and sender. The merged text is stored before the merge is acknowledged,
|
|
@@ -2873,7 +2901,7 @@ From then on, `start`, `stop`, `restart` and `upgrade` drive the unit for the AG
|
|
|
2873
2901
|
|
|
2874
2902
|
`agl status` shows `agl-controller.service` in place of `detached` for a controller the unit runs. `agl service status [--json]` reports the unit's state, its port and AGL home, and its unit and log files. `agl service uninstall` disables the unit, stops the controller it runs, waits for the unit to stop and removes exactly the definition AGL installed; it refuses while processes it started, such as jobs, still run in the unit's control group. Start AGL detached again with `agl start`.
|
|
2875
2903
|
|
|
2876
|
-
The unit carries `PATH` and `AGL_HOME`, and, when set, `AGL_DB_DIR`, `AGL_MONGO_DB`, `AGL_MONGO_URL`, `AGL_CODEX_EXECUTABLE`, `AGL_CLAUDE_EXECUTABLE`, `CODEX_HOME`, `CLAUDE_CONFIG_DIR`, `XDG_CONFIG_HOME`, `XDG_DATA_HOME`, `XDG_STATE_HOME`, `XDG_CACHE_HOME`, `NODE_EXTRA_CA_CERTS`, `SSL_CERT_FILE`, `SSL_CERT_DIR`, `TZ`, `HTTP_PROXY`, `HTTPS_PROXY` and `NO_PROXY`; nothing else from the installing shell reaches it. The unit file is readable by every local user, so it never holds a secret: `service install` refuses while `AGL_MONGO_URL`, `HTTP_PROXY` or `HTTPS_PROXY` carries credentials, and while `AGL_FORWARD_ENV` names variables the fixed set would drop. Such a controller keeps running detached.
|
|
2904
|
+
The unit carries `PATH` and `AGL_HOME`, and, when set, `AGL_DB_DIR`, `AGL_MONGO_DB`, `AGL_MONGO_URL`, `AGL_CODEX_EXECUTABLE`, `AGL_CLAUDE_EXECUTABLE`, `CODEX_HOME`, `CLAUDE_CONFIG_DIR`, `XDG_CONFIG_HOME`, `XDG_DATA_HOME`, `XDG_STATE_HOME`, `XDG_CACHE_HOME`, `NODE_EXTRA_CA_CERTS`, `SSL_CERT_FILE`, `SSL_CERT_DIR`, `TZ`, `HTTP_PROXY`, `HTTPS_PROXY` and `NO_PROXY`; nothing else from the installing shell reaches it. `PATH` is the installing shell's; when `service install` rewrites an installed unit, the unit's `PATH` keeps, after the shell's entries and in their old order, every directory of the installed unit's `PATH` the shell lacks that still exists, so installing from a shell without, say, `~/.bun/bin` does not take Bun away from the controller (an empty, relative or removed directory is dropped, and the command names the directories it kept). To take a directory out, `agl service uninstall` first. The unit file is readable by every local user, so it never holds a secret: `service install` refuses while `AGL_MONGO_URL`, `HTTP_PROXY` or `HTTPS_PROXY` carries credentials, and while `AGL_FORWARD_ENV` names variables the fixed set would drop. Such a controller keeps running detached.
|
|
2877
2905
|
|
|
2878
2906
|
The unit appends the controller's errors to the same `$AGL_HOME/logs/controller-<port>.log` a detached controller writes; standard output is discarded, as it is for a detached controller.
|
|
2879
2907
|
|
|
@@ -2937,6 +2965,8 @@ While stopped turns are ending, progress output and the private upgrade log list
|
|
|
2937
2965
|
|
|
2938
2966
|
An upgrade prepared by AGL 39.5.x or older paused its cohort with a control prompt instead. The release that ends this is installed by such an AGL, which still pauses; install it while the Driver is idle, or stop the controller first (`agl stop`, `agl upgrade`, `agl start`). The new controller reads that older transaction and continues its paused conversations with `--continue-sessions`.
|
|
2939
2967
|
|
|
2968
|
+
`agl upgrade` asks a running controller to launch the upgrade worker against a one-time grant. When the controller refuses before it takes the grant, as one still starting right after a restart does, or the request never reaches it, the command fails, the upgrade ends as failed and the next `agl upgrade` can start at once. Only a launch that failed after the controller took the grant keeps the upgrade open, since a worker the command cannot see may run.
|
|
2969
|
+
|
|
2940
2970
|
If a forward-only upgrade worker is lost after target startup or package commit begins, a later fixed AGL installation can adopt exactly one stalled transaction during an explicit `agl upgrade`. Adoption requires a free port, no live worker, controller, Flex child, temporary-password writer, or token-bound metadata, and a compatible installed version. It preserves the original preparation timeline and stopped cohort. Do not delete upgrade files, copy transactions between roots, downgrade the package, or bypass recovery with `agl start`.
|
|
2941
2971
|
|
|
2942
2972
|
Upgrade coordination lives under `$AGL_HOME/upgrade`. Private logs live under `$AGL_HOME/logs`.
|
|
@@ -2955,6 +2985,12 @@ A recovery of AGL 42 that would roll a stalled upgrade back to a release older t
|
|
|
2955
2985
|
|
|
2956
2986
|
The audit events of types 41.x does not know (`remote.*`, `device.*`) stay in the audit log and are pruned with the others.
|
|
2957
2987
|
|
|
2988
|
+
### Rolling back from a release that plans deploys
|
|
2989
|
+
|
|
2990
|
+
A later release that plans deploys (AGL-909) stores what 42.1.0 cannot read: release plans, maintenance windows and deploy plans on tickets, `affects` links, release links without a package, the Closed column, and the Configuration master's `fleet.deployTargets`. 42.1.0 and earlier refuse a ticket or a master that holds any of them, so roll such a release back to 42.1.1 or a later 42.1.x. 42.1.1 reads all of it and acts on none of it: it probes no deploy target, plans and asks nothing, and moves no ticket to Closed.
|
|
2991
|
+
|
|
2992
|
+
While the master holds `fleet.deployTargets`, 42.1.1 refuses every save of the master, from the CLI or the browser, and the refusal names `fleet.deployTargets`. It reads them, but saving them is left to the release that acts on them. To change the master after the rollback, save it without `fleet.deployTargets`; that removes the targets until you configure them again on the later release. Or remove them on the later release before rolling back.
|
|
2993
|
+
|
|
2958
2994
|
### Migrating From `hcon`
|
|
2959
2995
|
|
|
2960
2996
|
Starting from `@modelprofile.com/harness-controller@20.0.2`, run the active command twice:
|