githolon 0.111.0 → 0.112.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.
package/dist/full-cli.mjs CHANGED
@@ -9279,7 +9279,7 @@ var init_recovery_desk_pb = __esm({
9279
9279
  // ../adapter/proto/nomos/runtime/v2/observability_desk_pb.js
9280
9280
  import { enumDesc as enumDesc15, fileDesc as fileDesc22, messageDesc as messageDesc22, tsEnum as tsEnum15 } from "@bufbuild/protobuf/codegenv2";
9281
9281
  import { file_google_protobuf_any as file_google_protobuf_any2 } from "@bufbuild/protobuf/wkt";
9282
- var file_nomos_runtime_v2_observability_desk, RuntimeFailureSchema, RuntimeUnavailableSchema, RuntimeRefusalSchema, DiagnosticAttributeSchema, RuntimeEventSchema, FollowsSummarySchema, FollowObservationSchema, CredentialRefreshRequestedSchema, RuntimeReadySchema, WatchChangedSchema, SyncCompletedSchema, LinkChangedSchema, RuntimeSpanSchema, RuntimeFailureKindSchema, RuntimeFailureKind, RuntimeUnavailableReasonSchema, RuntimeUnavailableReason, RuntimeRefusalReasonSchema, RuntimeRefusalReason, FollowObservationPhaseSchema, FollowObservationPhase, LinkStatusSchema, LinkStatus;
9282
+ var file_nomos_runtime_v2_observability_desk, RuntimeFailureSchema, RuntimeUnavailableSchema, RuntimeRefusalSchema, DiagnosticAttributeSchema, RuntimeEventSchema, FollowsSummarySchema, FollowObservationSchema, CredentialRefreshRequestedSchema, RuntimeReadySchema, WatchChangedSchema, SyncCompletedSchema, LinkChangedSchema, RuntimeSpanSchema, WritePreparationSchema, RuntimeFailureKindSchema, RuntimeFailureKind, RuntimeUnavailableReasonSchema, RuntimeUnavailableReason, RuntimeRefusalReasonSchema, RuntimeRefusalReason, FollowObservationPhaseSchema, FollowObservationPhase, LinkStatusSchema, LinkStatus;
9283
9283
  var init_observability_desk_pb = __esm({
9284
9284
  "../adapter/proto/nomos/runtime/v2/observability_desk_pb.js"() {
9285
9285
  "use strict";
@@ -9291,7 +9291,7 @@ var init_observability_desk_pb = __esm({
9291
9291
  init_model_adoption_desk_pb();
9292
9292
  init_receiving_group_desk_pb();
9293
9293
  init_recovery_desk_pb();
9294
- file_nomos_runtime_v2_observability_desk = /* @__PURE__ */ fileDesc22("Cilub21vcy9ydW50aW1lL3YyL29ic2VydmFiaWxpdHlfZGVzay5wcm90bxIQbm9tb3MucnVudGltZS52MiJCCgxUcmFjZUNvbnRleHQSEAoIdHJhY2VfaWQYASABKAwSDwoHc3Bhbl9pZBgCIAEoDBIPCgdzYW1wbGVkGAMgASgIIp0CCg5SdW50aW1lRmFpbHVyZRIMCgRjb2RlGAEgASgJEg8KB21lc3NhZ2UYAiABKAkSEQoJY29tcG9uZW50GAMgASgJEhYKCXdvcmtzcGFjZRgEIAEoCUgAiAEBEhMKBmRvbWFpbhgFIAEoCUgBiAEBEhYKCWRpcmVjdGl2ZRgGIAEoCUgCiAEBEjkKCmF0dHJpYnV0ZXMYByADKAsyJS5ub21vcy5ydW50aW1lLnYyLkRpYWdub3N0aWNBdHRyaWJ1dGUSMgoEa2luZBgIIAEoDjIkLm5vbW9zLnJ1bnRpbWUudjIuUnVudGltZUZhaWx1cmVLaW5kQgwKCl93b3Jrc3BhY2VCCQoHX2RvbWFpbkIMCgpfZGlyZWN0aXZlIr4BChJSdW50aW1lVW5hdmFpbGFibGUSOgoGcmVhc29uGAEgASgOMioubm9tb3MucnVudGltZS52Mi5SdW50aW1lVW5hdmFpbGFibGVSZWFzb24SEQoJd29ya3NwYWNlGAIgASgJEhEKCXJldHJ5YWJsZRgDIAEoCBIfChJyZXRyeV9hZnRlcl9taWxsaXMYBCABKA1IAIgBARIOCgZkZXRhaWwYBSABKAlCFQoTX3JldHJ5X2FmdGVyX21pbGxpcyJ+Cg5SdW50aW1lUmVmdXNhbBI2CgZyZWFzb24YASABKA4yJi5ub21vcy5ydW50aW1lLnYyLlJ1bnRpbWVSZWZ1c2FsUmVhc29uEhEKCXdvcmtzcGFjZRgCIAEoCRIRCglyZ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kZPTExPV19PQlNFUlZBVElPTl9QSEFTRV9MT0NBTF9DT1BZX1VOUkVBREFCTEUQCypXCgpMaW5rU3RhdHVzEhsKF0xJTktfU1RBVFVTX1VOU1BFQ0lGSUVEEAASFAoQTElOS19TVEFUVVNfT1BFThABEhYKEkxJTktfU1RBVFVTX0NMT1NFRBACKnYKDFRyYW5zZmVyS2luZBIdChlUUkFOU0ZFUl9LSU5EX1VOU1BFQ0lGSUVEEAASFwoTVFJBTlNGRVJfS0lORF9ERUxUQRABEhYKElRSQU5TRkVSX0tJTkRfRlVMTBACEhYKElRSQU5TRkVSX0tJTkRfUFVTSBADYgZwcm90bzM", [file_google_protobuf_any2, file_nomos_kernel_v1_progress, file_nomos_runtime_v2_correspondence_desk, file_nomos_runtime_v2_custody_desk, file_nomos_runtime_v2_placement_desk, file_nomos_runtime_v2_maintenance_desk, file_nomos_runtime_v2_model_adoption_desk, file_nomos_runtime_v2_receiving_group_desk, file_nomos_runtime_v2_recovery_desk]);
9294
+ file_nomos_runtime_v2_observability_desk = /* @__PURE__ */ fileDesc22("Cilub21vcy9ydW50aW1lL3YyL29ic2VydmFiaWxpdHlfZGVzay5wcm90bxIQbm9tb3MucnVudGltZS52MiJCCgxUcmFjZUNvbnRleHQSEAoIdHJhY2VfaWQYASABKAwSDwoHc3Bhbl9pZBgCIAEoDBIPCgdzYW1wbGVkGAMgASgIIp0CCg5SdW50aW1lRmFpbHVyZRIMCgRjb2RlGAEgASgJEg8KB21lc3NhZ2UYAiABKAkSEQoJY29tcG9uZW50GAMgASgJEhYKCXdvcmtzcGFjZRgEIAEoCUgAiAEBEhMKBmRvbWFpbhgFIAEoCUgBiAEBEhYKCWRpcmVjdGl2ZRgGIAEoCUgCiAEBEjkKCmF0dHJpYnV0ZXMYByADKAsyJS5ub21vcy5ydW50aW1lLnYyLkRpYWdub3N0aWNBdHRyaWJ1dGUSMgoEa2luZBgIIAEoDjIkLm5vbW9zLnJ1bnRpbWUudjIuUnVudGltZUZhaWx1c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l9QSEFTRV9VTlNQRUNJRklFRBAAEiQKIEZPTExPV19PQlNFUlZBVElPTl9QSEFTRV9ERVNJUkVEEAESIAocRk9MTE9XX09CU0VSVkFUSU9OX1BIQVNFX0RVRRACEiQKIEZPTExPV19PQlNFUlZBVElPTl9QSEFTRV9SVU5OSU5HEAMSJAogRk9MTE9XX09CU0VSVkFUSU9OX1BIQVNFX1NFVFRMRUQQBBIwCixGT0xMT1dfT0JTRVJWQVRJT05fUEhBU0VfQVdBSVRJTkdfREVQRU5ERU5DWRAFEiQKIEZPTExPV19PQlNFUlZBVElPTl9QSEFTRV9PRkZMSU5FEAYSLworRk9MTE9XX09CU0VSVkFUSU9OX1BIQVNFX0lOVkFMSURfQ1JFREVOVElBTBAHEiQKIEZPTExPV19PQlNFUlZBVElPTl9QSEFTRV9CQUNLT0ZGEAgSLAooRk9MTE9XX09CU0VSVkFUSU9OX1BIQVNFX1JFQk9STl9SRU1PVEVMWRAJEiwKKEZPTExPV19PQlNFUlZBVElPTl9QSEFTRV9SRVBMQUNJTkdfTE9DQUwQChIyCi5GT0xMT1dfT0JTRVJWQVRJT05fUEhBU0VfTE9DQUxfQ09QWV9VTlJFQURBQkxFEAsqVwoKTGlua1N0YXR1cxIbChdMSU5LX1NUQVRVU19VTlNQRUNJRklFRBAAEhQKEExJTktfU1RBVFVTX09QRU4QARIWChJMSU5LX1NUQVRVU19DTE9TRUQQAip2CgxUcmFuc2ZlcktpbmQSHQoZVFJBTlNGRVJfS0lORF9VTlNQRUNJRklFRBAAEhcKE1RSQU5TRkVSX0tJTkRfREVMVEEQARIWChJUUkFOU0ZFUl9LSU5EX0ZVTEwQAhIWChJUUkFOU0ZFUl9LSU5EX1BVU0gQA2IGcHJvdG8z", [file_google_protobuf_any2, file_nomos_kernel_v1_progress, file_nomos_runtime_v2_correspondence_desk, file_nomos_runtime_v2_custody_desk, file_nomos_runtime_v2_placement_desk, file_nomos_runtime_v2_maintenance_desk, file_nomos_runtime_v2_model_adoption_desk, file_nomos_runtime_v2_receiving_group_desk, file_nomos_runtime_v2_recovery_desk]);
9295
9295
  RuntimeFailureSchema = /* @__PURE__ */ messageDesc22(file_nomos_runtime_v2_observability_desk, 1);
9296
9296
  RuntimeUnavailableSchema = /* @__PURE__ */ messageDesc22(file_nomos_runtime_v2_observability_desk, 2);
9297
9297
  RuntimeRefusalSchema = /* @__PURE__ */ messageDesc22(file_nomos_runtime_v2_observability_desk, 3);
@@ -9305,6 +9305,7 @@ var init_observability_desk_pb = __esm({
9305
9305
  SyncCompletedSchema = /* @__PURE__ */ messageDesc22(file_nomos_runtime_v2_observability_desk, 11);
9306
9306
  LinkChangedSchema = /* @__PURE__ */ messageDesc22(file_nomos_runtime_v2_observability_desk, 12);
9307
9307
  RuntimeSpanSchema = /* @__PURE__ */ messageDesc22(file_nomos_runtime_v2_observability_desk, 15);
9308
+ WritePreparationSchema = /* @__PURE__ */ messageDesc22(file_nomos_runtime_v2_observability_desk, 18);
9308
9309
  RuntimeFailureKindSchema = /* @__PURE__ */ enumDesc15(file_nomos_runtime_v2_observability_desk, 0);
9309
9310
  RuntimeFailureKind = /* @__PURE__ */ tsEnum15(RuntimeFailureKindSchema);
9310
9311
  RuntimeUnavailableReasonSchema = /* @__PURE__ */ enumDesc15(file_nomos_runtime_v2_observability_desk, 1);
@@ -11691,7 +11692,7 @@ function filesystemCustodyFetch(dataDir, origin, options = {}, networkFetch = fe
11691
11692
  async function runGitHttpBackend(projectRoot, { method, pathInfo, query: query2, contentType, body }, options = {}) {
11692
11693
  const stdin = body && body.length ? await requestBodyStdin(body) : void 0;
11693
11694
  try {
11694
- return await new Promise((resolve8, reject) => {
11695
+ return await new Promise((resolve9, reject) => {
11695
11696
  const env = {
11696
11697
  ...process.env,
11697
11698
  GIT_PROJECT_ROOT: projectRoot,
@@ -11766,7 +11767,7 @@ async function runGitHttpBackend(projectRoot, { method, pathInfo, query: query2,
11766
11767
  }
11767
11768
  headers[k] = v;
11768
11769
  }
11769
- resolve8({ status: status2, headers, body: payload });
11770
+ resolve9({ status: status2, headers, body: payload });
11770
11771
  });
11771
11772
  });
11772
11773
  } finally {
@@ -14850,6 +14851,22 @@ var init_credential_sessions = __esm({
14850
14851
  }
14851
14852
  });
14852
14853
 
14854
+ // ../peer-office/src/runtime/credential_failure.ts
14855
+ function recoverableCredential(failure) {
14856
+ return failure.code === "nomos.auth.token_expired" || failure.code === "nomos.auth.token_missing";
14857
+ }
14858
+ function syncNeedsCredentialRefresh(result, failure) {
14859
+ if (failure !== void 0 && recoverableCredential(failure)) return true;
14860
+ const offer = result?.offerReceipt?.outcome;
14861
+ const pushNeedsRefresh = offer?.case === "failure" ? recoverableCredential(offer.value) : result?.pushError?.status === 401;
14862
+ return pushNeedsRefresh || result?.discoveryError?.status === 401;
14863
+ }
14864
+ var init_credential_failure = __esm({
14865
+ "../peer-office/src/runtime/credential_failure.ts"() {
14866
+ "use strict";
14867
+ }
14868
+ });
14869
+
14853
14870
  // ../peer-office/src/runtime/credential_renewal.ts
14854
14871
  function identityTokenClaim(token, claim) {
14855
14872
  const claims = tokenClaims(token);
@@ -15048,19 +15065,11 @@ var init_sha256 = __esm({
15048
15065
 
15049
15066
  // ../peer-office/src/runtime/credential_recovery_desk.ts
15050
15067
  import { create as create17, fromBinary as fromBinary9, toBinary as toBinary8 } from "@bufbuild/protobuf";
15051
- function recoverableCredential(failure) {
15052
- return failure.code === "nomos.auth.token_expired" || failure.code === "nomos.auth.token_missing";
15053
- }
15054
- function syncNeedsCredentialRefresh(event) {
15055
- const failures = [event.result?.pushError, event.result?.discoveryError];
15056
- if (failures.some((failure) => failure?.status === 401 || failure?.status === 403)) return true;
15057
- const text2 = `${event.failure?.message ?? ""} ${failures.map((failure) => failure?.message ?? "").join(" ")}`.toLowerCase();
15058
- return text2.includes("unauthenticated") || text2.includes("token expired") || text2.includes("invalid token");
15059
- }
15060
15068
  var CredentialRecoveryDesk;
15061
15069
  var init_credential_recovery_desk = __esm({
15062
15070
  "../peer-office/src/runtime/credential_recovery_desk.ts"() {
15063
15071
  "use strict";
15072
+ init_credential_failure();
15064
15073
  init_kernel_pb();
15065
15074
  init_correspondence_desk_pb();
15066
15075
  init_credentials_desk_pb();
@@ -15145,7 +15154,7 @@ var init_credential_recovery_desk = __esm({
15145
15154
  return false;
15146
15155
  }
15147
15156
  observeSync(session, event) {
15148
- if (!syncNeedsCredentialRefresh(event) || this.#tokenless(session)) return;
15157
+ if (!syncNeedsCredentialRefresh(event.result, event.failure) || this.#tokenless(session)) return;
15149
15158
  this.#prune();
15150
15159
  const capability = this.#ports.capabilityFor(session);
15151
15160
  const existing = this.#active.get(capability);
@@ -16352,6 +16361,7 @@ var init_receiving_group_desk = __esm({
16352
16361
  #accounts = /* @__PURE__ */ new Map();
16353
16362
  /** D22: device key hash → the workspaces the console reported this key enrolled in (this process's memory, not truth). */
16354
16363
  #consoleEnrolments = /* @__PURE__ */ new Map();
16364
+ #preparingWrites = /* @__PURE__ */ new Map();
16355
16365
  #sequence = 0;
16356
16366
  #internalRequestId = 30000000000n;
16357
16367
  constructor(ports) {
@@ -16391,16 +16401,124 @@ var init_receiving_group_desk = __esm({
16391
16401
  if (head === account.observedHead) return;
16392
16402
  this.#tails.set(workspace, { ...account, inFlight: false, attempts: 0, notBefore: 0n });
16393
16403
  }
16394
- /** A refused nominal Home action can wait for framework recovery and retry once.
16395
- * Sealed/pending history is never re-signed, and no child is mistaken for Home. */
16404
+ /** Only a proven non-admission can enter recovery. Console-enrolled children
16405
+ * share the owning application's route, selected by credential capability and
16406
+ * principal, never by workspace-name guessing or an unverified payload. */
16396
16407
  recoverOffer(request, response) {
16397
- if (!this.#ports.call || request.command.case !== "kernelCall" || request.command.value.credentialUse !== CredentialUse.SESSION || request.command.value.request?.operation.case !== "offer" || request.command.value.request.operation.value.intent.case !== "call" || response.outcome.case !== "failure" || !["nomos.authz.signer_enrollment_missing", "nomos.authz.device_key_revoked"].includes(response.outcome.value.code)) return;
16408
+ if (!this.#ports.call || request.command.case !== "kernelCall" || request.command.value.credentialUse !== CredentialUse.SESSION || request.command.value.request?.operation.case !== "offer" || request.command.value.request.operation.value.intent.case !== "call") return;
16409
+ const missing = response.outcome.case === "failure" ? response.outcome.value.code === "nomos.authz.signer_enrollment_missing" : response.outcome.case === "offer" && response.outcome.value.outcome.case === "refused" && response.outcome.value.outcome.value.refusal?.code === KernelRefusalCode.FORGED_PRINCIPAL && response.outcome.value.outcome.value.refusal.details?.fields.actor?.kind.case === "text" && response.outcome.value.outcome.value.refusal.details.fields.actor.kind.value === "unenrolled-signer-key";
16410
+ const revoked = response.outcome.case === "failure" && response.outcome.value.code === "nomos.authz.device_key_revoked";
16411
+ if (!missing && !revoked) return;
16398
16412
  const binding = this.#ports.binding(request.command.value.session);
16399
- const account = binding ? this.#accounts.get(binding.workspace) : void 0;
16400
- if (!account) return;
16413
+ if (!binding) return;
16414
+ const enrolled = [...this.#accounts.values()].find((account2) => {
16415
+ const owner = this.#ports.binding(account2.session);
16416
+ return account2.enrolment && owner?.credentialCapability === binding.credentialCapability && owner.principal === binding.principal;
16417
+ });
16401
16418
  const copy3 = fromBinary14(RuntimeRequestSchema, toBinary11(RuntimeRequestSchema, request));
16419
+ if (enrolled?.enrolment) {
16420
+ if (revoked) return this.#writeRefused(binding.workspace, "This device's access has been revoked.");
16421
+ return this.#begin(request, `enrolled-write-${++this.#sequence}`, (workId2) => this.#prepareEnrolledWrite(copy3, binding, enrolled.application, enrolled.enrolment, workId2));
16422
+ }
16423
+ const account = this.#accounts.get(binding.workspace);
16424
+ if (!account) return;
16402
16425
  return this.#begin(request, `receiving-group-authoring-${++this.#sequence}`, (workId2) => this.#recoverOffer(copy3, response, account, workId2));
16403
16426
  }
16427
+ #writeRefused(workspace, detail, reason = RuntimeRefusalReason.ACCESS_DENIED) {
16428
+ return { case: "refused", value: create24(RuntimeRefusalSchema, {
16429
+ reason,
16430
+ workspace,
16431
+ retryable: false,
16432
+ detail
16433
+ }) };
16434
+ }
16435
+ #writeWaiting(workspace, detail) {
16436
+ return { case: "unavailable", value: create24(RuntimeUnavailableSchema, {
16437
+ reason: RuntimeUnavailableReason.CREDENTIAL_UNAVAILABLE,
16438
+ workspace,
16439
+ retryable: true,
16440
+ retryAfterMillis: 1e3,
16441
+ detail
16442
+ }) };
16443
+ }
16444
+ *#prepareEnrolledWrite(request, binding, application, route, workId2) {
16445
+ if (request.command.case !== "kernelCall") throw new Error("write preparation lost its call");
16446
+ const command = request.command.value;
16447
+ const principal = binding.principal;
16448
+ const unavailable = () => this.#writeWaiting(
16449
+ binding.workspace,
16450
+ "This device is still being prepared to save changes. Your change has not been saved. Try again when connected."
16451
+ );
16452
+ this.#ports.emit(binding.session, { case: "writePreparation", value: create24(WritePreparationSchema, {
16453
+ requestId: command.request.requestId,
16454
+ workspace: binding.workspace
16455
+ }) });
16456
+ const key2 = JSON.stringify([binding.credentialCapability, principal, binding.workspace]);
16457
+ const shared = this.#preparingWrites.get(key2);
16458
+ const deadline = this.#ports.clock.monotonicNanoseconds() + 30000000000n;
16459
+ let wake = 0;
16460
+ if (shared) {
16461
+ while (!shared.settled) {
16462
+ if (this.#ports.clock.monotonicNanoseconds() >= deadline) return unavailable();
16463
+ const receipt = yield { case: "wake", value: create24(PeerWakeEffectSchema, {
16464
+ effectId: `${workId2}:join-${++wake}`,
16465
+ delayMillis: 250
16466
+ }) };
16467
+ if (receipt.outcome.case !== "woken") return unavailable();
16468
+ }
16469
+ if (shared.result) return shared.result;
16470
+ } else {
16471
+ const preparation = { settled: false };
16472
+ this.#preparingWrites.set(key2, preparation);
16473
+ try {
16474
+ const secret = this.#ports.authorSecretIfPresent(binding.session);
16475
+ if (!secret) return preparation.result = this.#writeRefused(binding.workspace, "Sign in again to set up this device.", RuntimeRefusalReason.INVALID_CREDENTIAL);
16476
+ const keyHash = sha256Hex6(this.#ports.deriveSigningPublicKey(secret));
16477
+ let posture = this.#ports.posture(request, binding.session, principal, secret, false);
16478
+ if (posture.deviceSignerStatus === DeviceSignerStatus.REVOKED) {
16479
+ return preparation.result = this.#writeRefused(binding.workspace, "This device's access has been revoked.");
16480
+ }
16481
+ if (!posture.enrolledDevice || posture.deviceSignerStatus !== DeviceSignerStatus.ACTIVE) {
16482
+ const enrolled = yield* this.#enrolAtConsole(
16483
+ route,
16484
+ binding,
16485
+ `${application}|${principal}`,
16486
+ principal,
16487
+ keyHash,
16488
+ [binding.workspace],
16489
+ `${workId2}:console`
16490
+ );
16491
+ if (enrolled.case === "deferred") return preparation.result = enrolled.credentialRefused ? this.#writeRefused(binding.workspace, "Sign in again to set up this device.", RuntimeRefusalReason.INVALID_CREDENTIAL) : unavailable();
16492
+ if (!(binding.workspace in enrolled.value.heads)) {
16493
+ return preparation.result = this.#writeRefused(binding.workspace, "This device could not obtain access to save changes in this workspace.");
16494
+ }
16495
+ while (true) {
16496
+ posture = this.#ports.posture(request, binding.session, principal, secret, false);
16497
+ if (posture.deviceSignerStatus === DeviceSignerStatus.REVOKED) {
16498
+ return preparation.result = this.#writeRefused(binding.workspace, "This device's access has been revoked.");
16499
+ }
16500
+ if (posture.enrolledDevice && posture.deviceSignerStatus === DeviceSignerStatus.ACTIVE) break;
16501
+ if (this.#ports.clock.monotonicNanoseconds() >= deadline) return preparation.result = unavailable();
16502
+ const receipt = yield { case: "wake", value: create24(PeerWakeEffectSchema, {
16503
+ effectId: `${workId2}:observe-${++wake}`,
16504
+ delayMillis: 500
16505
+ }) };
16506
+ if (receipt.outcome.case !== "woken") return preparation.result = unavailable();
16507
+ }
16508
+ }
16509
+ } catch (error) {
16510
+ if (error instanceof ReceivingGroupRefusal) {
16511
+ return preparation.result = this.#writeRefused(binding.workspace, "This device could not obtain access to save changes in this workspace.");
16512
+ }
16513
+ preparation.result = unavailable();
16514
+ throw error;
16515
+ } finally {
16516
+ preparation.settled = true;
16517
+ this.#preparingWrites.delete(key2);
16518
+ }
16519
+ }
16520
+ return { case: "retried", request, response: this.#ports.call(request, command) };
16521
+ }
16404
16522
  *#recoverOffer(request, response, account, workId2) {
16405
16523
  const workspace = this.#ports.binding(account.session).workspace;
16406
16524
  const deadline = this.#ports.clock.monotonicNanoseconds() + 60000000000n;
@@ -16468,6 +16586,7 @@ var init_receiving_group_desk = __esm({
16468
16586
  this.#opening.clear();
16469
16587
  this.#accounts.clear();
16470
16588
  this.#consoleEnrolments.clear();
16589
+ this.#preparingWrites.clear();
16471
16590
  }
16472
16591
  #begin(request, workId2, procedure) {
16473
16592
  const held = {
@@ -20359,6 +20478,7 @@ var init_replica_follow_controller = __esm({
20359
20478
  init_replica_follow_state();
20360
20479
  init_local_copy_readability();
20361
20480
  init_placement_desk();
20481
+ init_credential_failure();
20362
20482
  ReplicaFollowReconciliationKind = Object.freeze({
20363
20483
  Following: "following",
20364
20484
  NotFollowing: "not_following"
@@ -20626,12 +20746,12 @@ var init_replica_follow_controller = __esm({
20626
20746
  this.#desk.transition(result.workspace, { case: ReplicaFollowEventKind.WentOffline, nowUnixMillis });
20627
20747
  return delayUntilDue(this.#desk.get(result.workspace), nowUnixMillis);
20628
20748
  }
20629
- const credentialFailure = [result.pushError, result.discoveryError].find((failure) => failure?.status === 401 || failure?.status === 403);
20630
- if (credentialFailure) {
20749
+ if (syncNeedsCredentialRefresh(result)) {
20750
+ const offer = result.offerReceipt?.outcome;
20631
20751
  const transition = this.#desk.transition(result.workspace, {
20632
20752
  case: ReplicaFollowEventKind.CredentialRejected,
20633
20753
  nowUnixMillis,
20634
- failure: credentialFailure.message || `remote rejected credential with HTTP ${credentialFailure.status}`
20754
+ failure: (offer?.case === "failure" ? offer.value.message : void 0) || result.pushError?.message || result.discoveryError?.message || "remote requires a refreshed credential"
20635
20755
  });
20636
20756
  if (transition.effects.some((effect) => effect.case === ReplicaFollowEffectKind.RefreshCredential)) {
20637
20757
  return 0;
@@ -23855,9 +23975,9 @@ var init_workspace_sync = __esm({
23855
23975
  return this.#route?.receptionUrl || `${this.#cloudBase()}/v2/workspaces/${encodeURIComponent(this.#mount.workspace)}`;
23856
23976
  }
23857
23977
  #authToken() {
23858
- const resolve8 = this.#credentials.authTokenForCapability ?? this.#credentials.authToken;
23859
- if (!resolve8) throw new Error("workspace sync has no credential capability resolver");
23860
- return resolve8.call(this.#credentials, this.#binding.credentialCapability);
23978
+ const resolve9 = this.#credentials.authTokenForCapability ?? this.#credentials.authToken;
23979
+ if (!resolve9) throw new Error("workspace sync has no credential capability resolver");
23980
+ return resolve9.call(this.#credentials, this.#binding.credentialCapability);
23861
23981
  }
23862
23982
  };
23863
23983
  }
@@ -29347,6 +29467,7 @@ var init_peer_office = __esm({
29347
29467
  return this.#responses.modelAdoption(request, step);
29348
29468
  }
29349
29469
  #receivingGroupResponse(request, step) {
29470
+ if (step.case === "refused") return this.#response(request, { case: "refused", value: step.value });
29350
29471
  if (step.case === "retried") return this.#birthCustodyResponse(step.request, this.#birthCustody.afterKernelCall(step.request, step.response));
29351
29472
  if (step.case === "pending") return this.#response(request, { case: "correspondencePending", value: step.value });
29352
29473
  if (step.case === "failure") return this.#failure(request, step.code, step.message);
@@ -29640,7 +29761,7 @@ function createPeerOfficeFrameRunner(kernel, credentials, profile, observations,
29640
29761
  const deadline = Date.now() + Math.max(0, withinMillis);
29641
29762
  while (outstanding() > 0 && Date.now() < deadline) {
29642
29763
  lanes.wake(0);
29643
- await new Promise((resolve8) => setTimeout(resolve8, 10));
29764
+ await new Promise((resolve9) => setTimeout(resolve9, 10));
29644
29765
  }
29645
29766
  return outstanding();
29646
29767
  },
@@ -29701,7 +29822,7 @@ async function drivePeerFrame(runner, initialFrame, fetchImpl = globalThis.fetch
29701
29822
  if (response.outcome.case === "localReadPending") {
29702
29823
  if (yieldLocalReadToCaller) return responseFrame;
29703
29824
  const pending2 = response.outcome.value;
29704
- await new Promise((resolve8) => setTimeout(resolve8, pending2.resumeAfterMillis));
29825
+ await new Promise((resolve9) => setTimeout(resolve9, pending2.resumeAfterMillis));
29705
29826
  responseFrame = runner.handleFrame(toBinary26(RuntimeRequestSchema, create72(RuntimeRequestSchema, {
29706
29827
  protocolVersion: response.protocolVersion,
29707
29828
  requestId: response.requestId,
@@ -29871,7 +29992,7 @@ async function executeHistoryAcquisitionEffect(effect, custody) {
29871
29992
  }
29872
29993
  }
29873
29994
  async function executeWakeEffect(effect) {
29874
- await new Promise((resolve8) => setTimeout(resolve8, effect.delayMillis));
29995
+ await new Promise((resolve9) => setTimeout(resolve9, effect.delayMillis));
29875
29996
  return create72(PeerEffectReceiptSchema, { effectId: effect.effectId, outcome: { case: "woken", value: create72(PeerWokenSchema) } });
29876
29997
  }
29877
29998
  async function executeCredentialRefreshEffect(effect, provider) {
@@ -31188,7 +31309,7 @@ async function prepareRemoteModelTransition(cloud, input) {
31188
31309
  }
31189
31310
  atHash = status2.outcome.value.head ?? "";
31190
31311
  if (atHash || Date.now() >= deadline) break;
31191
- await new Promise((resolve8) => setTimeout(resolve8, 1e3));
31312
+ await new Promise((resolve9) => setTimeout(resolve9, 1e3));
31192
31313
  }
31193
31314
  if (!atHash) {
31194
31315
  throw new Error("workspace has no current Git frontier to prove after pulling it");
@@ -31234,8 +31355,8 @@ async function prepareRemoteModelTransition(cloud, input) {
31234
31355
  target3
31235
31356
  );
31236
31357
  if (response.outcome.case !== "unavailable" || !response.outcome.value.retryable || Date.now() >= proofDeadline) break;
31237
- await new Promise((resolve8) => setTimeout(
31238
- resolve8,
31358
+ await new Promise((resolve9) => setTimeout(
31359
+ resolve9,
31239
31360
  Math.max(500, response.outcome.case === "unavailable" ? response.outcome.value.retryAfterMillis ?? 1e3 : 1e3)
31240
31361
  ));
31241
31362
  }
@@ -32088,7 +32209,7 @@ async function waitForWorkspaceMain(cloud, workspace, timeoutMs = 3e4) {
32088
32209
  while (Date.now() < deadline) {
32089
32210
  const head = await workspaceMainHead(cloud, workspace);
32090
32211
  if (head !== void 0) return head;
32091
- await new Promise((resolve8) => setTimeout(resolve8, 250));
32212
+ await new Promise((resolve9) => setTimeout(resolve9, 250));
32092
32213
  }
32093
32214
  return void 0;
32094
32215
  }
@@ -32309,7 +32430,7 @@ async function ensureSovereignHome(opts = {}) {
32309
32430
  const deadline = Date.now() + 3e4;
32310
32431
  while (Date.now() < deadline) {
32311
32432
  if (await fetch(`${cloud}/v2/workspaces/${encodeURIComponent(home)}`).then((r) => r.ok).catch(() => false)) break;
32312
- await new Promise((resolve8) => setTimeout(resolve8, 250));
32433
+ await new Promise((resolve9) => setTimeout(resolve9, 250));
32313
32434
  }
32314
32435
  if (!await fetch(`${cloud}/v2/workspaces/${encodeURIComponent(home)}`).then((r) => r.ok).catch(() => false)) {
32315
32436
  throw new Error(`Nomos admitted the birth of '${home}' but its custody did not become readable`);
@@ -32357,7 +32478,7 @@ async function ensureSovereignHome(opts = {}) {
32357
32478
  return typeof leaf?.verifiedVia === "string" && leaf.verifiedVia.length > 0;
32358
32479
  }).catch(() => false);
32359
32480
  if (visible) break;
32360
- await new Promise((resolve8) => setTimeout(resolve8, 250));
32481
+ await new Promise((resolve9) => setTimeout(resolve9, 250));
32361
32482
  }
32362
32483
  if (!visible) throw new Error(`the session home's verified device enrollment did not become readable`);
32363
32484
  }
@@ -33741,7 +33862,7 @@ async function waitForDurableMainAdvance(cloud, ws2, previousHead, opts = {}) {
33741
33862
  while (Date.now() < deadline) {
33742
33863
  const head = await durableMainHead(cloud, ws2, fetchImpl);
33743
33864
  if (head !== void 0 && head !== previousHead) return head;
33744
- await new Promise((resolve8) => setTimeout(resolve8, pollMs));
33865
+ await new Promise((resolve9) => setTimeout(resolve9, pollMs));
33745
33866
  }
33746
33867
  return void 0;
33747
33868
  }
@@ -34108,6 +34229,19 @@ function runLsp(args) {
34108
34229
  const r = spawnSync2(process.execPath, [launcher, ...args], { stdio: "inherit", cwd: process.cwd() });
34109
34230
  return r.status ?? 1;
34110
34231
  }
34232
+ function runInspectRelease(args) {
34233
+ const compile = resolveCompileLauncher(process.cwd());
34234
+ if (!compile) {
34235
+ process.stderr.write(`error: ${NO_DSL_REMEDY}
34236
+ `);
34237
+ return 1;
34238
+ }
34239
+ return spawnSync2(
34240
+ process.execPath,
34241
+ [join10(dirname2(compile), "inspect_release.mjs"), ...args],
34242
+ { stdio: "inherit", cwd: process.cwd() }
34243
+ ).status ?? 1;
34244
+ }
34111
34245
  var NO_DSL_REMEDY;
34112
34246
  var init_compile = __esm({
34113
34247
  "src/compile.ts"() {
@@ -34292,11 +34426,13 @@ var init_commands = __esm({
34292
34426
  "use strict";
34293
34427
  DISPATCHED_COMMANDS = [
34294
34428
  "compile",
34429
+ "inspect-release",
34295
34430
  "check",
34296
34431
  "lsp",
34297
34432
  "mcp",
34298
34433
  "init-editor",
34299
34434
  "test",
34435
+ "conformance",
34300
34436
  "doctor",
34301
34437
  "cloud",
34302
34438
  "console",
@@ -34375,6 +34511,17 @@ var init_help = __esm({
34375
34511
  ],
34376
34512
  examples: ["githolon compile", "githolon compile nomos.application.ts --require-usdcat"]
34377
34513
  },
34514
+ "inspect-release": {
34515
+ usage: "githolon inspect-release --identity <ledger.usda> --units <build/app.units>",
34516
+ what: "Read-only release baseline observations as JSON. Verify unit bytes, compare identity metadata and\noptionally compare an installed workspace export. No admission, publication or installation approval.",
34517
+ flags: [
34518
+ ["--identity <path>", "current authoring identity ledger"],
34519
+ ["--units <directory>", "compiler-emitted law unit directory"],
34520
+ ["--against <path>", "optional prior identity ledger"],
34521
+ ["--installed <path>", "optional JSON export from the console workspace API"]
34522
+ ],
34523
+ examples: ["githolon inspect-release --identity nomos.identity.usda --units build/app.units"]
34524
+ },
34378
34525
  check: {
34379
34526
  usage: "githolon check [config] [--against <nomos.identity.usda|package dir>] [--json]",
34380
34527
  what: "THE AUTHOR-TIME GATE: run the static twins over the law you have written and print everything the\nkernel can already prove it would refuse \u2014 before a compile, before a deploy, before a user. --against adds\nthe EVOLVE PREVIEW: diff this build against a prior identity surface and pre-fire the evolve gate, so a\nrename, removal or retype is named here instead of at the install offer. Exit non-zero on any refusal.",
@@ -34428,6 +34575,16 @@ var init_help = __esm({
34428
34575
  ],
34429
34576
  examples: ["githolon cloud dev", "githolon cloud dev --port 8787 --ephemeral", "githolon cloud dev --platform my-platform --law build/my.law.usdz"]
34430
34577
  },
34578
+ conformance: {
34579
+ usage: "githolon conformance [--json] [--offline] [--runtime <directory>]",
34580
+ what: "Check the installed Node packages with an isolated generated application and the real test harness.\nProves write, read, refusal without mutation, persisted history and cold restore. Reports package versions\nand the kernel identity. First use may download verified runtime artifacts; no cloud workspace is changed.",
34581
+ flags: [
34582
+ ["--json", "emit one report for CI; exit nonzero if any check fails"],
34583
+ ["--offline", "use local runtime artifacts only; fail if unavailable"],
34584
+ ["--runtime <directory>", "use this verified runtime bundle"]
34585
+ ],
34586
+ examples: ["githolon conformance", "githolon conformance --offline --json"]
34587
+ },
34431
34588
  test: {
34432
34589
  usage: "githolon test [test-file-or-flutter-test-flags] [--diagnostics]",
34433
34590
  what: "Run generated Dart application scenarios through Flutter with the real local Nomos custody plane.\nThe server rides inside githolon; connected scenarios, partitions, restarts and fresh reinstalls need no\nserver path, environment variables, certificates, workspace setup or separate application state.",
@@ -35040,35 +35197,171 @@ var init_mcp = __esm({
35040
35197
  }
35041
35198
  });
35042
35199
 
35200
+ // src/conformance.ts
35201
+ var conformance_exports = {};
35202
+ __export(conformance_exports, {
35203
+ runConformance: () => runConformance
35204
+ });
35205
+ import { spawnSync as spawnSync5 } from "node:child_process";
35206
+ import { cpSync, existsSync as existsSync13, mkdirSync as mkdirSync11, mkdtempSync as mkdtempSync4, readFileSync as readFileSync12, rmSync as rmSync6, symlinkSync, writeFileSync as writeFileSync12 } from "node:fs";
35207
+ import { createRequire as createRequire3 } from "node:module";
35208
+ import { tmpdir as tmpdir3 } from "node:os";
35209
+ import { dirname as dirname4, join as join17, resolve as resolve5 } from "node:path";
35210
+ import { fileURLToPath as fileURLToPath2 } from "node:url";
35211
+ function installedPackage(name, from) {
35212
+ const require2 = createRequire3(join17(from, "package.json"));
35213
+ const entry = require2.resolve(name === "@githolon/testing" ? name : `${name}/package.json`);
35214
+ for (let directory2 = dirname4(entry); ; directory2 = dirname4(directory2)) {
35215
+ const manifest = join17(directory2, "package.json");
35216
+ if (existsSync13(manifest)) {
35217
+ const pkg = JSON.parse(readFileSync12(manifest, "utf8"));
35218
+ if (pkg.name === name) return { name, version: pkg.version, directory: directory2 };
35219
+ }
35220
+ if (dirname4(directory2) === directory2) throw new Error(`Cannot identify installed ${name}`);
35221
+ }
35222
+ }
35223
+ function runConformance(args, cwd = process.cwd()) {
35224
+ let json = false, offline = false, runtime;
35225
+ for (let index = 0; index < args.length; index++) {
35226
+ const arg = args[index];
35227
+ if (arg === "--json") json = true;
35228
+ else if (arg === "--offline") offline = true;
35229
+ else if (arg === "--runtime" && args[index + 1] && !args[index + 1].startsWith("--")) runtime = resolve5(cwd, args[++index]);
35230
+ else {
35231
+ process.stderr.write(`error: unknown or incomplete conformance option: ${arg}. See githolon conformance --help.
35232
+ `);
35233
+ return 2;
35234
+ }
35235
+ }
35236
+ const report = { passed: false, packages: [], checks: [] };
35237
+ let scratch;
35238
+ let stage = "installed packages";
35239
+ let action = "Run npm install in this project. Install githolon, @githolon/dsl and @githolon/testing as development dependencies if absent.";
35240
+ try {
35241
+ const packages = ["githolon", "@githolon/dsl", "@githolon/testing"].map((name) => {
35242
+ const pkg = installedPackage(name, cwd);
35243
+ report.packages.push({ name, version: pkg.version });
35244
+ return pkg;
35245
+ });
35246
+ const [cli, dsl] = packages;
35247
+ const peer2 = installedPackage("@githolon/runtime", dsl.directory);
35248
+ report.packages.push({ name: peer2.name, version: peer2.version });
35249
+ report.checks.push({ name: stage, passed: true });
35250
+ if (!json) {
35251
+ process.stdout.write("Nomos conformance \u2014 isolated generated application, real local runtime\n");
35252
+ for (const pkg of report.packages) process.stdout.write(` ${pkg.name} ${pkg.version}
35253
+ `);
35254
+ }
35255
+ scratch = mkdtempSync4(join17(tmpdir3(), "nomos-conformance-"));
35256
+ const here = dirname4(fileURLToPath2(import.meta.url));
35257
+ const distribution = existsSync13(join17(here, "conformance-probe.mjs")) ? here : resolve5(here, "../dist");
35258
+ cpSync(join17(distribution, "conformance-fixture"), scratch, { recursive: true });
35259
+ writeFileSync12(join17(scratch, "package.json"), '{"name":"nomos-conformance-probe","private":true,"type":"module"}\n');
35260
+ const modules = join17(scratch, "node_modules");
35261
+ mkdirSync11(join17(modules, "@githolon"), { recursive: true });
35262
+ for (const pkg of [dsl, peer2]) {
35263
+ symlinkSync(pkg.directory, join17(modules, pkg.name), process.platform === "win32" ? "junction" : "dir");
35264
+ }
35265
+ const environment = { ...process.env, TMPDIR: scratch, TMP: scratch, TEMP: scratch };
35266
+ const run2 = (argv) => {
35267
+ const result = spawnSync5(process.execPath, argv, {
35268
+ cwd: scratch,
35269
+ env: environment,
35270
+ encoding: "utf8",
35271
+ timeout: 18e4,
35272
+ maxBuffer: 8 * 1024 * 1024
35273
+ });
35274
+ if (result.error) throw result.error;
35275
+ if (result.status !== 0) throw new Error((result.stderr || result.stdout || `Exited ${result.status}`).slice(-6e3));
35276
+ };
35277
+ stage = "compile generated application";
35278
+ action = "Reinstall compatible githolon and @githolon/dsl versions from your lockfile. If this bundled fixture still fails, report the diagnostic and package versions to Nomos.";
35279
+ if (!json) process.stdout.write(`Checking ${stage}\u2026
35280
+ `);
35281
+ run2([join17(cli.directory, "dist/cli.mjs"), "compile", "--no-mount-check"]);
35282
+ report.checks.push({ name: stage, passed: true });
35283
+ stage = "runtime and application behavior";
35284
+ action = "Check the selected runtime and installed @githolon/testing version. For an uncached runtime, run once online or supply a verified runtime directory with --runtime. Report repeatable behavior failures with this report.";
35285
+ if (!json) process.stdout.write(`Checking ${stage}\u2026
35286
+ `);
35287
+ const resultFile = join17(scratch, "result.json");
35288
+ const testingEntry = createRequire3(join17(cwd, "package.json")).resolve("@githolon/testing");
35289
+ const probe = spawnSync5(process.execPath, [
35290
+ join17(distribution, "conformance-probe.mjs"),
35291
+ testingEntry,
35292
+ scratch,
35293
+ resultFile,
35294
+ runtime ?? "",
35295
+ String(offline)
35296
+ ], {
35297
+ cwd: scratch,
35298
+ env: environment,
35299
+ encoding: "utf8",
35300
+ timeout: 18e4,
35301
+ maxBuffer: 8 * 1024 * 1024
35302
+ });
35303
+ if (existsSync13(resultFile)) {
35304
+ const result = JSON.parse(readFileSync12(resultFile, "utf8"));
35305
+ report.checks.push(...result.checks);
35306
+ if (result.runtime) report.runtime = result.runtime;
35307
+ if (result.failure) report.failure = result.failure;
35308
+ report.passed = result.passed && probe.status === 0;
35309
+ }
35310
+ if (!report.passed && !report.failure) throw probe.error ?? new Error((probe.stderr || probe.stdout || `Probe exited ${probe.status}`).slice(-6e3));
35311
+ } catch (error) {
35312
+ report.checks.push({ name: stage, passed: false });
35313
+ report.failure = { stage, detail: error instanceof Error ? error.message : String(error), action };
35314
+ } finally {
35315
+ if (scratch) rmSync6(scratch, { recursive: true, force: true });
35316
+ }
35317
+ if (json) process.stdout.write(JSON.stringify(report, null, 2) + "\n");
35318
+ else {
35319
+ if (report.runtime) process.stdout.write(`Kernel SHA-256: ${report.runtime.kernelSha256}
35320
+ `);
35321
+ for (const check2 of report.checks) process.stdout.write(`${check2.passed ? "PASS" : "FAIL"} ${check2.name}${check2.detail ? ` \u2014 ${check2.detail}` : ""}
35322
+ `);
35323
+ if (report.failure) process.stderr.write(`${report.failure.detail}
35324
+ Next: ${report.failure.action}
35325
+ `);
35326
+ process.stdout.write(report.passed ? "PASS \u2014 installed Node stack conforms.\n" : "FAIL \u2014 conformance did not pass.\n");
35327
+ }
35328
+ return report.passed ? 0 : 1;
35329
+ }
35330
+ var init_conformance = __esm({
35331
+ "src/conformance.ts"() {
35332
+ "use strict";
35333
+ }
35334
+ });
35335
+
35043
35336
  // src/test.ts
35044
35337
  var test_exports = {};
35045
35338
  __export(test_exports, {
35046
35339
  resolveTestCloudEntry: () => resolveTestCloudEntry,
35047
35340
  runDartTests: () => runDartTests
35048
35341
  });
35049
- import { spawnSync as spawnSync5 } from "node:child_process";
35050
- import { existsSync as existsSync13 } from "node:fs";
35051
- import { dirname as dirname4, resolve as resolve5 } from "node:path";
35052
- import { fileURLToPath as fileURLToPath2 } from "node:url";
35342
+ import { spawnSync as spawnSync6 } from "node:child_process";
35343
+ import { existsSync as existsSync14 } from "node:fs";
35344
+ import { dirname as dirname5, resolve as resolve6 } from "node:path";
35345
+ import { fileURLToPath as fileURLToPath3 } from "node:url";
35053
35346
  function resolveTestCloudEntry(options = {}) {
35054
35347
  const cwd = options.cwd ?? process.cwd();
35055
35348
  const environment = options.environment ?? process.env;
35056
35349
  const explicit = environment.NOMOS_TEST_CLOUD_ENTRY;
35057
35350
  if (explicit !== void 0) {
35058
- const candidate = resolve5(cwd, explicit);
35059
- if (!existsSync13(candidate)) {
35351
+ const candidate = resolve6(cwd, explicit);
35352
+ if (!existsSync14(candidate)) {
35060
35353
  throw new Error(`NOMOS_TEST_CLOUD_ENTRY does not exist: ${candidate}`);
35061
35354
  }
35062
35355
  return candidate;
35063
35356
  }
35064
- const here = dirname4(fileURLToPath2(options.moduleUrl ?? import.meta.url));
35357
+ const here = dirname5(fileURLToPath3(options.moduleUrl ?? import.meta.url));
35065
35358
  const candidates = [
35066
- resolve5(here, "dev-server.mjs"),
35067
- resolve5(here, "../dist/dev-server.mjs"),
35068
- resolve5(here, "../../platform-shells/node/local-development/server.ts"),
35069
- resolve5(cwd, "platform-shells/node/local-development/server.ts")
35359
+ resolve6(here, "dev-server.mjs"),
35360
+ resolve6(here, "../dist/dev-server.mjs"),
35361
+ resolve6(here, "../../platform-shells/node/local-development/server.ts"),
35362
+ resolve6(cwd, "platform-shells/node/local-development/server.ts")
35070
35363
  ];
35071
- const server = candidates.find((candidate) => existsSync13(candidate));
35364
+ const server = candidates.find((candidate) => existsSync14(candidate));
35072
35365
  if (server === void 0) {
35073
35366
  throw new Error("the bundled local Nomos cloud is missing \u2014 rebuild or reinstall githolon");
35074
35367
  }
@@ -35086,7 +35379,7 @@ function runDartTests(args) {
35086
35379
  return 1;
35087
35380
  }
35088
35381
  process.stdout.write("githolon test \u2014 generated application scenarios with real local custody\n");
35089
- const result = spawnSync5("flutter", ["test", ...forwarded], {
35382
+ const result = spawnSync6("flutter", ["test", ...forwarded], {
35090
35383
  cwd: process.cwd(),
35091
35384
  stdio: "inherit",
35092
35385
  env: {
@@ -35702,7 +35995,7 @@ var init_law_command_projection = __esm({
35702
35995
  });
35703
35996
 
35704
35997
  // src/law_encoder.ts
35705
- import { readFileSync as readFileSync12 } from "node:fs";
35998
+ import { readFileSync as readFileSync13 } from "node:fs";
35706
35999
  async function loadInstalledLaw(input) {
35707
36000
  const file = discoverLawUsdz(input.cwd ?? process.cwd(), input.file);
35708
36001
  const inspected = await inspectLawArchive(input.cloud, file);
@@ -35714,7 +36007,7 @@ async function loadInstalledLaw(input) {
35714
36007
  );
35715
36008
  }
35716
36009
  const projection = parseLawCommandProjection(
35717
- readLawClosureAsset(new Uint8Array(readFileSync12(file)), COMMAND_PROJECTION)
36010
+ readLawClosureAsset(new Uint8Array(readFileSync13(file)), COMMAND_PROJECTION)
35718
36011
  );
35719
36012
  return { identity: inspected.identity, servedDomains: served, projection, file };
35720
36013
  }
@@ -36010,7 +36303,7 @@ var init_model_children = __esm({
36010
36303
  init_law_directive_call();
36011
36304
  init_law_command_projection();
36012
36305
  init_law_encoder();
36013
- sleep = (ms) => new Promise((resolve8) => setTimeout(resolve8, ms));
36306
+ sleep = (ms) => new Promise((resolve9) => setTimeout(resolve9, ms));
36014
36307
  }
36015
36308
  });
36016
36309
 
@@ -36135,7 +36428,7 @@ async function modelAdopt(workspace, opts) {
36135
36428
  inventory = observed;
36136
36429
  break;
36137
36430
  }
36138
- await new Promise((resolve8) => setTimeout(resolve8, 250));
36431
+ await new Promise((resolve9) => setTimeout(resolve9, 250));
36139
36432
  } while (Date.now() < deadline);
36140
36433
  if (inventory === void 0) throw new Error("the active-law projection did not converge within 30 seconds");
36141
36434
  const candidate = inventory.domains.find((installed) => installed.domainHash === identity);
@@ -36200,8 +36493,8 @@ __export(platform_exports, {
36200
36493
  storeSeatDevice: () => storeSeatDevice
36201
36494
  });
36202
36495
  import { createHash as createHash6 } from "node:crypto";
36203
- import { existsSync as existsSync14, mkdirSync as mkdirSync11, readFileSync as readFileSync13, writeFileSync as writeFileSync12 } from "node:fs";
36204
- import { join as join17 } from "node:path";
36496
+ import { existsSync as existsSync15, mkdirSync as mkdirSync12, readFileSync as readFileSync14, writeFileSync as writeFileSync13 } from "node:fs";
36497
+ import { join as join18 } from "node:path";
36205
36498
  function refuse(message) {
36206
36499
  throw new PlatformRefusal(message);
36207
36500
  }
@@ -36274,8 +36567,8 @@ async function readModelAuthority(cloud, platform, seatedAt) {
36274
36567
  }
36275
36568
  function loadSeatDevice(workspace) {
36276
36569
  const path4 = seatDevicePath(workspace);
36277
- if (!existsSync14(path4)) return void 0;
36278
- const stored = JSON.parse(readFileSync13(path4, "utf8"));
36570
+ if (!existsSync15(path4)) return void 0;
36571
+ const stored = JSON.parse(readFileSync14(path4, "utf8"));
36279
36572
  const publicKey = stored.publicKey ?? (stored.publicKeyHex === void 0 ? void 0 : Buffer.from(stored.publicKeyHex, "hex").toString("base64"));
36280
36573
  if (typeof stored.secret !== "string" || publicKey === void 0 || typeof stored.keyHash !== "string") {
36281
36574
  refuse(`${path4} is not a stored device key {secret, publicKey, keyHash}`);
@@ -36284,8 +36577,8 @@ function loadSeatDevice(workspace) {
36284
36577
  }
36285
36578
  function storeSeatDevice(workspace, device) {
36286
36579
  const path4 = seatDevicePath(workspace);
36287
- mkdirSync11(join17(path4, ".."), { recursive: true });
36288
- writeFileSync12(path4, JSON.stringify(device, null, 2) + "\n", { mode: 384 });
36580
+ mkdirSync12(join18(path4, ".."), { recursive: true });
36581
+ writeFileSync13(path4, JSON.stringify(device, null, 2) + "\n", { mode: 384 });
36289
36582
  }
36290
36583
  async function mintSeatDevice(cloud) {
36291
36584
  const generated = await generateDeviceKey(cloud);
@@ -36508,7 +36801,7 @@ async function platformAuthor(workspace, directiveId, opts) {
36508
36801
  }
36509
36802
  }
36510
36803
  function readPayload(opts) {
36511
- const raw = opts.payloadFile !== void 0 ? readFileSync13(opts.payloadFile, "utf8") : opts.payload;
36804
+ const raw = opts.payloadFile !== void 0 ? readFileSync14(opts.payloadFile, "utf8") : opts.payload;
36512
36805
  if (raw === void 0 || raw.trim() === "") refuse("author needs --payload <json> or --payload-file <file>");
36513
36806
  let parsed;
36514
36807
  try {
@@ -36700,7 +36993,7 @@ async function waitFor(condition, deadlineMillis, report) {
36700
36993
  announced = elapsed;
36701
36994
  report(elapsed);
36702
36995
  }
36703
- await new Promise((resolve8) => setTimeout(resolve8, 1e3));
36996
+ await new Promise((resolve9) => setTimeout(resolve9, 1e3));
36704
36997
  }
36705
36998
  return false;
36706
36999
  }
@@ -36720,7 +37013,7 @@ var init_platform = __esm({
36720
37013
  PlatformRefusal = class extends Error {
36721
37014
  };
36722
37015
  ws = (name) => encodeURIComponent(name);
36723
- seatDevicePath = (workspace) => join17(configDir(), `seat-device-${workspace}.json`);
37016
+ seatDevicePath = (workspace) => join18(configDir(), `seat-device-${workspace}.json`);
36724
37017
  SEAT_CONVERGENCE_MILLIS = 18e4;
36725
37018
  }
36726
37019
  });
@@ -36786,9 +37079,9 @@ var init_dlq = __esm({
36786
37079
 
36787
37080
  // src/custodian.ts
36788
37081
  import { createHash as createHash7, createPrivateKey as createPrivateKey2, createPublicKey as createPublicKey2 } from "node:crypto";
36789
- import { existsSync as existsSync15, readFileSync as readFileSync14 } from "node:fs";
36790
- import { dirname as dirname5, isAbsolute as isAbsolute3, join as join18, resolve as resolve6 } from "node:path";
36791
- import { fileURLToPath as fileURLToPath3, pathToFileURL as pathToFileURL3 } from "node:url";
37082
+ import { existsSync as existsSync16, readFileSync as readFileSync15 } from "node:fs";
37083
+ import { dirname as dirname6, isAbsolute as isAbsolute3, join as join19, resolve as resolve7 } from "node:path";
37084
+ import { fileURLToPath as fileURLToPath4, pathToFileURL as pathToFileURL3 } from "node:url";
36792
37085
  import { create as create80 } from "@bufbuild/protobuf";
36793
37086
  import { AnySchema as AnySchema3 } from "@bufbuild/protobuf/wkt";
36794
37087
  function custodianKeyHash(seed) {
@@ -36834,8 +37127,8 @@ async function resolveCustodianCredential(reference) {
36834
37127
  return fromSeed(custodianSeedFromText(device.secret, `~/.holon device key for ${rest}`), reference);
36835
37128
  }
36836
37129
  if (scheme === "file") {
36837
- if (rest === "" || !existsSync15(rest)) throw new Error(`--custodian-key file:<path> \u2014 no file at '${rest}'`);
36838
- return fromSeed(custodianSeedFromText(readFileSync14(rest, "utf8"), rest), `file:${rest}`);
37130
+ if (rest === "" || !existsSync16(rest)) throw new Error(`--custodian-key file:<path> \u2014 no file at '${rest}'`);
37131
+ return fromSeed(custodianSeedFromText(readFileSync15(rest, "utf8"), rest), `file:${rest}`);
36839
37132
  }
36840
37133
  if (scheme === "env") {
36841
37134
  const value = process.env[rest];
@@ -36861,8 +37154,8 @@ async function resolveCustodianCredential(reference) {
36861
37154
  }
36862
37155
  function readCustodianChain(file) {
36863
37156
  if (file === void 0) return [];
36864
- if (!existsSync15(file)) throw new Error(`--chain <file> \u2014 no file at '${file}'`);
36865
- const parsed = JSON.parse(readFileSync14(file, "utf8"));
37157
+ if (!existsSync16(file)) throw new Error(`--chain <file> \u2014 no file at '${file}'`);
37158
+ const parsed = JSON.parse(readFileSync15(file, "utf8"));
36866
37159
  const links = Array.isArray(parsed) ? parsed : typeof parsed === "object" && parsed !== null && Array.isArray(parsed.certChain) ? parsed.certChain : void 0;
36867
37160
  if (links === void 0) {
36868
37161
  throw new Error(
@@ -36912,10 +37205,10 @@ function scarFromVerdict(verdict) {
36912
37205
  }
36913
37206
  function frameworkReceptionPath(here = moduleDirectory()) {
36914
37207
  const candidates = [
36915
- join18(here, "framework", "nomos.reception.mjs"),
36916
- resolve6(here, "../../cloud/cloudflare-shell/domains/build/nomos/nomos.reception.mjs")
37208
+ join19(here, "framework", "nomos.reception.mjs"),
37209
+ resolve7(here, "../../cloud/cloudflare-shell/domains/build/nomos/nomos.reception.mjs")
36917
37210
  ];
36918
- const found = candidates.find((candidate) => existsSync15(candidate));
37211
+ const found = candidates.find((candidate) => existsSync16(candidate));
36919
37212
  if (found === void 0) {
36920
37213
  throw new Error(
36921
37214
  "the framework controller's compiled Reception is missing \u2014 reinstall `githolon`, or compile it with `node dsl/compile_package.mjs domain_nomos.nomos.project.ts` in cloud/cloudflare-shell/domains"
@@ -36924,8 +37217,8 @@ function frameworkReceptionPath(here = moduleDirectory()) {
36924
37217
  return found;
36925
37218
  }
36926
37219
  async function encodeDirectiveCall(receptionPath, domain, directiveId, workspace, payload) {
36927
- const absolute = isAbsolute3(receptionPath) ? receptionPath : resolve6(process.cwd(), receptionPath);
36928
- if (!existsSync15(absolute)) throw new Error(`--reception <path> \u2014 no compiled Reception at '${absolute}'`);
37220
+ const absolute = isAbsolute3(receptionPath) ? receptionPath : resolve7(process.cwd(), receptionPath);
37221
+ if (!existsSync16(absolute)) throw new Error(`--reception <path> \u2014 no compiled Reception at '${absolute}'`);
36929
37222
  const module = await import(pathToFileURL3(absolute).href);
36930
37223
  const frameworkCalls = module["nomosFrameworkCalls"];
36931
37224
  if (typeof frameworkCalls === "object" && frameworkCalls !== null) {
@@ -36990,7 +37283,7 @@ async function encodeDirectiveCall(receptionPath, domain, directiveId, workspace
36990
37283
  return captured;
36991
37284
  }
36992
37285
  function readPayload2(opts) {
36993
- const text2 = opts.payloadFile !== void 0 ? readFileSync14(opts.payloadFile, "utf8") : opts.payload;
37286
+ const text2 = opts.payloadFile !== void 0 ? readFileSync15(opts.payloadFile, "utf8") : opts.payload;
36994
37287
  if (text2 === void 0) throw new Error("pass the directive's payload with --payload <json> or --payload-file <file>");
36995
37288
  const parsed = JSON.parse(text2);
36996
37289
  if (typeof parsed !== "object" || parsed === null || Array.isArray(parsed)) {
@@ -37204,7 +37497,7 @@ var init_custodian = __esm({
37204
37497
  [/forged-principal|ForgedPrincipal|VERIFIED author/i, "ForgedPrincipal"],
37205
37498
  [/bad-signature|BadSignature/i, "BadSignature"]
37206
37499
  ];
37207
- moduleDirectory = () => dirname5(fileURLToPath3(import.meta.url));
37500
+ moduleDirectory = () => dirname6(fileURLToPath4(import.meta.url));
37208
37501
  CapturedCall = class extends Error {
37209
37502
  constructor() {
37210
37503
  super("call captured");
@@ -37330,9 +37623,9 @@ Options
37330
37623
  });
37331
37624
 
37332
37625
  // src/cli.ts
37333
- import { existsSync as existsSync16, readFileSync as readFileSync15 } from "node:fs";
37334
- import { dirname as dirname6, join as join19, resolve as resolve7 } from "node:path";
37335
- import { pathToFileURL as pathToFileURL4, fileURLToPath as fileURLToPath4 } from "node:url";
37626
+ import { existsSync as existsSync17, readFileSync as readFileSync16 } from "node:fs";
37627
+ import { dirname as dirname7, join as join20, resolve as resolve8 } from "node:path";
37628
+ import { pathToFileURL as pathToFileURL4, fileURLToPath as fileURLToPath5 } from "node:url";
37336
37629
 
37337
37630
  // src/generate.ts
37338
37631
  import { mkdirSync, existsSync, writeFileSync } from "node:fs";
@@ -37844,6 +38137,8 @@ var USAGE2 = `githolon \u2014 model a business; Nomos owns the compute science
37844
38137
  Start here:
37845
38138
  githolon compile compile aggregates, birth, directives, and reads into law + a typed client
37846
38139
  githolon test run generated Dart scenarios with real local custody
38140
+ githolon conformance check the installed stack with an isolated generated application
38141
+ githolon inspect-release inspect identity continuity and compiled/installed units (read-only)
37847
38142
  githolon check explain anything the law can already prove it would refuse
37848
38143
 
37849
38144
  The application surface is one idea:
@@ -38038,6 +38333,7 @@ async function main(argv) {
38038
38333
  if (argv[0] === "compile") {
38039
38334
  return runCompileCommand(argv.slice(1));
38040
38335
  }
38336
+ if (argv[0] === "inspect-release") return runInspectRelease(argv.slice(1));
38041
38337
  if (argv[0] === "check") {
38042
38338
  return runCheck(argv.slice(1));
38043
38339
  }
@@ -38052,6 +38348,9 @@ async function main(argv) {
38052
38348
  const { initEditor: initEditor2 } = await Promise.resolve().then(() => (init_editor(), editor_exports));
38053
38349
  return initEditor2(process.cwd());
38054
38350
  }
38351
+ if (argv[0] === "conformance") {
38352
+ return (await Promise.resolve().then(() => (init_conformance(), conformance_exports))).runConformance(argv.slice(1));
38353
+ }
38055
38354
  if (argv[0] === "test") {
38056
38355
  const { runDartTests: runDartTests2 } = await Promise.resolve().then(() => (init_test(), test_exports));
38057
38356
  return runDartTests2(argv.slice(1));
@@ -38075,18 +38374,18 @@ async function main(argv) {
38075
38374
  ${commandHelp("cloud") ?? USAGE2}`);
38076
38375
  return 1;
38077
38376
  }
38078
- const { spawnSync: spawnSync6 } = await import("node:child_process");
38079
- const here = dirname6(fileURLToPath4(import.meta.url));
38377
+ const { spawnSync: spawnSync7 } = await import("node:child_process");
38378
+ const here = dirname7(fileURLToPath5(import.meta.url));
38080
38379
  const candidates = [
38081
- resolve7(here, "dev-server.mjs")
38380
+ resolve8(here, "dev-server.mjs")
38082
38381
  // published: dist/dev-server.mjs
38083
38382
  ];
38084
- const serverPath = candidates.find((p) => existsSync16(p));
38383
+ const serverPath = candidates.find((p) => existsSync17(p));
38085
38384
  if (!serverPath) {
38086
38385
  process.stderr.write("error: dev-server not found \u2014 reinstall `githolon` or run `npm run build` in the cli package\n");
38087
38386
  return 1;
38088
38387
  }
38089
- const r = spawnSync6(process.execPath, [serverPath, ...argv.slice(2)], { stdio: "inherit" });
38388
+ const r = spawnSync7(process.execPath, [serverPath, ...argv.slice(2)], { stdio: "inherit" });
38090
38389
  return r.status ?? 0;
38091
38390
  }
38092
38391
  if (argv[0] === "status") {