archctx 0.6.0 → 0.6.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "schemaVersion": "archcontext.practice-catalog-manifest/v1",
3
3
  "catalogVersion": "2026.06.0",
4
- "productVersion": "0.6.0",
4
+ "productVersion": "0.6.1",
5
5
  "generatedAt": "1970-01-01T00:00:00.000Z",
6
6
  "entries": [
7
7
  {
@@ -389,5 +389,5 @@
389
389
  "structurizr.dsl",
390
390
  "twelve-factor"
391
391
  ],
392
- "catalogDigest": "sha256:d284e2b877e9db3f5a579325cdf1a5f57b2891778a81b3b6a580f80c4ff456e7"
392
+ "catalogDigest": "sha256:ebfdab809c0fa136197717d3d7190648fa60b779f193d05434dc7812a414474d"
393
393
  }
package/bin/archctx.mjs CHANGED
@@ -1,38 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  // @bun
3
3
  import { createRequire } from "node:module";
4
- var __create = Object.create;
5
- var __getProtoOf = Object.getPrototypeOf;
6
4
  var __defProp = Object.defineProperty;
7
- var __getOwnPropNames = Object.getOwnPropertyNames;
8
- var __hasOwnProp = Object.prototype.hasOwnProperty;
9
- function __accessProp(key) {
10
- return this[key];
11
- }
12
- var __toESMCache_node;
13
- var __toESMCache_esm;
14
- var __toESM = (mod, isNodeMode, target) => {
15
- var canCache = mod != null && typeof mod === "object";
16
- if (canCache) {
17
- var cache = isNodeMode ? __toESMCache_node ??= new WeakMap : __toESMCache_esm ??= new WeakMap;
18
- var cached = cache.get(mod);
19
- if (cached)
20
- return cached;
21
- }
22
- target = mod != null ? __create(__getProtoOf(mod)) : {};
23
- const to = isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target;
24
- if (mod && typeof mod === "object" || typeof mod === "function") {
25
- for (let key of __getOwnPropNames(mod))
26
- if (!__hasOwnProp.call(to, key))
27
- __defProp(to, key, {
28
- get: __accessProp.bind(mod, key),
29
- enumerable: true
30
- });
31
- }
32
- if (canCache)
33
- cache.set(mod, to);
34
- return to;
35
- };
36
5
  var __commonJS = (cb, mod) => () => (mod || cb((mod = { exports: {} }).exports, mod), mod.exports);
37
6
  var __returnValue = (v) => v;
38
7
  function __exportSetter(name, newValue) {
@@ -1356,13 +1325,13 @@ function productVersionManifest() {
1356
1325
  sqliteMigrations: "0001_runtime_state..0012_explorer_projection_index",
1357
1326
  codeGraph: {
1358
1327
  packageName: "@colbymchenry/codegraph",
1359
- requiredVersion: "1.5.0",
1328
+ requiredVersion: "1.6.1",
1360
1329
  adapter: "codegraph-cli"
1361
1330
  }
1362
1331
  }
1363
1332
  };
1364
1333
  }
1365
- var ARCHCONTEXT_PRODUCT_NAME = "archctx", ARCHCONTEXT_PRODUCT_VERSION = "0.6.0", ARCHCONTEXT_PACKAGE_MANAGER = "bun@1.4.0", ARCHCONTEXT_NODE_RANGE = ">=22.22 <26", LOCAL_RUNTIME_RPC_SCHEMA_VERSION = "archcontext.runtime-rpc/v1", ARCHCONTEXT_SCHEMA_SET_VERSION = "2026-07-11.explorer-view-v2";
1334
+ var ARCHCONTEXT_PRODUCT_NAME = "archctx", ARCHCONTEXT_PRODUCT_VERSION = "0.6.1", ARCHCONTEXT_PACKAGE_MANAGER = "bun@1.4.0", ARCHCONTEXT_NODE_RANGE = ">=22.22 <26", LOCAL_RUNTIME_RPC_SCHEMA_VERSION = "archcontext.runtime-rpc/v1", ARCHCONTEXT_SCHEMA_SET_VERSION = "2026-07-11.explorer-view-v2";
1366
1335
 
1367
1336
  // packages/contracts/src/refactor.ts
