@sechroom/cli 2026.7.20 → 2026.7.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.js +26 -7
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -2367,8 +2367,7 @@ function registerChannel(program2) {
2367
2367
  );
2368
2368
  const withFilterOpts = (c) => c.option(
2369
2369
  "--name <name>",
2370
- "Subscription name (idempotent per name)",
2371
- "wlp-dispatch"
2370
+ "Deprecated: ignored; the installed executor selects its delivery subscription"
2372
2371
  ).option(
2373
2372
  "--tag <tag...>",
2374
2373
  "Deprecated: executor eligibility comes from the installed capability advertisement"
@@ -2404,6 +2403,7 @@ function registerChannel(program2) {
2404
2403
  instance.id
2405
2404
  );
2406
2405
  await drain();
2406
+ const stopReconciliation = startOfferReconciliation(drain);
2407
2407
  if (json) {
2408
2408
  emit(
2409
2409
  {
@@ -2423,7 +2423,11 @@ function registerChannel(program2) {
2423
2423
  ) + style.dim("streaming matched events to stdout; Ctrl-C to stop.\n")
2424
2424
  );
2425
2425
  }
2426
- await holdOpen(conn);
2426
+ try {
2427
+ await holdOpen(conn);
2428
+ } finally {
2429
+ stopReconciliation();
2430
+ }
2427
2431
  });
2428
2432
  withFilterOpts(
2429
2433
  channel.command("mcp").description(
@@ -2464,13 +2468,18 @@ function registerChannel(program2) {
2464
2468
  instance.id
2465
2469
  );
2466
2470
  await drain();
2471
+ const stopReconciliation = startOfferReconciliation(drain);
2467
2472
  process.stderr.write(
2468
2473
  style.dim(
2469
2474
  `sechroom channel (mcp) \u2014 tenant ${cfg.tenant}, executor ${located.state.instanceKey}
2470
2475
  `
2471
2476
  )
2472
2477
  );
2473
- await holdOpen(conn);
2478
+ try {
2479
+ await holdOpen(conn);
2480
+ } finally {
2481
+ stopReconciliation();
2482
+ }
2474
2483
  });
2475
2484
  channel.command("install").description(
2476
2485
  "Wire `sechroom channel mcp` into the project .mcp.json as a Claude Code channel MCP server (idempotent)"
@@ -2487,7 +2496,7 @@ function registerChannel(program2) {
2487
2496
  ).option("--dry-run", "Print what would change; write nothing").action((opts) => {
2488
2497
  const path = join9(process.cwd(), ".mcp.json");
2489
2498
  const dryRun = Boolean(opts.dryRun);
2490
- const args = ["channel", "mcp", "--name", opts.name];
2499
+ const args = ["channel", "mcp"];
2491
2500
  const entry = { command: "sechroom", args };
2492
2501
  const config2 = readMcpConfig(path);
2493
2502
  config2.mcpServers ??= {};
@@ -2544,11 +2553,11 @@ function requireExecutorState() {
2544
2553
  return located;
2545
2554
  }
2546
2555
  function warnLegacyChannelOptions(opts) {
2547
- if ((opts.workspace?.length ?? 0) === 0 && (opts.tag?.length ?? 0) === 0 && !opts.executorInstance)
2556
+ if (!opts.name && (opts.workspace?.length ?? 0) === 0 && (opts.tag?.length ?? 0) === 0 && !opts.executorInstance)
2548
2557
  return;
2549
2558
  process.stderr.write(
2550
2559
  style.dim(
2551
- "channel: --workspace, --tag, and --executor-instance are retired; eligibility and identity come from the installed executor advertisement.\n"
2560
+ "channel: --name, --workspace, --tag, and --executor-instance are retired; delivery, eligibility, and identity come from the installed executor advertisement.\n"
2552
2561
  )
2553
2562
  );
2554
2563
  }
@@ -2565,6 +2574,16 @@ function createClaimDrain(cfg, executorInstanceId, deliver, dependencies = {}) {
2565
2574
  return active2;
2566
2575
  };
2567
2576
  }
2577
+ function startOfferReconciliation(drain, intervalMilliseconds = 5e3, dependencies = {}) {
2578
+ const schedule = dependencies.setInterval ?? setInterval;
2579
+ const cancel = dependencies.clearInterval ?? clearInterval;
2580
+ const onError = dependencies.onError ?? ((error) => process.stderr.write(err(`channel claim failed: ${String(error)}
2581
+ `)));
2582
+ const timer = schedule(() => {
2583
+ void drain().catch(onError);
2584
+ }, intervalMilliseconds);
2585
+ return () => cancel(timer);
2586
+ }
2568
2587
  async function drainClaims(cfg, executorInstanceId, deliver, dependencies = {}) {
2569
2588
  const request = dependencies.request ?? api;
2570
2589
  const sleep = dependencies.sleep ?? ((milliseconds) => new Promise((resolve3) => setTimeout(resolve3, milliseconds)));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sechroom/cli",
3
- "version": "2026.7.20",
3
+ "version": "2026.7.21",
4
4
  "description": "Sechroom CLI — a thin, generated client over the Sechroom HTTP API. An agent/human surface alongside MCP.",
5
5
  "type": "module",
6
6
  "license": "UNLICENSED",