agl 43.3.1 → 43.4.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.
Files changed (85) hide show
  1. package/changelog.md +22 -0
  2. package/dist_serve/bundle.js +1377 -1375
  3. package/dist_serve/bundle.js.map +2 -2
  4. package/dist_ts/00_commitinfo_data.js +1 -1
  5. package/dist_ts/aglapi/interfaces.d.ts +5 -0
  6. package/dist_ts/aglapi/interfaces.js +2 -1
  7. package/dist_ts/classes.authstore.js +5 -2
  8. package/dist_ts/classes.claudeharness.js +4 -3
  9. package/dist_ts/classes.codexclientadapter.d.ts +5 -0
  10. package/dist_ts/classes.codexclientadapter.js +12 -6
  11. package/dist_ts/classes.controller.d.ts +33 -9
  12. package/dist_ts/classes.controller.js +173 -113
  13. package/dist_ts/classes.flexservice.d.ts +12 -1
  14. package/dist_ts/classes.flexservice.js +44 -13
  15. package/dist_ts/classes.flexstore.d.ts +20 -0
  16. package/dist_ts/classes.flexstore.js +30 -1
  17. package/dist_ts/classes.mcpclient.d.ts +2 -2
  18. package/dist_ts/classes.mcpclient.js +14 -9
  19. package/dist_ts/classes.mcptools.d.ts +1 -1
  20. package/dist_ts/classes.mcptools.js +2 -1
  21. package/dist_ts/classes.opencodeclient.js +20 -4
  22. package/dist_ts/driver/functions.driverinstructions.d.ts +1 -1
  23. package/dist_ts/driver/functions.driverinstructions.js +2 -1
  24. package/dist_ts/fleet/classes.deploymodels.d.ts +58 -1
  25. package/dist_ts/fleet/classes.deploymodels.js +121 -2
  26. package/dist_ts/fleet/classes.deploymonitor.d.ts +193 -47
  27. package/dist_ts/fleet/classes.deploymonitor.js +548 -180
  28. package/dist_ts/fleet/classes.gitfacts.d.ts +4 -1
  29. package/dist_ts/fleet/classes.gitfacts.js +13 -10
  30. package/dist_ts/fleet/classes.service.d.ts +2 -0
  31. package/dist_ts/fleet/classes.service.js +6 -3
  32. package/dist_ts/fleet/functions.deployprobes.js +21 -2
  33. package/dist_ts/fleet/functions.deploystatus.d.ts +26 -0
  34. package/dist_ts/fleet/functions.deploystatus.js +33 -0
  35. package/dist_ts/fleet/functions.deployvalidation.d.ts +1 -0
  36. package/dist_ts/fleet/functions.deployvalidation.js +5 -2
  37. package/dist_ts/functions.deploycli.js +3 -2
  38. package/dist_ts/functions.deviceapi.d.ts +7 -6
  39. package/dist_ts/functions.deviceapi.js +13 -5
  40. package/dist_ts/functions.mcpdeploytools.js +3 -1
  41. package/dist_ts/functions.promptreply.d.ts +13 -0
  42. package/dist_ts/functions.promptreply.js +17 -0
  43. package/dist_ts/interfaces.flexipc.d.ts +17 -9
  44. package/dist_ts/interfaces.flexipc.js +19 -20
  45. package/dist_ts_interfaces/deployments.d.ts +38 -6
  46. package/dist_ts_interfaces/deployments.js +7 -3
  47. package/dist_ts_interfaces/devices.d.ts +2 -1
  48. package/dist_ts_interfaces/devices.js +1 -1
  49. package/dist_ts_interfaces/inbox.d.ts +10 -1
  50. package/dist_ts_interfaces/inbox.js +1 -1
  51. package/dist_ts_interfaces/mcprequests.d.ts +1 -1
  52. package/package.json +5 -5
  53. package/readme.md +30 -12
  54. package/ts/00_commitinfo_data.ts +1 -1
  55. package/ts/aglapi/interfaces.ts +1 -0
  56. package/ts/classes.authstore.ts +4 -1
  57. package/ts/classes.claudeharness.ts +3 -2
  58. package/ts/classes.codexclientadapter.ts +11 -5
  59. package/ts/classes.controller.ts +188 -128
  60. package/ts/classes.flexservice.ts +57 -14
  61. package/ts/classes.flexstore.ts +40 -0
  62. package/ts/classes.mcpclient.ts +14 -5
  63. package/ts/classes.mcptools.ts +1 -0
  64. package/ts/classes.opencodeclient.ts +23 -3
  65. package/ts/driver/functions.driverinstructions.ts +1 -0
  66. package/ts/fleet/classes.deploymodels.ts +113 -1
  67. package/ts/fleet/classes.deploymonitor.ts +565 -179
  68. package/ts/fleet/classes.gitfacts.ts +10 -8
  69. package/ts/fleet/classes.service.ts +7 -1
  70. package/ts/fleet/functions.deployprobes.ts +16 -1
  71. package/ts/fleet/functions.deploystatus.ts +56 -0
  72. package/ts/fleet/functions.deployvalidation.ts +4 -1
  73. package/ts/functions.deploycli.ts +2 -1
  74. package/ts/functions.deviceapi.ts +19 -9
  75. package/ts/functions.mcpdeploytools.ts +2 -0
  76. package/ts/functions.promptreply.ts +20 -0
  77. package/ts/interfaces.flexipc.ts +43 -27
  78. package/ts_interfaces/deployments.ts +39 -6
  79. package/ts_interfaces/devices.schema.json +1 -1
  80. package/ts_interfaces/devices.ts +2 -1
  81. package/ts_interfaces/inbox.ts +8 -1
  82. package/ts_web/00_commitinfo_data.ts +1 -1
  83. package/ts_web/elements.deployments.ts +20 -4
  84. package/ts_web/elements.harnesscontrollerapp.ts +43 -13
  85. package/ts_web/elements.inbox.ts +3 -3
