@llblab/pi-telegram 0.48.1 → 0.48.2
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/CHANGELOG.md +4 -0
- package/dist/lib/bus-follower.js +5 -2
- package/dist/package.json +1 -1
- package/lib/bus-follower.ts +5 -2
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,10 @@
|
|
|
4
4
|
|
|
5
5
|
## Unreleased
|
|
6
6
|
|
|
7
|
+
## 0.48.2: Follower promotion recovery
|
|
8
|
+
|
|
9
|
+
- `Follower promotion recovery`: A failed follower-to-leader promotion, including unavailable Thread slot authority, is now contained as a retryable bus recovery event instead of escaping a detached heartbeat recovery promise and terminating Pi.
|
|
10
|
+
|
|
7
11
|
## 0.48.1: Truthful terminal queue count hotfix
|
|
8
12
|
|
|
9
13
|
- `Terminal queue status`: The yellow `+N` suffix now counts only executable prompts still waiting in the Telegram queue. The current agent run never contributes—whether it started from Telegram, the terminal, or autonomous continuation—and a dispatched Telegram prompt leaves the visible count before its run settles.
|
package/dist/lib/bus-follower.js
CHANGED
|
@@ -821,8 +821,8 @@ export function createTelegramBusFollowerHeartbeatRecoveryHandler(deps) {
|
|
|
821
821
|
return;
|
|
822
822
|
promotionPending = true;
|
|
823
823
|
deps.registrationState.beginRecovery();
|
|
824
|
+
const initialBinding = carriedBinding ?? snapshotBinding();
|
|
824
825
|
try {
|
|
825
|
-
const initialBinding = carriedBinding ?? snapshotBinding();
|
|
826
826
|
const state = deps.getLeaderState();
|
|
827
827
|
if (state.kind === "active-elsewhere") {
|
|
828
828
|
clearRegisteredState(ctx);
|
|
@@ -862,7 +862,10 @@ export function createTelegramBusFollowerHeartbeatRecoveryHandler(deps) {
|
|
|
862
862
|
});
|
|
863
863
|
return;
|
|
864
864
|
}
|
|
865
|
-
|
|
865
|
+
deps.recordRuntimeEvent("bus", promotionError, {
|
|
866
|
+
phase: "follower-promotion-failed",
|
|
867
|
+
});
|
|
868
|
+
scheduleRecovery(promotionError, ctx, initialBinding);
|
|
866
869
|
}
|
|
867
870
|
finally {
|
|
868
871
|
promotionPending = false;
|
package/dist/package.json
CHANGED
package/lib/bus-follower.ts
CHANGED
|
@@ -1496,8 +1496,8 @@ export function createTelegramBusFollowerHeartbeatRecoveryHandler<TContext>(
|
|
|
1496
1496
|
if (promotionPending) return;
|
|
1497
1497
|
promotionPending = true;
|
|
1498
1498
|
deps.registrationState.beginRecovery();
|
|
1499
|
+
const initialBinding = carriedBinding ?? snapshotBinding();
|
|
1499
1500
|
try {
|
|
1500
|
-
const initialBinding = carriedBinding ?? snapshotBinding();
|
|
1501
1501
|
const state = deps.getLeaderState();
|
|
1502
1502
|
if (state.kind === "active-elsewhere") {
|
|
1503
1503
|
clearRegisteredState(ctx);
|
|
@@ -1563,7 +1563,10 @@ export function createTelegramBusFollowerHeartbeatRecoveryHandler<TContext>(
|
|
|
1563
1563
|
});
|
|
1564
1564
|
return;
|
|
1565
1565
|
}
|
|
1566
|
-
|
|
1566
|
+
deps.recordRuntimeEvent("bus", promotionError, {
|
|
1567
|
+
phase: "follower-promotion-failed",
|
|
1568
|
+
});
|
|
1569
|
+
scheduleRecovery(promotionError, ctx, initialBinding);
|
|
1567
1570
|
} finally {
|
|
1568
1571
|
promotionPending = false;
|
|
1569
1572
|
}
|