switchroom 0.12.15 → 0.12.17
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/agent-scheduler/index.js +82 -81
- package/dist/auth-broker/index.js +82 -81
- package/dist/cli/drive-write-pretool.mjs +10 -10
- package/dist/cli/skill-validate-pretool.mjs +72 -72
- package/dist/cli/switchroom.js +359 -358
- package/dist/host-control/main.js +101 -100
- package/dist/vault/approvals/kernel-server.js +84 -83
- package/dist/vault/broker/server.js +85 -84
- package/package.json +1 -1
- package/telegram-plugin/bridge/bridge.ts +7 -0
- package/telegram-plugin/dist/bridge/bridge.js +115 -113
- package/telegram-plugin/dist/gateway/gateway.js +484 -287
- package/telegram-plugin/dist/server.js +163 -161
- package/telegram-plugin/gateway/gateway.ts +154 -5
- package/telegram-plugin/gateway/ipc-protocol.ts +9 -0
- package/telegram-plugin/gateway/pending-inbound-buffer.ts +32 -0
- package/telegram-plugin/gateway/proactive-compact.ts +84 -0
- package/telegram-plugin/tests/pending-inbound-buffer.test.ts +48 -1
- package/telegram-plugin/tests/proactive-compact.test.ts +101 -0
|
@@ -66,7 +66,7 @@ var __export = (target, all) => {
|
|
|
66
66
|
var __esm = (fn, res) => () => (fn && (res = fn(fn = 0)), res);
|
|
67
67
|
var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
68
68
|
|
|
69
|
-
//
|
|
69
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/filter.js
|
|
70
70
|
var require_filter = __commonJS((exports) => {
|
|
71
71
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
72
72
|
exports.matchFilter = matchFilter;
|
|
@@ -430,7 +430,7 @@ var require_filter = __commonJS((exports) => {
|
|
|
430
430
|
};
|
|
431
431
|
});
|
|
432
432
|
|
|
433
|
-
//
|
|
433
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/context.js
|
|
434
434
|
var require_context = __commonJS((exports) => {
|
|
435
435
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
436
436
|
exports.Context = undefined;
|
|
@@ -1457,7 +1457,7 @@ var require_context = __commonJS((exports) => {
|
|
|
1457
1457
|
}
|
|
1458
1458
|
});
|
|
1459
1459
|
|
|
1460
|
-
//
|
|
1460
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/composer.js
|
|
1461
1461
|
var require_composer = __commonJS((exports) => {
|
|
1462
1462
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1463
1463
|
exports.Composer = exports.BotError = undefined;
|
|
@@ -1619,7 +1619,7 @@ var require_composer = __commonJS((exports) => {
|
|
|
1619
1619
|
exports.Composer = Composer;
|
|
1620
1620
|
});
|
|
1621
1621
|
|
|
1622
|
-
//
|
|
1622
|
+
// ../../switchroom/node_modules/.bun/ms@2.1.3/node_modules/ms/index.js
|
|
1623
1623
|
var require_ms = __commonJS((exports, module) => {
|
|
1624
1624
|
var s = 1000;
|
|
1625
1625
|
var m = s * 60;
|
|
@@ -1729,7 +1729,7 @@ var require_ms = __commonJS((exports, module) => {
|
|
|
1729
1729
|
}
|
|
1730
1730
|
});
|
|
1731
1731
|
|
|
1732
|
-
//
|
|
1732
|
+
// ../../switchroom/node_modules/.bun/debug@4.4.3/node_modules/debug/src/common.js
|
|
1733
1733
|
var require_common = __commonJS((exports, module) => {
|
|
1734
1734
|
function setup(env) {
|
|
1735
1735
|
createDebug.debug = createDebug;
|
|
@@ -1904,7 +1904,7 @@ var require_common = __commonJS((exports, module) => {
|
|
|
1904
1904
|
module.exports = setup;
|
|
1905
1905
|
});
|
|
1906
1906
|
|
|
1907
|
-
//
|
|
1907
|
+
// ../../switchroom/node_modules/.bun/debug@4.4.3/node_modules/debug/src/browser.js
|
|
1908
1908
|
var require_browser = __commonJS((exports, module) => {
|
|
1909
1909
|
exports.formatArgs = formatArgs;
|
|
1910
1910
|
exports.save = save;
|
|
@@ -2064,7 +2064,7 @@ var require_browser = __commonJS((exports, module) => {
|
|
|
2064
2064
|
};
|
|
2065
2065
|
});
|
|
2066
2066
|
|
|
2067
|
-
//
|
|
2067
|
+
// ../../switchroom/node_modules/.bun/has-flag@4.0.0/node_modules/has-flag/index.js
|
|
2068
2068
|
var require_has_flag = __commonJS((exports, module) => {
|
|
2069
2069
|
module.exports = (flag, argv = process.argv) => {
|
|
2070
2070
|
const prefix = flag.startsWith("-") ? "" : flag.length === 1 ? "-" : "--";
|
|
@@ -2074,7 +2074,7 @@ var require_has_flag = __commonJS((exports, module) => {
|
|
|
2074
2074
|
};
|
|
2075
2075
|
});
|
|
2076
2076
|
|
|
2077
|
-
//
|
|
2077
|
+
// ../../switchroom/node_modules/.bun/supports-color@7.2.0/node_modules/supports-color/index.js
|
|
2078
2078
|
var require_supports_color = __commonJS((exports, module) => {
|
|
2079
2079
|
var os = __require("os");
|
|
2080
2080
|
var tty = __require("tty");
|
|
@@ -2173,7 +2173,7 @@ var require_supports_color = __commonJS((exports, module) => {
|
|
|
2173
2173
|
};
|
|
2174
2174
|
});
|
|
2175
2175
|
|
|
2176
|
-
//
|
|
2176
|
+
// ../../switchroom/node_modules/.bun/debug@4.4.3/node_modules/debug/src/node.js
|
|
2177
2177
|
var require_node = __commonJS((exports, module) => {
|
|
2178
2178
|
var tty = __require("tty");
|
|
2179
2179
|
var util = __require("util");
|
|
@@ -2344,7 +2344,7 @@ var require_node = __commonJS((exports, module) => {
|
|
|
2344
2344
|
};
|
|
2345
2345
|
});
|
|
2346
2346
|
|
|
2347
|
-
//
|
|
2347
|
+
// ../../switchroom/node_modules/.bun/debug@4.4.3/node_modules/debug/src/index.js
|
|
2348
2348
|
var require_src = __commonJS((exports, module) => {
|
|
2349
2349
|
if (typeof process === "undefined" || process.type === "renderer" || false || process.__nwjs) {
|
|
2350
2350
|
module.exports = require_browser();
|
|
@@ -2353,7 +2353,7 @@ var require_src = __commonJS((exports, module) => {
|
|
|
2353
2353
|
}
|
|
2354
2354
|
});
|
|
2355
2355
|
|
|
2356
|
-
//
|
|
2356
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/platform.node.js
|
|
2357
2357
|
var require_platform_node = __commonJS((exports) => {
|
|
2358
2358
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
2359
2359
|
exports.defaultAdapter = exports.itrToStream = exports.debug = undefined;
|
|
@@ -2393,7 +2393,7 @@ var require_platform_node = __commonJS((exports) => {
|
|
|
2393
2393
|
exports.defaultAdapter = "express";
|
|
2394
2394
|
});
|
|
2395
2395
|
|
|
2396
|
-
//
|
|
2396
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/core/error.js
|
|
2397
2397
|
var require_error = __commonJS((exports) => {
|
|
2398
2398
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
2399
2399
|
exports.HttpError = exports.GrammyError = undefined;
|
|
@@ -2449,10 +2449,10 @@ var require_error = __commonJS((exports) => {
|
|
|
2449
2449
|
}
|
|
2450
2450
|
});
|
|
2451
2451
|
|
|
2452
|
-
//
|
|
2452
|
+
// ../../switchroom/node_modules/.bun/@grammyjs+types@3.26.0/node_modules/@grammyjs/types/mod.js
|
|
2453
2453
|
var exports_mod = {};
|
|
2454
2454
|
|
|
2455
|
-
//
|
|
2455
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/types.node.js
|
|
2456
2456
|
var require_types_node = __commonJS((exports) => {
|
|
2457
2457
|
var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) {
|
|
2458
2458
|
if (k2 === undefined)
|
|
@@ -2543,7 +2543,7 @@ var require_types_node = __commonJS((exports) => {
|
|
|
2543
2543
|
}
|
|
2544
2544
|
});
|
|
2545
2545
|
|
|
2546
|
-
//
|
|
2546
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/types.js
|
|
2547
2547
|
var require_types = __commonJS((exports) => {
|
|
2548
2548
|
var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) {
|
|
2549
2549
|
if (k2 === undefined)
|
|
@@ -2569,7 +2569,7 @@ var require_types = __commonJS((exports) => {
|
|
|
2569
2569
|
__exportStar(require_types_node(), exports);
|
|
2570
2570
|
});
|
|
2571
2571
|
|
|
2572
|
-
//
|
|
2572
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/core/payload.js
|
|
2573
2573
|
var require_payload = __commonJS((exports) => {
|
|
2574
2574
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
2575
2575
|
exports.requiresFormDataUpload = requiresFormDataUpload;
|
|
@@ -2709,7 +2709,7 @@ content-type:application/octet-stream\r
|
|
|
2709
2709
|
}
|
|
2710
2710
|
});
|
|
2711
2711
|
|
|
2712
|
-
//
|
|
2712
|
+
// ../../switchroom/node_modules/.bun/event-target-shim@5.0.1/node_modules/event-target-shim/dist/event-target-shim.js
|
|
2713
2713
|
var require_event_target_shim = __commonJS((exports, module) => {
|
|
2714
2714
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
2715
2715
|
var privateData = new WeakMap;
|
|
@@ -3149,7 +3149,7 @@ var require_event_target_shim = __commonJS((exports, module) => {
|
|
|
3149
3149
|
module.exports.defineEventAttribute = defineEventAttribute;
|
|
3150
3150
|
});
|
|
3151
3151
|
|
|
3152
|
-
//
|
|
3152
|
+
// ../../switchroom/node_modules/.bun/abort-controller@3.0.0/node_modules/abort-controller/dist/abort-controller.js
|
|
3153
3153
|
var require_abort_controller = __commonJS((exports, module) => {
|
|
3154
3154
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3155
3155
|
var eventTargetShim = require_event_target_shim();
|
|
@@ -3229,7 +3229,7 @@ var require_abort_controller = __commonJS((exports, module) => {
|
|
|
3229
3229
|
module.exports.AbortSignal = AbortSignal2;
|
|
3230
3230
|
});
|
|
3231
3231
|
|
|
3232
|
-
//
|
|
3232
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/shim.node.js
|
|
3233
3233
|
var require_shim_node = __commonJS((exports) => {
|
|
3234
3234
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3235
3235
|
exports.fetch = exports.AbortController = undefined;
|
|
@@ -3243,7 +3243,7 @@ var require_shim_node = __commonJS((exports) => {
|
|
|
3243
3243
|
} });
|
|
3244
3244
|
});
|
|
3245
3245
|
|
|
3246
|
-
//
|
|
3246
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/core/client.js
|
|
3247
3247
|
var require_client = __commonJS((exports) => {
|
|
3248
3248
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3249
3249
|
exports.createRawApi = createRawApi;
|
|
@@ -3423,7 +3423,7 @@ If you want to prevent such mistakes in the future, consider using TypeScript. h
|
|
|
3423
3423
|
var shim_node_js_1 = require_shim_node();
|
|
3424
3424
|
});
|
|
3425
3425
|
|
|
3426
|
-
//
|
|
3426
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/core/api.js
|
|
3427
3427
|
var require_api = __commonJS((exports) => {
|
|
3428
3428
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3429
3429
|
exports.Api = undefined;
|
|
@@ -4041,7 +4041,7 @@ var require_api = __commonJS((exports) => {
|
|
|
4041
4041
|
exports.Api = Api;
|
|
4042
4042
|
});
|
|
4043
4043
|
|
|
4044
|
-
//
|
|
4044
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/bot.js
|
|
4045
4045
|
var require_bot = __commonJS((exports) => {
|
|
4046
4046
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4047
4047
|
exports.Bot = exports.BotError = exports.DEFAULT_UPDATE_TYPES = undefined;
|
|
@@ -4370,7 +4370,7 @@ On the other hand, if you actually know what you're doing and you do need to ins
|
|
|
4370
4370
|
var shim_node_js_1 = require_shim_node();
|
|
4371
4371
|
});
|
|
4372
4372
|
|
|
4373
|
-
//
|
|
4373
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/convenience/constants.js
|
|
4374
4374
|
var require_constants = __commonJS((exports) => {
|
|
4375
4375
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4376
4376
|
exports.API_CONSTANTS = undefined;
|
|
@@ -4406,7 +4406,7 @@ var require_constants = __commonJS((exports) => {
|
|
|
4406
4406
|
Object.freeze(exports.API_CONSTANTS);
|
|
4407
4407
|
});
|
|
4408
4408
|
|
|
4409
|
-
//
|
|
4409
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/convenience/inline_query.js
|
|
4410
4410
|
var require_inline_query = __commonJS((exports) => {
|
|
4411
4411
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4412
4412
|
exports.InlineQueryResultBuilder = undefined;
|
|
@@ -4604,7 +4604,7 @@ var require_inline_query = __commonJS((exports) => {
|
|
|
4604
4604
|
};
|
|
4605
4605
|
});
|
|
4606
4606
|
|
|
4607
|
-
//
|
|
4607
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/convenience/input_media.js
|
|
4608
4608
|
var require_input_media = __commonJS((exports) => {
|
|
4609
4609
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4610
4610
|
exports.InputMediaBuilder = undefined;
|
|
@@ -4627,7 +4627,7 @@ var require_input_media = __commonJS((exports) => {
|
|
|
4627
4627
|
};
|
|
4628
4628
|
});
|
|
4629
4629
|
|
|
4630
|
-
//
|
|
4630
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/convenience/keyboard.js
|
|
4631
4631
|
var require_keyboard = __commonJS((exports) => {
|
|
4632
4632
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4633
4633
|
exports.InlineKeyboard = exports.Keyboard = undefined;
|
|
@@ -4985,7 +4985,7 @@ var require_keyboard = __commonJS((exports) => {
|
|
|
4985
4985
|
}
|
|
4986
4986
|
});
|
|
4987
4987
|
|
|
4988
|
-
//
|
|
4988
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/convenience/session.js
|
|
4989
4989
|
var require_session = __commonJS((exports) => {
|
|
4990
4990
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4991
4991
|
exports.MemorySessionStorage = undefined;
|
|
@@ -5285,7 +5285,7 @@ var require_session = __commonJS((exports) => {
|
|
|
5285
5285
|
}
|
|
5286
5286
|
});
|
|
5287
5287
|
|
|
5288
|
-
//
|
|
5288
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/convenience/frameworks.js
|
|
5289
5289
|
var require_frameworks = __commonJS((exports) => {
|
|
5290
5290
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5291
5291
|
exports.adapters = undefined;
|
|
@@ -5653,7 +5653,7 @@ var require_frameworks = __commonJS((exports) => {
|
|
|
5653
5653
|
};
|
|
5654
5654
|
});
|
|
5655
5655
|
|
|
5656
|
-
//
|
|
5656
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/convenience/webhook.js
|
|
5657
5657
|
var require_webhook = __commonJS((exports) => {
|
|
5658
5658
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5659
5659
|
exports.webhookCallback = webhookCallback;
|
|
@@ -5747,7 +5747,7 @@ var require_webhook = __commonJS((exports) => {
|
|
|
5747
5747
|
}
|
|
5748
5748
|
});
|
|
5749
5749
|
|
|
5750
|
-
//
|
|
5750
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/mod.js
|
|
5751
5751
|
var require_mod = __commonJS((exports) => {
|
|
5752
5752
|
var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) {
|
|
5753
5753
|
if (k2 === undefined)
|
|
@@ -5813,7 +5813,7 @@ var require_mod = __commonJS((exports) => {
|
|
|
5813
5813
|
} });
|
|
5814
5814
|
});
|
|
5815
5815
|
|
|
5816
|
-
//
|
|
5816
|
+
// ../../switchroom/node_modules/.bun/@grammyjs+runner@2.0.3+c6be0243b1bbec89/node_modules/@grammyjs/runner/out/platform.node.js
|
|
5817
5817
|
var require_platform_node2 = __commonJS((exports) => {
|
|
5818
5818
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5819
5819
|
exports.parentThread = exports.createThread = undefined;
|
|
@@ -5844,7 +5844,7 @@ var require_platform_node2 = __commonJS((exports) => {
|
|
|
5844
5844
|
exports.parentThread = parentThread;
|
|
5845
5845
|
});
|
|
5846
5846
|
|
|
5847
|
-
//
|
|
5847
|
+
// ../../switchroom/node_modules/.bun/@grammyjs+runner@2.0.3+c6be0243b1bbec89/node_modules/@grammyjs/runner/out/distribute.js
|
|
5848
5848
|
var require_distribute = __commonJS((exports) => {
|
|
5849
5849
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5850
5850
|
exports.distribute = undefined;
|
|
@@ -5889,7 +5889,7 @@ var require_distribute = __commonJS((exports) => {
|
|
|
5889
5889
|
exports.distribute = distribute;
|
|
5890
5890
|
});
|
|
5891
5891
|
|
|
5892
|
-
//
|
|
5892
|
+
// ../../switchroom/node_modules/.bun/@grammyjs+runner@2.0.3+c6be0243b1bbec89/node_modules/@grammyjs/runner/out/queue.js
|
|
5893
5893
|
var require_queue = __commonJS((exports) => {
|
|
5894
5894
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5895
5895
|
exports.DecayingDeque = undefined;
|
|
@@ -6033,7 +6033,7 @@ var require_queue = __commonJS((exports) => {
|
|
|
6033
6033
|
exports.DecayingDeque = DecayingDeque;
|
|
6034
6034
|
});
|
|
6035
6035
|
|
|
6036
|
-
//
|
|
6036
|
+
// ../../switchroom/node_modules/.bun/@grammyjs+runner@2.0.3+c6be0243b1bbec89/node_modules/@grammyjs/runner/out/sink.js
|
|
6037
6037
|
var require_sink = __commonJS((exports) => {
|
|
6038
6038
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6039
6039
|
exports.createConcurrentSink = exports.createBatchSink = exports.createSequentialSink = undefined;
|
|
@@ -6078,7 +6078,7 @@ var require_sink = __commonJS((exports) => {
|
|
|
6078
6078
|
exports.createConcurrentSink = createConcurrentSink;
|
|
6079
6079
|
});
|
|
6080
6080
|
|
|
6081
|
-
//
|
|
6081
|
+
// ../../switchroom/node_modules/.bun/@grammyjs+runner@2.0.3+c6be0243b1bbec89/node_modules/@grammyjs/runner/out/node-shim.js
|
|
6082
6082
|
var require_node_shim = __commonJS((exports) => {
|
|
6083
6083
|
var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) {
|
|
6084
6084
|
if (k2 === undefined)
|
|
@@ -6104,7 +6104,7 @@ var require_node_shim = __commonJS((exports) => {
|
|
|
6104
6104
|
__exportStar(require_abort_controller(), exports);
|
|
6105
6105
|
});
|
|
6106
6106
|
|
|
6107
|
-
//
|
|
6107
|
+
// ../../switchroom/node_modules/.bun/@grammyjs+runner@2.0.3+c6be0243b1bbec89/node_modules/@grammyjs/runner/out/source.js
|
|
6108
6108
|
var require_source = __commonJS((exports) => {
|
|
6109
6109
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6110
6110
|
exports.createSource = undefined;
|
|
@@ -6184,7 +6184,7 @@ var require_source = __commonJS((exports) => {
|
|
|
6184
6184
|
var node_shim_js_1 = require_node_shim();
|
|
6185
6185
|
});
|
|
6186
6186
|
|
|
6187
|
-
//
|
|
6187
|
+
// ../../switchroom/node_modules/.bun/@grammyjs+runner@2.0.3+c6be0243b1bbec89/node_modules/@grammyjs/runner/out/runner.js
|
|
6188
6188
|
var require_runner = __commonJS((exports) => {
|
|
6189
6189
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6190
6190
|
exports.createRunner = exports.createUpdateFetcher = exports.run = undefined;
|
|
@@ -6336,7 +6336,7 @@ var require_runner = __commonJS((exports) => {
|
|
|
6336
6336
|
}
|
|
6337
6337
|
});
|
|
6338
6338
|
|
|
6339
|
-
//
|
|
6339
|
+
// ../../switchroom/node_modules/.bun/@grammyjs+runner@2.0.3+c6be0243b1bbec89/node_modules/@grammyjs/runner/out/sequentialize.js
|
|
6340
6340
|
var require_sequentialize = __commonJS((exports) => {
|
|
6341
6341
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6342
6342
|
exports.sequentialize = undefined;
|
|
@@ -6379,7 +6379,7 @@ var require_sequentialize = __commonJS((exports) => {
|
|
|
6379
6379
|
exports.sequentialize = sequentialize;
|
|
6380
6380
|
});
|
|
6381
6381
|
|
|
6382
|
-
//
|
|
6382
|
+
// ../../switchroom/node_modules/.bun/grammy@1.42.0/node_modules/grammy/out/mod.js
|
|
6383
6383
|
var require_mod2 = __commonJS((exports) => {
|
|
6384
6384
|
var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) {
|
|
6385
6385
|
if (k2 === undefined)
|
|
@@ -6445,7 +6445,7 @@ var require_mod2 = __commonJS((exports) => {
|
|
|
6445
6445
|
} });
|
|
6446
6446
|
});
|
|
6447
6447
|
|
|
6448
|
-
//
|
|
6448
|
+
// ../../switchroom/node_modules/.bun/@grammyjs+runner@2.0.3+c6be0243b1bbec89/node_modules/@grammyjs/runner/out/deps.node.js
|
|
6449
6449
|
var require_deps_node = __commonJS((exports) => {
|
|
6450
6450
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6451
6451
|
exports.BotError = exports.Bot = undefined;
|
|
@@ -6458,7 +6458,7 @@ var require_deps_node = __commonJS((exports) => {
|
|
|
6458
6458
|
} });
|
|
6459
6459
|
});
|
|
6460
6460
|
|
|
6461
|
-
//
|
|
6461
|
+
// ../../switchroom/node_modules/.bun/@grammyjs+runner@2.0.3+c6be0243b1bbec89/node_modules/@grammyjs/runner/out/worker.js
|
|
6462
6462
|
var require_worker = __commonJS((exports) => {
|
|
6463
6463
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6464
6464
|
exports.BotWorker = undefined;
|
|
@@ -6500,7 +6500,7 @@ var require_worker = __commonJS((exports) => {
|
|
|
6500
6500
|
exports.BotWorker = BotWorker;
|
|
6501
6501
|
});
|
|
6502
6502
|
|
|
6503
|
-
//
|
|
6503
|
+
// ../../switchroom/node_modules/.bun/@grammyjs+runner@2.0.3+c6be0243b1bbec89/node_modules/@grammyjs/runner/out/mod.js
|
|
6504
6504
|
var require_mod3 = __commonJS((exports) => {
|
|
6505
6505
|
var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) {
|
|
6506
6506
|
if (k2 === undefined)
|
|
@@ -6532,7 +6532,7 @@ var require_mod3 = __commonJS((exports) => {
|
|
|
6532
6532
|
__exportStar(require_worker(), exports);
|
|
6533
6533
|
});
|
|
6534
6534
|
|
|
6535
|
-
//
|
|
6535
|
+
// ../../switchroom/node_modules/.bun/@grammyjs+runner@2.0.3+c6be0243b1bbec89/node_modules/@grammyjs/runner/out/mod.js
|
|
6536
6536
|
var require_mod4 = __commonJS((exports) => {
|
|
6537
6537
|
var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) {
|
|
6538
6538
|
if (k2 === undefined)
|
|
@@ -6564,7 +6564,7 @@ var require_mod4 = __commonJS((exports) => {
|
|
|
6564
6564
|
__exportStar(require_worker(), exports);
|
|
6565
6565
|
});
|
|
6566
6566
|
|
|
6567
|
-
//
|
|
6567
|
+
// ../../switchroom/node_modules/.bun/@xterm+headless@6.0.0/node_modules/@xterm/headless/lib-headless/xterm-headless.js
|
|
6568
6568
|
var require_xterm_headless = __commonJS((exports2) => {
|
|
6569
6569
|
(() => {
|
|
6570
6570
|
var e = { 5639: (e2, t2, s2) => {
|
|
@@ -12119,7 +12119,7 @@ ${i3.join(`
|
|
|
12119
12119
|
})();
|
|
12120
12120
|
});
|
|
12121
12121
|
|
|
12122
|
-
//
|
|
12122
|
+
// ../../switchroom/node_modules/.bun/zod@3.25.76/node_modules/zod/v3/helpers/util.js
|
|
12123
12123
|
var util, objectUtil, ZodParsedType, getParsedType = (data) => {
|
|
12124
12124
|
const t = typeof data;
|
|
12125
12125
|
switch (t) {
|
|
@@ -12250,7 +12250,7 @@ var init_util = __esm(() => {
|
|
|
12250
12250
|
]);
|
|
12251
12251
|
});
|
|
12252
12252
|
|
|
12253
|
-
//
|
|
12253
|
+
// ../../switchroom/node_modules/.bun/zod@3.25.76/node_modules/zod/v3/ZodError.js
|
|
12254
12254
|
var ZodIssueCode, quotelessJson = (obj) => {
|
|
12255
12255
|
const json = JSON.stringify(obj, null, 2);
|
|
12256
12256
|
return json.replace(/"([^"]+)":/g, "$1:");
|
|
@@ -12371,7 +12371,7 @@ var init_ZodError = __esm(() => {
|
|
|
12371
12371
|
};
|
|
12372
12372
|
});
|
|
12373
12373
|
|
|
12374
|
-
//
|
|
12374
|
+
// ../../switchroom/node_modules/.bun/zod@3.25.76/node_modules/zod/v3/locales/en.js
|
|
12375
12375
|
var errorMap = (issue, _ctx) => {
|
|
12376
12376
|
let message;
|
|
12377
12377
|
switch (issue.code) {
|
|
@@ -12478,7 +12478,7 @@ var init_en = __esm(() => {
|
|
|
12478
12478
|
en_default = errorMap;
|
|
12479
12479
|
});
|
|
12480
12480
|
|
|
12481
|
-
//
|
|
12481
|
+
// ../../switchroom/node_modules/.bun/zod@3.25.76/node_modules/zod/v3/errors.js
|
|
12482
12482
|
function setErrorMap(map) {
|
|
12483
12483
|
overrideErrorMap = map;
|
|
12484
12484
|
}
|
|
@@ -12491,7 +12491,7 @@ var init_errors = __esm(() => {
|
|
|
12491
12491
|
overrideErrorMap = en_default;
|
|
12492
12492
|
});
|
|
12493
12493
|
|
|
12494
|
-
//
|
|
12494
|
+
// ../../switchroom/node_modules/.bun/zod@3.25.76/node_modules/zod/v3/helpers/parseUtil.js
|
|
12495
12495
|
function addIssueToContext(ctx, issueData) {
|
|
12496
12496
|
const overrideMap = getErrorMap();
|
|
12497
12497
|
const issue = makeIssue({
|
|
@@ -12596,10 +12596,10 @@ var init_parseUtil = __esm(() => {
|
|
|
12596
12596
|
});
|
|
12597
12597
|
});
|
|
12598
12598
|
|
|
12599
|
-
//
|
|
12599
|
+
// ../../switchroom/node_modules/.bun/zod@3.25.76/node_modules/zod/v3/helpers/typeAliases.js
|
|
12600
12600
|
var init_typeAliases = () => {};
|
|
12601
12601
|
|
|
12602
|
-
//
|
|
12602
|
+
// ../../switchroom/node_modules/.bun/zod@3.25.76/node_modules/zod/v3/helpers/errorUtil.js
|
|
12603
12603
|
var errorUtil;
|
|
12604
12604
|
var init_errorUtil = __esm(() => {
|
|
12605
12605
|
(function(errorUtil2) {
|
|
@@ -12608,7 +12608,7 @@ var init_errorUtil = __esm(() => {
|
|
|
12608
12608
|
})(errorUtil || (errorUtil = {}));
|
|
12609
12609
|
});
|
|
12610
12610
|
|
|
12611
|
-
//
|
|
12611
|
+
// ../../switchroom/node_modules/.bun/zod@3.25.76/node_modules/zod/v3/types.js
|
|
12612
12612
|
class ParseInputLazyPath {
|
|
12613
12613
|
constructor(parent, value, path, key) {
|
|
12614
12614
|
this._cachedPath = [];
|
|
@@ -15959,7 +15959,7 @@ var init_types = __esm(() => {
|
|
|
15959
15959
|
NEVER = INVALID;
|
|
15960
15960
|
});
|
|
15961
15961
|
|
|
15962
|
-
//
|
|
15962
|
+
// ../../switchroom/node_modules/.bun/zod@3.25.76/node_modules/zod/v3/external.js
|
|
15963
15963
|
var exports_external = {};
|
|
15964
15964
|
__export(exports_external, {
|
|
15965
15965
|
void: () => voidType,
|
|
@@ -16079,7 +16079,7 @@ var init_external = __esm(() => {
|
|
|
16079
16079
|
init_ZodError();
|
|
16080
16080
|
});
|
|
16081
16081
|
|
|
16082
|
-
//
|
|
16082
|
+
// ../../switchroom/node_modules/.bun/zod@3.25.76/node_modules/zod/index.js
|
|
16083
16083
|
var init_zod = __esm(() => {
|
|
16084
16084
|
init_external();
|
|
16085
16085
|
init_external();
|
|
@@ -16627,7 +16627,7 @@ var init_client = __esm(() => {
|
|
|
16627
16627
|
};
|
|
16628
16628
|
});
|
|
16629
16629
|
|
|
16630
|
-
//
|
|
16630
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/nodes/identity.js
|
|
16631
16631
|
var require_identity = __commonJS((exports2) => {
|
|
16632
16632
|
var ALIAS = Symbol.for("yaml.alias");
|
|
16633
16633
|
var DOC = Symbol.for("yaml.document");
|
|
@@ -16681,7 +16681,7 @@ var require_identity = __commonJS((exports2) => {
|
|
|
16681
16681
|
exports2.isSeq = isSeq;
|
|
16682
16682
|
});
|
|
16683
16683
|
|
|
16684
|
-
//
|
|
16684
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/visit.js
|
|
16685
16685
|
var require_visit = __commonJS((exports2) => {
|
|
16686
16686
|
var identity = require_identity();
|
|
16687
16687
|
var BREAK = Symbol("break visit");
|
|
@@ -16836,7 +16836,7 @@ var require_visit = __commonJS((exports2) => {
|
|
|
16836
16836
|
exports2.visitAsync = visitAsync;
|
|
16837
16837
|
});
|
|
16838
16838
|
|
|
16839
|
-
//
|
|
16839
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/doc/directives.js
|
|
16840
16840
|
var require_directives = __commonJS((exports2) => {
|
|
16841
16841
|
var identity = require_identity();
|
|
16842
16842
|
var visit = require_visit();
|
|
@@ -16988,7 +16988,7 @@ var require_directives = __commonJS((exports2) => {
|
|
|
16988
16988
|
exports2.Directives = Directives;
|
|
16989
16989
|
});
|
|
16990
16990
|
|
|
16991
|
-
//
|
|
16991
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/doc/anchors.js
|
|
16992
16992
|
var require_anchors = __commonJS((exports2) => {
|
|
16993
16993
|
var identity = require_identity();
|
|
16994
16994
|
var visit = require_visit();
|
|
@@ -17050,7 +17050,7 @@ var require_anchors = __commonJS((exports2) => {
|
|
|
17050
17050
|
exports2.findNewAnchor = findNewAnchor;
|
|
17051
17051
|
});
|
|
17052
17052
|
|
|
17053
|
-
//
|
|
17053
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/doc/applyReviver.js
|
|
17054
17054
|
var require_applyReviver = __commonJS((exports2) => {
|
|
17055
17055
|
function applyReviver(reviver, obj, key, val) {
|
|
17056
17056
|
if (val && typeof val === "object") {
|
|
@@ -17097,7 +17097,7 @@ var require_applyReviver = __commonJS((exports2) => {
|
|
|
17097
17097
|
exports2.applyReviver = applyReviver;
|
|
17098
17098
|
});
|
|
17099
17099
|
|
|
17100
|
-
//
|
|
17100
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/nodes/toJS.js
|
|
17101
17101
|
var require_toJS = __commonJS((exports2) => {
|
|
17102
17102
|
var identity = require_identity();
|
|
17103
17103
|
function toJS(value, arg, ctx) {
|
|
@@ -17124,7 +17124,7 @@ var require_toJS = __commonJS((exports2) => {
|
|
|
17124
17124
|
exports2.toJS = toJS;
|
|
17125
17125
|
});
|
|
17126
17126
|
|
|
17127
|
-
//
|
|
17127
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/nodes/Node.js
|
|
17128
17128
|
var require_Node = __commonJS((exports2) => {
|
|
17129
17129
|
var applyReviver = require_applyReviver();
|
|
17130
17130
|
var identity = require_identity();
|
|
@@ -17161,7 +17161,7 @@ var require_Node = __commonJS((exports2) => {
|
|
|
17161
17161
|
exports2.NodeBase = NodeBase;
|
|
17162
17162
|
});
|
|
17163
17163
|
|
|
17164
|
-
//
|
|
17164
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/nodes/Alias.js
|
|
17165
17165
|
var require_Alias = __commonJS((exports2) => {
|
|
17166
17166
|
var anchors = require_anchors();
|
|
17167
17167
|
var visit = require_visit();
|
|
@@ -17269,7 +17269,7 @@ var require_Alias = __commonJS((exports2) => {
|
|
|
17269
17269
|
exports2.Alias = Alias;
|
|
17270
17270
|
});
|
|
17271
17271
|
|
|
17272
|
-
//
|
|
17272
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/nodes/Scalar.js
|
|
17273
17273
|
var require_Scalar = __commonJS((exports2) => {
|
|
17274
17274
|
var identity = require_identity();
|
|
17275
17275
|
var Node = require_Node();
|
|
@@ -17297,7 +17297,7 @@ var require_Scalar = __commonJS((exports2) => {
|
|
|
17297
17297
|
exports2.isScalarValue = isScalarValue;
|
|
17298
17298
|
});
|
|
17299
17299
|
|
|
17300
|
-
//
|
|
17300
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/doc/createNode.js
|
|
17301
17301
|
var require_createNode = __commonJS((exports2) => {
|
|
17302
17302
|
var Alias = require_Alias();
|
|
17303
17303
|
var identity = require_identity();
|
|
@@ -17369,7 +17369,7 @@ var require_createNode = __commonJS((exports2) => {
|
|
|
17369
17369
|
exports2.createNode = createNode;
|
|
17370
17370
|
});
|
|
17371
17371
|
|
|
17372
|
-
//
|
|
17372
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/nodes/Collection.js
|
|
17373
17373
|
var require_Collection = __commonJS((exports2) => {
|
|
17374
17374
|
var createNode = require_createNode();
|
|
17375
17375
|
var identity = require_identity();
|
|
@@ -17484,7 +17484,7 @@ var require_Collection = __commonJS((exports2) => {
|
|
|
17484
17484
|
exports2.isEmptyPath = isEmptyPath;
|
|
17485
17485
|
});
|
|
17486
17486
|
|
|
17487
|
-
//
|
|
17487
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/stringify/stringifyComment.js
|
|
17488
17488
|
var require_stringifyComment = __commonJS((exports2) => {
|
|
17489
17489
|
var stringifyComment = (str) => str.replace(/^(?!$)(?: $)?/gm, "#");
|
|
17490
17490
|
function indentComment(comment, indent) {
|
|
@@ -17501,7 +17501,7 @@ var require_stringifyComment = __commonJS((exports2) => {
|
|
|
17501
17501
|
exports2.stringifyComment = stringifyComment;
|
|
17502
17502
|
});
|
|
17503
17503
|
|
|
17504
|
-
//
|
|
17504
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/stringify/foldFlowLines.js
|
|
17505
17505
|
var require_foldFlowLines = __commonJS((exports2) => {
|
|
17506
17506
|
var FOLD_FLOW = "flow";
|
|
17507
17507
|
var FOLD_BLOCK = "block";
|
|
@@ -17638,7 +17638,7 @@ ${indent}${text.slice(fold + 1, end2)}`;
|
|
|
17638
17638
|
exports2.foldFlowLines = foldFlowLines;
|
|
17639
17639
|
});
|
|
17640
17640
|
|
|
17641
|
-
//
|
|
17641
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/stringify/stringifyString.js
|
|
17642
17642
|
var require_stringifyString = __commonJS((exports2) => {
|
|
17643
17643
|
var Scalar = require_Scalar();
|
|
17644
17644
|
var foldFlowLines = require_foldFlowLines();
|
|
@@ -17936,7 +17936,7 @@ ${indent}`);
|
|
|
17936
17936
|
exports2.stringifyString = stringifyString;
|
|
17937
17937
|
});
|
|
17938
17938
|
|
|
17939
|
-
//
|
|
17939
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/stringify/stringify.js
|
|
17940
17940
|
var require_stringify = __commonJS((exports2) => {
|
|
17941
17941
|
var anchors = require_anchors();
|
|
17942
17942
|
var identity = require_identity();
|
|
@@ -18057,7 +18057,7 @@ ${ctx.indent}${str}`;
|
|
|
18057
18057
|
exports2.stringify = stringify;
|
|
18058
18058
|
});
|
|
18059
18059
|
|
|
18060
|
-
//
|
|
18060
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/stringify/stringifyPair.js
|
|
18061
18061
|
var require_stringifyPair = __commonJS((exports2) => {
|
|
18062
18062
|
var identity = require_identity();
|
|
18063
18063
|
var Scalar = require_Scalar();
|
|
@@ -18193,7 +18193,7 @@ ${ctx.indent}`;
|
|
|
18193
18193
|
exports2.stringifyPair = stringifyPair;
|
|
18194
18194
|
});
|
|
18195
18195
|
|
|
18196
|
-
//
|
|
18196
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/log.js
|
|
18197
18197
|
var require_log = __commonJS((exports2) => {
|
|
18198
18198
|
var node_process = __require("process");
|
|
18199
18199
|
function debug(logLevel, ...messages) {
|
|
@@ -18212,7 +18212,7 @@ var require_log = __commonJS((exports2) => {
|
|
|
18212
18212
|
exports2.warn = warn;
|
|
18213
18213
|
});
|
|
18214
18214
|
|
|
18215
|
-
//
|
|
18215
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/yaml-1.1/merge.js
|
|
18216
18216
|
var require_merge = __commonJS((exports2) => {
|
|
18217
18217
|
var identity = require_identity();
|
|
18218
18218
|
var Scalar = require_Scalar();
|
|
@@ -18266,7 +18266,7 @@ var require_merge = __commonJS((exports2) => {
|
|
|
18266
18266
|
exports2.merge = merge;
|
|
18267
18267
|
});
|
|
18268
18268
|
|
|
18269
|
-
//
|
|
18269
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/nodes/addPairToJSMap.js
|
|
18270
18270
|
var require_addPairToJSMap = __commonJS((exports2) => {
|
|
18271
18271
|
var log = require_log();
|
|
18272
18272
|
var merge = require_merge();
|
|
@@ -18327,7 +18327,7 @@ var require_addPairToJSMap = __commonJS((exports2) => {
|
|
|
18327
18327
|
exports2.addPairToJSMap = addPairToJSMap;
|
|
18328
18328
|
});
|
|
18329
18329
|
|
|
18330
|
-
//
|
|
18330
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/nodes/Pair.js
|
|
18331
18331
|
var require_Pair = __commonJS((exports2) => {
|
|
18332
18332
|
var createNode = require_createNode();
|
|
18333
18333
|
var stringifyPair = require_stringifyPair();
|
|
@@ -18365,7 +18365,7 @@ var require_Pair = __commonJS((exports2) => {
|
|
|
18365
18365
|
exports2.createPair = createPair;
|
|
18366
18366
|
});
|
|
18367
18367
|
|
|
18368
|
-
//
|
|
18368
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/stringify/stringifyCollection.js
|
|
18369
18369
|
var require_stringifyCollection = __commonJS((exports2) => {
|
|
18370
18370
|
var identity = require_identity();
|
|
18371
18371
|
var stringify = require_stringify();
|
|
@@ -18517,7 +18517,7 @@ ${indent}${end}`;
|
|
|
18517
18517
|
exports2.stringifyCollection = stringifyCollection;
|
|
18518
18518
|
});
|
|
18519
18519
|
|
|
18520
|
-
//
|
|
18520
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/nodes/YAMLMap.js
|
|
18521
18521
|
var require_YAMLMap = __commonJS((exports2) => {
|
|
18522
18522
|
var stringifyCollection = require_stringifyCollection();
|
|
18523
18523
|
var addPairToJSMap = require_addPairToJSMap();
|
|
@@ -18644,7 +18644,7 @@ var require_YAMLMap = __commonJS((exports2) => {
|
|
|
18644
18644
|
exports2.findPair = findPair;
|
|
18645
18645
|
});
|
|
18646
18646
|
|
|
18647
|
-
//
|
|
18647
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/common/map.js
|
|
18648
18648
|
var require_map = __commonJS((exports2) => {
|
|
18649
18649
|
var identity = require_identity();
|
|
18650
18650
|
var YAMLMap = require_YAMLMap();
|
|
@@ -18663,7 +18663,7 @@ var require_map = __commonJS((exports2) => {
|
|
|
18663
18663
|
exports2.map = map;
|
|
18664
18664
|
});
|
|
18665
18665
|
|
|
18666
|
-
//
|
|
18666
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/nodes/YAMLSeq.js
|
|
18667
18667
|
var require_YAMLSeq = __commonJS((exports2) => {
|
|
18668
18668
|
var createNode = require_createNode();
|
|
18669
18669
|
var stringifyCollection = require_stringifyCollection();
|
|
@@ -18756,7 +18756,7 @@ var require_YAMLSeq = __commonJS((exports2) => {
|
|
|
18756
18756
|
exports2.YAMLSeq = YAMLSeq;
|
|
18757
18757
|
});
|
|
18758
18758
|
|
|
18759
|
-
//
|
|
18759
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/common/seq.js
|
|
18760
18760
|
var require_seq = __commonJS((exports2) => {
|
|
18761
18761
|
var identity = require_identity();
|
|
18762
18762
|
var YAMLSeq = require_YAMLSeq();
|
|
@@ -18775,7 +18775,7 @@ var require_seq = __commonJS((exports2) => {
|
|
|
18775
18775
|
exports2.seq = seq;
|
|
18776
18776
|
});
|
|
18777
18777
|
|
|
18778
|
-
//
|
|
18778
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/common/string.js
|
|
18779
18779
|
var require_string = __commonJS((exports2) => {
|
|
18780
18780
|
var stringifyString = require_stringifyString();
|
|
18781
18781
|
var string = {
|
|
@@ -18791,7 +18791,7 @@ var require_string = __commonJS((exports2) => {
|
|
|
18791
18791
|
exports2.string = string;
|
|
18792
18792
|
});
|
|
18793
18793
|
|
|
18794
|
-
//
|
|
18794
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/common/null.js
|
|
18795
18795
|
var require_null = __commonJS((exports2) => {
|
|
18796
18796
|
var Scalar = require_Scalar();
|
|
18797
18797
|
var nullTag = {
|
|
@@ -18806,7 +18806,7 @@ var require_null = __commonJS((exports2) => {
|
|
|
18806
18806
|
exports2.nullTag = nullTag;
|
|
18807
18807
|
});
|
|
18808
18808
|
|
|
18809
|
-
//
|
|
18809
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/core/bool.js
|
|
18810
18810
|
var require_bool = __commonJS((exports2) => {
|
|
18811
18811
|
var Scalar = require_Scalar();
|
|
18812
18812
|
var boolTag = {
|
|
@@ -18827,7 +18827,7 @@ var require_bool = __commonJS((exports2) => {
|
|
|
18827
18827
|
exports2.boolTag = boolTag;
|
|
18828
18828
|
});
|
|
18829
18829
|
|
|
18830
|
-
//
|
|
18830
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/stringify/stringifyNumber.js
|
|
18831
18831
|
var require_stringifyNumber = __commonJS((exports2) => {
|
|
18832
18832
|
function stringifyNumber({ format, minFractionDigits, tag, value }) {
|
|
18833
18833
|
if (typeof value === "bigint")
|
|
@@ -18851,7 +18851,7 @@ var require_stringifyNumber = __commonJS((exports2) => {
|
|
|
18851
18851
|
exports2.stringifyNumber = stringifyNumber;
|
|
18852
18852
|
});
|
|
18853
18853
|
|
|
18854
|
-
//
|
|
18854
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/core/float.js
|
|
18855
18855
|
var require_float = __commonJS((exports2) => {
|
|
18856
18856
|
var Scalar = require_Scalar();
|
|
18857
18857
|
var stringifyNumber = require_stringifyNumber();
|
|
@@ -18894,7 +18894,7 @@ var require_float = __commonJS((exports2) => {
|
|
|
18894
18894
|
exports2.floatNaN = floatNaN;
|
|
18895
18895
|
});
|
|
18896
18896
|
|
|
18897
|
-
//
|
|
18897
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/core/int.js
|
|
18898
18898
|
var require_int = __commonJS((exports2) => {
|
|
18899
18899
|
var stringifyNumber = require_stringifyNumber();
|
|
18900
18900
|
var intIdentify = (value) => typeof value === "bigint" || Number.isInteger(value);
|
|
@@ -18936,7 +18936,7 @@ var require_int = __commonJS((exports2) => {
|
|
|
18936
18936
|
exports2.intOct = intOct;
|
|
18937
18937
|
});
|
|
18938
18938
|
|
|
18939
|
-
//
|
|
18939
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/core/schema.js
|
|
18940
18940
|
var require_schema = __commonJS((exports2) => {
|
|
18941
18941
|
var map = require_map();
|
|
18942
18942
|
var _null = require_null();
|
|
@@ -18961,7 +18961,7 @@ var require_schema = __commonJS((exports2) => {
|
|
|
18961
18961
|
exports2.schema = schema;
|
|
18962
18962
|
});
|
|
18963
18963
|
|
|
18964
|
-
//
|
|
18964
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/json/schema.js
|
|
18965
18965
|
var require_schema2 = __commonJS((exports2) => {
|
|
18966
18966
|
var Scalar = require_Scalar();
|
|
18967
18967
|
var map = require_map();
|
|
@@ -19025,7 +19025,7 @@ var require_schema2 = __commonJS((exports2) => {
|
|
|
19025
19025
|
exports2.schema = schema;
|
|
19026
19026
|
});
|
|
19027
19027
|
|
|
19028
|
-
//
|
|
19028
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/yaml-1.1/binary.js
|
|
19029
19029
|
var require_binary = __commonJS((exports2) => {
|
|
19030
19030
|
var node_buffer = __require("buffer");
|
|
19031
19031
|
var Scalar = require_Scalar();
|
|
@@ -19080,7 +19080,7 @@ var require_binary = __commonJS((exports2) => {
|
|
|
19080
19080
|
exports2.binary = binary;
|
|
19081
19081
|
});
|
|
19082
19082
|
|
|
19083
|
-
//
|
|
19083
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/yaml-1.1/pairs.js
|
|
19084
19084
|
var require_pairs = __commonJS((exports2) => {
|
|
19085
19085
|
var identity = require_identity();
|
|
19086
19086
|
var Pair = require_Pair();
|
|
@@ -19155,7 +19155,7 @@ ${cn.comment}` : item.comment;
|
|
|
19155
19155
|
exports2.resolvePairs = resolvePairs;
|
|
19156
19156
|
});
|
|
19157
19157
|
|
|
19158
|
-
//
|
|
19158
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/yaml-1.1/omap.js
|
|
19159
19159
|
var require_omap = __commonJS((exports2) => {
|
|
19160
19160
|
var identity = require_identity();
|
|
19161
19161
|
var toJS = require_toJS();
|
|
@@ -19227,7 +19227,7 @@ var require_omap = __commonJS((exports2) => {
|
|
|
19227
19227
|
exports2.omap = omap;
|
|
19228
19228
|
});
|
|
19229
19229
|
|
|
19230
|
-
//
|
|
19230
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/yaml-1.1/bool.js
|
|
19231
19231
|
var require_bool2 = __commonJS((exports2) => {
|
|
19232
19232
|
var Scalar = require_Scalar();
|
|
19233
19233
|
function boolStringify({ value, source }, ctx) {
|
|
@@ -19256,7 +19256,7 @@ var require_bool2 = __commonJS((exports2) => {
|
|
|
19256
19256
|
exports2.trueTag = trueTag;
|
|
19257
19257
|
});
|
|
19258
19258
|
|
|
19259
|
-
//
|
|
19259
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/yaml-1.1/float.js
|
|
19260
19260
|
var require_float2 = __commonJS((exports2) => {
|
|
19261
19261
|
var Scalar = require_Scalar();
|
|
19262
19262
|
var stringifyNumber = require_stringifyNumber();
|
|
@@ -19302,7 +19302,7 @@ var require_float2 = __commonJS((exports2) => {
|
|
|
19302
19302
|
exports2.floatNaN = floatNaN;
|
|
19303
19303
|
});
|
|
19304
19304
|
|
|
19305
|
-
//
|
|
19305
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/yaml-1.1/int.js
|
|
19306
19306
|
var require_int2 = __commonJS((exports2) => {
|
|
19307
19307
|
var stringifyNumber = require_stringifyNumber();
|
|
19308
19308
|
var intIdentify = (value) => typeof value === "bigint" || Number.isInteger(value);
|
|
@@ -19378,7 +19378,7 @@ var require_int2 = __commonJS((exports2) => {
|
|
|
19378
19378
|
exports2.intOct = intOct;
|
|
19379
19379
|
});
|
|
19380
19380
|
|
|
19381
|
-
//
|
|
19381
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/yaml-1.1/set.js
|
|
19382
19382
|
var require_set = __commonJS((exports2) => {
|
|
19383
19383
|
var identity = require_identity();
|
|
19384
19384
|
var Pair = require_Pair();
|
|
@@ -19461,7 +19461,7 @@ var require_set = __commonJS((exports2) => {
|
|
|
19461
19461
|
exports2.set = set;
|
|
19462
19462
|
});
|
|
19463
19463
|
|
|
19464
|
-
//
|
|
19464
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/yaml-1.1/timestamp.js
|
|
19465
19465
|
var require_timestamp = __commonJS((exports2) => {
|
|
19466
19466
|
var stringifyNumber = require_stringifyNumber();
|
|
19467
19467
|
function parseSexagesimal(str, asBigInt) {
|
|
@@ -19543,7 +19543,7 @@ var require_timestamp = __commonJS((exports2) => {
|
|
|
19543
19543
|
exports2.timestamp = timestamp;
|
|
19544
19544
|
});
|
|
19545
19545
|
|
|
19546
|
-
//
|
|
19546
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/yaml-1.1/schema.js
|
|
19547
19547
|
var require_schema3 = __commonJS((exports2) => {
|
|
19548
19548
|
var map = require_map();
|
|
19549
19549
|
var _null = require_null();
|
|
@@ -19584,7 +19584,7 @@ var require_schema3 = __commonJS((exports2) => {
|
|
|
19584
19584
|
exports2.schema = schema;
|
|
19585
19585
|
});
|
|
19586
19586
|
|
|
19587
|
-
//
|
|
19587
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/tags.js
|
|
19588
19588
|
var require_tags = __commonJS((exports2) => {
|
|
19589
19589
|
var map = require_map();
|
|
19590
19590
|
var _null = require_null();
|
|
@@ -19675,7 +19675,7 @@ var require_tags = __commonJS((exports2) => {
|
|
|
19675
19675
|
exports2.getTags = getTags;
|
|
19676
19676
|
});
|
|
19677
19677
|
|
|
19678
|
-
//
|
|
19678
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/schema/Schema.js
|
|
19679
19679
|
var require_Schema = __commonJS((exports2) => {
|
|
19680
19680
|
var identity = require_identity();
|
|
19681
19681
|
var map = require_map();
|
|
@@ -19705,7 +19705,7 @@ var require_Schema = __commonJS((exports2) => {
|
|
|
19705
19705
|
exports2.Schema = Schema;
|
|
19706
19706
|
});
|
|
19707
19707
|
|
|
19708
|
-
//
|
|
19708
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/stringify/stringifyDocument.js
|
|
19709
19709
|
var require_stringifyDocument = __commonJS((exports2) => {
|
|
19710
19710
|
var identity = require_identity();
|
|
19711
19711
|
var stringify = require_stringify();
|
|
@@ -19785,7 +19785,7 @@ var require_stringifyDocument = __commonJS((exports2) => {
|
|
|
19785
19785
|
exports2.stringifyDocument = stringifyDocument;
|
|
19786
19786
|
});
|
|
19787
19787
|
|
|
19788
|
-
//
|
|
19788
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/doc/Document.js
|
|
19789
19789
|
var require_Document = __commonJS((exports2) => {
|
|
19790
19790
|
var Alias = require_Alias();
|
|
19791
19791
|
var Collection = require_Collection();
|
|
@@ -20020,7 +20020,7 @@ var require_Document = __commonJS((exports2) => {
|
|
|
20020
20020
|
exports2.Document = Document;
|
|
20021
20021
|
});
|
|
20022
20022
|
|
|
20023
|
-
//
|
|
20023
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/errors.js
|
|
20024
20024
|
var require_errors = __commonJS((exports2) => {
|
|
20025
20025
|
class YAMLError extends Error {
|
|
20026
20026
|
constructor(name, pos, code, message) {
|
|
@@ -20085,7 +20085,7 @@ ${pointer}
|
|
|
20085
20085
|
exports2.prettifyError = prettifyError;
|
|
20086
20086
|
});
|
|
20087
20087
|
|
|
20088
|
-
//
|
|
20088
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/compose/resolve-props.js
|
|
20089
20089
|
var require_resolve_props = __commonJS((exports2) => {
|
|
20090
20090
|
function resolveProps(tokens, { flow, indicator, next, offset, onError, parentIndent, startOnNewline }) {
|
|
20091
20091
|
let spaceBefore = false;
|
|
@@ -20215,7 +20215,7 @@ var require_resolve_props = __commonJS((exports2) => {
|
|
|
20215
20215
|
exports2.resolveProps = resolveProps;
|
|
20216
20216
|
});
|
|
20217
20217
|
|
|
20218
|
-
//
|
|
20218
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/compose/util-contains-newline.js
|
|
20219
20219
|
var require_util_contains_newline = __commonJS((exports2) => {
|
|
20220
20220
|
function containsNewline(key) {
|
|
20221
20221
|
if (!key)
|
|
@@ -20255,7 +20255,7 @@ var require_util_contains_newline = __commonJS((exports2) => {
|
|
|
20255
20255
|
exports2.containsNewline = containsNewline;
|
|
20256
20256
|
});
|
|
20257
20257
|
|
|
20258
|
-
//
|
|
20258
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/compose/util-flow-indent-check.js
|
|
20259
20259
|
var require_util_flow_indent_check = __commonJS((exports2) => {
|
|
20260
20260
|
var utilContainsNewline = require_util_contains_newline();
|
|
20261
20261
|
function flowIndentCheck(indent, fc, onError) {
|
|
@@ -20270,7 +20270,7 @@ var require_util_flow_indent_check = __commonJS((exports2) => {
|
|
|
20270
20270
|
exports2.flowIndentCheck = flowIndentCheck;
|
|
20271
20271
|
});
|
|
20272
20272
|
|
|
20273
|
-
//
|
|
20273
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/compose/util-map-includes.js
|
|
20274
20274
|
var require_util_map_includes = __commonJS((exports2) => {
|
|
20275
20275
|
var identity = require_identity();
|
|
20276
20276
|
function mapIncludes(ctx, items, search) {
|
|
@@ -20283,7 +20283,7 @@ var require_util_map_includes = __commonJS((exports2) => {
|
|
|
20283
20283
|
exports2.mapIncludes = mapIncludes;
|
|
20284
20284
|
});
|
|
20285
20285
|
|
|
20286
|
-
//
|
|
20286
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/compose/resolve-block-map.js
|
|
20287
20287
|
var require_resolve_block_map = __commonJS((exports2) => {
|
|
20288
20288
|
var Pair = require_Pair();
|
|
20289
20289
|
var YAMLMap = require_YAMLMap();
|
|
@@ -20390,7 +20390,7 @@ var require_resolve_block_map = __commonJS((exports2) => {
|
|
|
20390
20390
|
exports2.resolveBlockMap = resolveBlockMap;
|
|
20391
20391
|
});
|
|
20392
20392
|
|
|
20393
|
-
//
|
|
20393
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/compose/resolve-block-seq.js
|
|
20394
20394
|
var require_resolve_block_seq = __commonJS((exports2) => {
|
|
20395
20395
|
var YAMLSeq = require_YAMLSeq();
|
|
20396
20396
|
var resolveProps = require_resolve_props();
|
|
@@ -20438,7 +20438,7 @@ var require_resolve_block_seq = __commonJS((exports2) => {
|
|
|
20438
20438
|
exports2.resolveBlockSeq = resolveBlockSeq;
|
|
20439
20439
|
});
|
|
20440
20440
|
|
|
20441
|
-
//
|
|
20441
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/compose/resolve-end.js
|
|
20442
20442
|
var require_resolve_end = __commonJS((exports2) => {
|
|
20443
20443
|
function resolveEnd(end, offset, reqSpace, onError) {
|
|
20444
20444
|
let comment = "";
|
|
@@ -20478,7 +20478,7 @@ var require_resolve_end = __commonJS((exports2) => {
|
|
|
20478
20478
|
exports2.resolveEnd = resolveEnd;
|
|
20479
20479
|
});
|
|
20480
20480
|
|
|
20481
|
-
//
|
|
20481
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/compose/resolve-flow-collection.js
|
|
20482
20482
|
var require_resolve_flow_collection = __commonJS((exports2) => {
|
|
20483
20483
|
var identity = require_identity();
|
|
20484
20484
|
var Pair = require_Pair();
|
|
@@ -20669,7 +20669,7 @@ var require_resolve_flow_collection = __commonJS((exports2) => {
|
|
|
20669
20669
|
exports2.resolveFlowCollection = resolveFlowCollection;
|
|
20670
20670
|
});
|
|
20671
20671
|
|
|
20672
|
-
//
|
|
20672
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/compose/compose-collection.js
|
|
20673
20673
|
var require_compose_collection = __commonJS((exports2) => {
|
|
20674
20674
|
var identity = require_identity();
|
|
20675
20675
|
var Scalar = require_Scalar();
|
|
@@ -20731,7 +20731,7 @@ var require_compose_collection = __commonJS((exports2) => {
|
|
|
20731
20731
|
exports2.composeCollection = composeCollection;
|
|
20732
20732
|
});
|
|
20733
20733
|
|
|
20734
|
-
//
|
|
20734
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/compose/resolve-block-scalar.js
|
|
20735
20735
|
var require_resolve_block_scalar = __commonJS((exports2) => {
|
|
20736
20736
|
var Scalar = require_Scalar();
|
|
20737
20737
|
function resolveBlockScalar(ctx, scalar, onError) {
|
|
@@ -20924,7 +20924,7 @@ var require_resolve_block_scalar = __commonJS((exports2) => {
|
|
|
20924
20924
|
exports2.resolveBlockScalar = resolveBlockScalar;
|
|
20925
20925
|
});
|
|
20926
20926
|
|
|
20927
|
-
//
|
|
20927
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/compose/resolve-flow-scalar.js
|
|
20928
20928
|
var require_resolve_flow_scalar = __commonJS((exports2) => {
|
|
20929
20929
|
var Scalar = require_Scalar();
|
|
20930
20930
|
var resolveEnd = require_resolve_end();
|
|
@@ -21140,7 +21140,7 @@ var require_resolve_flow_scalar = __commonJS((exports2) => {
|
|
|
21140
21140
|
exports2.resolveFlowScalar = resolveFlowScalar;
|
|
21141
21141
|
});
|
|
21142
21142
|
|
|
21143
|
-
//
|
|
21143
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/compose/compose-scalar.js
|
|
21144
21144
|
var require_compose_scalar = __commonJS((exports2) => {
|
|
21145
21145
|
var identity = require_identity();
|
|
21146
21146
|
var Scalar = require_Scalar();
|
|
@@ -21218,7 +21218,7 @@ var require_compose_scalar = __commonJS((exports2) => {
|
|
|
21218
21218
|
exports2.composeScalar = composeScalar;
|
|
21219
21219
|
});
|
|
21220
21220
|
|
|
21221
|
-
//
|
|
21221
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/compose/util-empty-scalar-position.js
|
|
21222
21222
|
var require_util_empty_scalar_position = __commonJS((exports2) => {
|
|
21223
21223
|
function emptyScalarPosition(offset, before, pos) {
|
|
21224
21224
|
if (before) {
|
|
@@ -21245,7 +21245,7 @@ var require_util_empty_scalar_position = __commonJS((exports2) => {
|
|
|
21245
21245
|
exports2.emptyScalarPosition = emptyScalarPosition;
|
|
21246
21246
|
});
|
|
21247
21247
|
|
|
21248
|
-
//
|
|
21248
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/compose/compose-node.js
|
|
21249
21249
|
var require_compose_node = __commonJS((exports2) => {
|
|
21250
21250
|
var Alias = require_Alias();
|
|
21251
21251
|
var identity = require_identity();
|
|
@@ -21348,7 +21348,7 @@ var require_compose_node = __commonJS((exports2) => {
|
|
|
21348
21348
|
exports2.composeNode = composeNode;
|
|
21349
21349
|
});
|
|
21350
21350
|
|
|
21351
|
-
//
|
|
21351
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/compose/compose-doc.js
|
|
21352
21352
|
var require_compose_doc = __commonJS((exports2) => {
|
|
21353
21353
|
var Document = require_Document();
|
|
21354
21354
|
var composeNode = require_compose_node();
|
|
@@ -21388,7 +21388,7 @@ var require_compose_doc = __commonJS((exports2) => {
|
|
|
21388
21388
|
exports2.composeDoc = composeDoc;
|
|
21389
21389
|
});
|
|
21390
21390
|
|
|
21391
|
-
//
|
|
21391
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/compose/composer.js
|
|
21392
21392
|
var require_composer2 = __commonJS((exports2) => {
|
|
21393
21393
|
var node_process = __require("process");
|
|
21394
21394
|
var directives = require_directives();
|
|
@@ -21577,7 +21577,7 @@ ${end.comment}` : end.comment;
|
|
|
21577
21577
|
exports2.Composer = Composer;
|
|
21578
21578
|
});
|
|
21579
21579
|
|
|
21580
|
-
//
|
|
21580
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/parse/cst-scalar.js
|
|
21581
21581
|
var require_cst_scalar = __commonJS((exports2) => {
|
|
21582
21582
|
var resolveBlockScalar = require_resolve_block_scalar();
|
|
21583
21583
|
var resolveFlowScalar = require_resolve_flow_scalar();
|
|
@@ -21767,7 +21767,7 @@ var require_cst_scalar = __commonJS((exports2) => {
|
|
|
21767
21767
|
exports2.setScalarValue = setScalarValue;
|
|
21768
21768
|
});
|
|
21769
21769
|
|
|
21770
|
-
//
|
|
21770
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/parse/cst-stringify.js
|
|
21771
21771
|
var require_cst_stringify = __commonJS((exports2) => {
|
|
21772
21772
|
var stringify = (cst) => ("type" in cst) ? stringifyToken(cst) : stringifyItem(cst);
|
|
21773
21773
|
function stringifyToken(token) {
|
|
@@ -21825,7 +21825,7 @@ var require_cst_stringify = __commonJS((exports2) => {
|
|
|
21825
21825
|
exports2.stringify = stringify;
|
|
21826
21826
|
});
|
|
21827
21827
|
|
|
21828
|
-
//
|
|
21828
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/parse/cst-visit.js
|
|
21829
21829
|
var require_cst_visit = __commonJS((exports2) => {
|
|
21830
21830
|
var BREAK = Symbol("break visit");
|
|
21831
21831
|
var SKIP = Symbol("skip children");
|
|
@@ -21884,7 +21884,7 @@ var require_cst_visit = __commonJS((exports2) => {
|
|
|
21884
21884
|
exports2.visit = visit;
|
|
21885
21885
|
});
|
|
21886
21886
|
|
|
21887
|
-
//
|
|
21887
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/parse/cst.js
|
|
21888
21888
|
var require_cst = __commonJS((exports2) => {
|
|
21889
21889
|
var cstScalar = require_cst_scalar();
|
|
21890
21890
|
var cstStringify = require_cst_stringify();
|
|
@@ -21985,7 +21985,7 @@ var require_cst = __commonJS((exports2) => {
|
|
|
21985
21985
|
exports2.tokenType = tokenType;
|
|
21986
21986
|
});
|
|
21987
21987
|
|
|
21988
|
-
//
|
|
21988
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/parse/lexer.js
|
|
21989
21989
|
var require_lexer = __commonJS((exports2) => {
|
|
21990
21990
|
var cst = require_cst();
|
|
21991
21991
|
function isEmpty2(ch) {
|
|
@@ -22571,7 +22571,7 @@ var require_lexer = __commonJS((exports2) => {
|
|
|
22571
22571
|
exports2.Lexer = Lexer;
|
|
22572
22572
|
});
|
|
22573
22573
|
|
|
22574
|
-
//
|
|
22574
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/parse/line-counter.js
|
|
22575
22575
|
var require_line_counter = __commonJS((exports2) => {
|
|
22576
22576
|
class LineCounter {
|
|
22577
22577
|
constructor() {
|
|
@@ -22599,7 +22599,7 @@ var require_line_counter = __commonJS((exports2) => {
|
|
|
22599
22599
|
exports2.LineCounter = LineCounter;
|
|
22600
22600
|
});
|
|
22601
22601
|
|
|
22602
|
-
//
|
|
22602
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/parse/parser.js
|
|
22603
22603
|
var require_parser = __commonJS((exports2) => {
|
|
22604
22604
|
var node_process = __require("process");
|
|
22605
22605
|
var cst = require_cst();
|
|
@@ -23448,7 +23448,7 @@ var require_parser = __commonJS((exports2) => {
|
|
|
23448
23448
|
exports2.Parser = Parser;
|
|
23449
23449
|
});
|
|
23450
23450
|
|
|
23451
|
-
//
|
|
23451
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/public-api.js
|
|
23452
23452
|
var require_public_api = __commonJS((exports2) => {
|
|
23453
23453
|
var composer = require_composer2();
|
|
23454
23454
|
var Document = require_Document();
|
|
@@ -23542,7 +23542,7 @@ var require_public_api = __commonJS((exports2) => {
|
|
|
23542
23542
|
exports2.stringify = stringify;
|
|
23543
23543
|
});
|
|
23544
23544
|
|
|
23545
|
-
//
|
|
23545
|
+
// ../../switchroom/node_modules/.bun/yaml@2.8.3/node_modules/yaml/dist/index.js
|
|
23546
23546
|
var composer, Document, Schema, errors2, Alias, identity, Pair, Scalar, YAMLMap, YAMLSeq, cst, lexer, lineCounter, parser, publicApi, visit, $Composer, $Document, $Schema, $YAMLError, $YAMLParseError, $YAMLWarning, $Alias, $isAlias, $isCollection, $isDocument, $isMap, $isNode, $isPair, $isScalar, $isSeq, $Pair, $Scalar, $YAMLMap, $YAMLSeq, $Lexer, $LineCounter, $Parser, $parse, $parseAllDocuments, $parseDocument, $stringify, $visit, $visitAsync;
|
|
23547
23547
|
var init_dist = __esm(() => {
|
|
23548
23548
|
composer = require_composer2();
|
|
@@ -23664,7 +23664,8 @@ var init_schema = __esm(() => {
|
|
|
23664
23664
|
});
|
|
23665
23665
|
SessionSchema = exports_external.object({
|
|
23666
23666
|
max_idle: exports_external.string().regex(/^\d+[smh]$/, "Duration must be a number followed by s, m, or h (e.g. '2h', '30m')").optional().describe("Start a fresh session if the previous one has been idle " + "longer than this duration. Examples: '2h', '30m', '7200s'."),
|
|
23667
|
-
max_turns: exports_external.number().int().positive().optional().describe("Start a fresh session if the previous one has more user " + "turns than this. Useful for preventing context bloat on " + "long-running agents.")
|
|
23667
|
+
max_turns: exports_external.number().int().positive().optional().describe("Start a fresh session if the previous one has more user " + "turns than this. Useful for preventing context bloat on " + "long-running agents."),
|
|
23668
|
+
max_context_tokens: exports_external.number().int().positive().optional().describe("Proactively run /compact when the live context window " + "occupancy (latest assistant turn input + cache-read + " + "cache-creation tokens) reaches this many tokens. Opt-in: " + "unset means rely on Claude Code's native auto-compaction. " + "Useful on large-window models (e.g. 1M Opus) to hold a " + "deliberately lean working context.")
|
|
23668
23669
|
}).optional();
|
|
23669
23670
|
SessionContinuitySchema = exports_external.object({
|
|
23670
23671
|
enabled: exports_external.boolean().optional().describe("Master switch for the session-handoff briefing (default true)."),
|
|
@@ -25281,7 +25282,7 @@ function deriveSlug(inputs, existing) {
|
|
|
25281
25282
|
return `${base}_${n}`;
|
|
25282
25283
|
}
|
|
25283
25284
|
|
|
25284
|
-
//
|
|
25285
|
+
// ../../switchroom/node_modules/.bun/boundary@2.0.0/node_modules/boundary/lib/index.js
|
|
25285
25286
|
var require_lib = __commonJS((exports2) => {
|
|
25286
25287
|
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
25287
25288
|
exports2.binarySearch = exports2.upperBound = exports2.lowerBound = exports2.compare = undefined;
|
|
@@ -25328,7 +25329,7 @@ var require_lib = __commonJS((exports2) => {
|
|
|
25328
25329
|
exports2.binarySearch = binarySearch;
|
|
25329
25330
|
});
|
|
25330
25331
|
|
|
25331
|
-
//
|
|
25332
|
+
// ../../switchroom/node_modules/.bun/structured-source@4.0.0/node_modules/structured-source/lib/structured-source.js
|
|
25332
25333
|
var require_structured_source = __commonJS((exports2) => {
|
|
25333
25334
|
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
25334
25335
|
exports2.StructuredSource = undefined;
|
|
@@ -25383,13 +25384,13 @@ var require_structured_source = __commonJS((exports2) => {
|
|
|
25383
25384
|
}
|
|
25384
25385
|
exports2.StructuredSource = StructuredSource;
|
|
25385
25386
|
});
|
|
25386
|
-
//
|
|
25387
|
+
// ../../switchroom/node_modules/.bun/@secretlint+core@12.2.0/node_modules/@secretlint/core/module/SecretLintSourceCodeImpl.js
|
|
25387
25388
|
var import_structured_source;
|
|
25388
25389
|
var init_SecretLintSourceCodeImpl = __esm(() => {
|
|
25389
25390
|
import_structured_source = __toESM(require_structured_source(), 1);
|
|
25390
25391
|
});
|
|
25391
25392
|
|
|
25392
|
-
//
|
|
25393
|
+
// ../../switchroom/node_modules/.bun/@secretlint+core@12.2.0/node_modules/@secretlint/core/module/helper/promise-event-emitter.js
|
|
25393
25394
|
class EventEmitter {
|
|
25394
25395
|
#listeners = new Map;
|
|
25395
25396
|
on(type, listener) {
|
|
@@ -25428,9 +25429,9 @@ class EventEmitter {
|
|
|
25428
25429
|
return Array.from(this.#listeners.get(type) ?? []);
|
|
25429
25430
|
}
|
|
25430
25431
|
}
|
|
25431
|
-
//
|
|
25432
|
+
// ../../switchroom/node_modules/.bun/@secretlint+core@12.2.0/node_modules/@secretlint/core/module/RuleContext.js
|
|
25432
25433
|
var init_RuleContext = () => {};
|
|
25433
|
-
//
|
|
25434
|
+
// ../../switchroom/node_modules/.bun/@secretlint+profiler@12.2.0/node_modules/@secretlint/profiler/module/index.js
|
|
25434
25435
|
class SecretLintProfiler {
|
|
25435
25436
|
perf;
|
|
25436
25437
|
entries = [];
|
|
@@ -25487,7 +25488,7 @@ class SecretLintProfiler {
|
|
|
25487
25488
|
}
|
|
25488
25489
|
}
|
|
25489
25490
|
|
|
25490
|
-
//
|
|
25491
|
+
// ../../switchroom/node_modules/.bun/@secretlint+profiler@12.2.0/node_modules/@secretlint/profiler/module/node.js
|
|
25491
25492
|
import perf_hooks from "node:perf_hooks";
|
|
25492
25493
|
|
|
25493
25494
|
class NullPerformanceObserver {
|
|
@@ -25502,19 +25503,19 @@ var init_node = __esm(() => {
|
|
|
25502
25503
|
});
|
|
25503
25504
|
});
|
|
25504
25505
|
|
|
25505
|
-
//
|
|
25506
|
+
// ../../switchroom/node_modules/.bun/@secretlint+core@12.2.0/node_modules/@secretlint/core/module/RunningEvents.js
|
|
25506
25507
|
var init_RunningEvents = __esm(() => {
|
|
25507
25508
|
init_node();
|
|
25508
25509
|
});
|
|
25509
25510
|
|
|
25510
|
-
//
|
|
25511
|
+
// ../../switchroom/node_modules/.bun/@secretlint+core@12.2.0/node_modules/@secretlint/core/module/RulePresetContext.js
|
|
25511
25512
|
var init_RulePresetContext = __esm(() => {
|
|
25512
25513
|
init_RuleContext();
|
|
25513
25514
|
});
|
|
25514
|
-
//
|
|
25515
|
+
// ../../switchroom/node_modules/.bun/@secretlint+core@12.2.0/node_modules/@secretlint/core/module/messages/index.js
|
|
25515
25516
|
var init_messages = () => {};
|
|
25516
25517
|
|
|
25517
|
-
//
|
|
25518
|
+
// ../../switchroom/node_modules/.bun/@secretlint+core@12.2.0/node_modules/@secretlint/core/module/index.js
|
|
25518
25519
|
var import_debug, debug;
|
|
25519
25520
|
var init_module = __esm(() => {
|
|
25520
25521
|
init_SecretLintSourceCodeImpl();
|
|
@@ -25527,7 +25528,7 @@ var init_module = __esm(() => {
|
|
|
25527
25528
|
debug = import_debug.default("@secretlint/core");
|
|
25528
25529
|
});
|
|
25529
25530
|
|
|
25530
|
-
//
|
|
25531
|
+
// ../../switchroom/node_modules/.bun/@secretlint+secretlint-rule-preset-recommend@12.2.0/node_modules/@secretlint/secretlint-rule-preset-recommend/module/index.js
|
|
25531
25532
|
function requireLodash_uniq() {
|
|
25532
25533
|
if (hasRequiredLodash_uniq)
|
|
25533
25534
|
return lodash_uniq;
|
|
@@ -27287,7 +27288,7 @@ function renderAuthLine(state3, agentName3, now = Date.now()) {
|
|
|
27287
27288
|
}
|
|
27288
27289
|
|
|
27289
27290
|
// gateway/quota-cache.ts
|
|
27290
|
-
import { existsSync as
|
|
27291
|
+
import { existsSync as existsSync23, readFileSync as readFileSync22, writeFileSync as writeFileSync13, mkdirSync as mkdirSync11 } from "fs";
|
|
27291
27292
|
import { join as join20, dirname as dirname8 } from "path";
|
|
27292
27293
|
function defaultCachePath() {
|
|
27293
27294
|
return process.env.SWITCHROOM_QUOTA_CACHE_PATH ?? join20(process.env.HOME ?? "/tmp", ".switchroom", "quota-cache.json");
|
|
@@ -27295,11 +27296,11 @@ function defaultCachePath() {
|
|
|
27295
27296
|
function readQuotaCache(opts = {}) {
|
|
27296
27297
|
const path = opts.path ?? defaultCachePath();
|
|
27297
27298
|
const now = opts.now ?? Date.now();
|
|
27298
|
-
if (!
|
|
27299
|
+
if (!existsSync23(path))
|
|
27299
27300
|
return null;
|
|
27300
27301
|
let entry;
|
|
27301
27302
|
try {
|
|
27302
|
-
entry = JSON.parse(
|
|
27303
|
+
entry = JSON.parse(readFileSync22(path, "utf8"));
|
|
27303
27304
|
} catch {
|
|
27304
27305
|
return null;
|
|
27305
27306
|
}
|
|
@@ -27336,7 +27337,7 @@ var init_quota_cache = __esm(() => {
|
|
|
27336
27337
|
});
|
|
27337
27338
|
|
|
27338
27339
|
// gateway/boot-probes.ts
|
|
27339
|
-
import { readFileSync as
|
|
27340
|
+
import { readFileSync as readFileSync23, readdirSync as readdirSync4, existsSync as existsSync24 } from "fs";
|
|
27340
27341
|
import { join as join21 } from "path";
|
|
27341
27342
|
import { execFile as execFileCb } from "child_process";
|
|
27342
27343
|
import { promisify as promisify3 } from "util";
|
|
@@ -27383,7 +27384,7 @@ async function probeAccount(agentDir) {
|
|
|
27383
27384
|
const claudeJsonPath = join21(claudeDir, ".claude.json");
|
|
27384
27385
|
let cfg = {};
|
|
27385
27386
|
try {
|
|
27386
|
-
const raw =
|
|
27387
|
+
const raw = readFileSync23(claudeJsonPath, "utf8");
|
|
27387
27388
|
cfg = JSON.parse(raw);
|
|
27388
27389
|
} catch {
|
|
27389
27390
|
return { status: "fail", label: "Account", detail: "no .claude.json" };
|
|
@@ -27404,9 +27405,9 @@ async function probeAccount(agentDir) {
|
|
|
27404
27405
|
join21(claudeDir, ".oauth-token.meta.json"),
|
|
27405
27406
|
join21(claudeDir, "accounts", "default", ".oauth-token.meta.json")
|
|
27406
27407
|
]) {
|
|
27407
|
-
if (
|
|
27408
|
+
if (existsSync24(candidate)) {
|
|
27408
27409
|
try {
|
|
27409
|
-
const meta = JSON.parse(
|
|
27410
|
+
const meta = JSON.parse(readFileSync23(candidate, "utf8"));
|
|
27410
27411
|
if (meta.expiresAt) {
|
|
27411
27412
|
tokenStr = " \u00b7 " + formatDaysFromNow(meta.expiresAt);
|
|
27412
27413
|
const daysLeft = Math.round((meta.expiresAt - Date.now()) / 86400000);
|
|
@@ -27580,9 +27581,9 @@ async function resolveTmuxSupervisorPid(agentName3, execFileImpl) {
|
|
|
27580
27581
|
if (!cgroup)
|
|
27581
27582
|
return null;
|
|
27582
27583
|
const procsPath = `/sys/fs/cgroup${cgroup}/cgroup.procs`;
|
|
27583
|
-
if (!
|
|
27584
|
+
if (!existsSync24(procsPath))
|
|
27584
27585
|
return null;
|
|
27585
|
-
const pidsRaw =
|
|
27586
|
+
const pidsRaw = readFileSync23(procsPath, "utf-8");
|
|
27586
27587
|
const pids = pidsRaw.split(`
|
|
27587
27588
|
`).map((s) => s.trim()).filter(Boolean);
|
|
27588
27589
|
if (pids.length === 0)
|
|
@@ -27595,7 +27596,7 @@ async function resolveTmuxSupervisorPid(agentName3, execFileImpl) {
|
|
|
27595
27596
|
let rss = 0;
|
|
27596
27597
|
let comm = "";
|
|
27597
27598
|
try {
|
|
27598
|
-
const status =
|
|
27599
|
+
const status = readFileSync23(`/proc/${pid}/status`, "utf-8");
|
|
27599
27600
|
const rssLine = status.split(`
|
|
27600
27601
|
`).find((l) => l.startsWith("VmRSS:"));
|
|
27601
27602
|
if (rssLine) {
|
|
@@ -27607,7 +27608,7 @@ async function resolveTmuxSupervisorPid(agentName3, execFileImpl) {
|
|
|
27607
27608
|
continue;
|
|
27608
27609
|
}
|
|
27609
27610
|
try {
|
|
27610
|
-
comm =
|
|
27611
|
+
comm = readFileSync23(`/proc/${pid}/comm`, "utf-8").trim();
|
|
27611
27612
|
} catch {}
|
|
27612
27613
|
candidates.push({ pid, rss, comm });
|
|
27613
27614
|
}
|
|
@@ -27789,7 +27790,7 @@ async function probeQuota(claudeConfigDir, _agentDir, fetchImpl = fetch, opts =
|
|
|
27789
27790
|
claudeConfigDir,
|
|
27790
27791
|
join21(claudeConfigDir, "accounts", "default")
|
|
27791
27792
|
]) {
|
|
27792
|
-
if (
|
|
27793
|
+
if (existsSync24(join21(candidate, ".oauth-token"))) {
|
|
27793
27794
|
claudeDirForProbe = candidate;
|
|
27794
27795
|
break;
|
|
27795
27796
|
}
|
|
@@ -27854,7 +27855,7 @@ async function probeHindsight(bankName, fetchImpl = fetch) {
|
|
|
27854
27855
|
}
|
|
27855
27856
|
function readContainerBootTimeMsForProbe() {
|
|
27856
27857
|
try {
|
|
27857
|
-
const stat1 =
|
|
27858
|
+
const stat1 = readFileSync23("/proc/1/stat", "utf8");
|
|
27858
27859
|
const lastParen = stat1.lastIndexOf(")");
|
|
27859
27860
|
if (lastParen < 0)
|
|
27860
27861
|
return null;
|
|
@@ -27862,7 +27863,7 @@ function readContainerBootTimeMsForProbe() {
|
|
|
27862
27863
|
const starttimeTicks = Number(after[19]);
|
|
27863
27864
|
if (!Number.isFinite(starttimeTicks))
|
|
27864
27865
|
return null;
|
|
27865
|
-
const procStat =
|
|
27866
|
+
const procStat = readFileSync23("/proc/stat", "utf8");
|
|
27866
27867
|
const btimeLine = procStat.split(`
|
|
27867
27868
|
`).find((l) => l.startsWith("btime "));
|
|
27868
27869
|
if (!btimeLine)
|
|
@@ -27960,7 +27961,7 @@ async function probeUds(label, socketPath, opts = {}) {
|
|
|
27960
27961
|
}
|
|
27961
27962
|
return withTimeout(label, (async () => {
|
|
27962
27963
|
if (!opts.connectImpl) {
|
|
27963
|
-
if (!
|
|
27964
|
+
if (!existsSync24(socketPath)) {
|
|
27964
27965
|
return {
|
|
27965
27966
|
status: "fail",
|
|
27966
27967
|
label,
|
|
@@ -28096,24 +28097,24 @@ var init_boot_probes = __esm(() => {
|
|
|
28096
28097
|
execFile3 = promisify3(execFileCb);
|
|
28097
28098
|
realProcFs = {
|
|
28098
28099
|
readdir: (p) => readdirSync4(p),
|
|
28099
|
-
readFile: (p) =>
|
|
28100
|
+
readFile: (p) => readFileSync23(p, "utf-8")
|
|
28100
28101
|
};
|
|
28101
28102
|
realSchedulerFs = {
|
|
28102
|
-
readFile: (p) =>
|
|
28103
|
+
readFile: (p) => readFileSync23(p, "utf-8"),
|
|
28103
28104
|
mtimeMs: (p) => {
|
|
28104
28105
|
const { statSync: statSync7 } = __require("fs");
|
|
28105
28106
|
return statSync7(p).mtimeMs;
|
|
28106
28107
|
},
|
|
28107
|
-
exists: (p) =>
|
|
28108
|
+
exists: (p) => existsSync24(p)
|
|
28108
28109
|
};
|
|
28109
28110
|
realSkillsFs = {
|
|
28110
28111
|
readdir: (p) => readdirSync4(p),
|
|
28111
|
-
exists: (p) =>
|
|
28112
|
+
exists: (p) => existsSync24(p)
|
|
28112
28113
|
};
|
|
28113
28114
|
});
|
|
28114
28115
|
|
|
28115
28116
|
// gateway/boot-issue-cache.ts
|
|
28116
|
-
import { existsSync as
|
|
28117
|
+
import { existsSync as existsSync25, readFileSync as readFileSync24, writeFileSync as writeFileSync14, mkdirSync as mkdirSync12, renameSync as renameSync9 } from "fs";
|
|
28117
28118
|
import { dirname as dirname9 } from "path";
|
|
28118
28119
|
function fingerprintProbe(key, r) {
|
|
28119
28120
|
if (r.status === "ok")
|
|
@@ -28193,11 +28194,11 @@ function diffProbes(probes, cache, opts = {}) {
|
|
|
28193
28194
|
return out;
|
|
28194
28195
|
}
|
|
28195
28196
|
function loadCache(path, now = Date.now) {
|
|
28196
|
-
if (!
|
|
28197
|
+
if (!existsSync25(path))
|
|
28197
28198
|
return { ...EMPTY_CACHE, probes: {} };
|
|
28198
28199
|
let raw;
|
|
28199
28200
|
try {
|
|
28200
|
-
raw =
|
|
28201
|
+
raw = readFileSync24(path, "utf-8");
|
|
28201
28202
|
} catch {
|
|
28202
28203
|
return { ...EMPTY_CACHE, probes: {} };
|
|
28203
28204
|
}
|
|
@@ -28587,9 +28588,9 @@ var init_flock = () => {};
|
|
|
28587
28588
|
// ../src/vault/vault.ts
|
|
28588
28589
|
import { randomBytes as randomBytes5, scryptSync, createCipheriv, createDecipheriv } from "node:crypto";
|
|
28589
28590
|
import {
|
|
28590
|
-
readFileSync as
|
|
28591
|
+
readFileSync as readFileSync31,
|
|
28591
28592
|
writeFileSync as writeFileSync19,
|
|
28592
|
-
existsSync as
|
|
28593
|
+
existsSync as existsSync32,
|
|
28593
28594
|
renameSync as renameSync11,
|
|
28594
28595
|
mkdirSync as mkdirSync18,
|
|
28595
28596
|
unlinkSync as unlinkSync12,
|
|
@@ -28627,12 +28628,12 @@ function normalizeSecrets(raw) {
|
|
|
28627
28628
|
return out;
|
|
28628
28629
|
}
|
|
28629
28630
|
function openVault(passphrase, vaultPath) {
|
|
28630
|
-
if (!
|
|
28631
|
+
if (!existsSync32(vaultPath)) {
|
|
28631
28632
|
throw new VaultError(`Vault file not found: ${vaultPath}`);
|
|
28632
28633
|
}
|
|
28633
28634
|
let vaultFile;
|
|
28634
28635
|
try {
|
|
28635
|
-
vaultFile = JSON.parse(
|
|
28636
|
+
vaultFile = JSON.parse(readFileSync31(vaultPath, "utf8"));
|
|
28636
28637
|
} catch {
|
|
28637
28638
|
throw new VaultError(`Failed to read vault file: ${vaultPath}`);
|
|
28638
28639
|
}
|
|
@@ -28906,7 +28907,7 @@ __export(exports_materialize_bot_token, {
|
|
|
28906
28907
|
materializeBotToken: () => materializeBotToken,
|
|
28907
28908
|
BotTokenMaterializeError: () => BotTokenMaterializeError
|
|
28908
28909
|
});
|
|
28909
|
-
import { existsSync as
|
|
28910
|
+
import { existsSync as existsSync33 } from "node:fs";
|
|
28910
28911
|
function pickConfiguredToken(config, agentName3) {
|
|
28911
28912
|
if (agentName3) {
|
|
28912
28913
|
const agent = config.agents?.[agentName3];
|
|
@@ -28920,7 +28921,7 @@ function tryDirectVaultRead(ref, config, passphrase) {
|
|
|
28920
28921
|
if (!passphrase)
|
|
28921
28922
|
return null;
|
|
28922
28923
|
const vaultPath = resolvePath(config.vault?.path ?? "~/.switchroom/vault.enc");
|
|
28923
|
-
if (!
|
|
28924
|
+
if (!existsSync33(vaultPath))
|
|
28924
28925
|
return null;
|
|
28925
28926
|
try {
|
|
28926
28927
|
const secrets = openVault(passphrase, vaultPath);
|
|
@@ -29713,7 +29714,7 @@ var import_runner2 = __toESM(require_mod3(), 1);
|
|
|
29713
29714
|
import { randomBytes as randomBytes6 } from "crypto";
|
|
29714
29715
|
import { execFileSync as execFileSync5, execSync as execSync2, spawn as spawn2 } from "child_process";
|
|
29715
29716
|
import {
|
|
29716
|
-
readFileSync as
|
|
29717
|
+
readFileSync as readFileSync32,
|
|
29717
29718
|
writeFileSync as writeFileSync21,
|
|
29718
29719
|
mkdirSync as mkdirSync21,
|
|
29719
29720
|
readdirSync as readdirSync7,
|
|
@@ -29724,7 +29725,7 @@ import {
|
|
|
29724
29725
|
chmodSync as chmodSync5,
|
|
29725
29726
|
openSync as openSync8,
|
|
29726
29727
|
closeSync as closeSync8,
|
|
29727
|
-
existsSync as
|
|
29728
|
+
existsSync as existsSync34,
|
|
29728
29729
|
unlinkSync as unlinkSync14
|
|
29729
29730
|
} from "fs";
|
|
29730
29731
|
import { homedir as homedir12 } from "os";
|
|
@@ -32032,7 +32033,7 @@ function clear(key) {
|
|
|
32032
32033
|
state.delete(key);
|
|
32033
32034
|
}
|
|
32034
32035
|
|
|
32035
|
-
//
|
|
32036
|
+
// ../../switchroom/node_modules/.bun/posthog-node@5.29.2/node_modules/posthog-node/dist/extensions/error-tracking/modifiers/module.node.mjs
|
|
32036
32037
|
import { dirname as dirname2, posix, sep as sep2 } from "path";
|
|
32037
32038
|
function createModulerModifier() {
|
|
32038
32039
|
const getModuleFromFileName = createGetModuleFromFilename();
|
|
@@ -32068,7 +32069,7 @@ function normalizeWindowsPath(path) {
|
|
|
32068
32069
|
return path.replace(/^[A-Z]:/, "").replace(/\\/g, "/");
|
|
32069
32070
|
}
|
|
32070
32071
|
|
|
32071
|
-
//
|
|
32072
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/featureFlagUtils.mjs
|
|
32072
32073
|
var normalizeFlagsResponse = (flagsResponse) => {
|
|
32073
32074
|
if ("flags" in flagsResponse) {
|
|
32074
32075
|
const featureFlags = getFlagValuesFromFlags(flagsResponse.flags);
|
|
@@ -32139,7 +32140,7 @@ var parsePayload = (response) => {
|
|
|
32139
32140
|
}
|
|
32140
32141
|
};
|
|
32141
32142
|
|
|
32142
|
-
//
|
|
32143
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/gzip.mjs
|
|
32143
32144
|
function isGzipSupported() {
|
|
32144
32145
|
return "CompressionStream" in globalThis;
|
|
32145
32146
|
}
|
|
@@ -32159,7 +32160,7 @@ async function gzipCompress(input, isDebug = true) {
|
|
|
32159
32160
|
}
|
|
32160
32161
|
}
|
|
32161
32162
|
|
|
32162
|
-
//
|
|
32163
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/vendor/uuidv7.mjs
|
|
32163
32164
|
/*! For license information please see uuidv7.mjs.LICENSE.txt */
|
|
32164
32165
|
var DIGITS = "0123456789abcdef";
|
|
32165
32166
|
|
|
@@ -32337,7 +32338,7 @@ var defaultGenerator;
|
|
|
32337
32338
|
var uuidv7 = () => uuidv7obj().toString();
|
|
32338
32339
|
var uuidv7obj = () => (defaultGenerator || (defaultGenerator = new V7Generator)).generate();
|
|
32339
32340
|
|
|
32340
|
-
//
|
|
32341
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/types.mjs
|
|
32341
32342
|
var types_PostHogPersistedProperty = /* @__PURE__ */ function(PostHogPersistedProperty) {
|
|
32342
32343
|
PostHogPersistedProperty["AnonymousId"] = "anonymous_id";
|
|
32343
32344
|
PostHogPersistedProperty["DistinctId"] = "distinct_id";
|
|
@@ -32370,7 +32371,7 @@ var types_PostHogPersistedProperty = /* @__PURE__ */ function(PostHogPersistedPr
|
|
|
32370
32371
|
return PostHogPersistedProperty;
|
|
32371
32372
|
}({});
|
|
32372
32373
|
|
|
32373
|
-
//
|
|
32374
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/utils/bot-detection.mjs
|
|
32374
32375
|
var DEFAULT_BLOCKED_UA_STRS = [
|
|
32375
32376
|
"amazonbot",
|
|
32376
32377
|
"amazonproductbot",
|
|
@@ -32459,7 +32460,7 @@ var isBlockedUA = function(ua, customBlockedUserAgents = []) {
|
|
|
32459
32460
|
return uaLower.indexOf(blockedUaLower) !== -1;
|
|
32460
32461
|
});
|
|
32461
32462
|
};
|
|
32462
|
-
//
|
|
32463
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/utils/type-utils.mjs
|
|
32463
32464
|
var nativeIsArray = Array.isArray;
|
|
32464
32465
|
var ObjProto = Object.prototype;
|
|
32465
32466
|
var type_utils_hasOwnProperty = ObjProto.hasOwnProperty;
|
|
@@ -32496,7 +32497,7 @@ function isInstanceOf(candidate, base) {
|
|
|
32496
32497
|
}
|
|
32497
32498
|
}
|
|
32498
32499
|
|
|
32499
|
-
//
|
|
32500
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/utils/number-utils.mjs
|
|
32500
32501
|
function clampToRange(value, min, max, logger, fallbackValue) {
|
|
32501
32502
|
if (min > max) {
|
|
32502
32503
|
logger.warn("min cannot be greater than max.");
|
|
@@ -32516,7 +32517,7 @@ function clampToRange(value, min, max, logger, fallbackValue) {
|
|
|
32516
32517
|
return clampToRange(fallbackValue || max, min, max, logger);
|
|
32517
32518
|
}
|
|
32518
32519
|
|
|
32519
|
-
//
|
|
32520
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/utils/bucketed-rate-limiter.mjs
|
|
32520
32521
|
var ONE_DAY_IN_MS = 86400000;
|
|
32521
32522
|
|
|
32522
32523
|
class BucketedRateLimiter {
|
|
@@ -32560,7 +32561,7 @@ class BucketedRateLimiter {
|
|
|
32560
32561
|
this._buckets = {};
|
|
32561
32562
|
}
|
|
32562
32563
|
}
|
|
32563
|
-
//
|
|
32564
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/utils/promise-queue.mjs
|
|
32564
32565
|
class PromiseQueue {
|
|
32565
32566
|
add(promise) {
|
|
32566
32567
|
const promiseUUID = uuidv7();
|
|
@@ -32586,7 +32587,7 @@ class PromiseQueue {
|
|
|
32586
32587
|
this.promiseByIds = {};
|
|
32587
32588
|
}
|
|
32588
32589
|
}
|
|
32589
|
-
//
|
|
32590
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/utils/logger.mjs
|
|
32590
32591
|
function createConsole(consoleLike = console) {
|
|
32591
32592
|
const lockedMethods = {
|
|
32592
32593
|
log: consoleLike.log.bind(consoleLike),
|
|
@@ -32624,7 +32625,7 @@ var passThrough = (fn) => fn();
|
|
|
32624
32625
|
function createLogger(prefix, maybeCall = passThrough) {
|
|
32625
32626
|
return _createLogger(prefix, maybeCall, createConsole());
|
|
32626
32627
|
}
|
|
32627
|
-
//
|
|
32628
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/utils/user-agent-utils.mjs
|
|
32628
32629
|
var MOBILE = "Mobile";
|
|
32629
32630
|
var IOS = "iOS";
|
|
32630
32631
|
var ANDROID = "Android";
|
|
@@ -32881,7 +32882,7 @@ var osMatchers = [
|
|
|
32881
32882
|
]
|
|
32882
32883
|
];
|
|
32883
32884
|
|
|
32884
|
-
//
|
|
32885
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/utils/index.mjs
|
|
32885
32886
|
var STRING_FORMAT = "utf8";
|
|
32886
32887
|
function assert(truthyValue, message) {
|
|
32887
32888
|
if (!truthyValue || typeof truthyValue != "string" || isEmpty(truthyValue))
|
|
@@ -32929,7 +32930,7 @@ function allSettled(promises) {
|
|
|
32929
32930
|
reason
|
|
32930
32931
|
}))));
|
|
32931
32932
|
}
|
|
32932
|
-
//
|
|
32933
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/eventemitter.mjs
|
|
32933
32934
|
class SimpleEventEmitter {
|
|
32934
32935
|
constructor() {
|
|
32935
32936
|
this.events = {};
|
|
@@ -32951,7 +32952,7 @@ class SimpleEventEmitter {
|
|
|
32951
32952
|
}
|
|
32952
32953
|
}
|
|
32953
32954
|
|
|
32954
|
-
//
|
|
32955
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/posthog-core-stateless.mjs
|
|
32955
32956
|
class PostHogFetchHttpError extends Error {
|
|
32956
32957
|
constructor(response, reqByteLength) {
|
|
32957
32958
|
super("HTTP error while fetching PostHog: status=" + response.status + ", reqByteLength=" + reqByteLength), this.response = response, this.reqByteLength = reqByteLength, this.name = "PostHogFetchHttpError";
|
|
@@ -33666,7 +33667,7 @@ class PostHogCoreStateless {
|
|
|
33666
33667
|
return this.shutdownPromise;
|
|
33667
33668
|
}
|
|
33668
33669
|
}
|
|
33669
|
-
//
|
|
33670
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/index.mjs
|
|
33670
33671
|
var exports_error_tracking = {};
|
|
33671
33672
|
__export(exports_error_tracking, {
|
|
33672
33673
|
winjsStackLineParser: () => winjsStackLineParser,
|
|
@@ -33690,7 +33691,7 @@ __export(exports_error_tracking, {
|
|
|
33690
33691
|
DOMExceptionCoercer: () => DOMExceptionCoercer
|
|
33691
33692
|
});
|
|
33692
33693
|
|
|
33693
|
-
//
|
|
33694
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/chunk-ids.mjs
|
|
33694
33695
|
var parsedStackResults;
|
|
33695
33696
|
var lastKeysCount;
|
|
33696
33697
|
var cachedFilenameChunkIds;
|
|
@@ -33729,7 +33730,7 @@ function getFilenameToChunkIdMap(stackParser) {
|
|
|
33729
33730
|
return cachedFilenameChunkIds;
|
|
33730
33731
|
}
|
|
33731
33732
|
|
|
33732
|
-
//
|
|
33733
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/error-properties-builder.mjs
|
|
33733
33734
|
var MAX_CAUSE_RECURSION = 4;
|
|
33734
33735
|
|
|
33735
33736
|
class ErrorPropertiesBuilder {
|
|
@@ -33851,7 +33852,7 @@ class ErrorPropertiesBuilder {
|
|
|
33851
33852
|
return context;
|
|
33852
33853
|
}
|
|
33853
33854
|
}
|
|
33854
|
-
//
|
|
33855
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/parsers/base.mjs
|
|
33855
33856
|
var UNKNOWN_FUNCTION = "?";
|
|
33856
33857
|
function createFrame(platform, filename, func, lineno, colno) {
|
|
33857
33858
|
const frame = {
|
|
@@ -33867,7 +33868,7 @@ function createFrame(platform, filename, func, lineno, colno) {
|
|
|
33867
33868
|
return frame;
|
|
33868
33869
|
}
|
|
33869
33870
|
|
|
33870
|
-
//
|
|
33871
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/parsers/safari.mjs
|
|
33871
33872
|
var extractSafariExtensionDetails = (func, filename) => {
|
|
33872
33873
|
const isSafariExtension = func.indexOf("safari-extension") !== -1;
|
|
33873
33874
|
const isSafariWebExtension = func.indexOf("safari-web-extension") !== -1;
|
|
@@ -33880,7 +33881,7 @@ var extractSafariExtensionDetails = (func, filename) => {
|
|
|
33880
33881
|
];
|
|
33881
33882
|
};
|
|
33882
33883
|
|
|
33883
|
-
//
|
|
33884
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/parsers/chrome.mjs
|
|
33884
33885
|
var chromeRegexNoFnName = /^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i;
|
|
33885
33886
|
var chromeRegex = /^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i;
|
|
33886
33887
|
var chromeEvalRegex = /\((\S*)(?::(\d+))(?::(\d+))\)/;
|
|
@@ -33906,7 +33907,7 @@ var chromeStackLineParser = (line, platform) => {
|
|
|
33906
33907
|
}
|
|
33907
33908
|
};
|
|
33908
33909
|
|
|
33909
|
-
//
|
|
33910
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/parsers/gecko.mjs
|
|
33910
33911
|
var geckoREgex = /^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i;
|
|
33911
33912
|
var geckoEvalRegex = /(\S+) line (\d+)(?: > eval line \d+)* > eval/i;
|
|
33912
33913
|
var geckoStackLineParser = (line, platform) => {
|
|
@@ -33929,14 +33930,14 @@ var geckoStackLineParser = (line, platform) => {
|
|
|
33929
33930
|
}
|
|
33930
33931
|
};
|
|
33931
33932
|
|
|
33932
|
-
//
|
|
33933
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/parsers/winjs.mjs
|
|
33933
33934
|
var winjsRegex = /^\s*at (?:((?:\[object object\])?.+) )?\(?((?:[-a-z]+):.*?):(\d+)(?::(\d+))?\)?\s*$/i;
|
|
33934
33935
|
var winjsStackLineParser = (line, platform) => {
|
|
33935
33936
|
const parts = winjsRegex.exec(line);
|
|
33936
33937
|
return parts ? createFrame(platform, parts[2], parts[1] || UNKNOWN_FUNCTION, +parts[3], parts[4] ? +parts[4] : undefined) : undefined;
|
|
33937
33938
|
};
|
|
33938
33939
|
|
|
33939
|
-
//
|
|
33940
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/parsers/opera.mjs
|
|
33940
33941
|
var opera10Regex = / line (\d+).*script (?:in )?(\S+)(?:: in function (\S+))?$/i;
|
|
33941
33942
|
var opera10StackLineParser = (line, platform) => {
|
|
33942
33943
|
const parts = opera10Regex.exec(line);
|
|
@@ -33948,7 +33949,7 @@ var opera11StackLineParser = (line, platform) => {
|
|
|
33948
33949
|
return parts ? createFrame(platform, parts[5], parts[3] || parts[4] || UNKNOWN_FUNCTION, +parts[1], +parts[2]) : undefined;
|
|
33949
33950
|
};
|
|
33950
33951
|
|
|
33951
|
-
//
|
|
33952
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/parsers/node.mjs
|
|
33952
33953
|
var FILENAME_MATCH = /^\s*[-]{4,}$/;
|
|
33953
33954
|
var FULL_MATCH = /at (?:async )?(?:(.+?)\s+\()?(?:(.+):(\d+):(\d+)?|([^)]+))\)?/;
|
|
33954
33955
|
var nodeStackLineParser = (line, platform) => {
|
|
@@ -34017,7 +34018,7 @@ function _parseIntOrUndefined(input) {
|
|
|
34017
34018
|
return parseInt(input || "", 10) || undefined;
|
|
34018
34019
|
}
|
|
34019
34020
|
|
|
34020
|
-
//
|
|
34021
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/parsers/index.mjs
|
|
34021
34022
|
var WEBPACK_ERROR_REGEXP = /\(error: (.*)\)/;
|
|
34022
34023
|
var STACKTRACE_FRAME_LIMIT = 50;
|
|
34023
34024
|
function reverseAndStripFrames(stack) {
|
|
@@ -34062,7 +34063,7 @@ function createStackParser(platform, ...parsers) {
|
|
|
34062
34063
|
return reverseAndStripFrames(frames);
|
|
34063
34064
|
};
|
|
34064
34065
|
}
|
|
34065
|
-
//
|
|
34066
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/coercers/dom-exception-coercer.mjs
|
|
34066
34067
|
class DOMExceptionCoercer {
|
|
34067
34068
|
match(err) {
|
|
34068
34069
|
return this.isDOMException(err) || this.isDOMError(err);
|
|
@@ -34092,7 +34093,7 @@ class DOMExceptionCoercer {
|
|
|
34092
34093
|
return isBuiltin(err, "DOMError");
|
|
34093
34094
|
}
|
|
34094
34095
|
}
|
|
34095
|
-
//
|
|
34096
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/coercers/error-coercer.mjs
|
|
34096
34097
|
class ErrorCoercer {
|
|
34097
34098
|
match(err) {
|
|
34098
34099
|
return isPlainError(err);
|
|
@@ -34119,7 +34120,7 @@ class ErrorCoercer {
|
|
|
34119
34120
|
return err.stacktrace || err.stack || undefined;
|
|
34120
34121
|
}
|
|
34121
34122
|
}
|
|
34122
|
-
//
|
|
34123
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/coercers/error-event-coercer.mjs
|
|
34123
34124
|
class ErrorEventCoercer {
|
|
34124
34125
|
constructor() {}
|
|
34125
34126
|
match(err) {
|
|
@@ -34137,7 +34138,7 @@ class ErrorEventCoercer {
|
|
|
34137
34138
|
return exceptionLike;
|
|
34138
34139
|
}
|
|
34139
34140
|
}
|
|
34140
|
-
//
|
|
34141
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/coercers/string-coercer.mjs
|
|
34141
34142
|
var ERROR_TYPES_PATTERN = /^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i;
|
|
34142
34143
|
|
|
34143
34144
|
class StringCoercer {
|
|
@@ -34167,7 +34168,7 @@ class StringCoercer {
|
|
|
34167
34168
|
];
|
|
34168
34169
|
}
|
|
34169
34170
|
}
|
|
34170
|
-
//
|
|
34171
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/types.mjs
|
|
34171
34172
|
var severityLevels = [
|
|
34172
34173
|
"fatal",
|
|
34173
34174
|
"error",
|
|
@@ -34177,7 +34178,7 @@ var severityLevels = [
|
|
|
34177
34178
|
"debug"
|
|
34178
34179
|
];
|
|
34179
34180
|
|
|
34180
|
-
//
|
|
34181
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/coercers/utils.mjs
|
|
34181
34182
|
function extractExceptionKeysForMessage(err, maxLength = 40) {
|
|
34182
34183
|
const keys = Object.keys(err);
|
|
34183
34184
|
keys.sort();
|
|
@@ -34194,7 +34195,7 @@ function extractExceptionKeysForMessage(err, maxLength = 40) {
|
|
|
34194
34195
|
return "";
|
|
34195
34196
|
}
|
|
34196
34197
|
|
|
34197
|
-
//
|
|
34198
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/coercers/object-coercer.mjs
|
|
34198
34199
|
class ObjectCoercer {
|
|
34199
34200
|
match(candidate) {
|
|
34200
34201
|
return typeof candidate == "object" && candidate !== null;
|
|
@@ -34247,7 +34248,7 @@ class ObjectCoercer {
|
|
|
34247
34248
|
}
|
|
34248
34249
|
}
|
|
34249
34250
|
}
|
|
34250
|
-
//
|
|
34251
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/coercers/event-coercer.mjs
|
|
34251
34252
|
class EventCoercer {
|
|
34252
34253
|
match(err) {
|
|
34253
34254
|
return isEvent(err);
|
|
@@ -34262,7 +34263,7 @@ class EventCoercer {
|
|
|
34262
34263
|
};
|
|
34263
34264
|
}
|
|
34264
34265
|
}
|
|
34265
|
-
//
|
|
34266
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/coercers/primitive-coercer.mjs
|
|
34266
34267
|
class PrimitiveCoercer {
|
|
34267
34268
|
match(candidate) {
|
|
34268
34269
|
return isPrimitive(candidate);
|
|
@@ -34276,7 +34277,7 @@ class PrimitiveCoercer {
|
|
|
34276
34277
|
};
|
|
34277
34278
|
}
|
|
34278
34279
|
}
|
|
34279
|
-
//
|
|
34280
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/coercers/promise-rejection-event.mjs
|
|
34280
34281
|
class PromiseRejectionEventCoercer {
|
|
34281
34282
|
match(err) {
|
|
34282
34283
|
return isBuiltin(err, "PromiseRejectionEvent") || this.isCustomEventWrappingRejection(err);
|
|
@@ -34312,7 +34313,7 @@ class PromiseRejectionEventCoercer {
|
|
|
34312
34313
|
return error;
|
|
34313
34314
|
}
|
|
34314
34315
|
}
|
|
34315
|
-
//
|
|
34316
|
+
// ../../switchroom/node_modules/.bun/@posthog+core@1.25.2/node_modules/@posthog/core/dist/error-tracking/utils.mjs
|
|
34316
34317
|
class ReduceableCache {
|
|
34317
34318
|
constructor(_maxSize) {
|
|
34318
34319
|
this._maxSize = _maxSize;
|
|
@@ -34337,7 +34338,7 @@ class ReduceableCache {
|
|
|
34337
34338
|
}
|
|
34338
34339
|
}
|
|
34339
34340
|
}
|
|
34340
|
-
//
|
|
34341
|
+
// ../../switchroom/node_modules/.bun/posthog-node@5.29.2/node_modules/posthog-node/dist/extensions/error-tracking/modifiers/context-lines.node.mjs
|
|
34341
34342
|
import { createReadStream } from "node:fs";
|
|
34342
34343
|
import { createInterface } from "node:readline";
|
|
34343
34344
|
var LRU_FILE_CONTENTS_CACHE = new exports_error_tracking.ReduceableCache(25);
|
|
@@ -34555,7 +34556,7 @@ function snipLine(line, colno) {
|
|
|
34555
34556
|
return newLine;
|
|
34556
34557
|
}
|
|
34557
34558
|
|
|
34558
|
-
//
|
|
34559
|
+
// ../../switchroom/node_modules/.bun/posthog-node@5.29.2/node_modules/posthog-node/dist/extensions/error-tracking/autocapture.mjs
|
|
34559
34560
|
function makeUncaughtExceptionHandler(captureFn, onFatalFn) {
|
|
34560
34561
|
let calledFatalError = false;
|
|
34561
34562
|
return Object.assign((error) => {
|
|
@@ -34587,7 +34588,7 @@ function addUnhandledRejectionListener(captureFn) {
|
|
|
34587
34588
|
}));
|
|
34588
34589
|
}
|
|
34589
34590
|
|
|
34590
|
-
//
|
|
34591
|
+
// ../../switchroom/node_modules/.bun/posthog-node@5.29.2/node_modules/posthog-node/dist/extensions/error-tracking/index.mjs
|
|
34591
34592
|
var SHUTDOWN_TIMEOUT = 2000;
|
|
34592
34593
|
|
|
34593
34594
|
class ErrorTracking {
|
|
@@ -34656,10 +34657,10 @@ class ErrorTracking {
|
|
|
34656
34657
|
}
|
|
34657
34658
|
}
|
|
34658
34659
|
|
|
34659
|
-
//
|
|
34660
|
+
// ../../switchroom/node_modules/.bun/posthog-node@5.29.2/node_modules/posthog-node/dist/version.mjs
|
|
34660
34661
|
var version = "5.29.2";
|
|
34661
34662
|
|
|
34662
|
-
//
|
|
34663
|
+
// ../../switchroom/node_modules/.bun/posthog-node@5.29.2/node_modules/posthog-node/dist/types.mjs
|
|
34663
34664
|
var FeatureFlagError2 = {
|
|
34664
34665
|
ERRORS_WHILE_COMPUTING: "errors_while_computing_flags",
|
|
34665
34666
|
FLAG_MISSING: "flag_missing",
|
|
@@ -34667,7 +34668,7 @@ var FeatureFlagError2 = {
|
|
|
34667
34668
|
UNKNOWN_ERROR: "unknown_error"
|
|
34668
34669
|
};
|
|
34669
34670
|
|
|
34670
|
-
//
|
|
34671
|
+
// ../../switchroom/node_modules/.bun/posthog-node@5.29.2/node_modules/posthog-node/dist/extensions/feature-flags/crypto.mjs
|
|
34671
34672
|
async function hashSHA1(text) {
|
|
34672
34673
|
const subtle = globalThis.crypto?.subtle;
|
|
34673
34674
|
if (!subtle)
|
|
@@ -34677,7 +34678,7 @@ async function hashSHA1(text) {
|
|
|
34677
34678
|
return hashArray.map((byte) => byte.toString(16).padStart(2, "0")).join("");
|
|
34678
34679
|
}
|
|
34679
34680
|
|
|
34680
|
-
//
|
|
34681
|
+
// ../../switchroom/node_modules/.bun/posthog-node@5.29.2/node_modules/posthog-node/dist/extensions/feature-flags/feature-flags.mjs
|
|
34681
34682
|
var SIXTY_SECONDS = 60000;
|
|
34682
34683
|
var LONG_SCALE = 1152921504606847000;
|
|
34683
34684
|
var NULL_VALUES_ALLOWED_OPERATORS = [
|
|
@@ -35551,7 +35552,7 @@ function relativeDateParseForFeatureFlagMatching(value) {
|
|
|
35551
35552
|
}
|
|
35552
35553
|
}
|
|
35553
35554
|
|
|
35554
|
-
//
|
|
35555
|
+
// ../../switchroom/node_modules/.bun/posthog-node@5.29.2/node_modules/posthog-node/dist/storage-memory.mjs
|
|
35555
35556
|
class PostHogMemoryStorage {
|
|
35556
35557
|
getProperty(key) {
|
|
35557
35558
|
return this._memoryStorage[key];
|
|
@@ -35564,7 +35565,7 @@ class PostHogMemoryStorage {
|
|
|
35564
35565
|
}
|
|
35565
35566
|
}
|
|
35566
35567
|
|
|
35567
|
-
//
|
|
35568
|
+
// ../../switchroom/node_modules/.bun/posthog-node@5.29.2/node_modules/posthog-node/dist/client.mjs
|
|
35568
35569
|
var MINIMUM_POLLING_INTERVAL = 100;
|
|
35569
35570
|
var THIRTY_SECONDS = 30000;
|
|
35570
35571
|
var MAX_CACHE_SIZE = 50000;
|
|
@@ -36352,7 +36353,7 @@ class PostHogBackendClient extends PostHogCoreStateless {
|
|
|
36352
36353
|
}
|
|
36353
36354
|
}
|
|
36354
36355
|
|
|
36355
|
-
//
|
|
36356
|
+
// ../../switchroom/node_modules/.bun/posthog-node@5.29.2/node_modules/posthog-node/dist/extensions/context/context.mjs
|
|
36356
36357
|
import { AsyncLocalStorage as AsyncLocalStorage2 } from "node:async_hooks";
|
|
36357
36358
|
|
|
36358
36359
|
class PostHogContext {
|
|
@@ -36383,7 +36384,7 @@ class PostHogContext {
|
|
|
36383
36384
|
}
|
|
36384
36385
|
}
|
|
36385
36386
|
|
|
36386
|
-
//
|
|
36387
|
+
// ../../switchroom/node_modules/.bun/posthog-node@5.29.2/node_modules/posthog-node/dist/extensions/sentry-integration.mjs
|
|
36387
36388
|
var NAME = "posthog-node";
|
|
36388
36389
|
function createEventProcessor(_posthog, { organization, projectId, prefix, severityAllowList = [
|
|
36389
36390
|
"error"
|
|
@@ -36451,7 +36452,7 @@ class PostHogSentryIntegration {
|
|
|
36451
36452
|
};
|
|
36452
36453
|
}
|
|
36453
36454
|
}
|
|
36454
|
-
//
|
|
36455
|
+
// ../../switchroom/node_modules/.bun/posthog-node@5.29.2/node_modules/posthog-node/dist/entrypoints/index.node.mjs
|
|
36455
36456
|
ErrorTracking.errorPropertiesBuilder = new exports_error_tracking.ErrorPropertiesBuilder([
|
|
36456
36457
|
new exports_error_tracking.EventCoercer,
|
|
36457
36458
|
new exports_error_tracking.ErrorCoercer,
|
|
@@ -42346,8 +42347,133 @@ function mergeAgentConfig(defaultsIn, agentIn) {
|
|
|
42346
42347
|
mergeAgentConfig.notifiedWorkerIsolationMove = false;
|
|
42347
42348
|
})(mergeAgentConfig ||= {});
|
|
42348
42349
|
|
|
42350
|
+
// ../src/agents/perf.ts
|
|
42351
|
+
import { existsSync as existsSync19, readFileSync as readFileSync15 } from "node:fs";
|
|
42352
|
+
function readTurnUsages(jsonlPath, lastN) {
|
|
42353
|
+
if (!existsSync19(jsonlPath))
|
|
42354
|
+
return [];
|
|
42355
|
+
if (lastN <= 0)
|
|
42356
|
+
return [];
|
|
42357
|
+
let raw;
|
|
42358
|
+
try {
|
|
42359
|
+
raw = readFileSync15(jsonlPath, "utf-8");
|
|
42360
|
+
} catch {
|
|
42361
|
+
return [];
|
|
42362
|
+
}
|
|
42363
|
+
const ring = new Array(lastN);
|
|
42364
|
+
let count = 0;
|
|
42365
|
+
const lines = raw.split(`
|
|
42366
|
+
`);
|
|
42367
|
+
for (const line of lines) {
|
|
42368
|
+
if (!line)
|
|
42369
|
+
continue;
|
|
42370
|
+
let obj;
|
|
42371
|
+
try {
|
|
42372
|
+
obj = JSON.parse(line);
|
|
42373
|
+
} catch {
|
|
42374
|
+
continue;
|
|
42375
|
+
}
|
|
42376
|
+
const turn = extractTurnUsage(obj);
|
|
42377
|
+
if (!turn)
|
|
42378
|
+
continue;
|
|
42379
|
+
ring[count % lastN] = turn;
|
|
42380
|
+
count++;
|
|
42381
|
+
}
|
|
42382
|
+
if (count === 0)
|
|
42383
|
+
return [];
|
|
42384
|
+
const out = [];
|
|
42385
|
+
if (count <= lastN) {
|
|
42386
|
+
for (let i = 0;i < count; i++)
|
|
42387
|
+
out.push(ring[i]);
|
|
42388
|
+
} else {
|
|
42389
|
+
const start = count % lastN;
|
|
42390
|
+
for (let i = 0;i < lastN; i++) {
|
|
42391
|
+
out.push(ring[(start + i) % lastN]);
|
|
42392
|
+
}
|
|
42393
|
+
}
|
|
42394
|
+
return out;
|
|
42395
|
+
}
|
|
42396
|
+
function extractTurnUsage(obj) {
|
|
42397
|
+
if (!obj || typeof obj !== "object")
|
|
42398
|
+
return null;
|
|
42399
|
+
const o = obj;
|
|
42400
|
+
if (o.type !== "assistant")
|
|
42401
|
+
return null;
|
|
42402
|
+
const message = o.message;
|
|
42403
|
+
if (!message)
|
|
42404
|
+
return null;
|
|
42405
|
+
const usage = message.usage;
|
|
42406
|
+
if (!usage)
|
|
42407
|
+
return null;
|
|
42408
|
+
const cacheRead = numField(usage, "cache_read_input_tokens");
|
|
42409
|
+
const cacheCreateFlat = numField(usage, "cache_creation_input_tokens");
|
|
42410
|
+
const input = numField(usage, "input_tokens");
|
|
42411
|
+
const output = numField(usage, "output_tokens");
|
|
42412
|
+
let ephemeral1h = 0;
|
|
42413
|
+
let ephemeral5m = 0;
|
|
42414
|
+
const cc = usage.cache_creation;
|
|
42415
|
+
if (cc && typeof cc === "object") {
|
|
42416
|
+
ephemeral1h = numField(cc, "ephemeral_1h_input_tokens");
|
|
42417
|
+
ephemeral5m = numField(cc, "ephemeral_5m_input_tokens");
|
|
42418
|
+
}
|
|
42419
|
+
const cacheCreate = cacheCreateFlat > 0 ? cacheCreateFlat : ephemeral1h + ephemeral5m;
|
|
42420
|
+
if (cacheRead === 0 && cacheCreate === 0 && input === 0 && output === 0) {
|
|
42421
|
+
return null;
|
|
42422
|
+
}
|
|
42423
|
+
let ts = 0;
|
|
42424
|
+
const tsRaw = o.timestamp;
|
|
42425
|
+
if (typeof tsRaw === "string") {
|
|
42426
|
+
const parsed = Date.parse(tsRaw);
|
|
42427
|
+
if (!isNaN(parsed))
|
|
42428
|
+
ts = parsed;
|
|
42429
|
+
} else if (typeof tsRaw === "number") {
|
|
42430
|
+
ts = tsRaw;
|
|
42431
|
+
}
|
|
42432
|
+
return {
|
|
42433
|
+
cacheRead,
|
|
42434
|
+
cacheCreate,
|
|
42435
|
+
ephemeral1h,
|
|
42436
|
+
ephemeral5m,
|
|
42437
|
+
input,
|
|
42438
|
+
output,
|
|
42439
|
+
ts
|
|
42440
|
+
};
|
|
42441
|
+
}
|
|
42442
|
+
function numField(obj, key) {
|
|
42443
|
+
const v = obj[key];
|
|
42444
|
+
if (typeof v === "number" && isFinite(v) && v >= 0)
|
|
42445
|
+
return v;
|
|
42446
|
+
return 0;
|
|
42447
|
+
}
|
|
42448
|
+
|
|
42449
|
+
// gateway/proactive-compact.ts
|
|
42450
|
+
var COMPACT_REARM_FRACTION = 0.6;
|
|
42451
|
+
var COMPACT_COOLDOWN_TURNS = 3;
|
|
42452
|
+
function initialCompactState() {
|
|
42453
|
+
return { armed: true, cooldownTurns: 0 };
|
|
42454
|
+
}
|
|
42455
|
+
function decideProactiveCompact(state3, occupancy, cap) {
|
|
42456
|
+
if (state3.cooldownTurns > 0) {
|
|
42457
|
+
return {
|
|
42458
|
+
fire: false,
|
|
42459
|
+
state: { armed: state3.armed, cooldownTurns: state3.cooldownTurns - 1 }
|
|
42460
|
+
};
|
|
42461
|
+
}
|
|
42462
|
+
if (!state3.armed) {
|
|
42463
|
+
const armed = occupancy < cap * COMPACT_REARM_FRACTION;
|
|
42464
|
+
return { fire: false, state: { armed, cooldownTurns: 0 } };
|
|
42465
|
+
}
|
|
42466
|
+
if (occupancy < cap) {
|
|
42467
|
+
return { fire: false, state: state3 };
|
|
42468
|
+
}
|
|
42469
|
+
return {
|
|
42470
|
+
fire: true,
|
|
42471
|
+
state: { armed: false, cooldownTurns: COMPACT_COOLDOWN_TURNS }
|
|
42472
|
+
};
|
|
42473
|
+
}
|
|
42474
|
+
|
|
42349
42475
|
// gateway/hostd-dispatch.ts
|
|
42350
|
-
import { existsSync as
|
|
42476
|
+
import { existsSync as existsSync20 } from "node:fs";
|
|
42351
42477
|
import { randomBytes as randomBytes3 } from "node:crypto";
|
|
42352
42478
|
|
|
42353
42479
|
// ../src/host-control/client.ts
|
|
@@ -42588,13 +42714,13 @@ function hostdSocketPath(agentName3) {
|
|
|
42588
42714
|
function hostdWillBeUsed(agentName3) {
|
|
42589
42715
|
if (!isHostdEnabled())
|
|
42590
42716
|
return false;
|
|
42591
|
-
return
|
|
42717
|
+
return existsSync20(hostdSocketPath(agentName3));
|
|
42592
42718
|
}
|
|
42593
42719
|
async function tryHostdDispatch(agentName3, req) {
|
|
42594
42720
|
if (!isHostdEnabled())
|
|
42595
42721
|
return "not-configured";
|
|
42596
42722
|
const sockPath = hostdSocketPath(agentName3);
|
|
42597
|
-
if (!
|
|
42723
|
+
if (!existsSync20(sockPath))
|
|
42598
42724
|
return "not-configured";
|
|
42599
42725
|
try {
|
|
42600
42726
|
return await hostdRequest({ socketPath: sockPath, timeoutMs: 5000 }, req);
|
|
@@ -42618,7 +42744,7 @@ async function hostdGetStatusOnce(agentName3, targetRequestId) {
|
|
|
42618
42744
|
if (!isHostdEnabled())
|
|
42619
42745
|
return "not-configured";
|
|
42620
42746
|
const sockPath = hostdSocketPath(agentName3);
|
|
42621
|
-
if (!
|
|
42747
|
+
if (!existsSync20(sockPath))
|
|
42622
42748
|
return "not-configured";
|
|
42623
42749
|
try {
|
|
42624
42750
|
const resp = await hostdRequest({ socketPath: sockPath, timeoutMs: 3000 }, {
|
|
@@ -42639,7 +42765,7 @@ async function pollHostdStatus(agentName3, targetRequestId, opts) {
|
|
|
42639
42765
|
if (!isHostdEnabled())
|
|
42640
42766
|
return "not-configured";
|
|
42641
42767
|
const sockPath = hostdSocketPath(agentName3);
|
|
42642
|
-
if (!
|
|
42768
|
+
if (!existsSync20(sockPath))
|
|
42643
42769
|
return "not-configured";
|
|
42644
42770
|
const now = opts.now ?? Date.now;
|
|
42645
42771
|
const sleep2 = opts.sleep ?? ((ms) => new Promise((r) => setTimeout(r, ms)));
|
|
@@ -43366,6 +43492,15 @@ function redeliverBufferedInbound(buffer, agent, send) {
|
|
|
43366
43492
|
}
|
|
43367
43493
|
return { drained: pending.length, redelivered, rebuffered };
|
|
43368
43494
|
}
|
|
43495
|
+
function idleDrainTick(buffer, agent, isBridgeAlive, send) {
|
|
43496
|
+
if (!agent)
|
|
43497
|
+
return null;
|
|
43498
|
+
if (buffer.depth(agent) === 0)
|
|
43499
|
+
return null;
|
|
43500
|
+
if (!isBridgeAlive())
|
|
43501
|
+
return null;
|
|
43502
|
+
return redeliverBufferedInbound(buffer, agent, send);
|
|
43503
|
+
}
|
|
43369
43504
|
function createPendingInboundBuffer(opts = {}) {
|
|
43370
43505
|
const cap = opts.capPerAgent ?? DEFAULT_PENDING_INBOUND_CAP;
|
|
43371
43506
|
const log = opts.log ?? ((line) => process.stderr.write(line));
|
|
@@ -43808,7 +43943,7 @@ function escapeBody(s) {
|
|
|
43808
43943
|
}
|
|
43809
43944
|
|
|
43810
43945
|
// gateway/pid-file.ts
|
|
43811
|
-
import { writeFileSync as writeFileSync9, readFileSync as
|
|
43946
|
+
import { writeFileSync as writeFileSync9, readFileSync as readFileSync16, unlinkSync as unlinkSync6, renameSync as renameSync6 } from "node:fs";
|
|
43812
43947
|
function writePidFile(path, record) {
|
|
43813
43948
|
const tmp = `${path}.tmp-${process.pid}-${Date.now()}`;
|
|
43814
43949
|
writeFileSync9(tmp, JSON.stringify(record), "utf-8");
|
|
@@ -43827,10 +43962,10 @@ import {
|
|
|
43827
43962
|
writeFile as writeFileAsync,
|
|
43828
43963
|
readFile as readFileAsync
|
|
43829
43964
|
} from "node:fs/promises";
|
|
43830
|
-
import { readFileSync as
|
|
43965
|
+
import { readFileSync as readFileSync17 } from "node:fs";
|
|
43831
43966
|
function readCurrentBootId() {
|
|
43832
43967
|
try {
|
|
43833
|
-
const stat =
|
|
43968
|
+
const stat = readFileSync17("/proc/1/stat", "utf-8");
|
|
43834
43969
|
const lastParen = stat.lastIndexOf(")");
|
|
43835
43970
|
if (lastParen < 0)
|
|
43836
43971
|
return null;
|
|
@@ -44033,7 +44168,7 @@ function safeCount(fn) {
|
|
|
44033
44168
|
}
|
|
44034
44169
|
|
|
44035
44170
|
// gateway/session-marker.ts
|
|
44036
|
-
import { writeFileSync as writeFileSync10, readFileSync as
|
|
44171
|
+
import { writeFileSync as writeFileSync10, readFileSync as readFileSync18, renameSync as renameSync7, unlinkSync as unlinkSync7 } from "node:fs";
|
|
44037
44172
|
function writeSessionMarker(path, marker) {
|
|
44038
44173
|
const tmp = `${path}.tmp-${process.pid}-${Date.now()}`;
|
|
44039
44174
|
writeFileSync10(tmp, JSON.stringify(marker), "utf-8");
|
|
@@ -44041,7 +44176,7 @@ function writeSessionMarker(path, marker) {
|
|
|
44041
44176
|
}
|
|
44042
44177
|
function readSessionMarker(path) {
|
|
44043
44178
|
try {
|
|
44044
|
-
const raw =
|
|
44179
|
+
const raw = readFileSync18(path, "utf-8");
|
|
44045
44180
|
const parsed = JSON.parse(raw);
|
|
44046
44181
|
if (typeof parsed.pid === "number" && typeof parsed.startedAtMs === "number" && Number.isFinite(parsed.pid) && Number.isFinite(parsed.startedAtMs)) {
|
|
44047
44182
|
return { pid: parsed.pid, startedAtMs: parsed.startedAtMs };
|
|
@@ -44063,7 +44198,7 @@ function shouldFireRestartBanner(input) {
|
|
|
44063
44198
|
}
|
|
44064
44199
|
|
|
44065
44200
|
// gateway/clean-shutdown-marker.ts
|
|
44066
|
-
import { writeFileSync as writeFileSync11, readFileSync as
|
|
44201
|
+
import { writeFileSync as writeFileSync11, readFileSync as readFileSync19, renameSync as renameSync8, unlinkSync as unlinkSync8 } from "node:fs";
|
|
44067
44202
|
var DEFAULT_MAX_AGE_MS = 60000;
|
|
44068
44203
|
function writeCleanShutdownMarker(path, marker) {
|
|
44069
44204
|
const tmp = `${path}.tmp-${process.pid}-${Date.now()}`;
|
|
@@ -44072,7 +44207,7 @@ function writeCleanShutdownMarker(path, marker) {
|
|
|
44072
44207
|
}
|
|
44073
44208
|
function readCleanShutdownMarker(path) {
|
|
44074
44209
|
try {
|
|
44075
|
-
const raw =
|
|
44210
|
+
const raw = readFileSync19(path, "utf-8");
|
|
44076
44211
|
const parsed = JSON.parse(raw);
|
|
44077
44212
|
if (typeof parsed.ts === "number" && Number.isFinite(parsed.ts) && typeof parsed.signal === "string" && parsed.signal.length > 0) {
|
|
44078
44213
|
const out = { ts: parsed.ts, signal: parsed.signal };
|
|
@@ -44850,14 +44985,14 @@ function classifyAdminGate(text, myAgentName) {
|
|
|
44850
44985
|
|
|
44851
44986
|
// subagent-watcher.ts
|
|
44852
44987
|
import {
|
|
44853
|
-
existsSync as
|
|
44988
|
+
existsSync as existsSync22,
|
|
44854
44989
|
openSync as openSync2,
|
|
44855
44990
|
readSync,
|
|
44856
44991
|
statSync as statSync6,
|
|
44857
44992
|
closeSync as closeSync2,
|
|
44858
44993
|
watch,
|
|
44859
44994
|
readdirSync as readdirSync3,
|
|
44860
|
-
readFileSync as
|
|
44995
|
+
readFileSync as readFileSync21
|
|
44861
44996
|
} from "fs";
|
|
44862
44997
|
import { join as join19 } from "path";
|
|
44863
44998
|
|
|
@@ -45102,10 +45237,10 @@ function bumpSubagentActivity(db2, args) {
|
|
|
45102
45237
|
// gateway/turn-active-marker.ts
|
|
45103
45238
|
import {
|
|
45104
45239
|
closeSync,
|
|
45105
|
-
existsSync as
|
|
45240
|
+
existsSync as existsSync21,
|
|
45106
45241
|
mkdirSync as mkdirSync10,
|
|
45107
45242
|
openSync,
|
|
45108
|
-
readFileSync as
|
|
45243
|
+
readFileSync as readFileSync20,
|
|
45109
45244
|
statSync as statSync5,
|
|
45110
45245
|
unlinkSync as unlinkSync9,
|
|
45111
45246
|
utimesSync,
|
|
@@ -45115,7 +45250,7 @@ import { join as join18 } from "node:path";
|
|
|
45115
45250
|
var TURN_ACTIVE_MARKER_FILE = "turn-active.json";
|
|
45116
45251
|
function touchTurnActiveMarker(stateDir) {
|
|
45117
45252
|
const path = join18(stateDir, TURN_ACTIVE_MARKER_FILE);
|
|
45118
|
-
if (!
|
|
45253
|
+
if (!existsSync21(path))
|
|
45119
45254
|
return;
|
|
45120
45255
|
const now = new Date;
|
|
45121
45256
|
try {
|
|
@@ -45149,7 +45284,7 @@ function backfillJsonlAgentId(db2, jsonlPath, agentId, log) {
|
|
|
45149
45284
|
const metaPath = jsonlPath.replace(/\.jsonl$/, ".meta.json");
|
|
45150
45285
|
let meta;
|
|
45151
45286
|
try {
|
|
45152
|
-
const raw =
|
|
45287
|
+
const raw = readFileSync21(metaPath, "utf8");
|
|
45153
45288
|
meta = JSON.parse(raw);
|
|
45154
45289
|
} catch {
|
|
45155
45290
|
log?.(`subagent-watcher: backfill skip ${agentId} \u2014 meta.json not readable at ${metaPath}`);
|
|
@@ -45313,7 +45448,7 @@ function startSubagentWatcher(config) {
|
|
|
45313
45448
|
clearTimeout(ref.ref);
|
|
45314
45449
|
});
|
|
45315
45450
|
const fs2 = config.fs ?? {
|
|
45316
|
-
existsSync:
|
|
45451
|
+
existsSync: existsSync22,
|
|
45317
45452
|
readdirSync: readdirSync3,
|
|
45318
45453
|
statSync: statSync6,
|
|
45319
45454
|
openSync: openSync2,
|
|
@@ -45727,7 +45862,7 @@ function determineRestartReason(opts) {
|
|
|
45727
45862
|
init_boot_card();
|
|
45728
45863
|
|
|
45729
45864
|
// gateway/update-announce.ts
|
|
45730
|
-
import { existsSync as
|
|
45865
|
+
import { existsSync as existsSync26, mkdirSync as mkdirSync13, openSync as openSync3, closeSync as closeSync3, readFileSync as readFileSync25 } from "node:fs";
|
|
45731
45866
|
import { join as join24 } from "node:path";
|
|
45732
45867
|
import { homedir as homedir10 } from "node:os";
|
|
45733
45868
|
|
|
@@ -45841,8 +45976,8 @@ function readAndFilter(raw, filters, limit) {
|
|
|
45841
45976
|
var DEFAULT_LOOKBACK_MS = 10 * 60 * 1000;
|
|
45842
45977
|
function readLastTerminalUpdateAudit(opts = {}) {
|
|
45843
45978
|
const path = opts.auditLogPath ?? defaultAuditLogPath();
|
|
45844
|
-
const exists = opts.exists ??
|
|
45845
|
-
const readFile = opts.readFile ?? ((p) =>
|
|
45979
|
+
const exists = opts.exists ?? existsSync26;
|
|
45980
|
+
const readFile = opts.readFile ?? ((p) => readFileSync25(p, "utf-8"));
|
|
45846
45981
|
if (!exists(path))
|
|
45847
45982
|
return null;
|
|
45848
45983
|
let raw;
|
|
@@ -45930,7 +46065,7 @@ function maybeRenderUpdateAnnouncement(opts = {}) {
|
|
|
45930
46065
|
}
|
|
45931
46066
|
|
|
45932
46067
|
// issues-card.ts
|
|
45933
|
-
import { readFileSync as
|
|
46068
|
+
import { readFileSync as readFileSync26, writeFileSync as writeFileSync15 } from "node:fs";
|
|
45934
46069
|
var SEVERITY_EMOJI = {
|
|
45935
46070
|
info: "\u2139\ufe0f",
|
|
45936
46071
|
warn: "\u26a0\ufe0f",
|
|
@@ -46022,7 +46157,7 @@ function extractRetryAfterSecs(err) {
|
|
|
46022
46157
|
var COOLDOWN_JITTER_MS = 500;
|
|
46023
46158
|
function readPersistedMessageId(path, log) {
|
|
46024
46159
|
try {
|
|
46025
|
-
const raw =
|
|
46160
|
+
const raw = readFileSync26(path, "utf8");
|
|
46026
46161
|
const parsed = JSON.parse(raw);
|
|
46027
46162
|
const v = parsed.messageId;
|
|
46028
46163
|
if (typeof v === "number" && Number.isInteger(v) && v > 0)
|
|
@@ -46131,17 +46266,17 @@ function createIssuesCardHandle(opts) {
|
|
|
46131
46266
|
}
|
|
46132
46267
|
|
|
46133
46268
|
// issues-watcher.ts
|
|
46134
|
-
import { existsSync as
|
|
46269
|
+
import { existsSync as existsSync28, statSync as statSync8 } from "node:fs";
|
|
46135
46270
|
import { join as join26 } from "node:path";
|
|
46136
46271
|
|
|
46137
46272
|
// ../src/issues/store.ts
|
|
46138
46273
|
import {
|
|
46139
46274
|
closeSync as closeSync4,
|
|
46140
|
-
existsSync as
|
|
46275
|
+
existsSync as existsSync27,
|
|
46141
46276
|
mkdirSync as mkdirSync14,
|
|
46142
46277
|
openSync as openSync4,
|
|
46143
46278
|
readdirSync as readdirSync5,
|
|
46144
|
-
readFileSync as
|
|
46279
|
+
readFileSync as readFileSync27,
|
|
46145
46280
|
renameSync as renameSync10,
|
|
46146
46281
|
statSync as statSync7,
|
|
46147
46282
|
unlinkSync as unlinkSync10,
|
|
@@ -46165,11 +46300,11 @@ var ISSUES_FILE = "issues.jsonl";
|
|
|
46165
46300
|
var ISSUES_LOCK = "issues.lock";
|
|
46166
46301
|
function readAll(stateDir) {
|
|
46167
46302
|
const path = join25(stateDir, ISSUES_FILE);
|
|
46168
|
-
if (!
|
|
46303
|
+
if (!existsSync27(path))
|
|
46169
46304
|
return [];
|
|
46170
46305
|
let raw;
|
|
46171
46306
|
try {
|
|
46172
|
-
raw =
|
|
46307
|
+
raw = readFileSync27(path, "utf-8");
|
|
46173
46308
|
} catch {
|
|
46174
46309
|
return [];
|
|
46175
46310
|
}
|
|
@@ -46201,7 +46336,7 @@ function list(stateDir, opts = {}) {
|
|
|
46201
46336
|
});
|
|
46202
46337
|
}
|
|
46203
46338
|
function resolve6(stateDir, fingerprint, nowFn = Date.now) {
|
|
46204
|
-
if (!
|
|
46339
|
+
if (!existsSync27(join25(stateDir, ISSUES_FILE)))
|
|
46205
46340
|
return 0;
|
|
46206
46341
|
return withLock(stateDir, () => {
|
|
46207
46342
|
const all = readAll(stateDir);
|
|
@@ -46288,7 +46423,7 @@ function withLock(stateDir, fn) {
|
|
|
46288
46423
|
function tryStealStaleLock(lockPath) {
|
|
46289
46424
|
let pidStr;
|
|
46290
46425
|
try {
|
|
46291
|
-
pidStr =
|
|
46426
|
+
pidStr = readFileSync27(lockPath, "utf-8").trim();
|
|
46292
46427
|
} catch {
|
|
46293
46428
|
return true;
|
|
46294
46429
|
}
|
|
@@ -46386,7 +46521,7 @@ function startIssuesWatcher(opts) {
|
|
|
46386
46521
|
};
|
|
46387
46522
|
}
|
|
46388
46523
|
function defaultSignatureProvider(path) {
|
|
46389
|
-
if (!
|
|
46524
|
+
if (!existsSync28(path))
|
|
46390
46525
|
return null;
|
|
46391
46526
|
try {
|
|
46392
46527
|
const stat = statSync8(path);
|
|
@@ -46575,7 +46710,7 @@ function skillBasenameFromPath2(input) {
|
|
|
46575
46710
|
}
|
|
46576
46711
|
|
|
46577
46712
|
// credits-watch.ts
|
|
46578
|
-
import { readFileSync as
|
|
46713
|
+
import { readFileSync as readFileSync28, writeFileSync as writeFileSync17, existsSync as existsSync29, mkdirSync as mkdirSync15 } from "fs";
|
|
46579
46714
|
import { join as join27 } from "path";
|
|
46580
46715
|
var STATE_FILE = "credits-watch.json";
|
|
46581
46716
|
var FATAL_REASONS = new Set([
|
|
@@ -46589,11 +46724,11 @@ function emptyCreditState() {
|
|
|
46589
46724
|
}
|
|
46590
46725
|
function readClaudeJsonOverage(claudeConfigDir) {
|
|
46591
46726
|
const path = join27(claudeConfigDir, ".claude.json");
|
|
46592
|
-
if (!
|
|
46727
|
+
if (!existsSync29(path))
|
|
46593
46728
|
return null;
|
|
46594
46729
|
let raw;
|
|
46595
46730
|
try {
|
|
46596
|
-
raw =
|
|
46731
|
+
raw = readFileSync28(path, "utf-8");
|
|
46597
46732
|
} catch {
|
|
46598
46733
|
return null;
|
|
46599
46734
|
}
|
|
@@ -46674,10 +46809,10 @@ function escapeHtml10(s) {
|
|
|
46674
46809
|
}
|
|
46675
46810
|
function loadCreditState(stateDir) {
|
|
46676
46811
|
const path = join27(stateDir, STATE_FILE);
|
|
46677
|
-
if (!
|
|
46812
|
+
if (!existsSync29(path))
|
|
46678
46813
|
return emptyCreditState();
|
|
46679
46814
|
try {
|
|
46680
|
-
const raw =
|
|
46815
|
+
const raw = readFileSync28(path, "utf-8");
|
|
46681
46816
|
const parsed = JSON.parse(raw);
|
|
46682
46817
|
if (parsed && typeof parsed === "object" && (parsed.lastNotifiedReason === null || typeof parsed.lastNotifiedReason === "string") && typeof parsed.lastNotifiedAt === "number" && Number.isFinite(parsed.lastNotifiedAt)) {
|
|
46683
46818
|
return {
|
|
@@ -46698,10 +46833,10 @@ function saveCreditState(stateDir, state3) {
|
|
|
46698
46833
|
// gateway/turn-active-marker.ts
|
|
46699
46834
|
import {
|
|
46700
46835
|
closeSync as closeSync5,
|
|
46701
|
-
existsSync as
|
|
46836
|
+
existsSync as existsSync30,
|
|
46702
46837
|
mkdirSync as mkdirSync16,
|
|
46703
46838
|
openSync as openSync5,
|
|
46704
|
-
readFileSync as
|
|
46839
|
+
readFileSync as readFileSync29,
|
|
46705
46840
|
statSync as statSync9,
|
|
46706
46841
|
unlinkSync as unlinkSync11,
|
|
46707
46842
|
utimesSync as utimesSync2,
|
|
@@ -46718,7 +46853,7 @@ function writeTurnActiveMarker(stateDir, marker) {
|
|
|
46718
46853
|
}
|
|
46719
46854
|
function touchTurnActiveMarker2(stateDir) {
|
|
46720
46855
|
const path = join28(stateDir, TURN_ACTIVE_MARKER_FILE2);
|
|
46721
|
-
if (!
|
|
46856
|
+
if (!existsSync30(path))
|
|
46722
46857
|
return;
|
|
46723
46858
|
const now = new Date;
|
|
46724
46859
|
try {
|
|
@@ -46737,7 +46872,7 @@ function removeTurnActiveMarker(stateDir) {
|
|
|
46737
46872
|
}
|
|
46738
46873
|
function sweepStaleTurnActiveMarker(stateDir, opts) {
|
|
46739
46874
|
const path = join28(stateDir, TURN_ACTIVE_MARKER_FILE2);
|
|
46740
|
-
if (!
|
|
46875
|
+
if (!existsSync30(path))
|
|
46741
46876
|
return false;
|
|
46742
46877
|
const now = opts.now ?? Date.now();
|
|
46743
46878
|
try {
|
|
@@ -46749,7 +46884,7 @@ function sweepStaleTurnActiveMarker(stateDir, opts) {
|
|
|
46749
46884
|
return false;
|
|
46750
46885
|
let payload = null;
|
|
46751
46886
|
try {
|
|
46752
|
-
payload =
|
|
46887
|
+
payload = readFileSync29(path, "utf8");
|
|
46753
46888
|
} catch {}
|
|
46754
46889
|
unlinkSync11(path);
|
|
46755
46890
|
if (opts.onRemove) {
|
|
@@ -46768,11 +46903,11 @@ function sweepStaleTurnActiveMarker(stateDir, opts) {
|
|
|
46768
46903
|
}
|
|
46769
46904
|
|
|
46770
46905
|
// ../src/build-info.ts
|
|
46771
|
-
var VERSION = "0.12.
|
|
46772
|
-
var COMMIT_SHA = "
|
|
46773
|
-
var COMMIT_DATE = "2026-05-
|
|
46774
|
-
var LATEST_PR =
|
|
46775
|
-
var COMMITS_AHEAD_OF_TAG =
|
|
46906
|
+
var VERSION = "0.12.17";
|
|
46907
|
+
var COMMIT_SHA = "0177d926";
|
|
46908
|
+
var COMMIT_DATE = "2026-05-19T20:39:14+10:00";
|
|
46909
|
+
var LATEST_PR = null;
|
|
46910
|
+
var COMMITS_AHEAD_OF_TAG = 27;
|
|
46776
46911
|
|
|
46777
46912
|
// gateway/boot-version.ts
|
|
46778
46913
|
function formatRelativeAgo(iso) {
|
|
@@ -47333,7 +47468,7 @@ function formatBootVersion() {
|
|
|
47333
47468
|
}
|
|
47334
47469
|
try {
|
|
47335
47470
|
chmodSync5(ENV_FILE, 384);
|
|
47336
|
-
for (const line of
|
|
47471
|
+
for (const line of readFileSync32(ENV_FILE, "utf8").split(`
|
|
47337
47472
|
`)) {
|
|
47338
47473
|
const m = line.match(/^(\w+)=(.*)$/);
|
|
47339
47474
|
if (m && process.env[m[1]] === undefined)
|
|
@@ -47386,7 +47521,7 @@ installTgPostLogger(bot);
|
|
|
47386
47521
|
var _rawSendMessageDraft = bot.api.raw.sendMessageDraft;
|
|
47387
47522
|
var GRAMMY_VERSION = (() => {
|
|
47388
47523
|
try {
|
|
47389
|
-
const raw =
|
|
47524
|
+
const raw = readFileSync32(new URL("../../node_modules/grammy/package.json", import.meta.url), "utf8");
|
|
47390
47525
|
return JSON.parse(raw).version ?? "unknown";
|
|
47391
47526
|
} catch {
|
|
47392
47527
|
return "unknown";
|
|
@@ -47478,7 +47613,7 @@ function assertSendable(f) {
|
|
|
47478
47613
|
}
|
|
47479
47614
|
function readAccessFile() {
|
|
47480
47615
|
try {
|
|
47481
|
-
const raw =
|
|
47616
|
+
const raw = readFileSync32(ACCESS_FILE, "utf8");
|
|
47482
47617
|
const parsed = JSON.parse(raw);
|
|
47483
47618
|
const allowFrom = validateStringArray("allowFrom", parsed.allowFrom ?? []);
|
|
47484
47619
|
const groups = {};
|
|
@@ -47605,7 +47740,7 @@ try {
|
|
|
47605
47740
|
renameSync12(pendingEnvTmp, pendingEnvPath);
|
|
47606
47741
|
process.stderr.write(`telegram gateway: pending-turn env written to ${pendingEnvPath} turnKey=${pending.turn_key} endedVia=${pending.ended_via ?? "open"}
|
|
47607
47742
|
`);
|
|
47608
|
-
} else if (
|
|
47743
|
+
} else if (existsSync34(pendingEnvPath)) {
|
|
47609
47744
|
rmSync4(pendingEnvPath, { force: true });
|
|
47610
47745
|
process.stderr.write(`telegram gateway: pending-turn env cleared (clean previous shutdown)
|
|
47611
47746
|
`);
|
|
@@ -47677,6 +47812,9 @@ var chatAvailableReactions = new Map;
|
|
|
47677
47812
|
var chatProbesInFlight = new Set;
|
|
47678
47813
|
var activeTurnStartedAt = new Map;
|
|
47679
47814
|
var pendingRestarts = new Map;
|
|
47815
|
+
var lastSessionActiveFile = null;
|
|
47816
|
+
var compactState = initialCompactState();
|
|
47817
|
+
var compactDispatching = false;
|
|
47680
47818
|
var activeDraftStreams = new Map;
|
|
47681
47819
|
var activeDraftParseModes = new Map;
|
|
47682
47820
|
var suppressPtyPreview = new Set;
|
|
@@ -47724,13 +47862,56 @@ function purgeReactionTracking(key) {
|
|
|
47724
47862
|
if (agentDir != null)
|
|
47725
47863
|
removeActiveReaction(agentDir, msgInfo.chatId, msgInfo.messageId);
|
|
47726
47864
|
}
|
|
47727
|
-
if (activeTurnStartedAt.size === 0
|
|
47728
|
-
|
|
47729
|
-
|
|
47730
|
-
|
|
47865
|
+
if (activeTurnStartedAt.size === 0) {
|
|
47866
|
+
if (pendingRestarts.size > 0) {
|
|
47867
|
+
for (const [agentName3, _timestamp] of pendingRestarts.entries()) {
|
|
47868
|
+
triggerSelfRestart(agentName3, "turn-complete-pending-restart");
|
|
47869
|
+
pendingRestarts.delete(agentName3);
|
|
47870
|
+
}
|
|
47871
|
+
} else {
|
|
47872
|
+
maybeProactiveCompact();
|
|
47731
47873
|
}
|
|
47732
47874
|
}
|
|
47733
47875
|
}
|
|
47876
|
+
function maybeProactiveCompact() {
|
|
47877
|
+
if (compactDispatching)
|
|
47878
|
+
return;
|
|
47879
|
+
const agentName3 = process.env.SWITCHROOM_AGENT_NAME;
|
|
47880
|
+
if (!agentName3)
|
|
47881
|
+
return;
|
|
47882
|
+
let cap;
|
|
47883
|
+
try {
|
|
47884
|
+
const cfg = loadConfig2();
|
|
47885
|
+
const rawAgent = cfg.agents?.[agentName3] ?? {};
|
|
47886
|
+
const resolved = resolveAgentConfig(cfg.defaults, cfg.profiles, rawAgent);
|
|
47887
|
+
cap = resolved.session?.max_context_tokens;
|
|
47888
|
+
} catch {
|
|
47889
|
+
return;
|
|
47890
|
+
}
|
|
47891
|
+
if (cap == null || cap <= 0)
|
|
47892
|
+
return;
|
|
47893
|
+
const file = lastSessionActiveFile;
|
|
47894
|
+
if (!file)
|
|
47895
|
+
return;
|
|
47896
|
+
const turns = readTurnUsages(file, 1);
|
|
47897
|
+
if (turns.length === 0)
|
|
47898
|
+
return;
|
|
47899
|
+
const t = turns[0];
|
|
47900
|
+
const occupancy = t.input + t.cacheRead + t.cacheCreate;
|
|
47901
|
+
const decision = decideProactiveCompact(compactState, occupancy, cap);
|
|
47902
|
+
compactState = decision.state;
|
|
47903
|
+
if (!decision.fire)
|
|
47904
|
+
return;
|
|
47905
|
+
compactDispatching = true;
|
|
47906
|
+
process.stderr.write(`telegram gateway: proactive /compact for ${agentName3} (occupancy=${occupancy} >= cap=${cap})
|
|
47907
|
+
`);
|
|
47908
|
+
injectSlashCommand(agentName3, "/compact").catch((err) => {
|
|
47909
|
+
process.stderr.write(`telegram gateway: proactive /compact inject failed for ${agentName3}: ${err instanceof Error ? err.message : String(err)}
|
|
47910
|
+
`);
|
|
47911
|
+
}).finally(() => {
|
|
47912
|
+
compactDispatching = false;
|
|
47913
|
+
});
|
|
47914
|
+
}
|
|
47734
47915
|
function endStatusReaction(chatId, threadId, outcome) {
|
|
47735
47916
|
const key = statusKey(chatId, threadId);
|
|
47736
47917
|
const ctrl = activeStatusReactions.get(key);
|
|
@@ -48629,6 +48810,8 @@ ${reminder}
|
|
|
48629
48810
|
}
|
|
48630
48811
|
},
|
|
48631
48812
|
onSessionEvent(_client, msg) {
|
|
48813
|
+
if (msg.activeFile)
|
|
48814
|
+
lastSessionActiveFile = msg.activeFile;
|
|
48632
48815
|
const ev = msg.event;
|
|
48633
48816
|
const chatHint = msg.chatId || null;
|
|
48634
48817
|
const threadHint = msg.threadId != null ? String(msg.threadId) : undefined;
|
|
@@ -48777,6 +48960,20 @@ ${reminder}
|
|
|
48777
48960
|
log: (msg) => process.stderr.write(`telegram gateway: ipc \u2014 ${msg}
|
|
48778
48961
|
`)
|
|
48779
48962
|
});
|
|
48963
|
+
var IDLE_DRAIN_INTERVAL_MS = 5000;
|
|
48964
|
+
if (!STATIC) {
|
|
48965
|
+
setInterval(() => {
|
|
48966
|
+
const selfAgent = process.env.SWITCHROOM_AGENT_NAME ?? "";
|
|
48967
|
+
const r = idleDrainTick(pendingInboundBuffer, selfAgent, () => {
|
|
48968
|
+
const c = ipcServer.getClient(selfAgent);
|
|
48969
|
+
return c != null && c.isAlive();
|
|
48970
|
+
}, (m) => ipcServer.sendToAgent(selfAgent, m));
|
|
48971
|
+
if (r != null && r.redelivered > 0) {
|
|
48972
|
+
process.stderr.write(`telegram gateway: idle-drain flushed ${r.redelivered}/${r.drained} buffered inbound for ${selfAgent}${r.rebuffered > 0 ? ` (${r.rebuffered} re-buffered)` : ""}
|
|
48973
|
+
`);
|
|
48974
|
+
}
|
|
48975
|
+
}, IDLE_DRAIN_INTERVAL_MS).unref();
|
|
48976
|
+
}
|
|
48780
48977
|
var ALLOWED_TOOLS = new Set([
|
|
48781
48978
|
"reply",
|
|
48782
48979
|
"stream_reply",
|
|
@@ -49542,8 +49739,8 @@ async function publishToTelegraph(text, shortName, authorName) {
|
|
|
49542
49739
|
const accountPath = join32(STATE_DIR, "telegraph-account.json");
|
|
49543
49740
|
let account = null;
|
|
49544
49741
|
try {
|
|
49545
|
-
if (
|
|
49546
|
-
const raw =
|
|
49742
|
+
if (existsSync34(accountPath)) {
|
|
49743
|
+
const raw = readFileSync32(accountPath, "utf-8");
|
|
49547
49744
|
const parsed = JSON.parse(raw);
|
|
49548
49745
|
if (parsed.shortName && parsed.accessToken) {
|
|
49549
49746
|
account = parsed;
|
|
@@ -51422,7 +51619,7 @@ function readRestartMarker() {
|
|
|
51422
51619
|
if (!p)
|
|
51423
51620
|
return null;
|
|
51424
51621
|
try {
|
|
51425
|
-
return JSON.parse(
|
|
51622
|
+
return JSON.parse(readFileSync32(p, "utf8"));
|
|
51426
51623
|
} catch {
|
|
51427
51624
|
return null;
|
|
51428
51625
|
}
|
|
@@ -51491,7 +51688,7 @@ var _dockerReachable;
|
|
|
51491
51688
|
function isDockerReachable() {
|
|
51492
51689
|
if (_dockerReachable !== undefined)
|
|
51493
51690
|
return _dockerReachable;
|
|
51494
|
-
if (!
|
|
51691
|
+
if (!existsSync34("/var/run/docker.sock")) {
|
|
51495
51692
|
_dockerReachable = false;
|
|
51496
51693
|
return _dockerReachable;
|
|
51497
51694
|
}
|
|
@@ -51539,7 +51736,7 @@ function spawnSwitchroomDetached(args, onFailure) {
|
|
|
51539
51736
|
return;
|
|
51540
51737
|
let tail = "";
|
|
51541
51738
|
try {
|
|
51542
|
-
const full =
|
|
51739
|
+
const full = readFileSync32(logPath, "utf8");
|
|
51543
51740
|
tail = full.split(`
|
|
51544
51741
|
`).slice(-30).join(`
|
|
51545
51742
|
`).trim();
|
|
@@ -51882,9 +52079,9 @@ bot.use(async (ctx, next) => {
|
|
|
51882
52079
|
function readRecentDenialsForAgent(agentName3, windowMs, limit) {
|
|
51883
52080
|
try {
|
|
51884
52081
|
const auditPath = join32(homedir12(), ".switchroom", "vault-audit.log");
|
|
51885
|
-
if (!
|
|
52082
|
+
if (!existsSync34(auditPath))
|
|
51886
52083
|
return [];
|
|
51887
|
-
const raw =
|
|
52084
|
+
const raw = readFileSync32(auditPath, "utf8");
|
|
51888
52085
|
return recentDenialsFromAuditLog(raw, { agentName: agentName3, windowMs, limit });
|
|
51889
52086
|
} catch {
|
|
51890
52087
|
return [];
|
|
@@ -51935,7 +52132,7 @@ async function buildAgentMetadata(agentName3) {
|
|
|
51935
52132
|
try {
|
|
51936
52133
|
const agentDir = resolveAgentDirFromEnv();
|
|
51937
52134
|
if (agentDir) {
|
|
51938
|
-
const raw =
|
|
52135
|
+
const raw = readFileSync32(join32(agentDir, ".claude", ".claude.json"), "utf8");
|
|
51939
52136
|
claudeJson = JSON.parse(raw);
|
|
51940
52137
|
}
|
|
51941
52138
|
} catch {}
|
|
@@ -52151,7 +52348,7 @@ function flushAgentHandoff(agentDir) {
|
|
|
52151
52348
|
for (const fname of [".handoff.md", ".handoff-topic"]) {
|
|
52152
52349
|
const p = join32(agentDir, fname);
|
|
52153
52350
|
try {
|
|
52154
|
-
if (
|
|
52351
|
+
if (existsSync34(p)) {
|
|
52155
52352
|
unlinkSync14(p);
|
|
52156
52353
|
removed++;
|
|
52157
52354
|
}
|
|
@@ -52556,16 +52753,16 @@ bot.command("interrupt", async (ctx) => {
|
|
|
52556
52753
|
await runSwitchroomCommand(ctx, ["agent", "interrupt", name], `interrupt ${name}`);
|
|
52557
52754
|
});
|
|
52558
52755
|
var lockoutOps = {
|
|
52559
|
-
readFileSync: (p, enc) =>
|
|
52756
|
+
readFileSync: (p, enc) => readFileSync32(p, enc),
|
|
52560
52757
|
writeFileSync: (p, data, opts) => writeFileSync21(p, data, opts),
|
|
52561
|
-
existsSync: (p) =>
|
|
52758
|
+
existsSync: (p) => existsSync34(p),
|
|
52562
52759
|
mkdirSync: (p, opts) => mkdirSync21(p, opts),
|
|
52563
52760
|
joinPath: (...parts) => join32(...parts)
|
|
52564
52761
|
};
|
|
52565
52762
|
var FLEET_FALLBACK_DEDUP_MS = 30000;
|
|
52566
52763
|
function isAuthBrokerSocketReachable() {
|
|
52567
52764
|
try {
|
|
52568
|
-
return
|
|
52765
|
+
return existsSync34(resolveAuthBrokerSocketPath2());
|
|
52569
52766
|
} catch {
|
|
52570
52767
|
return false;
|
|
52571
52768
|
}
|
|
@@ -54750,8 +54947,8 @@ async function maybeTranscribeVoice(fileId, mimeType, language) {
|
|
|
54750
54947
|
let apiKey = null;
|
|
54751
54948
|
try {
|
|
54752
54949
|
const path = __require("path").join(__require("os").homedir(), ".switchroom", "openai-api-key");
|
|
54753
|
-
if (
|
|
54754
|
-
apiKey =
|
|
54950
|
+
if (existsSync34(path)) {
|
|
54951
|
+
apiKey = readFileSync32(path, "utf-8").trim();
|
|
54755
54952
|
}
|
|
54756
54953
|
} catch (err) {
|
|
54757
54954
|
process.stderr.write(`telegram gateway: voice-in: failed to read api key: ${err.message}
|