ai-agentmanager 1.35.0 → 1.36.0

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 CHANGED
@@ -1,5 +1,10 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.36.0 (2026-11-10)
4
+
5
+ - **Open sessions are always at the top of the agents list.** Agents needing your input come first, then working ones, then open sessions waiting for a prompt, in every list order. In **By project**, projects with an open session come first and, inside each project, open sessions come before the rest. The *last N days* filter no longer hides an older agent whose session is open. The **Running first** order is gone, since every order now does this; a saved choice falls back to **Recently used**.
6
+ - Fixed a flaky end-to-end test: the Eval's one-minute timer could redo an Eval the test had set by hand.
7
+
3
8
  ## 1.35.0 (2026-11-09)
4
9
 
5
10
  - **Flaky CI is caught before it reaches the agent.** When GitHub Actions checks fail on an agent's pull request, the failed jobs are run once more on the same commit (`gh run rerun --failed`) before the agent is told. If they pass, the checks are marked **Flaky** on the pull request's row in the Land tab and nothing is sent; if they fail again, the agent is told, and that it failed twice. Checks from other CI systems, and a re-run GitHub refuses, go to the agent straight away as before. Once per commit; turn it off in the Land tab's settings.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ai-agentmanager",
3
- "version": "1.35.0",
3
+ "version": "1.36.0",
4
4
  "description": "Run background coding agents (Claude Code, Codex) per intent, and keep track of them from a web UI, your phone or the CLI",
5
5
  "keywords": [
6
6
  "claude",
package/public/app.js CHANGED
@@ -82,8 +82,9 @@ const saveRecent = () => {
82
82
  localStorage.setItem('agentmgr.recentDays', String(recent.days));
83
83
  } catch {}
84
84
  };