1368
1337
  function refactorProposalDigest(proposal) {
@@ -2111,42 +2080,6 @@ var init_src = __esm(() => {
2111
2080
  init_validator();
2112
2081
  });
2113
2082
 
2114
- // node_modules/.bun/@colbymchenry+codegraph@1.5.0/node_modules/@colbymchenry/codegraph/npm-sdk.js
2115
- var require_npm_sdk = __commonJS(function(exports, module) {
2116
- var __dirname = "/Users/chris/Projects/arch-context-publish-0600/node_modules/.bun/@colbymchenry+codegraph@1.5.0/node_modules/@colbymchenry/codegraph";
2117
- var path = __require("path");
2118
- var os = __require("os");
2119
- var fs = __require("fs");
2120
- var target = process.platform + "-" + process.arch;
2121
- var pkg = "@colbymchenry/codegraph-" + target;
2122
- module.exports = __require(resolveLibrary());
2123
- function resolveLibrary() {
2124
- try {
2125
- return __require.resolve(pkg + "/lib/dist/index.js");
2126
- } catch (e) {}
2127
- var cached = cachedLibrary();
2128
- if (cached)
2129
- return cached;
2130
- throw new Error(`codegraph: the programmatic API is unavailable because the platform bundle
2131
- ` + "(" + pkg + `) is not installed.
2132
- ` + `The compiled library ships inside that per-platform optional dependency.
2133
- ` + `Fixes:
2134
- ` + ` - install from the official npm registry so the matching bundle is fetched:
2135
- ` + ` npm i @colbymchenry/codegraph --registry=https://registry.npmjs.org
2136
- ` + " - or run the CLI once (e.g. `npx @colbymchenry/codegraph status`) to\n" + " self-heal the bundle into ~/.codegraph, then require() will find it.");
2137
- }
2138
- function cachedLibrary() {
2139
- try {
2140
- var version = __require(path.join(__dirname, "package.json")).version;
2141
- var base = process.env.CODEGRAPH_INSTALL_DIR || path.join(os.homedir(), ".codegraph");
2142
- var lib = path.join(base, "bundles", target + "-" + version, "lib", "dist", "index.js");
2143
- if (fs.existsSync(lib))
2144
- return lib;
2145
- } catch (e) {}
2146
- return null;
2147
- }
2148
- });
2149
-
2150
2083
  // node_modules/.bun/yaml@2.9.1/node_modules/yaml/dist/nodes/identity.js
2151
2084
  var require_identity = __commonJS(function(exports) {
2152
2085
  var ALIAS = Symbol.for("yaml.alias");
@@ -11351,9 +11284,9 @@ class ControlPlane {
11351
11284
  rollback: "versioned-cloud-metadata-release"
11352
11285
  };
11353
11286
  }
11354
- rollbackChatGptRelease(version2) {
11355
- this.releaseRollbacks.push(version2);
11356
- return { rolledBack: true, version: version2 };
11287
+ rollbackChatGptRelease(version) {
11288
+ this.releaseRollbacks.push(version);
11289
+ return { rolledBack: true, version };
11357
11290
  }
11358
11291
  redactLog(value) {
11359
11292
  return value.replace(/(access|refresh|secret|token)_[a-zA-Z0-9_-]+/g, "[REDACTED]");
@@ -13550,11 +13483,10 @@ function withLocalEgress2(channel, operation, env = process.env) {
13550
13483
  }
13551
13484
 
13552
13485
  // packages/local-runtime/codegraph-adapter/src/index.ts
13553
- var import_codegraph = __toESM(require_npm_sdk(), 1);
13554
13486
  import { execFileSync as execFileSync2 } from "node:child_process";
13555
13487
  import { createHash as createHash5 } from "node:crypto";
13556
13488
  import { accessSync, closeSync as closeSync3, constants as fsConstants2, existsSync as existsSync6, openSync as openSync3, readFileSync as readFileSync7, readSync, realpathSync as realpathSync4, statSync as statSync3 } from "node:fs";
13557
- import { createRequire as createRequire4 } from "node:module";
13489
+ import { createRequire as createRequire2 } from "node:module";
13558
13490
  import { basename as basename3, delimiter, dirname as dirname4, isAbsolute as isAbsolute4, join as join4, posix as posix2, resolve as resolve8 } from "node:path";
13559
13491
 
13560
13492
  // packages/core/architecture-delta/src/index.ts
@@ -15314,401 +15246,7 @@ function evaluateChangeSetPaths(root, paths, scope) {
15314
15246
  init_src();
15315
15247
  import { chmodSync as chmodSync2, closeSync, constants as fsConstants, fstatSync, fsyncSync, linkSync, mkdirSync as mkdirSync2, openSync, readFileSync as readFileSync3, renameSync, rmSync as rmSync2, statSync as statSync2, writeFileSync as writeFileSync2 } from "node:fs";
15316
15248
  import { dirname as dirname2, join as join3, resolve as resolve4 } from "node:path";
15317
-
15318
- // node_modules/.bun/koffi@3.1.6/node_modules/koffi/src/koffi/index.js
15319
- import util from "node:util";
15320
- import fs2 from "node:fs";
15321
- import { createRequire as createRequire3 } from "node:module";
15322
- import fs from "node:fs";
15323
-
15324
- // node_modules/.bun/koffi@3.1.6/node_modules/koffi/src/koffi/src/static.js
15325
- import { createRequire as createRequire2 } from "node:module";
15326
- var require2 = createRequire2(import.meta.url);
15327
- function loadStatic(pkg) {
15328
- let native = null;
15329
- if (pkg == "linux-arm64") {
15330
- try {
15331
- native = require2("@koromix/koffi-linux-arm64");
15332
- } catch (err) {}
15333
- }
15334
- if (pkg == "linux-ia32") {
15335
- try {
15336
- native = require2("@koromix/koffi-linux-ia32");
15337
- } catch (err) {}
15338
- }
15339
- if (pkg == "linux-x64") {
15340
- try {
15341
- native = require2("@koromix/koffi-linux-x64");
15342
- } catch (err) {}
15343
- }
15344
- if (pkg == "linux-riscv64") {
15345
- try {
15346
- native = require2("@koromix/koffi-linux-riscv64");
15347
- } catch (err) {}
15348
- }
15349
- if (pkg == "freebsd-ia32") {
15350
- try {
15351
- native = require2("@koromix/koffi-freebsd-ia32");
15352
- } catch (err) {}
15353
- }
15354
- if (pkg == "freebsd-x64") {
15355
- try {
15356
- native = require2("@koromix/koffi-freebsd-x64");
15357
- } catch (err) {}
15358
- }
15359
- if (pkg == "freebsd-arm64") {
15360
- try {
15361
- native = require2("@koromix/koffi-freebsd-arm64");
15362
- } catch (err) {}
15363
- }
15364
- if (pkg == "openbsd-ia32") {
15365
- try {
15366
- native = require2("@koromix/koffi-openbsd-ia32");
15367
- } catch (err) {}
15368
- }
15369
- if (pkg == "openbsd-x64") {
15370
- try {
15371
- native = require2("@koromix/koffi-openbsd-x64");
15372
- } catch (err) {}
15373
- }
15374
- if (pkg == "win32-ia32") {
15375
- try {
15376
- native = require2("@koromix/koffi-win32-ia32");
15377
- } catch (err) {}
15378
- }
15379
- if (pkg == "win32-x64") {
15380
- try {
15381
- native = require2("@koromix/koffi-win32-x64");
15382
- } catch (err) {}
15383
- }
15384
- if (pkg == "win32-arm64") {
15385
- try {
15386
- native = require2("@koromix/koffi-win32-arm64");
15387
- } catch (err) {}
15388
- }
15389
- if (pkg == "darwin-x64") {
15390
- try {
15391
- native = require2("@koromix/koffi-darwin-x64");
15392
- } catch (err) {}
15393
- }
15394
- if (pkg == "darwin-arm64") {
15395
- try {
15396
- native = require2("@koromix/koffi-darwin-arm64");
15397
- } catch (err) {}
15398
- }
15399
- if (pkg == "linux-loong64") {
15400
- try {
15401
- native = require2("@koromix/koffi-linux-loong64");
15402
- } catch (err) {}
15403
- }
15404
- return native;
15405
- }
15406
-
15407
- // node_modules/.bun/koffi@3.1.6/node_modules/koffi/src/koffi/index.js
15408
- var __knownSymbol = (name, symbol) => (symbol = Symbol[name]) ? symbol : /* @__PURE__ */ Symbol.for("Symbol." + name);
15409
- var __typeError = (msg) => {
15410
- throw TypeError(msg);
15411
- };
15412
- var __using = (stack, value, async) => {
15413
- if (value != null) {
15414
- if (typeof value !== "object" && typeof value !== "function")
15415
- __typeError("Object expected");
15416
- var dispose, inner;
15417
- if (async)
15418
- dispose = value[__knownSymbol("asyncDispose")];
15419
- if (dispose === undefined) {
15420
- dispose = value[__knownSymbol("dispose")];
15421
- if (async)
15422
- inner = dispose;
15423
- }
15424
- if (typeof dispose !== "function")
15425
- __typeError("Object not disposable");
15426
- if (inner)
15427
- dispose = function() {
15428
- try {
15429
- inner.call(this);
15430
- } catch (e) {
15431
- return Promise.reject(e);
15432
- }
15433
- };
15434
- stack.push([async, dispose, value]);
15435
- } else if (async) {
15436
- stack.push([async]);
15437
- }
15438
- return value;
15439
- };
15440
- var __callDispose = (stack, error, hasError) => {
15441
- var E = typeof SuppressedError === "function" ? SuppressedError : function(e, s, m, _) {
15442
- return _ = Error(m), _.name = "SuppressedError", _.error = e, _.suppressed = s, _;
15443
- };
15444
- var fail = (e) => error = hasError ? new E(e, error, "An error was suppressed during disposal") : (hasError = true, e);
15445
- var next = (it) => {
15446
- while (it = stack.pop()) {
15447
- try {
15448
- var result = it[1] && it[1].call(it[2]);
15449
- if (it[0])
15450
- return Promise.resolve(result).then(next, (e) => (fail(e), next()));
15451
- } catch (e) {
15452
- fail(e);
15453
- }
15454
- }
15455
- if (hasError)
15456
- throw error;
15457
- };
15458
- return next();
15459
- };
15460
- function determineAbi() {
15461
- let abi = process.arch.toString();
15462
- if (abi == "riscv32" || abi == "riscv64") {
15463
- var _stack = [];
15464
- try {
15465
- const file = __using(_stack, openFile(process.execPath, "r"));
15466
- let header = readElfHeader(file);
15467
- let float_abi = header.e_flags & 6;
15468
- switch (float_abi) {
15469
- case 0:
15470
- {}
15471
- break;
15472
- case 2:
15473
- {
15474
- abi += "f";
15475
- }
15476
- break;
15477
- case 4:
15478
- {
15479
- abi += "d";
15480
- }
15481
- break;
15482
- case 6:
15483
- {
15484
- abi += "q";
15485
- }
15486
- break;
15487
- }
15488
- } catch (_) {
15489
- var _error = _, _hasError = true;
15490
- } finally {
15491
- __callDispose(_stack, _error, _hasError);
15492
- }
15493
- } else if (abi == "arm") {
15494
- var _stack2 = [];
15495
- try {
15496
- const file = __using(_stack2, openFile(process.execPath, "r"));
15497
- let header = readElfHeader(file);
15498
- if (header.e_flags & 1024) {
15499
- abi += "hf";
15500
- } else if (header.e_flags & 512) {
15501
- abi += "sf";
15502
- } else {
15503
- throw new Error("Unknown ARM floating-point ABI");
15504
- }
15505
- } catch (_2) {
15506
- var _error2 = _2, _hasError2 = true;
15507
- } finally {
15508
- __callDispose(_stack2, _error2, _hasError2);
15509
- }
15510
- }
15511
- return abi;
15512
- }
15513
- function readElfHeader(file, offset = 0) {
15514
- let buf = file.read(offset, 512);
15515
- if (buf.length < 16)
15516
- throw new Error("Truncated header");
15517
- if (buf[0] != 127 || buf[1] != 69 || buf[2] != 76 || buf[3] != 70)
15518
- throw new Error("Invalid magic number");
15519
- if (buf[6] != 1)
15520
- throw new Error("Invalid ELF version");
15521
- if (buf[5] != 1)
15522
- throw new Error("Big-endian architectures are not supported");
15523
- switch (buf[4]) {
15524
- case 1:
15525
- {
15526
- if (buf.length < 68)
15527
- throw new Error("Truncated ELF header");
15528
- return {
15529
- ei_class: 32,
15530
- e_machine: buf.readUInt16LE(18),
15531
- e_flags: buf.readUInt32LE(36),
15532
- e_phoff: buf.readUInt32LE(28),
15533
- e_phentsize: buf.readUInt16LE(42),
15534
- e_phnum: buf.readUInt16LE(44)
15535
- };
15536
- }
15537
- break;
15538
- case 2:
15539
- {
15540
- if (buf.length < 120)
15541
- throw new Error("Truncated ELF header");
15542
- return {
15543
- ei_class: 64,
15544
- e_machine: buf.readUInt16LE(18),
15545
- e_flags: buf.readUInt32LE(48),
15546
- e_phoff: buf.readBigUInt64LE(32),
15547
- e_phentsize: buf.readUInt16LE(54),
15548
- e_phnum: buf.readUInt16LE(56)
15549
- };
15550
- }
15551
- break;
15552
- default:
15553
- throw new Error("Invalid ELF class");
15554
- }
15555
- }
15556
- function openFile(filename, flags) {
15557
- let fd = fs.openSync(filename, flags);
15558
- return new FileHandle(fd);
15559
- }
15560
- var FileHandle = class {
15561
- constructor(fd) {
15562
- this.fd = fd;
15563
- }
15564
- close() {
15565
- fs.closeSync(this.fd);
15566
- }
15567
- [Symbol.dispose]() {
15568
- fs.closeSync(this.fd);
15569
- }
15570
- read(offset, len) {
15571
- let buf = Buffer.allocUnsafe(len);
15572
- let read = fs.readSync(this.fd, buf, 0, len, offset);
15573
- return buf.subarray(0, read);
15574
- }
15575
- };
15576
- var package_default = { name: "koffi", version: "3.1.6", cnoke: { api: "../../vendor/node-api-headers", output: "../../bin/Koffi/{{ toolchain }}", node: 16, napi: 8 } };
15577
- var require22 = createRequire3(import.meta.url);
15578
- function detectPlatform() {
15579
- if (process.versions.napi == null || process.versions.napi < package_default.cnoke.napi) {
15580
- let major = parseInt(process.versions.node, 10);
15581
- throw new Error(`This engine is based on Node ${process.versions.node}, but ${package_default.name} does not support the Node ${major}.x branch (Node-API < ${package_default.cnoke.napi})`);
15582
- }
15583
- let abi = determineAbi();
15584
- let pkg2 = `${process.platform}-${process.arch}`;
15585
- let triplets2 = [`${process.platform}_${abi}`];
15586
- if (process.platform == "linux")
15587
- triplets2.push(`musl_${abi}`);
15588
- return [package_default.version, pkg2, triplets2];
15589
- }
15590
- function loadDynamic(dirname2, pkg2, triplets2) {
15591
- let suffix = "/../../build/koffi";
15592
- let root = dirname2 + suffix;
15593
- let roots = [root];
15594
- let native2 = null;
15595
- let err = null;
15596
- if (process["resourcesPath"] != null) {
15597
- let suffixes = [
15598
- "/koffi",
15599
- "/koffi/build",
15600
- "/node_modules/koffi/build"
15601
- ];
15602
- for (let suffix2 of suffixes)
15603
- roots.push(process["resourcesPath"] + suffix2);
15604
- }
15605
- let names = [
15606
- `${import.meta.dirname}/../../../@koromix/koffi-${pkg2}`,
15607
- ...triplets2.flatMap((triplet) => roots.map((dir) => `${dir}/${triplet}/koffi.node`))
15608
- ];
15609
- for (let name of names) {
15610
- if (!fs2.existsSync(name))
15611
- continue;
15612
- try {
15613
- native2 = require22(name);
15614
- break;
15615
- } catch (e) {
15616
- err ??= e;
15617
- }
15618
- }
15619
- if (native2 == null && err != null)
15620
- throw err;
15621
- return native2;
15622
- }
15623
- function wrapNative(native2, version2) {
15624
- if (native2 == null)
15625
- throw new Error("Cannot find the native Koffi module; did you bundle it correctly?");
15626
- if (native2.version != version2)
15627
- throw new Error("Mismatched native Koffi modules");
15628
- let load = native2.load;
15629
- let register = native2.register;
15630
- let introspect = native2.introspect ?? native2.type;
15631
- native2.sizeof = (spec) => introspect(spec).size;
15632
- native2.alignof = (spec) => introspect(spec).alignment;
15633
- native2.offsetof = (spec, name) => {
15634
- let info = introspect(spec);
15635
- if (info.primitive != "Record")
15636
- throw new TypeError("The offsetof() function can only be used with record types");
15637
- let member = info.members[name];
15638
- if (member == null)
15639
- throw new Error(`Record type ${info.name} does not have member '${name}'`);
15640
- return member.offset;
15641
- };
15642
- native2.register = (...args) => {
15643
- if (args.length >= 3 && typeof args[1] == "function") {
15644
- process.emitWarning("Using koffi.register() with a custom this value was deprecated in Koffi 2.17, use function.bind() instead", "DeprecationWarning", "KOFFI009");
15645
- args[1] = args[1].bind(args[0]);
15646
- args = args.slice(1);
15647
- }
15648
- return register(...args);
15649
- };
15650
- native2.load = (...args) => {
15651
- let lib = load(...args);
15652
- lib.cdecl = util.deprecate((...args2) => lib.func("__cdecl", ...args2), "The koffi.cdecl() function was deprecated in Koffi 2.7, use koffi.func(...) instead", "KOFFI003");
15653
- lib.stdcall = util.deprecate((...args2) => lib.func("__stdcall", ...args2), 'The koffi.stdcall() function was deprecated in Koffi 2.7, use koffi.func("__stdcall", ...) instead', "KOFFI004");
15654
- lib.fastcall = util.deprecate((...args2) => lib.func("__fastcall", ...args2), 'The koffi.fastcall() function was deprecated in Koffi 2.7, use koffi.func("__fastcall", ...) instead', "KOFFI005");
15655
- lib.thiscall = util.deprecate((...args2) => lib.func("__thiscall", ...args2), 'The koffi.thiscall() function was deprecated in Koffi 2.7, use koffi.func("__thiscall", ...) instead', "KOFFI006");
15656
- return lib;
15657
- };
15658
- if (native2.introspect == null) {
15659
- native2.resolve = util.deprecate(native2.type, "The koffi.resolve() function was deprecated in Koffi 3.0, use koffi.type() instead", "KOFFI007");
15660
- native2.introspect = util.deprecate(native2.type, "The koffi.introspect() function was deprecated in Koffi 3.0, use koffi.type() instead", "KOFFI008");
15661
- } else {
15662
- native2.resolve = native2.type;
15663
- }
15664
- }
15665
- var [version, pkg, triplets] = detectPlatform();
15666
- var native = loadStatic(pkg) ?? loadDynamic(import.meta.dirname, pkg, triplets);
15667
- wrapNative(native, version);
15668
- var mod_LibraryHandle = native.LibraryHandle;
15669
- var mod_TypeObject = native.TypeObject;
15670
- var mod_Union = native.Union;
15671
- var mod_address = native.address;
15672
- var mod_alias = native.alias;
15673
- var mod_alignof = native.alignof;
15674
- var mod_alloc = native.alloc;
15675
- var mod_array = native.array;
15676
- var mod_as = native.as;
15677
- var mod_call = native.call;
15678
- var mod_config = native.config;
15679
- var mod_decode = native.decode;
15680
- var mod_disposable = native.disposable;
15681
- var mod_encode = native.encode;
15682
- var mod_enumeration = native.enumeration;
15683
- var mod_errno = native.errno;
15684
- var mod_extension = native.extension;
15685
- var mod_free = native.free;
15686
- var mod_in = native.in;
15687
- var mod_inout = native.inout;
15688
- var mod_introspect = native.introspect;
15689
- var mod_load = native.load;
15690
- var mod_node = native.node;
15691
- var mod_offsetof = native.offsetof;
15692
- var mod_opaque = native.opaque;
15693
- var mod_os = native.os;
15694
- var mod_out = native.out;
15695
- var mod_pack = native.pack;
15696
- var mod_pointer = native.pointer;
15697
- var mod_proto = native.proto;
15698
- var mod_register = native.register;
15699
- var mod_reset = native.reset;
15700
- var mod_resolve = native.resolve;
15701
- var mod_sizeof = native.sizeof;
15702
- var mod_stats = native.stats;
15703
- var mod_struct = native.struct;
15704
- var mod_type = native.type;
15705
- var mod_types = native.types;
15706
- var mod_union = native.union;
15707
- var mod_unregister = native.unregister;
15708
- var mod_version = native.version;
15709
- var mod_view = native.view;
15710
- var index_default = native;
15711
- // packages/core/changeset-engine/src/descriptor-relative-write.ts
15249
+ import koffi from "koffi";
15712
15250
  var beforeCommitTestHook;
15713
15251
  var POSIX_FLAGS = {
15714
15252
  darwin: {
@@ -15748,7 +15286,7 @@ function descriptorRelativeWrite(request) {
15748
15286
  writeWithPosixDirectoryDescriptor(request, flags);
15749
15287
  }
15750
15288
  function writeWithPosixDirectoryDescriptor(request, flags) {
15751
- const libc = index_default.load(null);
15289
+ const libc = koffi.load(null);
15752
15290
  const open = libc.func("open", "int", ["str", "int"]);
15753
15291
  const openat = libc.func("openat", "int", ["int", "str", "int", "uint"]);
15754
15292
  const mkdirat = libc.func("mkdirat", "int", ["int", "str", "uint"]);
@@ -15760,7 +15298,7 @@ function writeWithPosixDirectoryDescriptor(request, flags) {
15760
15298
  const linkat = libc.func("linkat", "int", ["int", "str", "int", "str", "int"]);
15761
15299
  const unlinkat = libc.func("unlinkat", "int", ["int", "str", "int"]);
15762
15300
  const close = libc.func("close", "int", ["int"]);
15763
- const errno = index_default.os.errno;
15301
+ const errno = koffi.os.errno;
15764
15302
  const segments = request.path.split(/[\\/]/u);
15765
15303
  const leaf = segments.pop();
15766
15304
  if (!leaf || segments.some((segment) => !segment || segment === "." || segment === "..")) {
@@ -15771,7 +15309,7 @@ function writeWithPosixDirectoryDescriptor(request, flags) {
15771
15309
  try {
15772
15310
  for (const segment of segments) {
15773
15311
  let nextFd = openat(directoryFd, segment, flags.readOnly | flags.directory | flags.noFollow | flags.closeOnExec, 0);
15774
- if (nextFd < 0 && index_default.errno() === errno.ENOENT) {
15312
+ if (nextFd < 0 && koffi.errno() === errno.ENOENT) {
15775
15313
  checkedResult(mkdirat(directoryFd, segment, 511), `mkdirat ${segment}`);
15776
15314
  nextFd = openat(directoryFd, segment, flags.readOnly | flags.directory | flags.noFollow | flags.closeOnExec, 0);
15777
15315
  }
@@ -15794,7 +15332,7 @@ function writeWithPosixDirectoryDescriptor(request, flags) {
15794
15332
  }
15795
15333
  if (request.expectedHash === "missing") {
15796
15334
  if (linkat(directoryFd, request.tempName, directoryFd, leaf, 0) < 0) {
15797
- if (index_default.errno() === index_default.os.errno.EEXIST)
15335
+ if (koffi.errno() === koffi.os.errno.EEXIST)
15798
15336
  throw new Error(`Expected hash mismatch: ${leaf}`);
15799
15337
  throw posixError(`linkat ${leaf}`);
15800
15338
  }
@@ -15820,9 +15358,9 @@ function assertPinnedParentVisible(request, pinnedParent) {
15820
15358
  function assertExpectedHashAt(directoryFd, leaf, expectedHash, flags, openat, read, close) {
15821
15359
  const fd = openat(directoryFd, leaf, flags.readOnly | flags.noFollow | flags.closeOnExec, 0);
15822
15360
  if (fd < 0) {
15823
- if (index_default.errno() === index_default.os.errno.ENOENT && expectedHash === "missing")
15361
+ if (koffi.errno() === koffi.os.errno.ENOENT && expectedHash === "missing")
15824
15362
  return;
15825
- if (index_default.errno() === index_default.os.errno.ENOENT)
15363
+ if (koffi.errno() === koffi.os.errno.ENOENT)
15826
15364
  throw new Error(`Expected missing file hash for new path: ${leaf}`);
15827
15365
  throw posixError(`openat destination ${leaf}`);
15828
15366
  }
@@ -15865,17 +15403,17 @@ function checkedResult(result, action) {
15865
15403
  throw posixError(action);
15866
15404
  }
15867
15405
  function posixError(action) {
15868
- return new Error(`${action} failed with errno ${index_default.errno()}`);
15406
+ return new Error(`${action} failed with errno ${koffi.errno()}`);
15869
15407
  }
15870
15408
  function writeWithLockedWindowsParents(request) {
15871
- const kernel32 = index_default.load("kernel32.dll");
15409
+ const kernel32 = koffi.load("kernel32.dll");
15872
15410
  const createFileW = kernel32.func("CreateFileW", "void *", ["str16", "uint32", "uint32", "void *", "uint32", "uint32", "void *"]);
15873
15411
  const closeHandle = kernel32.func("CloseHandle", "int", ["void *"]);
15874
- const attributeTagInfo = index_default.struct({ FileAttributes: "uint32", ReparseTag: "uint32" });
15412
+ const attributeTagInfo = koffi.struct({ FileAttributes: "uint32", ReparseTag: "uint32" });
15875
15413
  const getFileInformationByHandleEx = kernel32.func("GetFileInformationByHandleEx", "int", [
15876
15414
  "void *",
15877
15415
  "int",
15878
- index_default.out(index_default.pointer(attributeTagInfo)),
15416
+ koffi.out(koffi.pointer(attributeTagInfo)),
15879
15417
  "uint32"
15880
15418
  ]);
15881
15419
  const handles = [];
@@ -15902,11 +15440,11 @@ function writeWithLockedWindowsParents(request) {
15902
15440
  }
15903
15441
  }
15904
15442
  const handle = createFileW(current, FILE_READ_ATTRIBUTES, FILE_SHARE_READ_WRITE, null, OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS | (index === 0 ? 0 : FILE_FLAG_OPEN_REPARSE_POINT), null);
15905
- if (index_default.address(handle) === 0xffffffffffffffffn)
15443
+ if (koffi.address(handle) === 0xffffffffffffffffn)
15906
15444
  throw new Error(`CreateFileW failed for protected parent: ${current}`);
15907
15445
  handles.push(handle);
15908
15446
  const info = {};
15909
- if (!getFileInformationByHandleEx(handle, FILE_ATTRIBUTE_TAG_INFO, info, index_default.sizeof(attributeTagInfo))) {
15447
+ if (!getFileInformationByHandleEx(handle, FILE_ATTRIBUTE_TAG_INFO, info, koffi.sizeof(attributeTagInfo))) {
15910
15448
  throw new Error(`GetFileInformationByHandleEx failed for protected parent: ${current}`);
15911
15449
  }
15912
15450
  if (!(info.FileAttributes & FILE_ATTRIBUTE_DIRECTORY) || index > 0 && info.FileAttributes & FILE_ATTRIBUTE_REPARSE_POINT) {
@@ -19005,7 +18543,8 @@ var REQUIRED_CODEGRAPH_VERSION = productVersionManifest().runtime.codeGraph.requ
19005
18543
  var CODEGRAPH_TELEMETRY_ENV = "DO_NOT_TRACK";
19006
18544
  var CODEGRAPH_TELEMETRY_DISABLED_VALUE = "1";
19007
18545
  var DEFAULT_CODEGRAPH_BINARY = "codegraph";
19008
- var requireFromAdapter = createRequire4(import.meta.url);
18546
+ var requireFromAdapter = createRequire2(import.meta.url);
18547
+ var { CodeGraph } = requireFromAdapter(REQUIRED_CODEGRAPH_PACKAGE);
19009
18548
  var CODEGRAPH_OUTPUT_MAX_BYTES = 32 * 1024 * 1024;
19010
18549
  var CODEGRAPH_QUERY_TIMEOUT_MS = 30000;
19011
18550
  function disableCodeGraphTelemetryByDefault(env = process.env) {
@@ -19169,7 +18708,7 @@ function resolvePackagedCodeGraphShim() {
19169
18708
  function packagedCodeGraphRuntimeDigest() {
19170
18709
  try {
19171
18710
  const manifestPath = requireFromAdapter.resolve(`${REQUIRED_CODEGRAPH_PACKAGE}/package.json`);
19172
- const packageRequire = createRequire4(manifestPath);
18711
+ const packageRequire = createRequire2(manifestPath);
19173
18712
  const manifest = JSON.parse(readFileSync7(manifestPath, "utf8"));
19174
18713
  if (manifest.version !== REQUIRED_CODEGRAPH_VERSION || !manifest.bin?.codegraph) {
19175
18714
  throw new Error(`package manifest is not exact ${REQUIRED_CODEGRAPH_VERSION}`);
@@ -19735,7 +19274,7 @@ function loadCapabilityCodeGraphProjectionInputs(root, model, options = {}) {
19735
19274
  disableCodeGraphTelemetryByDefault();
19736
19275
  const binary = options.binary ?? DEFAULT_CODEGRAPH_BINARY;
19737
19276
  const importGraphs = footprints.length > 0 ? capabilityImportGraphs(root, binary, footprints, options.importNodeLimit ?? CODEGRAPH_IMPORT_NODE_QUERY_LIMIT) : [];
19738
- const selectorIndex = entrypointNodes.length > 0 ? options.selectorIndexFactory?.(root) ?? import_codegraph.CodeGraph.openSync(root) : undefined;
19277
+ const selectorIndex = entrypointNodes.length > 0 ? options.selectorIndexFactory?.(root) ?? CodeGraph.openSync(root) : undefined;
19739
19278
  let selectorEvidence;
19740
19279
  try {
19741
19280
  selectorEvidence = entrypointNodes.flatMap((entry) => entry.entrypoints.flatMap((entrypoint) => entrypoint.symbols.flatMap((source) => source.sinks.map((sink) => exactSelectorEvidence(selectorIndex, {
@@ -20167,8 +19706,8 @@ function assertContext7LibraryId(libraryId) {
20167
19706
  if (!LIBRARY_ID_PATTERN.test(libraryId))
20168
19707
  throw new Error("Context7 libraryId must be /owner/project and repo-pinned");
20169
19708
  }
20170
- function assertContext7Version(version2) {
20171
- if (!VERSION_PATTERN.test(version2))
19709
+ function assertContext7Version(version) {
19710
+ if (!VERSION_PATTERN.test(version))
20172
19711
  throw new Error("Context7 version must be an exact pinned version");
20173
19712
  }
20174
19713
  function buildExternalDocumentationResource(input) {
@@ -20223,7 +19762,7 @@ function projectLibraryCandidate(result) {
20223
19762
  id: result.id,
20224
19763
  title: result.title,
20225
19764
  ...result.description ? { description: cleanExternalText(result.description).slice(0, 240) } : {},
20226
- versions: [...new Set(result.versions ?? [])].filter((version2) => VERSION_PATTERN.test(version2)).sort(),
19765
+ versions: [...new Set(result.versions ?? [])].filter((version) => VERSION_PATTERN.test(version)).sort(),
20227
19766
  ...typeof result.trustScore === "number" ? { trustScore: result.trustScore } : {},
20228
19767
  ...typeof result.benchmarkScore === "number" ? { benchmarkScore: result.benchmarkScore } : {}
20229
19768
  };
@@ -22726,8 +22265,8 @@ function diagnostics(egress) {
22726
22265
  egress
22727
22266
  };
22728
22267
  }
22729
- function isSupportedNodeVersion(version2) {
22730
- const match = /^v?(\d+)\.(\d+)\.(\d+)$/.exec(version2);
22268
+ function isSupportedNodeVersion(version) {
22269
+ const match = /^v?(\d+)\.(\d+)\.(\d+)$/.exec(version);
22731
22270
  if (!match)
22732
22271
  return false;
22733
22272
  const major = Number(match[1]);
@@ -22970,7 +22509,7 @@ function isProcessAlive(pid) {
22970
22509
  // packages/local-runtime/local-store-sqlite/src/index.ts
22971
22510
  import { createHash as createHash8, randomUUID } from "node:crypto";
22972
22511
  import { chmodSync as chmodSync5, closeSync as closeSync6, copyFileSync, existsSync as existsSync9, fsyncSync as fsyncSync4, lstatSync as lstatSync4, mkdirSync as mkdirSync5, openSync as openSync6, readFileSync as readFileSync12, readSync as readSync2, realpathSync as realpathSync6, renameSync as renameSync4, rmSync as rmSync6, statfsSync, statSync as statSync6, writeFileSync as writeFileSync6 } from "node:fs";
22973
- import { createRequire as createRequire5 } from "node:module";
22512
+ import { createRequire as createRequire3 } from "node:module";
22974
22513
  import { dirname as dirname6, isAbsolute as isAbsolute6, join as join6, relative as relative7, resolve as resolve12 } from "node:path";
22975
22514
  init_src();
22976
22515
  // schemas/runtime/explorer-projection-v2.schema.json
@@ -23527,7 +23066,7 @@ var explorer_projection_v2_schema_default = {
23527
23066
  };
23528
23067
 
23529
23068
  // packages/local-runtime/local-store-sqlite/src/index.ts
23530
- var runtimeRequire = createRequire5(import.meta.url);
23069
+ var runtimeRequire = createRequire3(import.meta.url);
23531
23070
  var SQLITE_SIDECAR_SUFFIXES = ["", "-wal", "-shm"];
23532
23071
  var LEGACY_MIGRATION_MARKER_FILE = "runtime.sqlite.migration.json";
23533
23072
  var LEGACY_MIGRATION_LOCK_FILE = "runtime.sqlite.migration.lock";
@@ -30786,9 +30325,9 @@ function readExactPackageVersion(root, packageName) {
30786
30325
  return lockVersion;
30787
30326
  for (const manifestPath of packageManifestPaths(root)) {
30788
30327
  const manifest = readJsonFile(manifestPath);
30789
- const version2 = exactVersionFromManifest(manifest, packageName);
30790
- if (version2)
30791
- return version2;
30328
+ const version = exactVersionFromManifest(manifest, packageName);
30329
+ if (version)
30330
+ return version;
30792
30331
  }
30793
30332
  return;
30794
30333
  }
@@ -35338,10 +34877,10 @@ init_src();
35338
34877
  import { createHash as createHash9, randomUUID as randomUUID2 } from "node:crypto";
35339
34878
  import { chmodSync as chmodSync7, closeSync as closeSync7, copyFileSync as copyFileSync2, existsSync as existsSync19, fsyncSync as fsyncSync5, lstatSync as lstatSync9, mkdirSync as mkdirSync10, openSync as openSync8, readFileSync as readFileSync20, readSync as readSync3, realpathSync as realpathSync8, renameSync as renameSync5, rmSync as rmSync12, statfsSync as statfsSync2, statSync as statSync9, writeFileSync as writeFileSync8 } from "node:fs";
35340
34879
  import { readdir, readFile } from "node:fs/promises";
35341
- import { createRequire as createRequire6 } from "node:module";
34880
+ import { createRequire as createRequire4 } from "node:module";
35342
34881
  import { dirname as dirname12, isAbsolute as isAbsolute7, join as join12, relative as relative10, resolve as resolve21 } from "node:path";
35343
34882
  init_src();
35344
- var runtimeRequire2 = createRequire6(import.meta.url);
34883
+ var runtimeRequire2 = createRequire4(import.meta.url);
35345
34884
  var SQLITE_SIDECAR_SUFFIXES2 = ["", "-wal", "-shm"];
35346
34885
  var LEGACY_MIGRATION_MARKER_FILE2 = "runtime.sqlite.migration.json";
35347
34886
  var LEGACY_MIGRATION_LOCK_FILE2 = "runtime.sqlite.migration.lock";
@@ -46510,7 +46049,7 @@ function readCodeFacts(root, worktreeDigest, edgeLimit) {
46510
46049
  }
46511
46050
  function attestCodeGraphBinary(root) {
46512
46051
  const invocation = codeGraphCliInvocation(CODEGRAPH_BINARY, root);
46513
- const version2 = execFileSync9(invocation.command, [...invocation.argsPrefix, "--version"], {
46052
+ const version = execFileSync9(invocation.command, [...invocation.argsPrefix, "--version"], {
46514
46053
  cwd: root,
46515
46054
  encoding: "utf8",
46516
46055
  stdio: ["ignore", "pipe", "pipe"],
@@ -46518,7 +46057,7 @@ function attestCodeGraphBinary(root) {
46518
46057
  }).trim();
46519
46058
  const binaryPath = invocation.argsPrefix[0] ?? invocation.command;
46520
46059
  return {
46521
- version: version2,
46060
+ version,
46522
46061
  binaryDigest: `sha256:${createHash10("sha256").update(readFileSync24(binaryPath)).digest("hex")}`
46523
46062
  };
46524
46063
  }
@@ -50375,10 +49914,10 @@ class McpLocalServer {
50375
49914
  ...localResources,
50376
49915
  ...cacheEntries.filter((entry) => typeof entry.contentDigest === "string" && /^sha256:[0-9a-f]{64}$/.test(entry.contentDigest)).map((entry) => {
50377
49916
  const library = typeof entry.libraryId === "string" ? entry.libraryId : "context7";
50378
- const version2 = typeof entry.version === "string" ? entry.version : "unknown";
49917
+ const version = typeof entry.version === "string" ? entry.version : "unknown";
50379
49918
  return {
50380
49919
  uri: `archcontext://external-docs/context7/${entry.contentDigest}`,
50381
- name: `Context7 ${library}@${version2}`,
49920
+ name: `Context7 ${library}@${version}`,
50382
49921
  description: "Read-only external documentation resource from the local daemon cache.",
50383
49922
  mimeType: "application/json",
50384
49923
  annotations: { safety: "read-only" }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "archctx",
3
- "version": "0.6.0",
3
+ "version": "0.6.1",
4
4
  "description": "Local architecture context CLI for agentic coding workflows.",
5
5
  "private": false,
6
6
  "type": "module",
@@ -23,7 +23,7 @@
23
23
  "node": ">=22.22 <26"
24
24
  },
25
25
  "dependencies": {
26
- "@colbymchenry/codegraph": "1.5.0",
26
+ "@colbymchenry/codegraph": "1.6.1",
27
27
  "@node-rs/jieba": "^2.0.1",
28
28
  "koffi": "3.1.6"
29
29
  }
@@ -95,7 +95,7 @@
95
95
  "const": "@colbymchenry/codegraph"
96
96
  },
97
97
  "codeGraphVersion": {
98
- "const": "1.5.0"
98
+ "const": "1.6.1"
99
99
  },
100
100
  "codeGraphBinaryDigest": {
101
101
  "$ref": "#/$defs/digest"
@@ -911,7 +911,7 @@
911
911
  "const": "@colbymchenry/codegraph"
912
912
  },
913
913
  "codeGraphVersion": {
914
- "const": "1.5.0"
914
+ "const": "1.6.1"
915
915
  },
916
916
  "codeGraphBinaryDigest": {
917
917
  "$ref": "#/$defs/digest"
@@ -41,7 +41,7 @@
41
41
  "required": ["codeGraphPackage", "codeGraphVersion", "codeGraphBinaryDigest", "codeGraphStatus"],
42
42
  "properties": {
43
43
  "codeGraphPackage": { "const": "@colbymchenry/codegraph" },
44
- "codeGraphVersion": { "const": "1.5.0" },
44
+ "codeGraphVersion": { "const": "1.6.1" },
45
45
  "codeGraphBinaryDigest": { "$ref": "#/$defs/digest" },
46
46
  "codeGraphStatus": { "enum": ["ready", "unavailable"] }
47
47
  }
@@ -59,7 +59,7 @@
59
59
  "required": ["codeGraphPackage", "codeGraphVersion", "codeGraphBinaryDigest", "codeGraphStatus"],
60
60
  "properties": {
61
61
  "codeGraphPackage": { "const": "@colbymchenry/codegraph" },
62
- "codeGraphVersion": { "const": "1.5.0" },
62
+ "codeGraphVersion": { "const": "1.6.1" },
63
63
  "codeGraphBinaryDigest": { "$ref": "#/$defs/digest" },
64
64
  "codeGraphStatus": { "enum": ["ready", "unavailable"] }
65
65
  }