@@ -222,11 +222,18 @@ export declare class OpenCodeController {
222
222
  private readInboxSource;
223
223
  /** The session feed's row of a session, and the name the Inbox shows for it. */
224
224
  private inboxRow;
225
+ /** An Inbox item's id: its kind, the session that holds the request and the request's id. */
226
+ private inboxRequestItemId;
225
227
  /**
226
- * The items of a session's requests. A permission that the owner's auto-accept answers (`autoAcceptedArg`) waits for
227
- * nobody and is left out; questions and MCP forms are never answered automatically.
228
+ * The items of a session's permissions and questions. A permission that the owner's auto-accept answers
229
+ * (`autoAcceptedArg`) waits for nobody and is left out; questions are never answered automatically.
228
230
  */
229
231
  private inboxSessionItems;
232
+ /**
233
+ * The items of a session's MCP forms, which are never answered automatically. Only Claude Code and Codex hand AGL
234
+ * MCP forms, so a direct child (an OpenCode subagent) never holds one.
235
+ */
236
+ private inboxElicitationItems;
230
237
  /** A native session as the Inbox names it: where it runs and how the browser opens it. */
231
238
  private inboxNativeWhere;
232
239
  /** The requests Claude Code holds: its conversations' and those of AGL's turns in native sessions. */
@@ -1023,6 +1030,11 @@ export declare class OpenCodeController {
1023
1030
  private requireFlexRuntimeExitAuthority;
1024
1031
  private assertOpenCodeSessionIdentityGenerationCurrent;
1025
1032
  private assertFlexSessionIdentityGenerationCurrent;
1033
+ /**
1034
+ * A project's Flex session identities, in one answer the child reads from the project's metadata:
1035
+ * the snapshot is atomic and never waits for a load of the sessions' histories (AGL-1713). The
1036
+ * supervisor has proven the answer: bounded, strictly ordered and generation-bearing.
1037
+ */
1026
1038
  private readFlexSessionIdentitySnapshot;
1027
1039
  private captureFlexCleanupCohort;
1028
1040
  private reconcileOpenCodeSessionIdentities;
@@ -1311,7 +1323,10 @@ export declare class OpenCodeController {
1311
1323
  private listUnboundDrivers;
1312
1324
  /** AGL-210: the loop that finds stalled tickets and tells the driver, configured by `fleet.boardPump`. */
1313
1325
  private startBoardPump;
1314
- /** AGL-911: the loop that observes what each deploy target runs; status and history are computed from it when read. */
1326
+ /**
1327
+ * AGL-911: the loop that observes what each deploy target runs. It stores the deploy status it computes (AGL-1704),
1328
+ * which status and release state answer from; history and where a ticket runs are read when asked.
1329
+ */
1315
1330
  private requireDeployMonitor;
1316
1331
  /**
1317
1332
  * Once (migration v41_ticketlinkrepos, AGL-909): the links and release plans that name a discovered repository by its
@@ -1365,7 +1380,7 @@ export declare class OpenCodeController {
1365
1380
  private serveDriver;
1366
1381
  /** The driver topbar: the host's one driver session, its status, and the unread turns it marks seen. */
1367
1382
  private registerDriverHandlers;
1368
- /** The Deployments view: status, history, a probe now and release state (AGL-911, AGL-914). */
1383
+ /** The Deployments view: status, history, a probe now, release state and a full check now (AGL-911, AGL-914, AGL-1704). */
1369
1384
  private registerDeployHandlers;
1370
1385
  private registerSessionFeedHandlers;
1371
1386
  /** The metrics board's usage windows: a watch answers the window's buckets, and its changes follow as `usage.changed`. */
@@ -1400,6 +1415,8 @@ export declare class OpenCodeController {
1400
1415
  private replyNativeSessionForPrincipal;
1401
1416
  /** The requests of AGL's own turns in a native session that wait for an answer. */
1402
1417
  private nativeSessionAttention;
1418
+ /** The requests AGL's own Claude Code holds for a conversation; none once it no longer runs the conversation. */
1419
+ private claudeAttention;
1403
1420
  private replyNativeSessionRequest;
1404
1421
  /**
1405
1422
  * Native session failures are bounded messages; the session view and the fleet's receipt show them as they are. Each
@@ -1742,7 +1759,12 @@ export declare class OpenCodeController {
1742
1759
  /** An unavailable runtime cannot prove an archive. Its stored layout rows remain authoritative. */
1743
1760
  private layoutSessionRuntimeIsUnavailable;
1744
1761
  private findArchivedLayoutSessionIds;
1745
- private assertAttentionRequestOwned;
1762
+ /**
1763
+ * Refuses an answer to a permission or question the session does not hold (`promptNoLongerPending`), read from
1764
+ * OpenCode's pending requests before anything is sent; OpenCode refuses one answered in between itself (its client
1765
+ * throws `promptNoLongerPending`).
1766
+ */
1767
+ private assertPromptPending;
1746
1768
  private toFlexMessageBundle;
1747
1769
  private toFlexPermission;
1748
1770
  /** A project's key starts with its id; a projectless session's key starts with NUL, which no project id does. */
@@ -2122,10 +2144,12 @@ export declare class OpenCodeController {
2122
2144
  /**
2123
2145
  * The reversion requests that settle what a Flex session already recorded: a capture's inspection
2124
2146
  * and finalization, a pending undo or redo, a release. A project reconciling its session authority
2125
- * admits them. Its reconciliation loads the project's sessions in the child (`project.register`,
2126
- * `session.list`), and that load settles each session's pending capture and apply before it
2127
- * answers; a refused settlement fails the load and with it the reconciliation, which then never
2128
- * succeeds. The ending turn of a run closes its capture with the same requests. A new capture
2147
+ * admits them. The first full load of the project's sessions in the child (the child's recovery
2148
+ * load once it is ready, a held prompt's settlement or a managed creation's recovery during the
2149
+ * reconciliation, any session read; never `session.identities`) settles each session's pending
2150
+ * capture and apply before it answers; a refused settlement fails that load, and with it a
2151
+ * reconciliation waiting for it, which then never succeeds. The ending turn of a run closes its
2152
+ * capture with the same requests. A new capture
2129
2153
  * (`reversion.prepare`) is new work and stays refused while authority is uncertain.
2130
2154
  */
2131
2155
  private flexHostMethodSettlesRecordedReversion;