85
- // How the agents list is ordered: recently used (the default), running first or newest first, one list each; or grouped by project.
86
- const ORDERS = ['recent', 'running', 'created', 'project'];
85
+ // How the agents list is ordered: recently used (the default) or newest first, one list each; or grouped by project.
86
+ // In each, open sessions come first: needing you, working, then waiting for a prompt.
87
+ const ORDERS = ['recent', 'created', 'project'];
87
88
  let listOrder = (() => {
88
89
  try {
89
90
  const v = localStorage.getItem('agentmgr.listOrder');
@@ -988,8 +989,8 @@ const copyBtn = (value) => `<button class="link" data-copy="${esc(value)}" title
988
989
 
989
990
  // ------------------------------------------------------------------ list
990
991
 
991
- /** Agents waiting on you first, then running ones, then the rest. */
992
- const rank = (a) => (a.runtime.attention ? 0 : a.runtime.running ? 1 : 2);
992
+ /** Agents needing you first, then working ones, then open sessions waiting for a prompt, then the rest. */
993
+ const rank = (a) => (a.runtime.attention ? 0 : a.runtime.running && a.runtime.busy ? 1 : a.runtime.running ? 2 : 3);
993
994
 
994
995
  // Agents with no work and no input from you for a day sink below the active ones.
995
996
  const ACTIVE_MS = 24 * 3600 * 1000;
@@ -1063,12 +1064,12 @@ function projectGroups(list) {
1063
1064
  }
1064
1065
  const out = [...groups.values()];
1065
1066
  for (const g of out) {
1066
- // Active in the last day first; then highest priority, agents needing you, running ones, most recent.
1067
+ // Open sessions first (needing you, working, waiting); then active in the last day, highest priority, most recent.
1067
1068
  g.agents.sort(
1068
1069
  (a, b) =>
1070
+ rank(a) - rank(b) ||
1069
1071
  isActive(b) - isActive(a) ||
1070
1072
  (a.priority ?? 2) - (b.priority ?? 2) ||
1071
- rank(a) - rank(b) ||
1072
1073
  (b.activeAt ?? b.createdAt).localeCompare(a.activeAt ?? a.createdAt),
1073
1074
  );
1074
1075
  g.active = g.agents.filter(isActive).length;
@@ -1087,6 +1088,7 @@ function projectGroups(list) {
1087
1088
  return out.sort(
1088
1089
  (a, b) =>
1089
1090
  special(a) - special(b) ||
1091
+ (b.waiting + b.running > 0) - (a.waiting + a.running > 0) ||
1090
1092
  (b.active > 0) - (a.active > 0) ||
1091
1093
  a.top - b.top ||
1092
1094
  b.waiting - a.waiting ||
@@ -1095,12 +1097,11 @@ function projectGroups(list) {
1095
1097
  );
1096
1098
  }
1097
1099
 
1098
- /** One list, most recently used first (Running first: the running agents, then the rest; Newest first: by creation). */
1100
+ /** One list: open sessions first (needing you, working, waiting), then most recently used (Newest first: by creation). */
1099
1101
  const usedAt = (a) => a.activeAt ?? a.createdAt ?? '';
1100
1102
  function orderedAgents(list) {
1101
- const top = (a) => (listOrder === 'running' && !a.runtime.running ? 1 : 0);
1102
1103
  const at = listOrder === 'created' ? (a) => a.createdAt ?? '' : usedAt;
1103
- return [...list].sort((a, b) => top(a) - top(b) || at(b).localeCompare(at(a)));
1104
+ return [...list].sort((a, b) => rank(a) - rank(b) || at(b).localeCompare(at(a)));
1104
1105
  }
1105
1106
 
1106
1107
  /** The project picker: every project with agents, by name; a project that's gone falls back to all. */
@@ -1135,9 +1136,9 @@ function renderList() {
1135
1136
  .toLowerCase()
1136
1137
  .includes(filterText),
1137
1138
  );
1138
- // The open agent stays in the list even when it's older.
1139
+ // The open agent, and agents with an open session, stay in the list even when they're older.
1139
1140
  const since = recent.on ? Date.now() - recent.days * 86_400_000 : 0;
1140
- const shown = since ? list.filter((a) => a.id === selectedId || (Date.parse(a.createdAt) || 0) >= since) : list;
1141
+ const shown = since ? list.filter((a) => a.id === selectedId || rank(a) < 3 || (Date.parse(a.createdAt) || 0) >= since) : list;
1141
1142
  const hidden = list.length - shown.length;
1142
1143
  $('#recent-bar').hidden = agents.size === 0;
1143
1144
  $('#recent-on').checked = recent.on;
package/public/index.html CHANGED
@@ -99,9 +99,8 @@
99
99
  <input type="number" id="recent-days" min="1" max="3650" value="7" aria-label="Days"> days
100
100
  <span class="spacer"></span><span id="recent-hidden"></span>
101
101
  <select id="list-project" aria-label="Project" title="Show only one project's agents" hidden></select>
102
- <select id="list-order" aria-label="Order" title="Recently used: one list, the agents created or worked in most recently on top. Running first: running agents on top, most recently used first, then the rest. Newest first: by creation date, the newest on top. By project: grouped, busiest and most urgent first.">
102
+ <select id="list-order" aria-label="Order" title="Open sessions are always on top: needing you, then working, then waiting for a prompt. Below them, Recently used: the agents created or worked in most recently first. Newest first: by creation date, the newest first. By project: grouped, projects with open sessions first.">
103
103
  <option value="recent">Recently used</option>
104
- <option value="running">Running first</option>
105
104
  <option value="created">Newest first</option>
106
105
  <option value="project">By project</option>
107
106
  </select>
package/src/server.js CHANGED
@@ -90,7 +90,7 @@ const HOOK_PATH = '/api/hooks/agents';
90
90
  const REPORT_PATH = '/api/agentkit/report';
91
91
  const NO_REPO_KINDS = new Set(['general', 'assistant']);
92
92
 
93
- export async function startServer({ port = PORT, host = HOST } = {}) {
93
+ export async function startServer({ port = PORT, host = HOST, evalTimer = true } = {}) {
94
94
  ensureHome();
95
95
  const config = loadConfig();
96
96
  const store = new Store(paths.state);
@@ -176,7 +176,7 @@ export async function startServer({ port = PORT, host = HOST } = {}) {
176
176
  transcript: (a) => (engineOf(a).id === 'claude' && a.workdir ? readTail(engineOf(a).sessionFile(a.workdir, a.sessionId)) : null),
177
177
  log: (m) => console.log(`[agentmgr] ${m}`),
178
178
  });
179
- evals.startTimer();
179
+ if (evalTimer) evals.startTimer();
180
180
  const races = new Races({ manager, store });
181
181
  const review = new Review({ manager });
182
182
  // The walkthrough explains the same diff the review screen shows.