instar 1.3.748 → 1.3.749
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/commands/server.d.ts.map +1 -1
- package/dist/commands/server.js +136 -2
- package/dist/commands/server.js.map +1 -1
- package/dist/core/HttpLeaseTransport.d.ts +22 -0
- package/dist/core/HttpLeaseTransport.d.ts.map +1 -1
- package/dist/core/HttpLeaseTransport.js +37 -3
- package/dist/core/HttpLeaseTransport.js.map +1 -1
- package/dist/core/LeaseCoordinator.d.ts +22 -0
- package/dist/core/LeaseCoordinator.d.ts.map +1 -1
- package/dist/core/LeaseCoordinator.js +11 -0
- package/dist/core/LeaseCoordinator.js.map +1 -1
- package/dist/core/MachinePoolRegistry.d.ts +11 -0
- package/dist/core/MachinePoolRegistry.d.ts.map +1 -1
- package/dist/core/MachinePoolRegistry.js +29 -1
- package/dist/core/MachinePoolRegistry.js.map +1 -1
- package/dist/core/PeerPresencePuller.d.ts +26 -1
- package/dist/core/PeerPresencePuller.d.ts.map +1 -1
- package/dist/core/PeerPresencePuller.js +15 -1
- package/dist/core/PeerPresencePuller.js.map +1 -1
- package/dist/core/PostUpdateMigrator.d.ts.map +1 -1
- package/dist/core/PostUpdateMigrator.js +16 -0
- package/dist/core/PostUpdateMigrator.js.map +1 -1
- package/dist/core/devGatedFeatures.d.ts.map +1 -1
- package/dist/core/devGatedFeatures.js +6 -0
- package/dist/core/devGatedFeatures.js.map +1 -1
- package/dist/core/machineCoherenceAdvert.d.ts +108 -0
- package/dist/core/machineCoherenceAdvert.d.ts.map +1 -0
- package/dist/core/machineCoherenceAdvert.js +160 -0
- package/dist/core/machineCoherenceAdvert.js.map +1 -0
- package/dist/core/machineCoherenceManifest.d.ts +133 -0
- package/dist/core/machineCoherenceManifest.d.ts.map +1 -0
- package/dist/core/machineCoherenceManifest.js +293 -0
- package/dist/core/machineCoherenceManifest.js.map +1 -0
- package/dist/core/types.d.ts +21 -0
- package/dist/core/types.d.ts.map +1 -1
- package/dist/core/types.js.map +1 -1
- package/dist/monitoring/MachineCoherenceSentinel.d.ts +240 -0
- package/dist/monitoring/MachineCoherenceSentinel.d.ts.map +1 -0
- package/dist/monitoring/MachineCoherenceSentinel.js +336 -0
- package/dist/monitoring/MachineCoherenceSentinel.js.map +1 -0
- package/dist/monitoring/guardManifest.d.ts.map +1 -1
- package/dist/monitoring/guardManifest.js +25 -0
- package/dist/monitoring/guardManifest.js.map +1 -1
- package/dist/monitoring/machineCoherenceEpisode.d.ts +152 -0
- package/dist/monitoring/machineCoherenceEpisode.d.ts.map +1 -0
- package/dist/monitoring/machineCoherenceEpisode.js +92 -0
- package/dist/monitoring/machineCoherenceEpisode.js.map +1 -0
- package/dist/monitoring/machineCoherenceEpisodeManager.d.ts +210 -0
- package/dist/monitoring/machineCoherenceEpisodeManager.d.ts.map +1 -0
- package/dist/monitoring/machineCoherenceEpisodeManager.js +724 -0
- package/dist/monitoring/machineCoherenceEpisodeManager.js.map +1 -0
- package/dist/monitoring/machineCoherenceEvaluate.d.ts +129 -0
- package/dist/monitoring/machineCoherenceEvaluate.d.ts.map +1 -0
- package/dist/monitoring/machineCoherenceEvaluate.js +183 -0
- package/dist/monitoring/machineCoherenceEvaluate.js.map +1 -0
- package/dist/scaffold/templates.d.ts.map +1 -1
- package/dist/scaffold/templates.js +6 -0
- package/dist/scaffold/templates.js.map +1 -1
- package/dist/server/AgentServer.d.ts +1 -0
- package/dist/server/AgentServer.d.ts.map +1 -1
- package/dist/server/AgentServer.js +1 -0
- package/dist/server/AgentServer.js.map +1 -1
- package/dist/server/routes.d.ts +1 -0
- package/dist/server/routes.d.ts.map +1 -1
- package/dist/server/routes.js +12 -0
- package/dist/server/routes.js.map +1 -1
- package/package.json +1 -1
- package/src/data/builtin-manifest.json +64 -64
- package/src/scaffold/templates.ts +6 -0
- package/upgrades/1.3.749.md +35 -0
- package/upgrades/side-effects/machine-coherence-guard.md +229 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../../src/commands/server.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAiDH,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAU3D,OAAO,EAAE,eAAe,EAAiC,MAAM,iCAAiC,CAAC;AAyBjG,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAGvD,OAAO,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;
|
|
1
|
+
{"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../../src/commands/server.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAiDH,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAU3D,OAAO,EAAE,eAAe,EAAiC,MAAM,iCAAiC,CAAC;AAyBjG,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAGvD,OAAO,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AA8H7D,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAgFtD;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,yBAAyB,CACvC,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE,MAAM,EACf,gBAAgB,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,GAC1C,OAAO,CAUT;AAyID,UAAU,YAAY;IACpB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb;2DACuD;IACvD,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AA2/CD,wBAAgB,mBAAmB,CACjC,QAAQ,EAAE,eAAe,EACzB,cAAc,EAAE,cAAc,EAC9B,YAAY,CAAC,EAAE,YAAY,EAC3B,WAAW,CAAC,EAAE,WAAW,EACzB,WAAW,CAAC,EAAE,WAAW,EACzB,iBAAiB,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC,OAAO,CAAC,EAGvE,UAAU,CAAC,EAAE,MAAM,OAAO,8BAA8B,EAAE,WAAW,GAAG,IAAI,EAK5E,qBAAqB,CAAC,EAAE,MAAM,OAAO,gCAAgC,EAAE,kBAAkB,GAAG,IAAI,EAKhG,mBAAmB,CAAC,EAAE,MAAM,MAAM,GAAG,IAAI,GAAG,SAAS,GACpD,IAAI,CAijBN;AA2lBD,wBAAsB,WAAW,CAAC,OAAO,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC,CA6rlBtE;AAED,wBAAsB,UAAU,CAAC,OAAO,EAAE;IAAE,GAAG,CAAC,EAAE,MAAM,CAAA;CAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAsDzE;AAED;;;;;;;;;;;GAWG;AACH,wBAAsB,aAAa,CAAC,OAAO,EAAE;IAAE,GAAG,CAAC,EAAE,MAAM,CAAA;CAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAuD5E"}
|
package/dist/commands/server.js
CHANGED
|
@@ -163,6 +163,7 @@ import { CoverageAuditor } from '../knowledge/CoverageAuditor.js';
|
|
|
163
163
|
import { LiveConfig } from '../config/LiveConfig.js';
|
|
164
164
|
import { CoherenceMonitor } from '../monitoring/CoherenceMonitor.js';
|
|
165
165
|
import { ProcessIntegrity } from '../core/ProcessIntegrity.js';
|
|
166
|
+
import { buildCoherenceAdvert } from '../core/machineCoherenceAdvert.js';
|
|
166
167
|
import { StaleProcessGuard } from '../core/StaleProcessGuard.js';
|
|
167
168
|
import { cleanupGlobalInstalls } from '../core/GlobalInstallCleanup.js';
|
|
168
169
|
import { ForegroundRestartWatcher } from '../core/ForegroundRestartWatcher.js';
|
|
@@ -472,6 +473,10 @@ let _sessionPoolStage = () => 'dark';
|
|
|
472
473
|
// The custody engine (null = feature dark / gate failed / invariants violated —
|
|
473
474
|
// every consumer treats null as "refused → today's fall-through").
|
|
474
475
|
let _inboundQueue = null;
|
|
476
|
+
// Module-level handle for the machine-coherence guard (machine-coherence-guard
|
|
477
|
+
// §6) so `GET /pool/machine-coherence` can read the sentinel constructed deep in
|
|
478
|
+
// the mesh peer-presence wiring. Null when the guard is dark (route 503s).
|
|
479
|
+
let _machineCoherenceSentinel = null;
|
|
475
480
|
// The store the unconditional boot sweep opened when the queue will run this
|
|
476
481
|
// boot — adopted by the engine construction (one open handle, single-writer).
|
|
477
482
|
let _sweptInboundStore = null;
|
|
@@ -16662,7 +16667,12 @@ export async function startServer(options) {
|
|
|
16662
16667
|
}
|
|
16663
16668
|
if (poolSelfId) {
|
|
16664
16669
|
try {
|
|
16665
|
-
|
|
16670
|
+
// §5a (machine-coherence-guard): stamp the RUNNING version into
|
|
16671
|
+
// hardware self-attest so peers can see it (activates the already-
|
|
16672
|
+
// written consumer at routes.ts:6645/6671). When ProcessIntegrity is
|
|
16673
|
+
// unavailable the argument is OMITTED so the field stays honestly
|
|
16674
|
+
// absent (L1) — never a possibly-stale config.version.
|
|
16675
|
+
poolIdMgr.recordSelfHardware(poolSelfId, poolMod.captureHardware(ProcessIntegrity.getInstance()?.runningVersion));
|
|
16666
16676
|
}
|
|
16667
16677
|
catch { /* best-effort hardware self-attest */ }
|
|
16668
16678
|
// Quota-aware placement (2026-06-05): self-report whether a NEW
|
|
@@ -16758,6 +16768,11 @@ export async function startServer(options) {
|
|
|
16758
16768
|
return undefined;
|
|
16759
16769
|
}
|
|
16760
16770
|
};
|
|
16771
|
+
// Machine-coherence advert beat counter (machine-coherence-guard §3.2
|
|
16772
|
+
// M5): sender-side monotonic advert generation. FORENSIC-ONLY —
|
|
16773
|
+
// resets on restart; receivers NEVER use it as a freshness check
|
|
16774
|
+
// (freshness is the receiver-stamped advert receipt time; R2-L1).
|
|
16775
|
+
let _coherenceBeatSeq = 0;
|
|
16761
16776
|
const refreshPool = () => {
|
|
16762
16777
|
try {
|
|
16763
16778
|
machinePoolRegistry.recordHeartbeat({
|
|
@@ -16785,6 +16800,27 @@ export async function startServer(options) {
|
|
|
16785
16800
|
// fixed-size summary, never an inventory. Reported live each
|
|
16786
16801
|
// heartbeat so a queue going dark withdraws the capability.
|
|
16787
16802
|
seamlessnessFlags: { ws11DeliverReceive: !!_inboundQueue, ws12DrainReceive: !!_drainRunner, ws44PoolLinks: !!_poolLink, ws44PoolCache: !!_poolPollCache, ws43JournalLease: resolveDevAgentGate(config.multiMachine?.seamlessness?.ws43JournalLease, config) && (config.multiMachine?.seamlessness?.ws43JournalLeaseDryRun ?? !resolveDevAgentGate(undefined, config)) !== true, stateSyncReceive: selfStateSyncReceive() },
|
|
16803
|
+
// Machine-coherence advert (machine-coherence-guard §3.2).
|
|
16804
|
+
// Emission is UNCONDITIONAL (M3, normative): it ships live with
|
|
16805
|
+
// the code, regardless of the sentinel's dev-gate/enabled/dryRun
|
|
16806
|
+
// — only the evaluator + alarm are dev-gated (§7). A gated
|
|
16807
|
+
// advert would make the guard misdiagnose the exact F4 topology
|
|
16808
|
+
// (dark side advert-less → false "peer predates the guard").
|
|
16809
|
+
// Recomputed each beat: boot-read entries re-advertise within
|
|
16810
|
+
// one beat of a restart; live-read entries (readSource:'live',
|
|
16811
|
+
// M8) within one beat of the PATCH /config. Alarm marker is the
|
|
16812
|
+
// episode machinery's to attach (increment C) — absent until an
|
|
16813
|
+
// open, successfully-raised local item exists.
|
|
16814
|
+
...(() => {
|
|
16815
|
+
try {
|
|
16816
|
+
return {
|
|
16817
|
+
coherenceAdvert: buildCoherenceAdvert({ boot: config, liveGet: (path, fallback) => liveConfig.get(path, fallback) }, { instarVersion: ProcessIntegrity.getInstance()?.runningVersion ?? 'unknown', beatSeq: _coherenceBeatSeq++ }),
|
|
16818
|
+
};
|
|
16819
|
+
}
|
|
16820
|
+
catch {
|
|
16821
|
+
return {};
|
|
16822
|
+
} // @silent-fallback-ok: a builder fault must never kill the liveness beat; self degrades to advert-less (loud via version-class after grace), never a dead heartbeat
|
|
16823
|
+
})(),
|
|
16788
16824
|
// Durable Inbound Message Queue §5.1: depth + oldest + tenure +
|
|
16789
16825
|
// bounded top-K — the survivor's loss-SUSPECTED item, capped
|
|
16790
16826
|
// re-placement arm, and supersede-dedupe key all read these.
|
|
@@ -19892,6 +19928,93 @@ export async function startServer(options) {
|
|
|
19892
19928
|
},
|
|
19893
19929
|
});
|
|
19894
19930
|
void peerPresencePuller.pullOnce();
|
|
19931
|
+
// ── Machine-Coherence Guard (machine-coherence-guard §3.3/§3.4/§6/§7,
|
|
19932
|
+
// roadmap 4.1 F4/P0-1) — PURE SIGNAL, rides THIS 30s peerPresenceTick ──
|
|
19933
|
+
// Compares version/resolved-flag/protocol/manifest across the agent's OWN
|
|
19934
|
+
// ONLINE machines (the F4 skew class) and — Session B — will raise ONE
|
|
19935
|
+
// episode-scoped attention item from exactly ONE elected machine. Dev-gate
|
|
19936
|
+
// dark on the fleet (`enabled` OMITTED → resolveMachineCoherenceConfig), dry-
|
|
19937
|
+
// run FIRST even on dev. Constructed ONLY when the gate resolves enabled — a
|
|
19938
|
+
// dark guard is never constructed (route 503s, no tick); single-machine is a
|
|
19939
|
+
// strict no-op inside tick(). MUTATES NOTHING. Own try/catch: a wiring
|
|
19940
|
+
// failure is logged non-fatal and the server runs without the evaluator.
|
|
19941
|
+
let machineCoherenceSentinel = null;
|
|
19942
|
+
try {
|
|
19943
|
+
const mcMod = await import('../monitoring/MachineCoherenceSentinel.js');
|
|
19944
|
+
const mcCfg = mcMod.resolveMachineCoherenceConfig(config);
|
|
19945
|
+
if (mcCfg.enabled) {
|
|
19946
|
+
machineCoherenceSentinel = new mcMod.MachineCoherenceSentinel({
|
|
19947
|
+
listCapacities: () => machinePoolRegistry?.getCapacities() ?? [],
|
|
19948
|
+
selfMachineId: () => meshSelfId ?? null,
|
|
19949
|
+
// Election lease view: the holder id when a lease coordinator is
|
|
19950
|
+
// attached; null otherwise (a git-only mesh has no live holder for
|
|
19951
|
+
// election — electRaiser then falls to the lowest machineId).
|
|
19952
|
+
leaseHolderMachineId: () => (leaseCoordinatorRef ? leaseCoordinatorRef.currentHolder() : null),
|
|
19953
|
+
now: () => Date.now(),
|
|
19954
|
+
// §4 episode machinery: the per-agent state root + the nickname
|
|
19955
|
+
// resolver (registry display label). With these the sentinel
|
|
19956
|
+
// owns a durable EpisodeManager and emits raise/append/resolve
|
|
19957
|
+
// effects the peerPresenceTick drains + executes below.
|
|
19958
|
+
stateDir: () => config.stateDir ?? null,
|
|
19959
|
+
nicknameOf: (m) => machinePoolRegistry?.getCapacities().find((c) => c.machineId === m)?.nickname ?? m,
|
|
19960
|
+
}, mcCfg);
|
|
19961
|
+
// expectRuntime:true on the GUARD_MANIFEST entry — register the
|
|
19962
|
+
// synchronous runtime getter so /guards grades the guard's posture.
|
|
19963
|
+
guardRegistry.register('monitoring.machineCoherence.enabled', () => machineCoherenceSentinel.guardStatus());
|
|
19964
|
+
_machineCoherenceSentinel = machineCoherenceSentinel; // expose to GET /pool/machine-coherence
|
|
19965
|
+
try {
|
|
19966
|
+
const mfMod = await import('../core/machineCoherenceManifest.js');
|
|
19967
|
+
console.log(pc.dim(` MachineCoherenceGuard: enabled dryRun=${mcCfg.dryRun} ` +
|
|
19968
|
+
`manifestHash=${mfMod.selfManifestHash().slice(0, 12)} flags=${mfMod.COHERENCE_CRITICAL_FLAGS.length} ` +
|
|
19969
|
+
`(pool-skew evaluator — pure signal)`));
|
|
19970
|
+
}
|
|
19971
|
+
catch { /* boot log line only — never fatal */ }
|
|
19972
|
+
}
|
|
19973
|
+
}
|
|
19974
|
+
catch (e) {
|
|
19975
|
+
// @silent-fallback-ok — optional dev-gated, pure-signal feature: a wiring
|
|
19976
|
+
// failure is logged (console.error, NOT silent) and is non-fatal BY DESIGN
|
|
19977
|
+
// — the monitoring sentinel must never crash server boot.
|
|
19978
|
+
console.error(' MachineCoherenceGuard wiring failed (non-fatal):', e instanceof Error ? e.message : String(e));
|
|
19979
|
+
}
|
|
19980
|
+
// Drain + execute the machine-coherence episode effects (§4) the last
|
|
19981
|
+
// reconcile produced (raise/append/resolve). Async + best-effort — a
|
|
19982
|
+
// Telegram fault never crashes the shared presence tick (fail toward
|
|
19983
|
+
// silence). Defined OUTSIDE the tick body so the tick stays lean; the
|
|
19984
|
+
// sentinel already gates effects to raiser && live posture.
|
|
19985
|
+
const executeMachineCoherenceEffects = (sentinel, tg) => {
|
|
19986
|
+
let effects;
|
|
19987
|
+
try {
|
|
19988
|
+
effects = sentinel.drainPendingEffects();
|
|
19989
|
+
}
|
|
19990
|
+
catch {
|
|
19991
|
+
return;
|
|
19992
|
+
}
|
|
19993
|
+
for (const eff of effects) {
|
|
19994
|
+
void (async () => {
|
|
19995
|
+
try {
|
|
19996
|
+
if (eff.kind === 'raise') {
|
|
19997
|
+
await tg?.createAttentionItem({
|
|
19998
|
+
id: eff.itemId, title: eff.title, summary: eff.summary, description: eff.description,
|
|
19999
|
+
category: 'machine-coherence', priority: 'HIGH', sourceContext: 'machine-coherence-guard',
|
|
20000
|
+
});
|
|
20001
|
+
}
|
|
20002
|
+
else if (eff.kind === 'append') {
|
|
20003
|
+
const item = tg?.getAttentionItem(eff.itemId);
|
|
20004
|
+
if (item?.topicId !== undefined)
|
|
20005
|
+
await tg?.sendToTopic(item.topicId, eff.text);
|
|
20006
|
+
}
|
|
20007
|
+
else if (eff.kind === 'resolve') {
|
|
20008
|
+
const item = tg?.getAttentionItem(eff.itemId);
|
|
20009
|
+
if (item?.topicId !== undefined)
|
|
20010
|
+
await tg?.sendToTopic(item.topicId, eff.note);
|
|
20011
|
+
await tg?.updateAttentionStatus(eff.itemId, 'DONE');
|
|
20012
|
+
}
|
|
20013
|
+
}
|
|
20014
|
+
catch { /* @silent-fallback-ok: episode effect execution is best-effort; a Telegram send/create fault must never crash the presence tick — the next reconcile re-derives from durable episode state */ }
|
|
20015
|
+
})();
|
|
20016
|
+
}
|
|
20017
|
+
};
|
|
19895
20018
|
const peerPresenceTick = () => {
|
|
19896
20019
|
void peerPresencePuller.pullOnce();
|
|
19897
20020
|
// mesh-coherence-live-state-honesty (Fix (b)): the periodic, signal-only live-vs-config
|
|
@@ -19951,6 +20074,17 @@ export async function startServer(options) {
|
|
|
19951
20074
|
}
|
|
19952
20075
|
}
|
|
19953
20076
|
}
|
|
20077
|
+
// Machine-Coherence Guard rider (§3.3): evaluator tick + drain/execute
|
|
20078
|
+
// §4 effects, both fail toward silence (helper defined above). Placed
|
|
20079
|
+
// AFTER the mesh recheck so it never grows the mesh block's source-
|
|
20080
|
+
// assertion window (mesh-coherence-wiring.test.ts slices a fixed span).
|
|
20081
|
+
if (machineCoherenceSentinel) {
|
|
20082
|
+
try {
|
|
20083
|
+
machineCoherenceSentinel.tick();
|
|
20084
|
+
}
|
|
20085
|
+
catch { /* @silent-fallback-ok: §3.3 the evaluator tick fails toward silence by design — a sentinel fault must never crash the shared 30s presence tick; the next reconcile re-derives from durable episode state */ }
|
|
20086
|
+
executeMachineCoherenceEffects(machineCoherenceSentinel, telegram);
|
|
20087
|
+
}
|
|
19954
20088
|
};
|
|
19955
20089
|
const peerPresenceTimer = setInterval(peerPresenceTick, 30_000);
|
|
19956
20090
|
if (typeof peerPresenceTimer.unref === 'function')
|
|
@@ -20506,7 +20640,7 @@ export async function startServer(options) {
|
|
|
20506
20640
|
const server = new AgentServer({ config, sessionManager, state, scheduler, telegram, relationships, feedback, feedbackAnomalyDetector, dispatches, updateChecker, autoUpdater, autoDispatcher, quotaTracker, quotaManager, publisher, viewer, tunnel, evolution, watchdog, topicMemory, triageNurse, projectMapper, cartographer: cartographer ?? undefined, coherenceGate: scopeVerifier, contextHierarchy, canonicalState, operationGate, sentinel, adaptiveTrust, memoryMonitor, orphanReaper, coherenceMonitor, commitmentTracker, subscriptionPool, accountFollowMePeerViews: async () => { const nickById = new Map((_listPoolMachines?.() ?? []).map((m) => [m.machineId, m.nickname ?? m.machineId])); let peers = (_resolvePeerUrls?.() ?? []).map((p) => ({ machineId: p.machineId, nickname: nickById.get(p.machineId) ?? p.machineId, url: p.url })); if (peers.length === 0) {
|
|
20507
20641
|
peers = (_listPoolMachines?.() ?? []).filter((m) => m.machineId !== _meshSelfId && !!m.lastKnownUrl).map((m) => ({ machineId: m.machineId, nickname: m.nickname ?? m.machineId, url: m.lastKnownUrl }));
|
|
20508
20642
|
} if (peers.length === 0)
|
|
20509
|
-
return []; const { fetchPeerSubscriptionViews } = await import('../core/fetchPeerSubscriptionViews.js'); return fetchPeerSubscriptionViews({ peers: () => peers, fetchImpl: fetch, authToken: config.authToken ?? '' }); }, quotaPoller, quotaAwareScheduler: _quotaAwareScheduler ?? undefined, proactiveSwapMonitor: _proactiveSwapMonitor ?? undefined, inUseAccountResolver, enrollmentWizard, accountFollowMeRevocation, credentialRepointing, semanticMemory, activitySentinel, rateLimitSentinel, releaseReadinessSentinel: releaseReadinessSentinel ?? undefined, greenPrAutoMerger: greenPrAutoMerger ?? undefined, guardLatchStore: guardLatchStore ?? undefined, messageRouter, summarySentinel, spawnManager, systemReviewer, capabilityMapper, selfKnowledgeTree, coverageAuditor, topicResumeMap: _topicResumeMap ?? undefined, topicProfile: _topicProfileCtx ?? undefined, sessionRefresh: _sessionRefresh ?? undefined, autonomyManager, trustElevationTracker, autonomousEvolution, coordinator: coordinator.enabled ? coordinator : undefined, meshBindActive: coordinator.managers.identityManager.hasIdentity() && config.multiMachine?.meshTransport?.enabled !== false, localSigningKeyPem, leaseTransport, peerEndpointRecorder, getSelfMeshEndpoints, onLeasePullRequest: () => leaseCoordinatorRef?.currentLease() ?? null, liveTailReceiver, handoffWireTransport, onHandoffBegin, onHandoffInitiate: handoffInitiate, handoffInProgress: handoffSentinelInProgress, messageLedger, currentInboundByTopic, replyMarkerTransport, onReplyMarker: messageLedger ? (marker) => { const m = marker; messageLedger.applyRemoteReplyMarker(m.dedupeKey, { platform: m.platform, replyIdempotencyKey: m.replyIdempotencyKey, epoch: m.epoch, topic: m.topic ?? null }); } : undefined, whatsapp: whatsappAdapter, slack: slackAdapter, imessage: imessageAdapter, conversationRegistry, conversationBindAuth, conversationFollowThrough, whatsappBusinessBackend, messageBridge, hookEventReceiver, worktreeMonitor, subagentTracker, instructionsVerifier, handshakeManager: threadlineHandshake, threadlineRouter, conversationStore, threadLog, threadMessageRecorder, warrantsReplyGate, collaborationSurfacer, threadResumeMap, topicLinkageHandler: topicLinkageHandler ?? undefined, threadlineRelayClient, threadlineReplyWaiters, listenerManager: listenerManager ?? undefined, a2aDeliveryTracker: a2aDeliveryTracker ?? undefined, responseReviewGate, reviewCanaryBattery, messagingToneGate, outboundDedupGate, telemetryHeartbeat, pasteManager, featureRegistry, discoveryEvaluator, completionEvaluator, unifiedTrust, liveConfig, sharedStateLedger, ledgerSessionRegistry, worktreeManager, oidcEnrolledRepos: parallelDevConfig?.oidcEnrolledRepos, initiativeTracker, projectRoundRunner, projectDriftChecker, machineHeartbeat, machinePoolRegistry, ropeHealthMonitor, writeAdmission: writeAdmission ?? undefined, getInboundQueue: () => _inboundQueue, meshRpcDispatcher, workingSetPullCoordinator, commitmentReplicaStore, preferenceReplicaStore, replicatedRecordEmitter, conflictStore, rollbackUnmerge, droppedOriginRegistry, preferencesUnionReader, forwardCommitmentMutate, sessionOwnershipRegistry, topicPinStore: _topicPinStore ?? undefined, topicPinSkewQuarantine: _topicPinSkewQuarantine ?? undefined, topicPinFoldView: _topicPinFoldView ?? undefined, ownershipReconciler: _ownershipReconciler ?? undefined, staleOwnerEngine: _staleOwnerEngine ?? undefined, leaseHandback: _leaseHandbackCtx ?? undefined, streamTicketStore: _streamTicketStore ?? undefined, poolStreamAllowRemoteInput: config.dashboard?.poolStream?.allowRemoteInput ?? false, poolStreamConnector: _poolStreamConnector ?? undefined, secretSync: _secretSyncHandle ?? undefined, meshSelfId: _meshSelfId ?? undefined, resolveRouterUrl: _resolveRouterUrl ?? undefined, resolvePeerUrls: _resolvePeerUrls ?? undefined, guardRegistry, listPoolMachines: _listPoolMachines ?? undefined, deliverMandateToMachine: _deliverMandateToMachine ?? undefined, poolLink: _poolLink ?? undefined, poolPollCache: _poolPollCache ?? undefined, sessionPoolE2EResultStore, proxyCoordinator, topicIntentStore, topicIntentArcCheck, usherSignalStore, intelligence: sharedIntelligence ?? undefined, telegramBridgeConfig, telegramBridge: telegramBridge ?? undefined, threadlineObservability, briefDeps, workingMemory, taskFlowRegistry, threadlineFlowBridge, sessionReaper, agentWorktreeReaper, orphanedWorkSentinel, mcpProcessReaper, geminiLoopRunner, sleepController, agentActivityState, reapLog, resumeQueue, resumeDrainer, autonomousLivenessReconciler, enforcedTerminationStatus: () => enforcedTerminationWatchdog?.guardStatus() ?? null, prHandLease: prHandLease ?? undefined, operatorStopRecorder: recordOperatorStop, sleepWakeDetector, unjustifiedStopGate, stopGateDb, stopNotifier, liveTestGate, liveTestGateMode, liveTestRunnerCtx }); // Resolve the late-bound topic-operator getter (increment 2e): routing was
|
|
20643
|
+
return []; const { fetchPeerSubscriptionViews } = await import('../core/fetchPeerSubscriptionViews.js'); return fetchPeerSubscriptionViews({ peers: () => peers, fetchImpl: fetch, authToken: config.authToken ?? '' }); }, quotaPoller, quotaAwareScheduler: _quotaAwareScheduler ?? undefined, proactiveSwapMonitor: _proactiveSwapMonitor ?? undefined, inUseAccountResolver, enrollmentWizard, accountFollowMeRevocation, credentialRepointing, semanticMemory, activitySentinel, rateLimitSentinel, releaseReadinessSentinel: releaseReadinessSentinel ?? undefined, greenPrAutoMerger: greenPrAutoMerger ?? undefined, guardLatchStore: guardLatchStore ?? undefined, messageRouter, summarySentinel, spawnManager, systemReviewer, capabilityMapper, selfKnowledgeTree, coverageAuditor, topicResumeMap: _topicResumeMap ?? undefined, topicProfile: _topicProfileCtx ?? undefined, sessionRefresh: _sessionRefresh ?? undefined, autonomyManager, trustElevationTracker, autonomousEvolution, coordinator: coordinator.enabled ? coordinator : undefined, meshBindActive: coordinator.managers.identityManager.hasIdentity() && config.multiMachine?.meshTransport?.enabled !== false, localSigningKeyPem, leaseTransport, peerEndpointRecorder, getSelfMeshEndpoints, onLeasePullRequest: () => leaseCoordinatorRef?.currentLease() ?? null, liveTailReceiver, handoffWireTransport, onHandoffBegin, onHandoffInitiate: handoffInitiate, handoffInProgress: handoffSentinelInProgress, messageLedger, currentInboundByTopic, replyMarkerTransport, onReplyMarker: messageLedger ? (marker) => { const m = marker; messageLedger.applyRemoteReplyMarker(m.dedupeKey, { platform: m.platform, replyIdempotencyKey: m.replyIdempotencyKey, epoch: m.epoch, topic: m.topic ?? null }); } : undefined, whatsapp: whatsappAdapter, slack: slackAdapter, imessage: imessageAdapter, conversationRegistry, conversationBindAuth, conversationFollowThrough, whatsappBusinessBackend, messageBridge, hookEventReceiver, worktreeMonitor, subagentTracker, instructionsVerifier, handshakeManager: threadlineHandshake, threadlineRouter, conversationStore, threadLog, threadMessageRecorder, warrantsReplyGate, collaborationSurfacer, threadResumeMap, topicLinkageHandler: topicLinkageHandler ?? undefined, threadlineRelayClient, threadlineReplyWaiters, listenerManager: listenerManager ?? undefined, a2aDeliveryTracker: a2aDeliveryTracker ?? undefined, responseReviewGate, reviewCanaryBattery, messagingToneGate, outboundDedupGate, telemetryHeartbeat, pasteManager, featureRegistry, discoveryEvaluator, completionEvaluator, unifiedTrust, liveConfig, sharedStateLedger, ledgerSessionRegistry, worktreeManager, oidcEnrolledRepos: parallelDevConfig?.oidcEnrolledRepos, initiativeTracker, projectRoundRunner, projectDriftChecker, machineHeartbeat, machinePoolRegistry, ropeHealthMonitor, writeAdmission: writeAdmission ?? undefined, getInboundQueue: () => _inboundQueue, getMachineCoherence: () => _machineCoherenceSentinel, meshRpcDispatcher, workingSetPullCoordinator, commitmentReplicaStore, preferenceReplicaStore, replicatedRecordEmitter, conflictStore, rollbackUnmerge, droppedOriginRegistry, preferencesUnionReader, forwardCommitmentMutate, sessionOwnershipRegistry, topicPinStore: _topicPinStore ?? undefined, topicPinSkewQuarantine: _topicPinSkewQuarantine ?? undefined, topicPinFoldView: _topicPinFoldView ?? undefined, ownershipReconciler: _ownershipReconciler ?? undefined, staleOwnerEngine: _staleOwnerEngine ?? undefined, leaseHandback: _leaseHandbackCtx ?? undefined, streamTicketStore: _streamTicketStore ?? undefined, poolStreamAllowRemoteInput: config.dashboard?.poolStream?.allowRemoteInput ?? false, poolStreamConnector: _poolStreamConnector ?? undefined, secretSync: _secretSyncHandle ?? undefined, meshSelfId: _meshSelfId ?? undefined, resolveRouterUrl: _resolveRouterUrl ?? undefined, resolvePeerUrls: _resolvePeerUrls ?? undefined, guardRegistry, listPoolMachines: _listPoolMachines ?? undefined, deliverMandateToMachine: _deliverMandateToMachine ?? undefined, poolLink: _poolLink ?? undefined, poolPollCache: _poolPollCache ?? undefined, sessionPoolE2EResultStore, proxyCoordinator, topicIntentStore, topicIntentArcCheck, usherSignalStore, intelligence: sharedIntelligence ?? undefined, telegramBridgeConfig, telegramBridge: telegramBridge ?? undefined, threadlineObservability, briefDeps, workingMemory, taskFlowRegistry, threadlineFlowBridge, sessionReaper, agentWorktreeReaper, orphanedWorkSentinel, mcpProcessReaper, geminiLoopRunner, sleepController, agentActivityState, reapLog, resumeQueue, resumeDrainer, autonomousLivenessReconciler, enforcedTerminationStatus: () => enforcedTerminationWatchdog?.guardStatus() ?? null, prHandLease: prHandLease ?? undefined, operatorStopRecorder: recordOperatorStop, sleepWakeDetector, unjustifiedStopGate, stopGateDb, stopNotifier, liveTestGate, liveTestGateMode, liveTestRunnerCtx }); // Resolve the late-bound topic-operator getter (increment 2e): routing was
|
|
20510
20644
|
// wired before the server existed; from here on inbound binds use the
|
|
20511
20645
|
// server's own store instance.
|
|
20512
20646
|
_agentServerRef = server;
|