@yemi33/minions 0.1.335 → 0.1.337
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 +3 -1
- package/dashboard/js/render-dispatch.js +1 -1
- package/dashboard.js +11 -1
- package/engine/queries.js +3 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
-
## 0.1.
|
|
3
|
+
## 0.1.337 (2026-04-03)
|
|
4
4
|
|
|
5
5
|
### Fixes
|
|
6
|
+
- completed dispatch stat shows actual count instead of capped 20
|
|
7
|
+
- CC session auto-invalidated when system prompt changes after restart
|
|
6
8
|
- clear stale buildStatus when PRs are merged or abandoned
|
|
7
9
|
|
|
8
10
|
## 0.1.334 (2026-04-03)
|
|
@@ -75,7 +75,7 @@ function renderDispatch(dispatch) {
|
|
|
75
75
|
stats.innerHTML =
|
|
76
76
|
'<div class="dispatch-stat"><div class="dispatch-stat-num yellow">' + (dispatch.active || []).length + '</div><div class="dispatch-stat-label">Active</div></div>' +
|
|
77
77
|
'<div class="dispatch-stat"><div class="dispatch-stat-num blue">' + (dispatch.pending || []).length + '</div><div class="dispatch-stat-label">Pending</div></div>' +
|
|
78
|
-
'<div class="dispatch-stat"><div class="dispatch-stat-num green">' + (dispatch.completed || []).length + '</div><div class="dispatch-stat-label">Completed</div></div>';
|
|
78
|
+
'<div class="dispatch-stat"><div class="dispatch-stat-num green">' + (dispatch.completedTotal || (dispatch.completed || []).length) + '</div><div class="dispatch-stat-label">Completed</div></div>';
|
|
79
79
|
|
|
80
80
|
// Active
|
|
81
81
|
const activeEl = document.getElementById('dispatch-active');
|
package/dashboard.js
CHANGED
|
@@ -277,8 +277,17 @@ let ccInFlight = false;
|
|
|
277
277
|
let ccInFlightSince = 0; // timestamp — auto-release stuck guard
|
|
278
278
|
const CC_INFLIGHT_TIMEOUT_MS = 2 * 60 * 1000; // 2 minutes — auto-release if request hangs
|
|
279
279
|
|
|
280
|
+
// Hash the system prompt so we can detect changes and invalidate stale sessions
|
|
281
|
+
const _ccPromptHash = require('crypto').createHash('md5').update(CC_STATIC_SYSTEM_PROMPT).digest('hex').slice(0, 8);
|
|
282
|
+
|
|
280
283
|
function ccSessionValid() {
|
|
281
284
|
if (!ccSession.sessionId) return false;
|
|
285
|
+
// Invalidate session if system prompt changed (e.g. after code update + restart)
|
|
286
|
+
if (ccSession._promptHash && ccSession._promptHash !== _ccPromptHash) {
|
|
287
|
+
console.log('[CC] System prompt changed — invalidating stale session');
|
|
288
|
+
ccSession = { sessionId: null, createdAt: null, lastActiveAt: null, turnCount: 0 };
|
|
289
|
+
return false;
|
|
290
|
+
}
|
|
282
291
|
const age = Date.now() - new Date(ccSession.lastActiveAt || 0).getTime();
|
|
283
292
|
return age < CC_SESSION_EXPIRY_MS && ccSession.turnCount < CC_SESSION_MAX_TURNS;
|
|
284
293
|
}
|
|
@@ -553,6 +562,7 @@ function updateSession(store, key, sessionId, existing) {
|
|
|
553
562
|
createdAt: existing ? ccSession.createdAt : now,
|
|
554
563
|
lastActiveAt: now,
|
|
555
564
|
turnCount: (existing ? ccSession.turnCount : 0) + 1,
|
|
565
|
+
_promptHash: _ccPromptHash,
|
|
556
566
|
};
|
|
557
567
|
safeWrite(path.join(ENGINE_DIR, 'cc-session.json'), ccSession);
|
|
558
568
|
} else if (key) {
|
|
@@ -3052,7 +3062,7 @@ What would you like to discuss or change? When you're happy, say "approve" and I
|
|
|
3052
3062
|
// Update session
|
|
3053
3063
|
const now = Date.now();
|
|
3054
3064
|
if (result.sessionId) {
|
|
3055
|
-
ccSession = { sessionId: result.sessionId, createdAt: ccSession.createdAt || now, lastActiveAt: now, turnCount: (ccSession.turnCount || 0) + 1 };
|
|
3065
|
+
ccSession = { sessionId: result.sessionId, createdAt: ccSession.createdAt || now, lastActiveAt: now, turnCount: (ccSession.turnCount || 0) + 1, _promptHash: _ccPromptHash };
|
|
3056
3066
|
safeWrite(path.join(ENGINE_DIR, 'cc-session.json'), ccSession);
|
|
3057
3067
|
}
|
|
3058
3068
|
|
package/engine/queries.js
CHANGED
|
@@ -55,7 +55,9 @@ function getDispatch() {
|
|
|
55
55
|
|
|
56
56
|
function getDispatchQueue() {
|
|
57
57
|
const d = getDispatch();
|
|
58
|
-
|
|
58
|
+
const allCompleted = d.completed || [];
|
|
59
|
+
d.completedTotal = allCompleted.length;
|
|
60
|
+
d.completed = allCompleted.slice(-20);
|
|
59
61
|
return d;
|
|
60
62
|
}
|
|
61
63
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yemi33/minions",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.337",
|
|
4
4
|
"description": "Multi-agent AI dev team that runs from ~/.minions/ — five autonomous agents share a single engine, dashboard, and knowledge base",
|
|
5
5
|
"bin": {
|
|
6
6
|
"minions": "bin/minions.js"
|