switchroom 0.19.11 → 0.19.13
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/cli/switchroom.js +1 -1
- package/dist/host-control/main.js +1 -1
- package/package.json +1 -1
- package/profiles/_base/cron-session.sh.hbs +5 -0
- package/profiles/_base/start.sh.hbs +11 -0
- package/telegram-plugin/dist/gateway/gateway.js +1382 -1032
- package/telegram-plugin/final-answer-detect.ts +23 -0
- package/telegram-plugin/gateway/gateway.ts +29 -36
- package/telegram-plugin/gateway/outbound-send-path.ts +109 -8
- package/telegram-plugin/gateway/outbox-sweep.ts +282 -0
- package/telegram-plugin/gateway/stream-render.ts +26 -50
- package/telegram-plugin/hooks/silent-end-interrupt-stop.mjs +94 -2
- package/telegram-plugin/hooks/silent-end-scan.mjs +279 -0
- package/telegram-plugin/outbox.ts +472 -0
- package/telegram-plugin/scripts/bun-test-ci.sh +91 -0
- package/telegram-plugin/temporal-normalize.ts +347 -0
- package/telegram-plugin/tests/gateway-outbound-redact.test.ts +22 -12
- package/telegram-plugin/tests/outbound-send-path.test.ts +191 -0
- package/telegram-plugin/tests/outbox-capture-scan.test.ts +222 -0
- package/telegram-plugin/tests/outbox-delivery.test.ts +278 -0
- package/telegram-plugin/tests/outbox-hook-capture.test.ts +112 -0
- package/telegram-plugin/tests/silent-end-interrupt-stop-integration.test.ts +60 -63
- package/telegram-plugin/tests/silent-end.test.ts +21 -28
- package/telegram-plugin/tests/temporal-normalize.test.ts +222 -0
- package/telegram-plugin/tests/turn-flush-safety.test.ts +23 -18
package/dist/cli/switchroom.js
CHANGED
|
@@ -2120,7 +2120,7 @@ var init_esm = __esm(() => {
|
|
|
2120
2120
|
});
|
|
2121
2121
|
|
|
2122
2122
|
// src/build-info.ts
|
|
2123
|
-
var VERSION = "0.19.
|
|
2123
|
+
var VERSION = "0.19.13", COMMIT_SHA = "fda10488";
|
|
2124
2124
|
|
|
2125
2125
|
// src/cli/resolve-version.ts
|
|
2126
2126
|
import { existsSync, readFileSync } from "node:fs";
|
|
@@ -26664,7 +26664,7 @@ import { existsSync as existsSync9, readFileSync as readFileSync7 } from "node:f
|
|
|
26664
26664
|
import { dirname as dirname5, join as join7 } from "node:path";
|
|
26665
26665
|
|
|
26666
26666
|
// src/build-info.ts
|
|
26667
|
-
var VERSION = "0.19.
|
|
26667
|
+
var VERSION = "0.19.13";
|
|
26668
26668
|
|
|
26669
26669
|
// src/cli/resolve-version.ts
|
|
26670
26670
|
function readPackageVersion() {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "switchroom",
|
|
3
3
|
"//version": "NOT the release version — source of truth is the git tag, resolved by scripts/build.mjs:resolveVersion() (see CLAUDE.md > Standard release process). This field is stale by design and only the Layer-4 dev/non-tag fallback for build.mjs + src/cli/resolve-version.ts; do NOT bump it expecting a release to pick it up. npm-pack tarball naming needs a real version — do that as an UNCOMMITTED pack-time bump (see release step 6), never a committed one.",
|
|
4
|
-
"version": "0.19.
|
|
4
|
+
"version": "0.19.13",
|
|
5
5
|
"description": "Run Claude Code 24/7 on your Claude Pro/Max subscription over Telegram. Open-source alternative to OpenClaw and NanoClaw — no API keys.",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"bin": {
|
|
@@ -69,6 +69,11 @@ fi
|
|
|
69
69
|
export SWITCHROOM_AGENT_NAME="$CRON_NAME"
|
|
70
70
|
export CLAUDE_CONFIG_DIR="$CRON_CONFIG_DIR"
|
|
71
71
|
|
|
72
|
+
# Preserve pre-2.1.217 nested sub-agent behaviour for cron-fired sessions too.
|
|
73
|
+
# Normally inherited from start.sh's env; set here as a belt-and-braces default
|
|
74
|
+
# (honouring any value already in the env). See start.sh.hbs for rationale.
|
|
75
|
+
export CLAUDE_CODE_MAX_SUBAGENT_SPAWN_DEPTH="${CLAUDE_CODE_MAX_SUBAGENT_SPAWN_DEPTH:-2}"
|
|
76
|
+
|
|
72
77
|
# Defer the (now full) MCP schema set via tool-search so the cron session keeps
|
|
73
78
|
# its low-context cost — the heavy servers load on demand; switchroom-telegram
|
|
74
79
|
# + hindsight stay alwaysLoad. Normally inherited from start.sh's env; set here
|
|
@@ -532,6 +532,17 @@ export CLAUDE_CONFIG_DIR="{{agentDir}}/.claude"
|
|
|
532
532
|
# Claude reads .credentials.json directly; the broker is the sole writer
|
|
533
533
|
# of that file and updates it before claude's own refresh window opens.
|
|
534
534
|
unset CLAUDE_CODE_OAUTH_TOKEN
|
|
535
|
+
# Claude Code 2.1.217 turned NESTED sub-agent spawning OFF by default: a
|
|
536
|
+
# sub-agent can no longer spawn its own sub-agent unless this env is set.
|
|
537
|
+
# The fleet relies on multi-level worker delegation (the main session
|
|
538
|
+
# dispatches @worker/@researcher, and a dispatched worker may in turn fan
|
|
539
|
+
# out its own sub-agents), so we restore the pre-2.1.217 behaviour. Depth 2
|
|
540
|
+
# = main → sub-agent → grandchild, which covers the one extra level the
|
|
541
|
+
# fleet actually uses; there is no evidence of deeper nesting, so we don't
|
|
542
|
+
# raise it further. (The companion 2.1.217 change — CLAUDE_CODE_MAX_
|
|
543
|
+
# CONCURRENT_SUBAGENTS defaulting to 20 — is already compatible: our fleet
|
|
544
|
+
# self-caps at 15 parallel sub-agents, so the 20 default is left untouched.)
|
|
545
|
+
export CLAUDE_CODE_MAX_SUBAGENT_SPAWN_DEPTH="${CLAUDE_CODE_MAX_SUBAGENT_SPAWN_DEPTH:-2}"
|
|
535
546
|
export TELEGRAM_STATE_DIR="{{agentDir}}/telegram"
|
|
536
547
|
# SWITCHROOM_AGENT_NAME is the canonical "which agent am I" identifier the
|
|
537
548
|
# telegram-plugin reads to detect self-restart commands. We can't rely on
|