orquesta-agent 0.2.66 → 0.2.67

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.
@@ -108,8 +108,21 @@ function setBar(id, pct) {
108
108
  async function loadAgents() {
109
109
  try {
110
110
  const res = await fetch(`${API}/agents`)
111
- agents = await res.json()
112
- renderAgents()
111
+ const newAgents = await res.json()
112
+
113
+ // Only re-render if agents changed (avoid killing open panels/SSE)
114
+ const changed = JSON.stringify(newAgents.map(a => `${a.id}:${a.status}:${a.pid}`)) !==
115
+ JSON.stringify(agents.map(a => `${a.id}:${a.status}:${a.pid}`))
116
+ agents = newAgents
117
+
118
+ if (changed) {
119
+ renderAgents()
120
+ } else {
121
+ // Just update counts
122
+ const running = agents.filter(a => a.status === 'running').length
123
+ const countEl = document.getElementById('agent-count')
124
+ if (countEl) countEl.textContent = `${running} of ${agents.length} online`
125
+ }
113
126
  } catch {}
114
127
  }
115
128
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "orquesta-agent",
3
- "version": "0.2.66",
3
+ "version": "0.2.67",
4
4
  "description": "Local agent for Orquesta - connects your VM to the Orquesta dashboard",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",