@mrrlin-dev/mcp 0.4.235 → 0.4.236

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/bin.cjs +21 -15
  2. package/package.json +1 -1
package/dist/bin.cjs CHANGED
@@ -106502,7 +106502,7 @@ Do NOT derail the current task - if the operator has an in-flight question, answ
106502
106502
  }
106503
106503
 
106504
106504
  // src/_generated/version.ts
106505
- var PKG_VERSION = "0.4.235";
106505
+ var PKG_VERSION = "0.4.236";
106506
106506
 
106507
106507
  // src/bridge-allowed-origins.ts
106508
106508
  var DEFAULT_DIRECTOR_BRIDGE_ALLOWED_ORIGINS = [
@@ -126653,22 +126653,28 @@ async function startDirectorBridge(startupDeps = {}) {
126653
126653
  throw error51;
126654
126654
  }
126655
126655
  }
126656
+ function resolveCompactBridgeOption(name, prerequisites, env = process.env, warn = (line) => {
126657
+ process.stderr.write(line);
126658
+ }) {
126659
+ const flag2 = env[name]?.trim().toLowerCase();
126660
+ if (flag2 && !["0", "1", "false"].includes(flag2)) throw new Error(`Invalid ${name}`);
126661
+ if (flag2 === "0" || flag2 === "false") return false;
126662
+ const ready = prerequisites.agentSecret && prerequisites.scopedScheduler;
126663
+ if (flag2 === "1" && !ready) {
126664
+ const missing = [
126665
+ ...prerequisites.agentSecret ? [] : ["a durable agent credential"],
126666
+ ...prerequisites.scopedScheduler ? [] : ["MRRLIN_BRIDGE_SCOPED_SCHEDULER=1"]
126667
+ ].join(" and ");
126668
+ warn(`[mrrlin-mcp director-bridge] ${name}=1 ignored: it requires ${missing}; staying off
126669
+ `);
126670
+ }
126671
+ return ready;
126672
+ }
126656
126673
  async function startBridge(startupDeps, agentSecret, startupRollback) {
126657
126674
  const scopedScheduler = process.env.MRRLIN_BRIDGE_SCOPED_SCHEDULER === "1";
126658
- const compactTickFlag = process.env.MRRLIN_BRIDGE_COMPACT_SCHEDULER?.trim().toLowerCase();
126659
- if (compactTickFlag && !["0", "1", "false"].includes(compactTickFlag)) {
126660
- throw new Error("Invalid MRRLIN_BRIDGE_COMPACT_SCHEDULER");
126661
- }
126662
- const compactTick = compactTickFlag === "1";
126663
- if (compactTick && (!agentSecret || !scopedScheduler)) {
126664
- throw new Error("Compact scheduler requires a durable agent credential and scoped scheduler");
126665
- }
126666
- const compactFlag = process.env.MRRLIN_BRIDGE_COMPACT_HEARTBEAT?.trim().toLowerCase();
126667
- if (compactFlag && !["0", "1", "false"].includes(compactFlag)) throw new Error("Invalid MRRLIN_BRIDGE_COMPACT_HEARTBEAT");
126668
- const compactHeartbeat = compactFlag === "1";
126669
- if (compactHeartbeat && (!agentSecret || !scopedScheduler)) {
126670
- throw new Error("Compact heartbeat requires a durable agent credential and scoped scheduler");
126671
- }
126675
+ const compactPrerequisites = { agentSecret: !!agentSecret, scopedScheduler };
126676
+ const compactTick = resolveCompactBridgeOption("MRRLIN_BRIDGE_COMPACT_SCHEDULER", compactPrerequisites);
126677
+ const compactHeartbeat = resolveCompactBridgeOption("MRRLIN_BRIDGE_COMPACT_HEARTBEAT", compactPrerequisites);
126672
126678
  const signingProvider = buildBridgeSigningProvider();
126673
126679
  const config2 = parseConfig();
126674
126680
  const failureLog = createFailureLog();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mrrlin-dev/mcp",
3
- "version": "0.4.235",
3
+ "version": "0.4.236",
4
4
  "type": "module",
5
5
  "bin": {
6
6
  "mrrlin-mcp": "dist/bin.cjs"