fleetlens 0.15.0 → 0.15.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.
Files changed (49) hide show
  1. package/app/apps/web/.next/BUILD_ID +1 -1
  2. package/app/apps/web/.next/build-manifest.json +3 -3
  3. package/app/apps/web/.next/prerender-manifest.json +3 -3
  4. package/app/apps/web/.next/server/app/_global-error.html +1 -1
  5. package/app/apps/web/.next/server/app/_global-error.rsc +1 -1
  6. package/app/apps/web/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  7. package/app/apps/web/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  8. package/app/apps/web/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  9. package/app/apps/web/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  10. package/app/apps/web/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  11. package/app/apps/web/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  12. package/app/apps/web/.next/server/app/changelog/page_client-reference-manifest.js +1 -1
  13. package/app/apps/web/.next/server/app/day/[date]/page_client-reference-manifest.js +1 -1
  14. package/app/apps/web/.next/server/app/day/page_client-reference-manifest.js +1 -1
  15. package/app/apps/web/.next/server/app/digest/[date]/page_client-reference-manifest.js +1 -1
  16. package/app/apps/web/.next/server/app/digest/page_client-reference-manifest.js +1 -1
  17. package/app/apps/web/.next/server/app/insights/[key]/page_client-reference-manifest.js +1 -1
  18. package/app/apps/web/.next/server/app/insights/page_client-reference-manifest.js +1 -1
  19. package/app/apps/web/.next/server/app/page_client-reference-manifest.js +1 -1
  20. package/app/apps/web/.next/server/app/parallelism/page_client-reference-manifest.js +1 -1
  21. package/app/apps/web/.next/server/app/print/[key]/page_client-reference-manifest.js +1 -1
  22. package/app/apps/web/.next/server/app/projects/[slug]/page_client-reference-manifest.js +1 -1
  23. package/app/apps/web/.next/server/app/projects/page_client-reference-manifest.js +1 -1
  24. package/app/apps/web/.next/server/app/runs/page_client-reference-manifest.js +1 -1
  25. package/app/apps/web/.next/server/app/sessions/[id]/page_client-reference-manifest.js +1 -1
  26. package/app/apps/web/.next/server/app/sessions/page_client-reference-manifest.js +1 -1
  27. package/app/apps/web/.next/server/app/settings/page_client-reference-manifest.js +1 -1
  28. package/app/apps/web/.next/server/app/team/onboarding/page_client-reference-manifest.js +1 -1
  29. package/app/apps/web/.next/server/app/team/page_client-reference-manifest.js +1 -1
  30. package/app/apps/web/.next/server/app/usage/page_client-reference-manifest.js +1 -1
  31. package/app/apps/web/.next/server/chunks/ssr/_0xu2pvc._.js +1 -1
  32. package/app/apps/web/.next/server/chunks/ssr/apps_web_lib_changelog_ts_0n7_p1d._.js +1 -1
  33. package/app/apps/web/.next/server/chunks/ssr/apps_web_lib_changelog_ts_0nb5_-s._.js +1 -1
  34. package/app/apps/web/.next/server/middleware-build-manifest.js +3 -3
  35. package/app/apps/web/.next/server/middleware-manifest.json +5 -5
  36. package/app/apps/web/.next/server/pages/500.html +1 -1
  37. package/app/apps/web/.next/server/server-reference-manifest.js +1 -1
  38. package/app/apps/web/.next/server/server-reference-manifest.json +1 -1
  39. package/app/apps/web/.next/static/chunks/0i77er85v.rj..js +1 -0
  40. package/app/apps/web/lib/changelog-data.generated.ts +1 -1
  41. package/app/apps/web/package.json +1 -1
  42. package/app/apps/web/tsconfig.tsbuildinfo +1 -1
  43. package/dist/daemon-worker.js +4 -4
  44. package/dist/index.js +69 -35
  45. package/package.json +1 -1
  46. package/app/apps/web/.next/static/chunks/06eiwghjkkbnh.js +0 -1
  47. /package/app/apps/web/.next/static/{C4y6rare_ZCcXXQLc8ysA → mTj8nKiazosAKJec15dLe}/_buildManifest.js +0 -0
  48. /package/app/apps/web/.next/static/{C4y6rare_ZCcXXQLc8ysA → mTj8nKiazosAKJec15dLe}/_clientMiddlewareManifest.js +0 -0
  49. /package/app/apps/web/.next/static/{C4y6rare_ZCcXXQLc8ysA → mTj8nKiazosAKJec15dLe}/_ssgManifest.js +0 -0
