instar 1.3.579 → 1.3.581

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.
@@ -1 +1 @@
1
- {"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../../src/commands/server.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAkCH,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAS3D,OAAO,EAAE,eAAe,EAAiC,MAAM,iCAAiC,CAAC;AAuBjG,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAGvD,OAAO,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAkH7D,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAsBtD;;;;;;;;;;;;;;;;;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;AAg4CD,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,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E,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,CA8eN;AA2lBD,wBAAsB,WAAW,CAAC,OAAO,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC,CA0zctE;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"}
@@ -8996,7 +8996,7 @@ export async function startServer(options) {
8996
8996
  // off (always, while dark) every gate read returns the enrollment-home fallback, so every
8997
8997
  // consumer is byte-for-byte today's behavior. A never-seeded ledger is the same fallback (back-
8998
8998
  // compat); only UNKNOWN mode (corrupt on-disk) raises a HIGH attention item, never throws.
8999
- const { CredentialLocationLedger } = await import('../core/CredentialLocationLedger.js');
8999
+ const { CredentialLocationLedger, shouldBootSeedCredentialLedger } = await import('../core/CredentialLocationLedger.js');
9000
9000
  const { CredentialIdentityOracle } = await import('../core/CredentialIdentityOracle.js');
9001
9001
  const { CredentialLocationGate } = await import('../core/CredentialLocationGate.js');
9002
9002
  const credentialGateEmitAttention = telegram
@@ -9185,6 +9185,26 @@ export async function startServer(options) {
9185
9185
  }
9186
9186
  },
9187
9187
  };
9188
+ // B3a — boot-seed the credential location ledger. This is the MISSING runtime trigger for
9189
+ // seedFromOracle: without it the ledger stays NEVER-SEEDED forever, so getAssignments() returns
9190
+ // [] and the rebalancer (B3b) only ever sees the default slot — it can decide but never actuate
9191
+ // a use-it-or-lose-it drain (it has no other slots to move between). Gated on the SAME dev-gate
9192
+ // as the rest of re-pointing (strict no-op / no probe on the fleet) and ONLY when the ledger is
9193
+ // not already seeded — isSeeded() is false for both never-seeded AND UNKNOWN (corrupt) mode, so
9194
+ // this also doubles as the named recovery path, and it's idempotent across restarts (a seeded
9195
+ // ledger is skipped). Fire-and-forget: the oracle probes are per-slot network calls, so boot is
9196
+ // never blocked on them; failures are loud at the slot level (quarantine + attention) INSIDE
9197
+ // seedFromOracle. Seeding writes ONLY the local slot→account map — it moves ZERO credentials
9198
+ // (the executor's dryRun gate + the one-home invariant still guard every real swap). <!-- tracked: 20905 -->
9199
+ if (shouldBootSeedCredentialLedger(resolveDevAgentGate(config.subscriptionPool?.credentialRepointing?.enabled, config), credentialLocationLedger.isSeeded())) {
9200
+ void credentialLocationLedger
9201
+ .seedFromOracle()
9202
+ .then((outcomes) => {
9203
+ const assigned = outcomes.filter((o) => o.result === 'assigned').length;
9204
+ console.log(pc.green(` Credential location ledger seeded: ${assigned}/${outcomes.length} slot(s) mapped`));
9205
+ })
9206
+ .catch((e) => console.warn(`[CredentialLedger] boot seed failed: ${e instanceof Error ? e.message : String(e)}`));
9207
+ }
9188
9208
  // B3b — the periodic balancer pass. tick() is a strict no-op while the feature resolves dark
9189
9209
  // (so the timer can always run; the gate lives INSIDE tick()), and on a dev agent it runs the
9190
9210
  // full decision loop in dry-run (zero writes). REENTRANCY-GUARDED: a slow tick never overlaps