@@ -6746,7 +6746,7 @@ function buildIngestPayload(inputs) {
6746
6746
  return {
6747
6747
  ingestId: randomUUID(),
6748
6748
  observedAt: (/* @__PURE__ */ new Date()).toISOString(),
6749
- cliVersion: "0.15.0",
6749
+ cliVersion: "0.15.2",
6750
6750
  ...richRollup || inputs.enrichedExtras || inputs.artifactSignals ? { schemaVersion: RICH_ROLLUP_SCHEMA_VERSION } : {},
6751
6751
  ...inputs.rollup ? { dailyRollup: inputs.rollup } : {},
6752
6752
  ...richRollup ? { richRollup } : {},
@@ -15660,14 +15660,14 @@ async function getUpdateAvailability() {
15660
15660
  if (isDevMode()) return null;
15661
15661
  const latest = await fetchLatestVersion();
15662
15662
  if (latest === null) return {
15663
- current: "0.15.0",
15663
+ current: "0.15.2",
15664
15664
  latest: null,
15665
15665
  updateAvailable: false
15666
15666
  };
15667
15667
  return {
15668
- current: "0.15.0",
15668
+ current: "0.15.2",
15669
15669
  latest,
15670
- updateAvailable: shouldUpdate("0.15.0", latest)
15670
+ updateAvailable: shouldUpdate("0.15.2", latest)
15671
15671
  };
15672
15672
  }
15673
15673
 
package/dist/index.js CHANGED
@@ -11,6 +11,7 @@ var __export = (target, all) => {
11
11
 
12
12
  // src/pid.ts
13
13
  import { readFileSync, writeFileSync, mkdirSync, unlinkSync } from "node:fs";
14
+ import { execFileSync } from "node:child_process";
14
15
  import { dirname } from "node:path";
15
16
  function writePid(filePath, pid, port, version) {
16
17
  mkdirSync(dirname(filePath), { recursive: true });
@@ -37,18 +38,26 @@ function readPid(filePath) {
37
38
  return null;
38
39
  }
39
40
  }
40
- function isProcessAlive(pid) {
41
+ function isProcessAlive(pid, markers) {
41
42
  try {
42
43
  process.kill(pid, 0);
43
- return true;
44
+ } catch {
45
+ return false;
46
+ }
47
+ if (!markers || markers.length === 0) return true;
48
+ try {
49
+ const cmd = execFileSync("ps", ["-p", String(pid), "-o", "command="], {
50
+ encoding: "utf8"
51
+ }).trim();
52
+ return markers.some((m) => cmd.includes(m));
44
53
  } catch {
45
54
  return false;
46
55
  }
47
56
  }
48
- function cleanStalePid(filePath) {
57
+ function cleanStalePid(filePath, markers) {
49
58
  const entry = readPid(filePath);
50
59
  if (entry === null) return false;
51
- if (isProcessAlive(entry.pid)) return false;
60
+ if (isProcessAlive(entry.pid, markers)) return false;
52
61
  try {
53
62
  unlinkSync(filePath);
54
63
  } catch {
@@ -4681,15 +4690,15 @@ function appDir() {
4681
4690
  return join2(here, "..", "app", "apps", "web");
4682
4691
  }
4683
4692
  function getServerStatus() {
4684
- cleanStalePid(PID_FILE);
4693
+ cleanStalePid(PID_FILE, SERVER_MARKERS);
4685
4694
  const entry = readPid(PID_FILE);
4686
- if (entry !== null && isProcessAlive(entry.pid)) {
4695
+ if (entry !== null && isProcessAlive(entry.pid, SERVER_MARKERS)) {
4687
4696
  return { running: true, pid: entry.pid, port: entry.port ?? DEFAULT_PORT, version: entry.version };
4688
4697
  }
4689
4698
  return { running: false };
4690
4699
  }
4691
4700
  function isServerStale(status2) {
4692
- return status2.running === true && status2.version !== "0.15.0";
4701
+ return status2.running === true && status2.version !== "0.15.2";
4693
4702
  }
4694
4703
  async function ensureCurrentServer(opts = {}) {
4695
4704
  const status2 = getServerStatus();
@@ -4716,7 +4725,7 @@ async function ensureCurrentServer(opts = {}) {
4716
4725
  const result = await startServer({ port });
4717
4726
  return { ...result, restarted: true, previousVersion };
4718
4727
  } catch (err) {
4719
- if (isProcessAlive(oldPid)) writePid(PID_FILE, oldPid, port, previousVersion);
4728
+ if (isProcessAlive(oldPid, SERVER_MARKERS)) writePid(PID_FILE, oldPid, port, previousVersion);
4720
4729
  throw err;
4721
4730
  }
4722
4731
  }
@@ -4745,12 +4754,12 @@ async function startServer(opts = {}) {
4745
4754
  });
4746
4755
  child.unref();
4747
4756
  const pid = child.pid;
4748
- writePid(PID_FILE, pid, port, "0.15.0");
4757
+ writePid(PID_FILE, pid, port, "0.15.2");
4749
4758
  await waitForHealth(`http://localhost:${port}`, 3e4);
4750
4759
  return { pid, port };
4751
4760
  }
4752
4761
  function stopServer() {
4753
- cleanStalePid(PID_FILE);
4762
+ cleanStalePid(PID_FILE, SERVER_MARKERS);
4754
4763
  const entry = readPid(PID_FILE);
4755
4764
  if (entry === null) {
4756
4765
  return { stopped: false };
@@ -4796,7 +4805,7 @@ function openBrowser(url) {
4796
4805
  const cmd = process.platform === "darwin" ? "open" : process.platform === "win32" ? "start" : "xdg-open";
4797
4806
  spawn(cmd, [url], { detached: true, stdio: "ignore" }).unref();
4798
4807
  }
4799
- var PID_FILE, DEFAULT_PORT;
4808
+ var PID_FILE, DEFAULT_PORT, SERVER_MARKERS;
4800
4809
  var init_server = __esm({
4801
4810
  "src/server.ts"() {
4802
4811
  "use strict";
@@ -4804,6 +4813,7 @@ var init_server = __esm({
4804
4813
  init_fs();
4805
4814
  PID_FILE = cclensPath("pid");
4806
4815
  DEFAULT_PORT = 3321;
4816
+ SERVER_MARKERS = ["next-server", "server.js"];
4807
4817
  }
4808
4818
  });
4809
4819
 
@@ -4865,9 +4875,9 @@ import { join as join3, dirname as dirname4 } from "node:path";
4865
4875
  import { fileURLToPath as fileURLToPath2 } from "node:url";
4866
4876
  import { existsSync as existsSync3, statSync, readFileSync as readFileSync4 } from "node:fs";
4867
4877
  function startDaemonSilent() {
4868
- cleanStalePid(DAEMON_PID);
4878
+ cleanStalePid(DAEMON_PID, DAEMON_MARKERS);
4869
4879
  const existing = readPid(DAEMON_PID);
4870
- if (existing !== null && isProcessAlive(existing.pid)) {
4880
+ if (existing !== null && isProcessAlive(existing.pid, DAEMON_MARKERS)) {
4871
4881
  return { started: false, pid: existing.pid, alreadyRunning: true };
4872
4882
  }
4873
4883
  const script = workerPath();
@@ -4889,7 +4899,7 @@ function startDaemonSilent() {
4889
4899
  return { started: true, pid, alreadyRunning: false };
4890
4900
  }
4891
4901
  function stopDaemonSilent() {
4892
- cleanStalePid(DAEMON_PID);
4902
+ cleanStalePid(DAEMON_PID, DAEMON_MARKERS);
4893
4903
  const entry = readPid(DAEMON_PID);
4894
4904
  if (entry === null) return { stopped: false, pid: null };
4895
4905
  try {
@@ -4900,9 +4910,9 @@ function stopDaemonSilent() {
4900
4910
  return { stopped: true, pid: entry.pid };
4901
4911
  }
4902
4912
  function getDaemonStatusInfo() {
4903
- cleanStalePid(DAEMON_PID);
4913
+ cleanStalePid(DAEMON_PID, DAEMON_MARKERS);
4904
4914
  const entry = readPid(DAEMON_PID);
4905
- const running = entry !== null && isProcessAlive(entry.pid);
4915
+ const running = entry !== null && isProcessAlive(entry.pid, DAEMON_MARKERS);
4906
4916
  const latest = latestSnapshot(USAGE_LOG);
4907
4917
  const lastSnapshotAgeMs = latest ? Date.now() - new Date(latest.captured_at).getTime() : null;
4908
4918
  const usageLogSize = existsSync3(USAGE_LOG) ? statSync(USAGE_LOG).size : null;
@@ -4989,7 +4999,7 @@ function daemonLogs() {
4989
4999
  const lines = content.trim().split("\n").slice(-20);
4990
5000
  for (const line of lines) process.stdout.write(line + "\n");
4991
5001
  }
4992
- var DAEMON_PID, USAGE_LOG, DAEMON_LOG;
5002
+ var DAEMON_PID, USAGE_LOG, DAEMON_LOG, DAEMON_MARKERS;
4993
5003
  var init_daemon = __esm({
4994
5004
  "src/commands/daemon.ts"() {
4995
5005
  "use strict";
@@ -4999,6 +5009,7 @@ var init_daemon = __esm({
4999
5009
  DAEMON_PID = cclensPath("daemon.pid");
5000
5010
  USAGE_LOG = cclensPath("usage.jsonl");
5001
5011
  DAEMON_LOG = cclensPath("daemon.log");
5012
+ DAEMON_MARKERS = ["daemon-worker"];
5002
5013
  }
5003
5014
  });
5004
5015
 
@@ -5032,7 +5043,7 @@ async function fetchLatestVersion() {
5032
5043
  }
5033
5044
  function runNpmInstall() {
5034
5045
  try {
5035
- execSync(`npm install -g ${PACKAGE_NAME}@latest`, {
5046
+ execSync(`npm install -g ${PACKAGE_NAME}@latest --prefer-online`, {
5036
5047
  stdio: "pipe",
5037
5048
  timeout: 6e4
5038
5049
  });
@@ -5112,9 +5123,9 @@ Installed: ${PACKAGE_NAME}@${verify.installedVersion} at ${verify.installedPath
5112
5123
  console.warn(
5113
5124
  ` \u2022 reinstall in the correct Node env: 'npm install -g ${PACKAGE_NAME}@latest'`
5114
5125
  );
5115
- } else if (verify.installedVersion !== "0.15.0") {
5126
+ } else if (verify.installedVersion !== "0.15.2") {
5116
5127
  console.log(
5117
- ` \u2192 This process is still running ${"0.15.0"}. Next invocation will use ${verify.installedVersion}.`
5128
+ ` \u2192 This process is still running ${"0.15.2"}. Next invocation will use ${verify.installedVersion}.`
5118
5129
  );
5119
5130
  }
5120
5131
  }
@@ -5149,14 +5160,14 @@ async function getUpdateAvailability() {
5149
5160
  if (isDevMode()) return null;
5150
5161
  const latest = await fetchLatestVersion();
5151
5162
  if (latest === null) return {
5152
- current: "0.15.0",
5163
+ current: "0.15.2",
5153
5164
  latest: null,
5154
5165
  updateAvailable: false
5155
5166
  };
5156
5167
  return {
5157
- current: "0.15.0",
5168
+ current: "0.15.2",
5158
5169
  latest,
5159
- updateAvailable: shouldUpdate("0.15.0", latest)
5170
+ updateAvailable: shouldUpdate("0.15.2", latest)
5160
5171
  };
5161
5172
  }
5162
5173
  async function checkForUpdate() {
@@ -5246,7 +5257,7 @@ async function restartServices(state) {
5246
5257
  }
5247
5258
  async function forceUpdate() {
5248
5259
  const latest = await fetchLatestVersion();
5249
- const current = "0.15.0";
5260
+ const current = "0.15.2";
5250
5261
  if (latest === null) {
5251
5262
  console.error("Could not reach npm registry. Check your network.");
5252
5263
  process.exit(1);
@@ -5294,6 +5305,7 @@ __export(autostart_exports, {
5294
5305
  installAutostart: () => installAutostart,
5295
5306
  isAutostartInstalled: () => isAutostartInstalled,
5296
5307
  isPromptDismissed: () => isPromptDismissed,
5308
+ isStalePlistContent: () => isStalePlistContent,
5297
5309
  maybePromptAutostart: () => maybePromptAutostart,
5298
5310
  recordOptOut: () => recordOptOut
5299
5311
  });
@@ -5312,6 +5324,16 @@ function isMac() {
5312
5324
  function isAutostartInstalled() {
5313
5325
  return isMac() && existsSync5(plistPath());
5314
5326
  }
5327
+ function isStalePlistContent(content) {
5328
+ return content.includes("<string>daemon</string>");
5329
+ }
5330
+ function installedPlistIsStale() {
5331
+ try {
5332
+ return isStalePlistContent(readFileSync6(plistPath(), "utf8"));
5333
+ } catch {
5334
+ return false;
5335
+ }
5336
+ }
5315
5337
  function resolveScriptPath() {
5316
5338
  const argv1 = process.argv[1] ?? "";
5317
5339
  try {
@@ -5392,7 +5414,13 @@ async function uninstallAutostart() {
5392
5414
  async function ensureTeamAutostart() {
5393
5415
  try {
5394
5416
  if (!isMac()) return;
5395
- if (isAutostartInstalled()) return;
5417
+ if (isAutostartInstalled()) {
5418
+ if (installedPlistIsStale()) {
5419
+ console.log(" Updating the Fleetlens login item to launch the full stack (dashboard + daemon).");
5420
+ await installAutostart();
5421
+ }
5422
+ return;
5423
+ }
5396
5424
  if (hasOptedOut()) return;
5397
5425
  console.log(" Team reporting stays on across reboots: enabling Fleetlens auto-start at login (dashboard + daemon).");
5398
5426
  console.log(" (Opt out anytime: fleetlens autostart uninstall \u2014 join won't re-enable it.)");
@@ -5468,7 +5496,13 @@ async function maybePromptAutostart(opts) {
5468
5496
  }
5469
5497
  if (!opts.daemonStarted) return;
5470
5498
  if (!process.stdin.isTTY) return;
5471
- if (isAutostartInstalled()) return;
5499
+ if (isAutostartInstalled()) {
5500
+ if (installedPlistIsStale()) {
5501
+ console.log("Updating the Fleetlens login item to launch the full stack (dashboard + daemon).");
5502
+ await installAutostart();
5503
+ }
5504
+ return;
5505
+ }
5472
5506
  if (isPromptDismissed()) return;
5473
5507
  console.log("");
5474
5508
  console.log("Tip: keep Fleetlens running after you restart your Mac?");
@@ -5636,7 +5670,7 @@ async function status() {
5636
5670
  console.log(`Server: running on ${url} (PID ${server.pid}, v${ver})`);
5637
5671
  if (isServerStale(server)) {
5638
5672
  console.log(
5639
- ` \u26A0 serving stale ${ver} (CLI is ${"0.15.0"}) \u2014 run 'fleetlens start' to restart on the current version`
5673
+ ` \u26A0 serving stale ${ver} (CLI is ${"0.15.2"}) \u2014 run 'fleetlens start' to restart on the current version`
5640
5674
  );
5641
5675
  }
5642
5676
  } else {
@@ -5717,7 +5751,7 @@ var init_update = __esm({
5717
5751
  });
5718
5752
 
5719
5753
  // src/usage/token.ts
5720
- import { execFileSync } from "node:child_process";
5754
+ import { execFileSync as execFileSync2 } from "node:child_process";
5721
5755
  import { readFileSync as readFileSync7 } from "node:fs";
5722
5756
  import { homedir as homedir3, platform } from "node:os";
5723
5757
  import { join as join6 } from "node:path";
@@ -5729,7 +5763,7 @@ function readOAuthCredentials() {
5729
5763
  }
5730
5764
  function readFromMacKeychain() {
5731
5765
  try {
5732
- const blob = execFileSync(
5766
+ const blob = execFileSync2(
5733
5767
  "security",
5734
5768
  ["find-generic-password", "-s", "Claude Code-credentials", "-w"],
5735
5769
  { stdio: ["ignore", "pipe", "ignore"], encoding: "utf8" }
@@ -17159,7 +17193,7 @@ function buildIngestPayload(inputs) {
17159
17193
  return {
17160
17194
  ingestId: randomUUID2(),
17161
17195
  observedAt: (/* @__PURE__ */ new Date()).toISOString(),
17162
- cliVersion: "0.15.0",
17196
+ cliVersion: "0.15.2",
17163
17197
  ...richRollup || inputs.enrichedExtras || inputs.artifactSignals ? { schemaVersion: RICH_ROLLUP_SCHEMA_VERSION } : {},
17164
17198
  ...inputs.rollup ? { dailyRollup: inputs.rollup } : {},
17165
17199
  ...richRollup ? { richRollup } : {},
@@ -17628,7 +17662,7 @@ import { createHash } from "node:crypto";
17628
17662
  import { existsSync as existsSync15, readdirSync as readdirSync4, statSync as statSync6 } from "node:fs";
17629
17663
  import { homedir as homedir5 } from "node:os";
17630
17664
  import { join as join13, relative, resolve as resolve2, sep } from "node:path";
17631
- import { execFileSync as execFileSync2 } from "node:child_process";
17665
+ import { execFileSync as execFileSync3 } from "node:child_process";
17632
17666
  function pathHash(relPath) {
17633
17667
  return createHash("sha256").update(relPath.split(sep).join("/")).digest("hex").slice(0, 32);
17634
17668
  }
@@ -17670,7 +17704,7 @@ function listMarkdownFiles(dir) {
17670
17704
  }
17671
17705
  function firstSeenDateOf(file) {
17672
17706
  try {
17673
- const out = execFileSync2(
17707
+ const out = execFileSync3(
17674
17708
  "git",
17675
17709
  ["log", "--diff-filter=A", "--follow", "--format=%cs", "--", file],
17676
17710
  { encoding: "utf8", stdio: ["ignore", "pipe", "ignore"], cwd: dirname14(file) }
@@ -17691,7 +17725,7 @@ function dirname14(p) {
17691
17725
  }
17692
17726
  function detectGitEmail(cwd) {
17693
17727
  try {
17694
- return execFileSync2("git", ["config", "user.email"], {
17728
+ return execFileSync3("git", ["config", "user.email"], {
17695
17729
  encoding: "utf8",
17696
17730
  stdio: ["ignore", "pipe", "ignore"],
17697
17731
  cwd
@@ -17756,7 +17790,7 @@ function claudemdLineDelta(extraRoots, authorEmail, day2) {
17756
17790
  if (existsSync15(homeClaudeMd)) candidates.push(homeClaudeMd);
17757
17791
  for (const file of candidates) {
17758
17792
  try {
17759
- const out = execFileSync2(
17793
+ const out = execFileSync3(
17760
17794
  "git",
17761
17795
  ["log", "--numstat", "--format=COMMIT %cs %ae", "--", file],
17762
17796
  { encoding: "utf8", stdio: ["ignore", "pipe", "ignore"], cwd: dirname14(file) }
@@ -19179,7 +19213,7 @@ async function main() {
19179
19213
  case "version":
19180
19214
  case "--version":
19181
19215
  case "-v":
19182
- console.log(`fleetlens ${"0.15.0"}`);
19216
+ console.log(`fleetlens ${"0.15.2"}`);
19183
19217
  break;
19184
19218
  case "help":
19185
19219
  case "--help":
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fleetlens",
3
- "version": "0.15.0",
3
+ "version": "0.15.2",
4
4
  "description": "fleetlens — local-only dashboard and usage tracker for Claude Code sessions and agent fleets",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -1 +0,0 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,98183,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0});var a={assign:function(){return l},searchParamsToUrlQuery:function(){return r},urlQueryToSearchParams:function(){return i}};for(var s in a)Object.defineProperty(n,s,{enumerable:!0,get:a[s]});function r(e){let t={};for(let[n,a]of e.entries()){let e=t[n];void 0===e?t[n]=a:Array.isArray(e)?e.push(a):t[n]=[e,a]}return t}function o(e){return"string"==typeof e?e:("number"!=typeof e||isNaN(e))&&"boolean"!=typeof e?"":String(e)}function i(e){let t=new URLSearchParams;for(let[n,a]of Object.entries(e))if(Array.isArray(a))for(let e of a)t.append(n,o(e));else t.set(n,o(a));return t}function l(e,...t){for(let n of t){for(let t of n.keys())e.delete(t);for(let[t,a]of n.entries())e.append(t,a)}return e}},18967,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0});var a={DecodeError:function(){return y},MiddlewareNotFoundError:function(){return k},MissingStaticPage:function(){return v},NormalizeError:function(){return w},PageNotFoundError:function(){return b},SP:function(){return m},ST:function(){return f},WEB_VITALS:function(){return r},execOnce:function(){return o},getDisplayName:function(){return u},getLocationOrigin:function(){return d},getURL:function(){return c},isAbsoluteUrl:function(){return l},isResSent:function(){return h},loadGetInitialProps:function(){return g},normalizeRepeatedSlashes:function(){return p},stringifyError:function(){return x}};for(var s in a)Object.defineProperty(n,s,{enumerable:!0,get:a[s]});let r=["CLS","FCP","FID","INP","LCP","TTFB"];function o(e){let t,n=!1;return(...a)=>(n||(n=!0,t=e(...a)),t)}let i=/^[a-zA-Z][a-zA-Z\d+\-.]*?:/,l=e=>i.test(e);function d(){let{protocol:e,hostname:t,port:n}=window.location;return`${e}//${t}${n?":"+n:""}`}function c(){let{href:e}=window.location,t=d();return e.substring(t.length)}function u(e){return"string"==typeof e?e:e.displayName||e.name||"Unknown"}function h(e){return e.finished||e.headersSent}function p(e){let t=e.split("?");return t[0].replace(/\\/g,"/").replace(/\/\/+/g,"/")+(t[1]?`?${t.slice(1).join("?")}`:"")}async function g(e,t){let n=t.res||t.ctx&&t.ctx.res;if(!e.getInitialProps)return t.ctx&&t.Component?{pageProps:await g(t.Component,t.ctx)}:{};let a=await e.getInitialProps(t);if(n&&h(n))return a;if(!a)throw Object.defineProperty(Error(`"${u(e)}.getInitialProps()" should resolve to an object. But found "${a}" instead.`),"__NEXT_ERROR_CODE",{value:"E1025",enumerable:!1,configurable:!0});return a}let m="u">typeof performance,f=m&&["mark","measure","getEntriesByName"].every(e=>"function"==typeof performance[e]);class y extends Error{}class w extends Error{}class b extends Error{constructor(e){super(),this.code="ENOENT",this.name="PageNotFoundError",this.message=`Cannot find module for page: ${e}`}}class v extends Error{constructor(e,t){super(),this.message=`Failed to load static file for page: ${e} ${t}`}}class k extends Error{constructor(){super(),this.code="ENOENT",this.message="Cannot find the middleware module"}}function x(e){return JSON.stringify({message:e.message,stack:e.stack})}},33525,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"warnOnce",{enumerable:!0,get:function(){return a}});let a=e=>{}},56324,e=>{"use strict";let t=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],n={input:1,output:5,cacheRead:.1,cacheWrite:1.25},a={input:3,output:15,cacheRead:.3,cacheWrite:3.75},s={input:5,output:25,cacheRead:.5,cacheWrite:6.25};e.s(["estimateCost",0,function(e,t){let r=function(e){if(!e)return s;let t=e.toLowerCase();return t.includes("haiku")?n:t.includes("sonnet")?a:s}(t);return e.input/1e6*r.input+e.output/1e6*r.output+e.cacheRead/1e6*r.cacheRead+e.cacheWrite/1e6*r.cacheWrite},"formatCost",0,function(e){return e<.01?"<$0.01":e<1||e<100?`$${e.toFixed(2)}`:e<1e3?`$${e.toFixed(1)}`:`$${e.toLocaleString(void 0,{maximumFractionDigits:0})}`},"formatDuration",0,function(e){if(void 0===e)return"—";if(e<1e3)return`${e}ms`;let t=Math.round(e/1e3);if(t<60)return`${t}s`;let n=Math.floor(t/60),a=t%60;if(n<60)return a?`${n}m ${a}s`:`${n}m`;let s=Math.floor(n/60),r=n%60;return r?`${s}h ${r}m`:`${s}h`},"formatGap",0,function(e){if(e<1e3)return`${e}ms`;let t=e/1e3;if(t<60)return`${t.toFixed(1)}s`;let n=Math.floor(t/60);if(n<60){let e=Math.round(t%60);return`${n}m ${e}s`}let a=Math.floor(n/60),s=n%60;if(a<24)return s?`${a}h ${s}m`:`${a}h`;let r=Math.floor(a/24),o=a%24;return o?`${r}d ${o}h`:`${r}d`},"formatOffset",0,function(e){if(void 0===e||e<0)return"—";let t=Math.floor(e/1e3),n=Math.floor(t/3600),a=String(Math.floor(t%3600/60)).padStart(2,"0"),s=String(t%60).padStart(2,"0");return`${n}:${a}:${s}`},"formatRelative",0,function(e){let t=Date.parse(e);if(Number.isNaN(t))return e;let n=Math.round((Date.now()-t)/1e3);if(n<60)return`${n}s ago`;let a=Math.round(n/60);if(a<60)return`${a}m ago`;let s=Math.round(a/60);if(s<24)return`${s}h ago`;let r=Math.round(s/24);return`${r}d ago`},"formatResumeStamp",0,function(e){let n=new Date(e);if(Number.isNaN(n.getTime()))return"";let a=n.getHours()>=12?"PM":"AM",s=n.getHours()%12||12,r=String(n.getMinutes()).padStart(2,"0");return`${t[n.getMonth()]} ${n.getDate()}, ${s}:${r} ${a}`},"formatTokens",0,function(e){return e<1e3?String(e):e<1e4?(e/1e3).toFixed(1)+"k":e<1e6?Math.round(e/1e3)+"k":e<1e7?(e/1e6).toFixed(2)+"M":(e/1e6).toFixed(1)+"M"},"prettyProjectName",0,function(e,t=35){let n=e.split("/").filter(Boolean),a=n.lastIndexOf(".worktrees");if(a>0&&a<n.length-1){let e=n[a-1],s=n[a+1],r=`${e}/${s}`;return r.length<=t?r:"…"+r.slice(r.length-t+1)}let s=n.length>=2?`${n[n.length-2]}/${n[n.length-1]}`:n[n.length-1]??e;return s.length<=t?s:"…"+s.slice(s.length-t+1)},"shortId",0,function(e){return e.length<=10?e:e.slice(0,6)+"…"+e.slice(-4)}])},18566,(e,t,n)=>{t.exports=e.r(76562)},95057,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0});var a={formatUrl:function(){return i},formatWithValidation:function(){return d},urlObjectKeys:function(){return l}};for(var s in a)Object.defineProperty(n,s,{enumerable:!0,get:a[s]});let r=e.r(90809)._(e.r(98183)),o=/https?|ftp|gopher|file/;function i(e){let{auth:t,hostname:n}=e,a=e.protocol||"",s=e.pathname||"",i=e.hash||"",l=e.query||"",d=!1;t=t?encodeURIComponent(t).replace(/%3A/i,":")+"@":"",e.host?d=t+e.host:n&&(d=t+(~n.indexOf(":")?`[${n}]`:n),e.port&&(d+=":"+e.port)),l&&"object"==typeof l&&(l=String(r.urlQueryToSearchParams(l)));let c=e.search||l&&`?${l}`||"";return a&&!a.endsWith(":")&&(a+=":"),e.slashes||(!a||o.test(a))&&!1!==d?(d="//"+(d||""),s&&"/"!==s[0]&&(s="/"+s)):d||(d=""),i&&"#"!==i[0]&&(i="#"+i),c&&"?"!==c[0]&&(c="?"+c),s=s.replace(/[?#]/g,encodeURIComponent),c=c.replace("#","%23"),`${a}${d}${s}${c}${i}`}let l=["auth","hash","host","hostname","href","path","pathname","port","protocol","query","search","slashes"];function d(e){return i(e)}},18581,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"useMergedRef",{enumerable:!0,get:function(){return s}});let a=e.r(71645);function s(e,t){let n=(0,a.useRef)(null),s=(0,a.useRef)(null);return(0,a.useCallback)(a=>{if(null===a){let e=n.current;e&&(n.current=null,e());let t=s.current;t&&(s.current=null,t())}else e&&(n.current=r(e,a)),t&&(s.current=r(t,a))},[e,t])}function r(e,t){if("function"!=typeof e)return e.current=t,()=>{e.current=null};{let n=e(t);return"function"==typeof n?n:()=>e(null)}}("function"==typeof n.default||"object"==typeof n.default&&null!==n.default)&&void 0===n.default.__esModule&&(Object.defineProperty(n.default,"__esModule",{value:!0}),Object.assign(n.default,n),t.exports=n.default)},73668,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"isLocalURL",{enumerable:!0,get:function(){return r}});let a=e.r(18967),s=e.r(52817);function r(e){if(!(0,a.isAbsoluteUrl)(e))return!0;try{let t=(0,a.getLocationOrigin)(),n=new URL(e,t);return n.origin===t&&(0,s.hasBasePath)(n.pathname)}catch(e){return!1}}},84508,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"errorOnce",{enumerable:!0,get:function(){return a}});let a=e=>{}},22016,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0});var a={default:function(){return y},useLinkStatus:function(){return b}};for(var s in a)Object.defineProperty(n,s,{enumerable:!0,get:a[s]});let r=e.r(90809),o=e.r(18050),i=r._(e.r(71645)),l=e.r(95057),d=e.r(8372),c=e.r(18581),u=e.r(18967),h=e.r(5550);e.r(33525);let p=e.r(88540),g=e.r(91949),m=e.r(73668),f=e.r(9396);function y(t){var n,a;let s,r,y,[b,v]=(0,i.useOptimistic)(g.IDLE_LINK_STATUS),k=(0,i.useRef)(null),{href:x,as:C,children:S,prefetch:T=null,passHref:j,replace:A,shallow:L,scroll:P,onClick:E,onMouseEnter:N,onTouchStart:O,legacyBehavior:M=!1,onNavigate:R,transitionTypes:$,ref:I,unstable_dynamicOnHover:_,...F}=t;s=S,M&&("string"==typeof s||"number"==typeof s)&&(s=(0,o.jsx)("a",{children:s}));let D=i.default.useContext(d.AppRouterContext),z=!1!==T,U=!1!==T?null===(a=T)||"auto"===a?f.FetchStrategy.PPR:f.FetchStrategy.Full:f.FetchStrategy.PPR,W="string"==typeof(n=C||x)?n:(0,l.formatUrl)(n);if(M){if(s?.$$typeof===Symbol.for("react.lazy"))throw Object.defineProperty(Error("`<Link legacyBehavior>` received a direct child that is either a Server Component, or JSX that was loaded with React.lazy(). This is not supported. Either remove legacyBehavior, or make the direct child a Client Component that renders the Link's `<a>` tag."),"__NEXT_ERROR_CODE",{value:"E863",enumerable:!1,configurable:!0});r=i.default.Children.only(s)}let B=M?r&&"object"==typeof r&&r.ref:I,q=i.default.useCallback(e=>(null!==D&&(k.current=(0,g.mountLinkInstance)(e,W,D,U,z,v)),()=>{k.current&&((0,g.unmountLinkForCurrentNavigation)(k.current),k.current=null),(0,g.unmountPrefetchableInstance)(e)}),[z,W,D,U,v]),G={ref:(0,c.useMergedRef)(q,B),onClick(t){M||"function"!=typeof E||E(t),M&&r.props&&"function"==typeof r.props.onClick&&r.props.onClick(t),!D||t.defaultPrevented||function(t,n,a,s,r,o,l){if("u">typeof window){let d,{nodeName:c}=t.currentTarget;if("A"===c.toUpperCase()&&((d=t.currentTarget.getAttribute("target"))&&"_self"!==d||t.metaKey||t.ctrlKey||t.shiftKey||t.altKey||t.nativeEvent&&2===t.nativeEvent.which)||t.currentTarget.hasAttribute("download"))return;if(!(0,m.isLocalURL)(n)){s&&(t.preventDefault(),location.replace(n));return}if(t.preventDefault(),o){let e=!1;if(o({preventDefault:()=>{e=!0}}),e)return}let{dispatchNavigateAction:u}=e.r(99781);i.default.startTransition(()=>{u(n,s?"replace":"push",!1===r?p.ScrollBehavior.NoScroll:p.ScrollBehavior.Default,a.current,l)})}}(t,W,k,A,P,R,$)},onMouseEnter(e){M||"function"!=typeof N||N(e),M&&r.props&&"function"==typeof r.props.onMouseEnter&&r.props.onMouseEnter(e),D&&z&&(0,g.onNavigationIntent)(e.currentTarget,!0===_)},onTouchStart:function(e){M||"function"!=typeof O||O(e),M&&r.props&&"function"==typeof r.props.onTouchStart&&r.props.onTouchStart(e),D&&z&&(0,g.onNavigationIntent)(e.currentTarget,!0===_)}};return(0,u.isAbsoluteUrl)(W)?G.href=W:M&&!j&&("a"!==r.type||"href"in r.props)||(G.href=(0,h.addBasePath)(W)),y=M?i.default.cloneElement(r,G):(0,o.jsx)("a",{...F,...G,children:s}),(0,o.jsx)(w.Provider,{value:b,children:y})}e.r(84508);let w=(0,i.createContext)(g.IDLE_LINK_STATUS),b=()=>(0,i.useContext)(w);("function"==typeof n.default||"object"==typeof n.default&&null!==n.default)&&void 0===n.default.__esModule&&(Object.defineProperty(n.default,"__esModule",{value:!0}),Object.assign(n.default,n),t.exports=n.default)},75254,e=>{"use strict";var t=e.i(71645);let n=(...e)=>e.filter((e,t,n)=>!!e&&""!==e.trim()&&n.indexOf(e)===t).join(" ").trim();var a={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};let s=(0,t.forwardRef)(({color:e="currentColor",size:s=24,strokeWidth:r=2,absoluteStrokeWidth:o,className:i="",children:l,iconNode:d,...c},u)=>(0,t.createElement)("svg",{ref:u,...a,width:s,height:s,stroke:e,strokeWidth:o?24*Number(r)/Number(s):r,className:n("lucide",i),...c},[...d.map(([e,n])=>(0,t.createElement)(e,n)),...Array.isArray(l)?l:[l]]));e.s(["default",0,(e,a)=>{let r=(0,t.forwardRef)(({className:r,...o},i)=>(0,t.createElement)(s,{ref:i,iconNode:a,className:n(`lucide-${e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,r),...o}));return r.displayName=`${e}`,r}],75254)},74472,33815,e=>{"use strict";let t=[{kind:"claude-code",displayName:"Claude Code",shortLabel:"Claude",accentColor:"var(--af-accent)",iconChar:"✦"},{kind:"codex",displayName:"Codex (OpenAI)",shortLabel:"Codex",accentColor:"rgb(16, 163, 127)",iconChar:"◆"},{kind:"gemini",displayName:"Gemini CLI",shortLabel:"Gemini",accentColor:"rgb(124, 92, 246)",iconChar:"✺"},{kind:"antigravity",displayName:"Antigravity",shortLabel:"Agy",accentColor:"rgb(236, 72, 153)",iconChar:"⏃"},{kind:"cowork",displayName:"Cowork",shortLabel:"Cowork",accentColor:"rgb(217, 119, 87)",iconChar:"⌘"}],n=new Set(t.map(e=>e.kind));e.s(["getAgentMetadata",0,function(e){return t.find(t=>t.kind===e)},"isAgentKind",0,function(e){return"string"==typeof e&&n.has(e)}],33815),e.s([],74472)},23614,41783,e=>{"use strict";var t=e.i(18050),n=e.i(22016);e.i(74472);var a=e.i(33815);function s({agent:e,size:n=11,title:r}){if(!e)return null;let o=(0,a.getAgentMetadata)(e);return o?(0,t.jsx)("span",{"aria-hidden":!0,title:r??o.displayName,style:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0,width:n+2,height:n+2,fontSize:n,lineHeight:1,color:o.accentColor},children:o.iconChar}):null}e.s(["AgentIcon",0,s],41783);let r={shipped:{bg:"rgba(72, 187, 120, 0.12)",fg:"#48bb78",label:"Shipped",icon:"🚀"},partial:{bg:"rgba(66, 153, 225, 0.12)",fg:"#4299e1",label:"Partial",icon:"🔨"},blocked:{bg:"rgba(245, 101, 101, 0.12)",fg:"#f56565",label:"Blocked",icon:"🚧"},exploratory:{bg:"rgba(160, 174, 192, 0.12)",fg:"#a0aec0",label:"Exploratory",icon:"🧭"},trivial:{bg:"rgba(203, 213, 224, 0.12)",fg:"#a0aec0",label:"Warmup",icon:"💤"},idle:{bg:"rgba(203, 213, 224, 0.12)",fg:"#a0aec0",label:"Idle",icon:"—"}},o={sm:{fontSize:9,padding:"1px 6px",iconGap:3,borderRadius:99},md:{fontSize:10,padding:"2px 8px",iconGap:4,borderRadius:99},lg:{fontSize:11,padding:"3px 10px",iconGap:5,borderRadius:99}},i={shipped:6,partial:5,blocked:4,exploratory:3,trivial:2,idle:1};e.s(["OUTCOME_STYLES",0,r,"OutcomePill",0,function(e){let a=o[e.size??"md"],i=a.fontSize+1;if("pending"in e&&e.pending){let r={display:"inline-flex",alignItems:"center",gap:a.iconGap,padding:a.padding,borderRadius:a.borderRadius,fontSize:a.fontSize,fontWeight:600,background:"rgba(160, 174, 192, 0.08)",color:"var(--af-text-tertiary)",border:"1px dashed var(--af-border-subtle)",textDecoration:"none",whiteSpace:"nowrap"},o=(0,t.jsxs)(t.Fragment,{children:[e.agent&&(0,t.jsx)(s,{agent:e.agent,size:i}),(0,t.jsx)("span",{"aria-hidden":!0,style:{lineHeight:1},children:"⋯"}),(0,t.jsx)("span",{children:"pending"})]});return e.noLink?(0,t.jsx)("span",{style:r,children:o}):(0,t.jsx)(n.default,{href:`/digest/${e.localDay}`,style:r,title:`Generate ${e.localDay} digest →`,children:o})}let l=r[e.outcome],d=e.label??"both",c={display:"inline-flex",alignItems:"center",gap:a.iconGap,padding:a.padding,borderRadius:a.borderRadius,fontSize:a.fontSize,fontWeight:600,background:l.bg,color:l.fg,whiteSpace:"nowrap"};return(0,t.jsxs)("span",{style:c,title:l.label,children:[e.agent&&(0,t.jsx)(s,{agent:e.agent,size:i}),("icon"===d||"both"===d)&&(0,t.jsx)("span",{"aria-hidden":!0,style:{lineHeight:1},children:l.icon}),("text"===d||"both"===d)&&(0,t.jsx)("span",{children:l.label})]})},"outcomePriority",0,function(e){return e?i[e]:0}],23614)},69198,e=>{"use strict";var t=e.i(18050);e.i(74472);var n=e.i(33815);e.s(["AgentBadge",0,function({agent:e}){if(!e||"claude-code"===e)return null;let a=(0,n.getAgentMetadata)(e);return a?(0,t.jsx)("span",{style:{display:"inline-flex",alignItems:"center",borderRadius:4,padding:"2px 6px",fontSize:10,letterSpacing:"0.04em",textTransform:"uppercase",whiteSpace:"nowrap",fontWeight:600,color:a.accentColor,background:`color-mix(in srgb, ${a.accentColor} 12%, transparent)`,border:`1px solid color-mix(in srgb, ${a.accentColor} 30%, transparent)`},title:`Source: ${a.displayName}`,children:a.shortLabel}):null}])},43531,e=>{"use strict";let t=(0,e.i(75254).default)("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);e.s(["Check",0,t],43531)},86619,e=>{"use strict";var t=e.i(71645);e.s(["usePersistentBoolean",0,function(e,n){let[a,s]=(0,t.useState)(n),[r,o]=(0,t.useState)(!1);return(0,t.useEffect)(()=>{try{let t=window.localStorage.getItem(e);"1"===t?s(!0):"0"===t&&s(!1)}catch{}o(!0)},[e]),(0,t.useEffect)(()=>{let t=t=>{let n=t.detail;n?.key===e&&"boolean"==typeof n.value&&s(n.value)},n=t=>{t.key===e&&("1"===t.newValue?s(!0):"0"===t.newValue&&s(!1))};return window.addEventListener("cclens:persistent-boolean",t),window.addEventListener("storage",n),()=>{window.removeEventListener("cclens:persistent-boolean",t),window.removeEventListener("storage",n)}},[e]),[a,(0,t.useCallback)(t=>{s(t);try{window.localStorage.setItem(e,t?"1":"0")}catch{}window.dispatchEvent(new CustomEvent("cclens:persistent-boolean",{detail:{key:e,value:t}}))},[e]),r]}])},88137,e=>{"use strict";function t(e){return e<-15?{tone:"danger",label:"may exhaust early"}:e>15?{tone:"warning",label:"below pace"}:{tone:"success",label:"on pace"}}e.s(["paceLabel",0,t,"paceToneForCycle",0,function(e,n,a,s=Date.now()){return t(100*Math.max(0,Math.min(1,(s-(n-a))/a))-e).tone},"toneVar",0,function(e){switch(e){case"success":return"var(--af-success)";case"warning":return"#b58400";case"danger":return"var(--af-danger)"}}])},55436,e=>{"use strict";let t=(0,e.i(75254).default)("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]);e.s(["Search",0,t],55436)},56004,e=>{"use strict";var t=e.i(18050),n=e.i(22016);let a={display:"inline-flex",alignItems:"center",borderRadius:4,padding:"2px 6px",fontSize:10,letterSpacing:"0.04em",textTransform:"uppercase",whiteSpace:"nowrap"};e.s(["TeamBadge",0,function({session:e,linkable:s=!0}){if(!e.teamName)return null;let r=!0===e.isTeamLead,o=void 0!==e.agentName;return r||o?r&&s?(0,t.jsx)(n.default,{href:`/sessions/${e.id}`,style:{...a,fontWeight:600,background:"var(--af-warning-subtle)",color:"var(--af-warning)",border:"1px solid var(--af-warning-subtle)",textDecoration:"none"},title:`Team lead — ${e.teamName}`,children:"Team Lead"}):r?(0,t.jsx)("span",{style:{...a,fontWeight:600,background:"var(--af-warning-subtle)",color:"var(--af-warning)",border:"1px solid var(--af-warning-subtle)"},title:`Team lead — ${e.teamName}`,children:"Team Lead"}):(0,t.jsx)("span",{style:{...a,fontWeight:500,background:"var(--af-surface-hover)",color:"var(--af-text-tertiary)",border:"1px solid var(--af-border-subtle)"},title:`Team member — ${e.teamName} \xb7 ${e.agentName}`,children:"Team Member"}):null}])},3116,e=>{"use strict";let t=(0,e.i(75254).default)("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);e.s(["Clock",0,t],3116)},41240,63639,e=>{"use strict";var t=e.i(75254);let n=(0,t.default)("Lightbulb",[["path",{d:"M15 14c.2-1 .7-1.7 1.5-2.5 1-.9 1.5-2.2 1.5-3.5A6 6 0 0 0 6 8c0 1 .2 2.2 1.5 3.5.7.7 1.3 1.5 1.5 2.5",key:"1gvzjb"}],["path",{d:"M9 18h6",key:"x1upvd"}],["path",{d:"M10 22h4",key:"ceow96"}]]);e.s(["Lightbulb",0,n],41240);let a=(0,t.default)("Radio",[["path",{d:"M4.9 19.1C1 15.2 1 8.8 4.9 4.9",key:"1vaf9d"}],["path",{d:"M7.8 16.2c-2.3-2.3-2.3-6.1 0-8.5",key:"u1ii0m"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}],["path",{d:"M16.2 7.8c2.3 2.3 2.3 6.1 0 8.5",key:"1j5fej"}],["path",{d:"M19.1 4.9C23 8.8 23 15.1 19.1 19",key:"10b0cb"}]]);e.s(["Radio",0,a],63639)},31278,e=>{"use strict";let t=(0,e.i(75254).default)("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);e.s(["Loader2",0,t],31278)},54611,e=>{"use strict";let t=/^##\s+\[([^\]]+)\](?:\s+[—\-–]\s+(\S+))?\s*$/,n=/^###\s+(.+?)\s*$/,a=/^[-*]\s+(.+?)\s*$/,s=function(e){let s=e.split(/\r?\n/),r=[],o=null,i=null,l=[];function d(){i&&l.length>0&&(i.bullets.push(l.join(" ").trim()),l=[])}for(let e of s){let s=t.exec(e);if(s){d(),i=null,o={version:s[1].trim(),date:s[2]?.trim()??null,sections:[]},r.push(o);continue}if(!o)continue;let c=n.exec(e);if(c){d(),i={kind:c[1].trim(),bullets:[]},o.sections.push(i);continue}let u=a.exec(e);if(u){d(),l=[u[1]];continue}l.length>0&&e.trim().length>0&&l.push(e.trim())}return d(),r}("# Changelog\n\nAll notable user-facing changes to the Fleetlens CLI (`fleetlens` on npm) are\nrecorded here. Format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).\nThe team-server has its own log at `packages/team-server/CHANGELOG.md`.\n\n## [0.15.0] — 2026-07-08\n\nTeam onboarding, rebuilt around a browser wizard — pairing now explains what leaves the machine, lets you pick which projects sync, and streams first-sync progress live. The Team page becomes the single home for sync management, and paired machines keep reporting across reboots. Safe upgrade from 0.14.x; pairs best with team-server 0.15.0.\n\n### Added\n- `fleetlens team join` now opens a browser onboarding wizard: explains exactly what data leaves the machine, lets you choose which projects sync to the team, and streams first-sync progress as a timestamped log. `--no-browser` keeps the old terminal-only behavior.\n- The Team page is the single home for team-sync management: pairing status, sync activity (last push details + raw payload + Sync now), and the synced-projects editor. Changing the selection re-pushes your **full history** under the new filter and streams a live log: excluded projects disappear from the team server (days left with no synced activity are overwritten with empty rollups), newly included ones backfill.\n- Settings gains a **Daemon auto-start** toggle showing the real LaunchAgent state — on after team pairing, with a durable opt-out.\n- `fleetlens team sync --progress-json` — machine-readable NDJSON progress events.\n- `team join` captures a first plan-usage snapshot before opening the wizard, so the first sync ships usage data even when the daemon's first poll loses a 429 race.\n- The synced-projects editor defaults to a read-only summary — \"Syncing N of M projects\" with chips linking to each project's dashboard page — and the full picker sits behind an Edit button. The server URL on the Team page opens the team dashboard in a new tab.\n\n### Changed\n- Team sync pushes days **newest-first**, so a long first sync fills the team dashboard with the freshest data immediately.\n- The project picker orders by **agent time** (busiest first), and the Team/Settings/wizard surfaces adopt the dashboard's design system — warm cards, teal-accent buttons, theme-aware borders (no more harsh black outlines from Tailwind v4's currentColor default).\n- Auto-start is **opt-out for team members** (macOS): `team join` and `fleetlens start` install the login LaunchAgent automatically on paired machines. The agent now launches the **full stack** (`fleetlens start`: dashboard + daemon), so both reporting and the dashboard survive reboots. `fleetlens autostart uninstall` records a durable opt-out that join/start never override.\n\n## [0.14.0] — 2026-07-08\n\nTeam-sync overhauled around one idea: a fresh pairing syncs **everything**, and every run leaves a story you can read. Safe upgrade from 0.13.x; pairs best with team-server 0.14.0.\n\n### Added\n- **One rich `[sync]` line per run** in the daemon log: `status · trigger(auto|boot|pair|manual) · pushed N days (range) · usage +N · server accepted <blocks> · duration · next ~Nm` — including the server's own accepted/skipped verdict, so the log shows both what was sent and what the server did with it. Uploaded per-member to the Team Edition.\n- **Pair backfill is complete and deterministic.** `team join` now pushes rich rollups (projects, skills, sub-agents, working shapes) for the whole backfilled history — perception entries are built on the spot at push time, no LLM required. Historical 7d cycle peaks now cover up to 26 cycles (was 12).\n- **Dropped-day self-heal**: a day rejected by an older server is remembered and retried once per sync until accepted (`recovered N dropped days`), instead of being lost.\n\n### Fixed\n- Re-pairing a machine to a different team no longer uploads the previous team's sync-log history.\n- The sync-log watermark only advances when the server actually accepted the log batch; oversized lines are truncated instead of poisoning the batch; long backlogs drain oldest-first so an outage's onset is never lost.\n- Manual `fleetlens team sync` runs now appear in the member's sync story (tagged `manual`).\n- Perception sweep no longer re-parses entry-less transcripts every 5 minutes; a transient transcript read failure no longer blocks a session's entries until daemon restart.\n\n## [0.13.2] — 2026-06-29\n\nTimeline and session-view polish, plus the second half of the session-view modularization. Mostly day-scope refinements — jumping into a session now lands on the right day, and the minimap and idle dividers read far more cleanly on long multi-day runs. Safe upgrade from 0.13.1.\n\n### Added\n- **Click a session, land on the day you were looking at.** Opening a session from the Day view or a Concurrency gantt now pins it to *that* day instead of the session's most-recent day — and actually scrolls the transcript there. Previously the day selector moved but the transcript stayed at the very top, a latent bug that also affected the plain last-day jump. Days that are entirely background-agent work — which live in the Workflows tab, not the transcript — fall back to the nearest rendered content instead of getting stuck at the top.\n- **Idle gaps that cross a day now show when work resumed.** A \"Session idle · 1d\" divider told you how long but not when; for a gap that picks back up on a later day it now reads \"Session resumed Jun 18, 11:02 AM\". Sub-day gaps keep their duration, since the pause length is the useful signal there.\n\n### Fixed\n- **The minimap no longer shreds a long run into idle slivers.** A collapsed turn now owns its internal idle (model thinking, long tool calls, a workflow it's waiting on) instead of fragmenting into a stutter of hatched bars; consecutive idle bands fuse into one; the gap between two days no longer leaks across the day-window edge as a giant block; and a day no longer opens on the overnight gap leading into it (which could be 60–70% of the whole bar) — the day's actual activity now fills the timeline.\n- **Cleaner day boundaries.** When a resume divider already names the new day, the redundant \"Start of \\<day\\>\" jump marker below it is dropped — the boundary is just the resume band plus an \"End of \\<prev day\\>\" back-nav, instead of three stacked elements restating the same date.\n- **Two workflow-panel bugs.** WorkflowPhaseTabs now reactively falls back to the first phase with agents until you pick one (and resets per run); WorkflowAgentDrawer paints synchronously from its detail cache on reopen, and a failed revalidation no longer blanks an already-shown detail.\n\n### Changed\n- **Internal: session-view.tsx modularization, part two.** The session-scoped Minimap (~1,580 LOC) and the WorkflowsPanel cluster (~940 LOC) were extracted into colocated `session-view/` modules. Pure code moves — `tsc --noEmit` clean throughout. Plus small review-surfaced cleanups: three dead imports removed, the gantt day-param simplified to the already-canonical date string, and a tail-mode effect dependency corrected.\n\n## [0.13.1] — 2026-06-26\n\nA quality-and-correctness release rolled up from a full code audit, plus the timeline scroll-follow polish from PR #73. No new surface — every change either fixes a bug, removes dead weight, or makes the codebase easier to work in. Safe upgrade from 0.13.0.\n\n### Fixed\n- **Day-scoped timeline now actually follows scroll across days, without flicker.** The minimap's selected day used to revert to the previous day when you scrolled into a new one on a long session, because the day-jump's `scrollIntoView` undershot tall preceding turn-blocks and the scroll-spy then read that block's offset as \"still on the old day.\" The follower now reads from the same playhead signal the minimap already uses, the day-jump self-corrects against the live header height across a few frames so the next day's strip lands exactly at the header line, and live sessions skip the mount day-jump entirely so tail-follow can land on the latest tail without being yanked back. Live-follow scrolls are now instant (not smooth) so they don't self-cancel mid-animation. (PR #73)\n- **Inline cross-day jump shortcuts.** New \"↓ Start of \\<day\\>\" and \"↑ End of \\<day\\>\" buttons sit at each day boundary in the transcript, so reading across a long idle gap is one click — not a hand-scroll across thousands of pixels. (PR #73)\n- **Searchable project filter on the sessions list.** The `<select>` project picker is replaced with a filterable combobox: type to filter, arrow keys + Enter/Escape to navigate, Tab to close. Painful with dozens of project folders before; now a few keystrokes. (PR #73)\n- **Six correctness bugs surfaced by a full audit:**\n - `INSTRUCTION_RE` in `extractUserInstructions` leaked `lastIndex` across calls. Once a turn hit the 5-cap break, later entries got truncated or empty `user_instructions` until the module re-loaded. Fixed; regression test added.\n - Linear/Jira ticket-ref matching was anchored only at the end of the identifier, so `\\m` matched `XKIP-315` against `KIP-315` — inflating AI-linked PR share and joining unrelated PRs into work-timeline cycle stats. Both `\\m` and `\\M` now anchor both sides.\n - **Usage dedup re-introduced 2–3× token inflation** on transcripts where two JSONL lines for the same `message.id` differed in whether they carried `requestId` (`msg_1:` vs `msg_1:req_a` keyed as distinct messages). Dedup now keys on `mid` alone — the comment already called it the stable identifier. Regression test added.\n - `loadUsageByDay`'s early break assumed strictly chronological JSONL; out-of-order timestamps from sleep-resume clock skew or backfill silently terminated the scan and dropped later in-range snapshots. Switched to a continue.\n - `enrichmentStatusBySession` depended on filesystem iteration order — a session whose newest day was pending could surface as enriched (or vice versa). Now reads from the most-recent entry after explicitly sorting by `local_day` desc.\n - `runDaemonUpdateCheck` could leave `updateCheckInFlight=true` forever if a registry fetch hung past its 3-second timeout, blocking all future update checks behind the 5-second watchdog tick. The in-flight return path now advances `nextUpdateCheckAtMs` properly.\n\n### Changed\n- **Five dead exports removed** surfaced by the audit (zero callers anywhere, verified by ripgrep): `predictUtilization` + `dollarsInWindow` from `parser/src/calibration.ts`; `parseDateArg` from `cli/src/args.ts`; `lastCompletedMonth` from `apps/web/lib/entries.ts`; `coworkSessionLocalDay` + its `parser/src/fs.ts` re-export.\n- **Type-safety + perf cleanups** to load-bearing primitives surfaced by the audit (no behavior change, but the code is now easier to refactor without surprises).\n- **Internal: six large files split for maintainability.** Pure code moves — every chunk landed with `tsc --noEmit` clean and the parser's `entries --all --json` output byte-identical to master.\n - `apps/web/app/sessions/[id]/session-view.tsx` 6,612 → 5,208 LOC, with 11 colocated modules extracted under `session-view/`.\n - `apps/web/app/parallelism/gantt-chart.tsx` 1,774 → 888 LOC, with `gantt-chart-utils.ts`, `concurrency-info-modal.tsx`, `burst-detail-modal.tsx` extracted.\n - `apps/web/app/sessions/[id]/team-tab/team-minimap.tsx` 682 → 427 LOC, with `minimap-shared.ts`, `minimap-idle-band.tsx`, `minimap-hover-card.tsx` extracted.\n - `packages/team-server/src/lib/team-report-aggregate.ts` 1,713 → 1,559 LOC, with `ticket-velocity.ts` extracted.\n - `apps/web/app/api/digest/{day,week,month}/[…]/route.ts` thinned to ~30 LOC each via a shared `digest-route-helpers.ts`.\n - `apps/web/components/{week,month}-digest-view.tsx` deduplicated through a shared `digest-actions.tsx`.\n- **Parser `antigravity.ts` tightened** from `any[]` to `unknown[]` with a local `RawEvent` / `RawToolCall` record cast (16 implicit-any property accesses eliminated). Verified byte-identical `SessionEvent` dump on a fixture exercising every parser branch.\n- **+83 unit tests** backfilling load-bearing primitives that had no coverage: `formatTokens`, `formatGap`, `formatDuration`, `prettyProjectName`, `formatUsage`, `mondayFor`, plus the parser/team-server regression tests for the dedup and word-boundary fixes above. Total: 1,275 → 1,358.\n\n## [0.13.0] — 2026-06-18\n\n### Added\n- **Day-scoped session timeline.** A long-running session that spans several days no longer crams every day into one unreadable strip. The timeline map gives you Prev/Next day controls (with the day's date) to step through the run one day at a time, and as you scroll the transcript the timeline follows along — auto-advancing to whichever day you're reading. Each day's perception digest card now sits inline at that day's first entry instead of stacked at the top, so the summary travels with the work it describes.\n- **LIVE now sees background agents and workflows.** A session whose main transcript has gone quiet but is still running background subagents or a workflow now correctly reads as live: liveness is computed from the newest activity across the session's nested subagent/workflow transcripts, not just the main JSONL. The live badge, the Running/Idle state, and the live-sessions widget all reflect in-flight background work, and the dashboard auto-refreshes when a background agent writes.\n- **Keep the usage daemon running across reboots (macOS).** New `fleetlens autostart <install|uninstall|status>` installs a launchd LaunchAgent that runs `fleetlens daemon start` at login, so usage polling survives a restart. `fleetlens start` offers to set this up the first time (a simple Y/n, with \"don't ask again\"); it's daemon-only and entirely opt-in. On non-macOS it prints how to add a login item manually.\n- **Per-member CLI version reported to Team Edition.** The daemon now stamps its installed Fleetlens CLI version into each team push, so the team roster can show who's up to date. Harmless to older servers, which ignore the field.\n\n### Changed\n- **Session view tabs renamed** to Timeline / Workflows / Log (from Transcript / Workflows / Debug).\n\n### Fixed\n- **Harness-injected lines no longer render as your messages.** Post-compact continuation summaries (\"This session is being continued…\") and session-scoped Stop-hook notices arrive with a user role but aren't things you typed — they're now hidden from the transcript and excluded from turn counts and digests, like other framework boilerplate.\n- **Sessions list hydration error** on pending session cards (a nested link inside the card link) is gone.\n\n## [0.12.3] — 2026-06-15\n\n### Fixed\n- **Opening a session under-counted its tokens everywhere afterward.** Viewing a session that spawned subagents returned parent-only token totals and overwrote the shared in-memory cache with them, so the dashboard, estimated cost, daily heatmap, and project rollups all dropped that session's subagent tokens until the server restarted. The detail path now applies the same subagent-inclusive recompute as the list path, so totals stay correct and consistent no matter which page you open first.\n- **`fleetlens usage --history` cost accuracy.** A single session on an unpriced model (e.g. `<synthetic>`) no longer nulls a whole day's cost — each day now sums the cost of its priced sessions and marks the figure as a lower bound (`≥`) when some sessions couldn't be priced. The Total row sums every priced day (it previously dropped them while still counting their tokens) and is likewise marked `≥` when any usage was unpriced, so Total cost and Total tokens no longer imply different scopes.\n- **`fleetlens usage --history` model labels.** A day with two minor model versions could render a duplicated/inconsistent label (e.g. `opus-4, opus-4`); model names now use one normalization for both de-duplication and display.\n- **Sidebar project count matches the Projects page.** The sidebar nav badge and footer counted Claude Code projects only, disagreeing with the all-source `/projects` page and omitting Codex / Cowork / Gemini / Antigravity projects. Both now reflect every agent source.\n- **A stale or corrupt digest file no longer 500s the dashboard.** Cached day/week/month digests are now validated on read (schema version + shape); an incompatible or damaged file is ignored and the page renders without it, honoring the \"a schema bump regenerates digests\" contract.\n- **A failed stale-server restart can't leave an invisible orphan.** If the replacement server can't take the port, `fleetlens start`/`web` now escalate to a force-kill and re-record the old server's pid so `status`/`stop` can still see and stop it, instead of leaving an untracked process serving the old bundle.\n- **Live-sessions count hydration.** The \"Live · N\" badge is time-derived and could briefly mismatch between server render and hydration; it's now marked so React doesn't warn.\n\n## [0.12.2] — 2026-06-15\n\n### Fixed\n- **A stale web server could survive an update and serve a broken dashboard.** After `fleetlens` updated itself, the CLI binary and usage daemon came up on the new version, but a web server that was already running kept serving the old build. Once npm removed the previous install directory, any dashboard route the old server hadn't already loaded into memory returned a 500 (Insights was the usual casualty). `fleetlens start` and `fleetlens web` now record the running server's version in the pid file and automatically restart it when it no longer matches the installed CLI; `fleetlens status` shows the served version and warns when it's stale.\n\n## [0.12.1] — 2026-06-15\n\n### Fixed\n- **Per-day metrics for cross-midnight sessions.** A session that ran past midnight had its agent time split across calendar days but its tokens, tool calls, turns, and session count pinned to the start day — so on the dashboard (and team rollups) the continuation days showed agent time with 0 tokens / 0 sessions. Each tool call, turn, and token is now attributed to the day its own event happened, and a session counts on every local day it worked. The split is sum-preserving (totals are unchanged) and keeps `sum(per-day tokens) === session total` even across subagents that run past midnight.\n\n### Changed\n- **Team push carries a `unique_sessions` count.** Because the per-day `sessions` figure is now \"session-days\" (a cross-midnight session counts on each day it touched), the daemon also pushes the start-day count so the team-server's roster/header/maturity aggregates keep exact unique-session semantics. Requires team-server ≥ 0.12.3; older servers ignore the extra field.\n\n## [0.12.0] — 2026-06-15\n\n### Added\n- **Dynamic workflow visualization.** A single `Workflow` tool call collapses a whole fan-out — 200+ spawned agents — into one opaque transcript row. Fleetlens now reads the aggregate journals Claude Code persists per run and surfaces the real fleet work:\n - **Workflows tab** on the session page (next to Transcript / Team / Debug) with a run-count badge. Each run is a card showing status, spawned-agent count, tool calls, tokens, and duration.\n - **Fleet stat** in the session header (`N workflows · M agents`) plus a spawned-agent badge on session-list cards, so workflow-driven sessions stand out at a glance.\n - **Per-phase action tabs** inside each run — the phases the workflow declared (e.g. Build / Panel / Skeptic / Merge), each listing the agents that ran in that phase.\n - **Full per-agent step log.** Clicking an agent opens a right side-sheet with its Task, the complete ordered step list (every tool call — expand any step for the full multi-line command), and the Result. Loaded on demand so even 100+ step, 200+ agent sessions stay fast; sections are collapsed by default.\n - **Workflow lanes** on the timeline minimap (distinct from subagent lanes); click a lane to open that run in the Workflows tab.\n- **Workflow execution counts as agent time.** A run's wall-clock span is folded into the session's \"agent time\" and carved out of the minimap idle bands, so the stretch where the parent waits on a workflow reads as active fleet work, not dead air.\n\n## [0.11.2] — 2026-05-27\n\n### Changed\n- **`fleetlens start` and `fleetlens web` no longer auto-launch the browser.** The dashboard URL is printed so you can click it (every modern terminal makes `http://localhost:…` clickable), but no browser tab opens unless you pass the new `--open` flag. Auto-launch was surprising users whose default browser had moved to a different desktop, was a corp-managed profile they didn't want spawned, or was simply already in flow on another window. The previous `--no-open` flag is still accepted as a no-op — existing scripts and aliases keep working without changes.\n\n## [0.11.1] — 2026-05-21\n\n### Added\n- **Team workspace seeding script.** Added `scripts/seed-team-workspace.mjs` for local end-to-end telemetry testing.\n\n### Changed\n- **Plan page layout grid consistency.** Enhanced the Team Edition Plan page layout grid consistency and renamed the 'Latest cycle' column to 'Current cycle'.\n- **Completed cycles alignment.** Modified the completed cycles strip to show a maximum of 4 historical cycles, padded on the left with empty placeholders for visual right-alignment and grid uniformity.\n\n### Fixed\n- **Mini-burndown SVG typings and filtering.** Resolved mini-burndown SVG typings and parameterized cycle strip filtering.\n- **Active cycle query performance.** Batched active cycle loads in a single query to eliminate N+1 DB lookups.\n\n## [0.11.0] — 2026-05-21\n\n### Added\n- **Team-issued commands to the daemon.** When you've paired with a Team Edition server, a team admin can now queue a 30-day activity backfill against your daemon from the team dashboard. The daemon picks the command up on its next 5-minute sync and re-pushes the last 30 days of daily activity rollups (server upserts, fully idempotent). No member-side UI changes — the existing \"last sync N ago\" tick on `/settings → Team connection` is the only feedback signal. Commands ride piggyback on the existing `/api/ingest/metrics` response; no new connections, no new polling. The privacy boundary holds: the dispatcher's switch has a single case (`backfill-activity`) and only calls existing aggregate-push helpers, so commands can widen the time window but never change the data shape. No transcripts, prompts, or project content can leak through a command. Always-on when paired (pairing implies consent); no opt-out env var. Requires `team-server v0.9.0+` to actually receive any commands; older servers simply don't issue any (the additive `commandResults` field is ignored, no harm).\n\n## [0.10.6] — 2026-05-21\n\n### Added\n- **Team-pairing visibility in the Personal Edition dashboard.** When you've paired with a Team Edition server (`fleetlens team join …`), the dashboard now surfaces what's syncing without you having to open a terminal. A sidebar chip with a health dot (green / amber / red — re-derived client-side every 30 s so it ages correctly even when the daemon stops) and a live-aging \"synced N ago\" label. A `/settings → Team connection` panel showing team metadata, a labeled last-push preview (Agent time / Session count / Tool call count / Turn count / Token total / Plan tier), an explicit \"What does NOT leave your machine\" block, and a \"Sync now\" button that spawns `fleetlens team sync` as a subprocess and renders its output inline. A first-run welcome banner on the overview after pairing, dismissable per pairing. The preview also includes a \"Show raw JSON payload\" disclosure that displays the literal `IngestPayload` from disk — verify byte-for-byte that no transcripts, prompts, or project content leave your machine. Solo users see no change.\n\n### Changed\n- **Wire-format types now live in `@claude-lens/parser`.** `IngestPayload`, `DailyRollup`, `LastPushRecord`, and the rest of the daemon→server wire shape moved out of `packages/cli/src/team/push.ts` so the CLI and the dashboard share a single canonical definition — no drift risk on future schema changes. The CLI's `team-config` module also moved to the parser (`@claude-lens/parser/fs`) for the same reason.\n\n## [0.10.5] — 2026-05-21\n\n### Changed\n- **Team backfill now rides the consolidated `/api/ingest/metrics` path.** Same endpoint as the daemon's regular 5-min push, just with the optional `snapshotHistory` field set. Removes the need for a separate path-allowlist entry on deployments fronted by a proxy (IAP, WAF, Cloud Run / GLB path matcher), and as a side-effect the old `/api/ingest/usage-history` route is now a thin deprecation shim. Requires `team-server v0.8.4+` — older servers will return 200 without a `snapshotHistory` result block, and the CLI aborts the backfill loudly rather than silently advancing the high-water mark.\n\n### Fixed\n- **Backfill no longer silently advances the high-water mark on an older team-server.** Previously, a server that didn't recognize `snapshotHistory` would return 200 (zod `passthrough()` swallows unknown fields), `runTeamSync` would persist `lastSyncedUsageSnapshotAt` as if all rows landed, and the dropped rows would never be retried after the server upgraded. Backfill now requires an explicit `snapshotHistory` result block in the response.\n\n## [0.10.4] — 2026-05-21\n\n### Fixed\n- **Fleetlens's own LLM runs no longer show up in the dashboard.** The tmux-driven runner records its enrichment / digest / `/ask` calls as real Claude Code transcripts under `~/.claude/projects/` (cwd `~/.cclens/runtime`), since tailing that transcript is how it reads the model's reply. Those self-generated sessions were surfacing as a `.cclens/runtime` project and inflating session, project, and token-calibration rollups. The tmux runner now deletes each transcript once the response is captured (kill-session before unlink so claude can't rewrite it, gated by `FLEETLENS_TMUX_KEEP_WRAPPER`), and the parser excludes the runtime project dir at the scan chokepoint as a safety net for any transcript that outlives cleanup.\n\n## [0.10.3] — 2026-05-16\n\n### Added\n- **Daemon auto-update every 6 hours.** The local daemon now hourly-checks `registry.npmjs.org/fleetlens/latest` and spawns a detached `fleetlens update` child when a newer version exists. Timestamp persisted in `~/.cclens/daemon-update.json` so closing the laptop lid for days and reopening triggers an immediate catch-up check instead of waiting out the interval. Opt-out via `FLEETLENS_DAEMON_AUTO_UPDATE=0`.\n\n### Changed\n- **Unified team sync.** `runTeamSync` now drives history backfill, daily activity, live utilization, queue drain, and tier propagation through a single path. `team join` and the daemon's 5-min tick both call the same function — so a user disconnected from the team server for days will autonomously catch up on next sync, no manual `team backfill` needed.\n- New `lastSyncedUsageSnapshotAt` high-water mark in `~/.cclens/team.json` means incremental syncs only ship eligible new snapshots. Cold-start full backfill is bypass-able via `fleetlens team backfill --force` (and still runs unconditionally on first pair).\n- Team sync cadence is now independent of Claude OAuth polling, so an expired Claude token can no longer turn team sync into a 5-second retry storm.\n\n### Fixed\n- `lastSyncedDay` no longer advances past a failed day on partial outage — previously a transient mid-stream 5xx left a permanent hole in the team-server's daily-activity coverage.\n- Both `/api/ingest/metrics` and `/api/ingest/usage-history` POSTs now have a 15-second `AbortSignal.timeout` to bound hangs on network stalls.\n\n## [0.10.2] — 2026-05-15\n\n### Fixed\n- **Session-detail minimap no longer paints subagent runtime as idle.** Long agent runs that dispatched many subagents were reading as wall-to-wall \"Session idle\" stripes because the parent's tool_use → tool_result gap (the subagent's actual runtime) was classified as in-turn idle. `rawIdleBands` now carves subagent run spans out of every candidate gap; for in-turn gaps that overlap any subagent run the entire gap is dropped, and between-turn gaps with background subagent activity keep only the genuinely-unwatched residue.\n- **First-response thinking stops registering as idle.** Anchors now include every timestamped event (agent-thinking, meta, etc.), and the loop tracks an \"awaiting first response\" phase across intermediate thinking anchors. A `user → thinking → thinking → agent` sequence where the model takes a while to compose its first reply is now treated as response latency rather than painted as a stripe.\n- **Turn duration no longer shows `0ms` for single-row turns.** `buildMegaRows` now anchors a turn's `tOffsetMs` and `durationMs` at the originating user message rather than at the first agent row. Single-row turns show the actual user → agent latency, and the visual span of the turn rectangle on the minimap covers the whole arc.\n- **Single `Session idle` divider per band.** A user row and the turn-collapsed row that follows it now share a `tOffsetMs`, so the body's `IdleDivider` emitter dedupes per band to stop two consecutive identical idle markers around the same boundary.\n\n### Changed\n- Minimap idle threshold raised from 10s to 30s. Ordinary tool latency (slow Bash, big-file Read, between-anchor model thinking) no longer registers as idle.\n\n## [0.10.1] — 2026-05-14\n\n### Added\n- **Alternative claude runtime via tmux.** When `tmux` is on PATH, both the LLM pipeline (digest synth, entry enrichment, top-session perception) and the `/ask` feature now drive `claude` through a detached tmux session instead of `claude -p`. Sessions produced this way carry `entrypoint: cli` in their JSONL, which is also extracted by the parser and surfaced as a small badge on `/sessions/<id>` next to the model chip — green for `cli` / `claude-desktop`, amber for `sdk-*`. The path falls back to `claude -p` whenever tmux is unavailable or the run errors; set `FLEETLENS_FORCE_PRINT_MODE=1` to disable the tmux path entirely.\n- **`CCLENS_HOME` env override.** All `~/.cclens/` state (pid file, daemon log, perception state, usage snapshot log, llm-runs traces) is now reached through a shared `cclensHome()` helper that honors `CCLENS_HOME`. Lets multiple installs / workspaces run side-by-side without stomping on each other's state.\n\n### Fixed\n- `/api/runs` rendered every successful tmux-driven run as `status=error`. Tmux runs have no subprocess exit code (the session is killed by cleanup), and the runs viewer was treating a missing code as failure. End records now stamp `exit_code: 0` on success and the active-process filter no longer requires the literal `claude -p` flag, so tmux-driven processes also show up in the \"active\" panel while they're running.\n- `JobQueueWidget`'s `/api/jobs` polling effect listed `jobs` in its deps, so each tick re-armed the effect on the freshly-set state ref — effective cadence collapsed to a 1–4 ms refetch loop. Now tracks `hasActive` in a closure-local var and runs the effect once on mount.\n\n### Conductor\n- New `conductor.json` + `scripts/conductor-{setup,run,archive}.sh` so each Conductor workspace allocates its own 3-port band (web / team-server / postgres) and boots its own `fleetlens-<workspace>` Compose stack against `.harness/cclens-state`. Replaces ~30 hard-coded `join(homedir(), \".cclens\", …)` call sites with the shared `cclensHome()/cclensPath()` helper so a second workspace can boot without colliding with the user's primary install.\n\n## [0.10.0] — 2026-05-08\n\n### Changed\n- **Plan utilization reframed.** High utilization is now \"getting plan value\" (green); low utilization is \"paying for unused headroom\" (red). Mirrors how an operator actually looks at the dashboard: the wasteful outcome is paying for a plan and barely touching it, not running near the cap. Applied across `/usage` burndown, gauges, sidebar, and previous-cycles strip.\n- **In-progress cycles colored by pace, not peak.** A 50% peak halfway through a 7-day cycle reads on-pace green, not amber — the chart no longer cries wolf on a fresh cycle that just hasn't burnt yet. Completed cycles still use peak tone.\n- **Pace label ±15pp band.** \"On pace\" now covers a ±15pp window around ideal; outside that, label is \"below pace\" (under-burning) or \"may exhaust early\" (over-burning). The previous +5/-50 thresholds flipped amber every time the user took a night off.\n- **Pace label collapses to three states.** \"May exhaust early\" / \"below pace\" / \"on pace\" — same color tones, one fewer qualifier to read.\n- **Wording softened across the utilization views** to describe the pattern rather than judge the user. \"Behind schedule\" → \"below pace\"; \"on track (+x%)\" → \"on pace (+xpp vs ideal)\".\n\n### Added\n- **Conductor multi-agent workspace support.** Sessions inside Conductor's worktree-style agent workspaces (`~/conductor/workspaces/<repo>/<agent>/...`) now group correctly under their parent project, with each agent shown as a separate worktree. Mirrors the existing `.worktrees/` handling.\n\n### Fixed\n- Hydration mismatch on `/usage` when pace labels rendered before client mount.\n\n### Notes for operators\n- The CLI's team push now ships **only Claude Code usage snapshots** to the team server. Codex snapshots stay local until `plan_utilization` gets a per-agent partition — without one, the team-server's \"latest snapshot\" pick flips between agents and miscolors the in-progress cycle. Existing rows in `plan_utilization` stay; new pushes are claude-code only.\n\n## [0.9.0] — 2026-05-07\n\n### Added\n- **Gemini CLI** as the third agent source. Sessions written to `~/.gemini/tmp/<slug>/chats/session-*.jsonl` are now read, parsed, and rendered alongside Claude Code and Codex. Tool calls (`read_file`, `list_directory`, `glob`, `run_shell_command`, `update_topic`, …) and their results show in the session timeline; thinking blocks, multi-write status replay, `$set` / `$rewindTo` semantics, and the legacy single-JSON file shape all handled. Slug → cwd inversion via `~/.gemini/projects.json`. `✺` glyph + purple accent in the UI.\n\n### Changed\n- Session detail timeline drops in-turn idle hatching. Within a turn, every wait — model loading, tool execution, network — is the agent's active time. Only between-turn idle (user reading + composing the next message) renders as hatched.\n- Gemini parser anchors `firstTimestamp`, `lastTimestamp`, and `activeSegments` on conversational events only. Login/OAuth `info` records and `metadata.startTime` (file-creation moment) no longer stretch the session bar back to before the first user message.\n\n## [0.7.1] — 2026-05-07\n\n### Fixed\n- Cycle-peaks trend no longer renders two bars labeled the same day. When Anthropic's rolling 7-day window slid its anchor between consecutive polls, the daemon's bucketer (hour-rounded) recorded both reset boundaries as distinct cycles. They're now merged within a 12 h tolerance — same fix in `apps/web/lib/cycle-peaks.ts` (used by `/usage`) and in `packages/cli/src/team/sync.ts` (the daemon's team-server push), so both the personal `/usage` chart and the team-server's plan-utilization view stay consistent. 5-hour cycles keep no merge tolerance (their anchor is stable; merging would collapse legitimate distinct cycles).\n\n## [0.7.0] — 2026-05-06\n\n### Added\n- **Multi-agent observability — Codex as the first non-Claude adapter.** The parser now defines an `AgentSource` registry; new agents land as a single file plus one registry entry. Codex CLI rollouts at `~/.codex/sessions/` flow through the same pipeline as Claude Code: their sessions appear in the dashboard, timeline, calendar, and per-project rollups alongside Claude sessions, with `agent: \"codex\"` carried through every event so consumers can split or aggregate.\n- **Per-agent representation in the UI.** Each session row carries an agent badge; top-sessions guarantees a multi-agent representation when both agents are active; the Gantt rail uses a per-agent glyph and outcome pills.\n- **Usage page is now agent-tabbed.** Switch between Claude and Codex views; cross-agent comparisons stay readable rather than smashed onto a single chart.\n- **Codex sessions blend into the day + week digest narratives** so the insights pipeline summarises across agents instead of treating Codex as a footnote.\n- **`fleetlens` → \"Ask\"** (agent-neutral). Previously labelled \"Ask Claude\"; the underlying prompt-routing stays Claude-backed, but the surface name no longer implies single-agent.\n\n### Changed\n- Dashboard default time range moved to **90 d** to match how multi-agent fleets actually use the tool — week-only views were truncating Codex activity that lands in week-old session files.\n- `AgentSource` interface opened up so future agents (OpenCode, Gemini CLI, …) are pure additive plug-ins; no parser core changes required.\n- Daemon auto-backfills *yesterday's* day digest on boot when `ai_features.auto_backfill_yesterday` is on, so `--no-daemon` users still get a yesterday digest on first homepage visit.\n\n### Fixed\n- **Codex calibration math no longer pollutes the Claude window.** Non-Claude snapshots are excluded from the Claude-side cycle-peaks calibration that drives plan-fit advice — previously a Codex-heavy run skewed the projected exhaustion line.\n- **Minimap idle bands** are now derived from raw event timestamps (not row kind) and coalesced per turn, so Codex sessions with sub-minute back-and-forth no longer paint as wall-to-wall idle.\n- Sessions filter state preserved in the URL so refresh / share doesn't lose the active filter.\n- `/insights` persists forced current-week digests so the page actually shows them on next load.\n\n## [0.6.4] — 2026-05-04\n\n### Fixed\n- Cached calibration events per-file so `/usage` warm renders complete in well under a second on large session histories.\n\n## [0.6.3] — 2026-05-04\n\n### Fixed\n- Dropped poisoned auto-week locks left behind by interrupted runs; backfill now gates on the live pipeline lock instead.\n\n## [0.6.2] — 2026-05-04\n\n### Added\n- Last week's digest auto-generates on launch when AI features are on. Disable in Settings → AI features.\n\n## [0.6.1] — 2026-05-04\n\n### Changed\n- Smaller install size — published bundle no longer drags in unused workspace metadata.\n\n## [0.6.0] — 2026-04-30\n\n### Added\n- V2 perception layer. Daily, weekly, and monthly digests synthesized from per-session entries via a strict hierarchical pipeline (entry → day → week → month). Past-period digests are immutable on disk; current-period digests use a 10-min in-memory TTL.\n- `/insights` route with on-demand week and month digest generation, picker history, and force-regen.\n- `fleetlens digest day | week | month [--json]` — CLI surface that reproduces the same digests served at `/insights`.\n- `fleetlens entries [--day | --session | --all] [--json]` — inspect the per-session entry primitive.\n\n### Changed\n- Renamed \"active time\" to \"agent time\" across the dashboard and CLI for clarity.\n\n## [0.4.1] — 2026-04-23\n\n### Added\n- Concurrency view on `/parallelism` page. Bursts colored teal for same-project and purple for cross-project (the genuinely interesting fleet-work signal).\n- Plan utilization sparkline on the sidebar, fed by the usage daemon's 5-min snapshots.\n\n### Fixed\n- Auto-update no longer leaves a zombie web server on the old binary; both server and daemon are torn down before re-exec.\n\n## [0.4.0] — 2026-04-18\n\n### Added\n- Usage daemon (`fleetlens daemon …`) polls `/api/oauth/usage` every 5 min and appends snapshots to `~/.cclens/usage.jsonl`. `fleetlens start` and `fleetlens stop` manage server + daemon together.\n- `fleetlens usage --history` for inspecting past plan utilization.\n\n## [0.3.0] — 2026-04-10\n\n### Added\n- Project rollups with worktree aggregation. Sessions inside `<project>/.worktrees/<name>` roll up under their parent canonical project with a `+N wt` badge.\n- Pinned projects in the sidebar (per-browser via localStorage).\n\n## [0.2.0] — 2026-04-01\n\n### Changed\n- Active-segment computation now uses all timestamped events (system + summary + sidechain + conversational) instead of conversational-only. Earlier filter undercounted by up to 100x on tool-heavy sessions.\n\n## [0.1.0] — 2026-03-15\n\n### Added\n- Initial release. Local-only dashboard for Claude Code sessions: timeline, projects, daily activity bucketing, parallelism detection, per-model cost estimation. Reads JSONL transcripts from `~/.claude/projects/`.\n");s[0]?.version,e.s(["STORAGE_KEY",0,"cclens:changelog-last-seen"],54611)}]);