daimon 0.8.0 → 0.9.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.
Files changed (77) hide show
  1. package/CHANGELOG.md +83 -0
  2. package/README.md +48 -1
  3. package/dist/cli.js +91 -86
  4. package/dist/dashboard/browser/chunk-3EPFSBJ2.js +2 -0
  5. package/dist/dashboard/browser/{chunk-PJPGLT4T.js → chunk-3ZFFKHPU.js} +1 -1
  6. package/dist/dashboard/browser/{chunk-QSBOKS53.js → chunk-4KVYA2AQ.js} +1 -1
  7. package/dist/dashboard/browser/chunk-55AO3FMG.js +1 -0
  8. package/dist/dashboard/browser/{chunk-V2KNRAE4.js → chunk-66VYPESU.js} +1 -1
  9. package/dist/dashboard/browser/chunk-6MTVWBQQ.js +2 -0
  10. package/dist/dashboard/browser/chunk-6Z4FDREI.js +1 -0
  11. package/dist/dashboard/browser/{chunk-7NPLP3QD.js → chunk-7LKM244H.js} +1 -1
  12. package/dist/dashboard/browser/chunk-ACPSBF55.js +1 -0
  13. package/dist/dashboard/browser/{chunk-OHX55ZU4.js → chunk-AGN2F6JP.js} +1 -1
  14. package/dist/dashboard/browser/chunk-B2DPS6BL.js +1 -0
  15. package/dist/dashboard/browser/{chunk-3WKRVGPT.js → chunk-BBTQXZIS.js} +1 -1
  16. package/dist/dashboard/browser/chunk-CIQNXWDY.js +1 -0
  17. package/dist/dashboard/browser/chunk-EBGPIJ7S.js +1 -0
  18. package/dist/dashboard/browser/{chunk-LBRCWYRN.js → chunk-F3FCHBFQ.js} +1 -1
  19. package/dist/dashboard/browser/chunk-FD3BW2ZN.js +1 -0
  20. package/dist/dashboard/browser/chunk-FRKUCFVI.js +1 -0
  21. package/dist/dashboard/browser/chunk-FZLMX6EY.js +1 -0
  22. package/dist/dashboard/browser/chunk-GMEW64AS.js +1 -0
  23. package/dist/dashboard/browser/chunk-HXX2OUOE.js +1 -0
  24. package/dist/dashboard/browser/chunk-HZNVO3JE.js +1 -0
  25. package/dist/dashboard/browser/chunk-JWXROQJJ.js +2 -0
  26. package/dist/dashboard/browser/chunk-K2SFF47Z.js +5 -0
  27. package/dist/dashboard/browser/chunk-K5WKBG55.js +1 -0
  28. package/dist/dashboard/browser/chunk-K6PUQAFE.js +2 -0
  29. package/dist/dashboard/browser/{chunk-NDSAQ2HK.js → chunk-KRC72WWY.js} +1 -1
  30. package/dist/dashboard/browser/{chunk-H3L4MTG4.js → chunk-LBWOIG7N.js} +1 -1
  31. package/dist/dashboard/browser/chunk-NVL5HFLU.js +1 -0
  32. package/dist/dashboard/browser/chunk-O76B43BY.js +4 -0
  33. package/dist/dashboard/browser/{chunk-EIWOTZT3.js → chunk-PRLUGTKR.js} +1 -1
  34. package/dist/dashboard/browser/chunk-QYIYT4YU.js +1 -0
  35. package/dist/dashboard/browser/{chunk-UC3XMN2Y.js → chunk-R7VSXL63.js} +1 -1
  36. package/dist/dashboard/browser/{chunk-7NRE3SNA.js → chunk-RNUJZTKS.js} +1 -1
  37. package/dist/dashboard/browser/{chunk-2BXIFQGQ.js → chunk-RWXAGDGT.js} +1 -1
  38. package/dist/dashboard/browser/chunk-RXOAYCKI.js +2 -0
  39. package/dist/dashboard/browser/chunk-SR4HVFOB.js +2 -0
  40. package/dist/dashboard/browser/chunk-TGSV7ZHM.js +2 -0
  41. package/dist/dashboard/browser/chunk-UC7AWK4C.js +2 -0
  42. package/dist/dashboard/browser/chunk-UUJWPV5O.js +3 -0
  43. package/dist/dashboard/browser/chunk-VHALTUPL.js +2 -0
  44. package/dist/dashboard/browser/{chunk-6WZJCF24.js → chunk-VMW35ZNT.js} +1 -1
  45. package/dist/dashboard/browser/{chunk-Q772THBA.js → chunk-WOMCRDMJ.js} +1 -2
  46. package/dist/dashboard/browser/chunk-WRX32YWH.js +1 -0
  47. package/dist/dashboard/browser/chunk-X4RGWMLE.js +4 -0
  48. package/dist/dashboard/browser/{chunk-P5IU57TV.js → chunk-YHBNUNU3.js} +1 -1
  49. package/dist/dashboard/browser/index.html +1 -1
  50. package/dist/dashboard/browser/main-YAROJLJV.js +1 -0
  51. package/dist/main.js +49 -48
  52. package/dist/mcp.js +3 -3
  53. package/package.json +6 -3
  54. package/dist/dashboard/browser/chunk-44JIQO3X.js +0 -1
  55. package/dist/dashboard/browser/chunk-4BAKWDAV.js +0 -1
  56. package/dist/dashboard/browser/chunk-4OCNYL7T.js +0 -1
  57. package/dist/dashboard/browser/chunk-7C772RJ3.js +0 -3
  58. package/dist/dashboard/browser/chunk-A4BNXJUT.js +0 -1
  59. package/dist/dashboard/browser/chunk-CILFSVSP.js +0 -2
  60. package/dist/dashboard/browser/chunk-CM4RQF3A.js +0 -5
  61. package/dist/dashboard/browser/chunk-CNSXWFDX.js +0 -1
  62. package/dist/dashboard/browser/chunk-CY5YRTQK.js +0 -1
  63. package/dist/dashboard/browser/chunk-GYWEXV2L.js +0 -3
  64. package/dist/dashboard/browser/chunk-H2N3RBHF.js +0 -1
  65. package/dist/dashboard/browser/chunk-I65I7J5Q.js +0 -2
  66. package/dist/dashboard/browser/chunk-K43KW4K2.js +0 -4
  67. package/dist/dashboard/browser/chunk-K7S4ITPJ.js +0 -2
  68. package/dist/dashboard/browser/chunk-KL6X73FV.js +0 -1
  69. package/dist/dashboard/browser/chunk-KLH6B22T.js +0 -1
  70. package/dist/dashboard/browser/chunk-LBL7Z5BE.js +0 -5
  71. package/dist/dashboard/browser/chunk-LHAMBNO6.js +0 -1
  72. package/dist/dashboard/browser/chunk-NX6DTO32.js +0 -1
  73. package/dist/dashboard/browser/chunk-P5IE6DI6.js +0 -2
  74. package/dist/dashboard/browser/chunk-VM2FOT77.js +0 -1
  75. package/dist/dashboard/browser/chunk-Y6B6X4Y6.js +0 -2
  76. package/dist/dashboard/browser/chunk-YYAZGY5M.js +0 -1
  77. package/dist/dashboard/browser/main-4CQTBXSB.js +0 -1
package/CHANGELOG.md CHANGED
@@ -4,6 +4,89 @@ All notable changes to Daimon are documented here. The format follows [Keep a Ch
4
4
 
5
5
  ## [Unreleased]
6
6
 
7
+ ## [0.9.0] — 2026-05-21
8
+
9
+ Strategic theme: **Multi-agent observability.** v0.9 finishes the pivot to many agents on one machine, each in their own workspace, all sharing one daemon and one dashboard. On top of the architectural shift, deepen what daimon *sees* (lint findings as a third signal class beyond errors + warnings) and *shows* (a unified event timeline), and broaden what it *understands* (framework-aware health probes for the polyglot stack landed in v0.7).
10
+
11
+ ### Added (M46) — Multi-workspace foundation
12
+
13
+ - `src/pathScope.ts` (`isPathUnder`, `normalizeForCompare`) — case-insensitive on Windows, separator-normalized.
14
+ - `POST /api/workspaces/ensure` — idempotent register; returns `{ added, root, addedApps }` or `{ added: false, reason: 'already covered' }`.
15
+ - `GET /api/apps?cwd=<path>` — filter by workspaceRoot under cwd (bidirectional: either direction counts).
16
+ - `daimon list` defaults to cwd-scoped; `--all` bypasses; auto-calls `ensureCurrentWorkspace()`.
17
+ - Warnings as a second signal class: parser `WARNING_PATTERNS`, `ErrorEntry.level?: 'error'|'warning'`, `warning-new` / `warning-recur` events, `?level=` filter, severity chips on the Errors page, tertiary-accent warning rows.
18
+ - `TrendChartComponent` skeleton regression fix: `loading`/`empty`/`title`/`subtitle` are signals (zoneless + OnPush).
19
+ - `scripts/dev-install.mjs` + `npm run dev:install` / `dev:install:fast` / `dev:unlink`.
20
+
21
+ ### Added (M47) — Per-cwd command resolution
22
+
23
+ - `Registry.resolveByCwd(name, cwd?)`: returns `{ kind: 'unique'|'collision'|'none', key?, candidates }`. Discovery now uniquifies storage names on collision (`<base>@<workspaceLabel>`), keeping the user-facing `baseName` intact.
24
+ - Every per-app endpoint resolves `<name>` via `?cwd=`. **412 `name-collision`** body `{ error, candidates: [...], hint }` when two workspaces share the same app name and no cwd disambiguates.
25
+ - CLI `start/stop/restart/status/logs/errors/wait/run` all send `?cwd=<process.cwd()>` unless `--all` is set. New `reportCollisionAndExit` renders candidates by `workspaceLabel`.
26
+ - MCP tools `get_status`, `get_status_full`, `get_errors`, `get_logs`, `start_app`/`stop_app`/`restart_app` accept an optional `cwd` param (defaults to the MCP server's `process.cwd()`).
27
+
28
+ ### Added (M48) — Workspace registry CLI + audit attribution
29
+
30
+ - `daimon workspaces list|add [path] [--label <name>] | rm <path> | show [path]`.
31
+ - `GET /api/workspaces`, `POST /api/workspaces/remove`, `GET /api/workspaces/resolve?cwd=<p>`.
32
+ - CLI sends `X-Daimon-Cwd: <process.cwd()>` on every authenticated POST.
33
+ - `appendAuditEntry` now records the cwd as the 5th column. Two agents sharing an IP can be told apart in `~/.daimon/audit.log`.
34
+
35
+ ### Added (M49) — Dashboard cwd context
36
+
37
+ - Dashboard reads `?cwd=<path>` and pre-selects the workspace pill that covers it.
38
+ - Unknown-cwd banner offers a one-click **Register** that POSTs `/api/workspaces/ensure` and then re-resolves.
39
+ - New `daimon dashboard` verb opens the default browser to `http://127.0.0.1:4999/?cwd=<process.cwd()>`.
40
+ - Header **scope chip** (`scope: <label> ×`) gives a one-click clear back to "all workspaces". No regression when no `?cwd=` is present.
41
+
42
+ ### Added (M50) — Lint findings channel
43
+
44
+ - Parser `LINT_PATTERNS` for eslint, biome, ruff, clippy. Lint runs **first** (before error/warning) so a tight `F401`/`lint/correctness/...` signal beats the generic `<file>:<line>:<col>:` error rule.
45
+ - `ErrorEntry.level` adds `'lint'`. `AppEventType` adds `lint-new` / `lint-recur`. **Status never flips on lint.**
46
+ - `?level=lint` filter on `/api/apps/:name/errors`. `AppSummary.lintCount`.
47
+ - Errors page severity chips become **errors / warnings / lint / all** with a secondary accent for lint rows. Lint events excluded from error trends.
48
+ - Fixtures: `lint-eslint.log`, `lint-biome.log`, `lint-ruff.log`, `lint-clippy.log`.
49
+ - **Daimon never spawns linters.** This is parse-only — read what the dev server already emits.
50
+
51
+ ### Added (M51) — Unified event timeline
52
+
53
+ - `History.queryTimeline()`: merges events + compile_times + bundles + task_runs into `{ ts, app, kind, summary, payload }`. Sorted desc; 5000-row cap.
54
+ - `GET /api/history/timeline?since=&app=&kinds=<csv>`.
55
+ - New lazy-loaded `/timeline` dashboard route with virtual scroll, kind/app filters, flyout drawer. Nav-rail entry between History and Trends, keyboard chord `g i`.
56
+ - New CLI verb: `daimon timeline [--since 24h] [--app <name>] [--kinds status,error,…]`.
57
+
58
+ ### Added (M52) — Polyglot v2 health probes
59
+
60
+ - `src/healthProfiles.ts` with per-profile probe defaults: django → `/admin/login/`, rails → `/up`, fastapi → `/docs`, go-air → `/`, rust-trunk → `/`.
61
+ - Probe resolution uses (in order): user override → prior auto-discovery → profile default → fallback `/`. The first probe cycle on a fresh Rails/FastAPI app now hits the right path instead of churning through `HEALTH_PROBE_CANDIDATES`.
62
+ - Smart probe outcome: 200, 301/302/304/307/308, and 401 (auth-gated but alive) classify healthy; 5xx and `ECONNREFUSED` / `ECONNRESET` / `EHOSTUNREACH` classify unhealthy.
63
+ - New doctor rule **`health-probe-missing`** with auto-fix: writes the profile-suggested `healthProbePath` into `overrides[<app>]` and triggers a soft-reload.
64
+
65
+ ### Added (M53) — Polish + release prep
66
+
67
+ - Doctor `ALL_AUTO_FIX` now lists 12 rules (added `health-probe-missing`).
68
+ - `CHANGELOG.md` + `RELEASE-v0.9.0.md`. `package.json` 0.8.1 → 0.9.0.
69
+
70
+ ### Migration notes
71
+
72
+ - **Multi-workspace is the migration headline.** Existing single-workspace setups keep working — `daimon list --all` reproduces the v0.8 default. Two agents in different workspaces sharing an app name now coexist; CLI commands run from a workspace cwd resolve automatically. Pass `--all` to see / act on apps across all workspaces.
73
+ - **Audit format change.** `~/.daimon/audit.log` gains a 5th tab-delimited column carrying the agent's cwd. Existing 4-column rows continue to parse — the cwd is empty for them.
74
+ - **Discovery storage keys.** When two workspaces have apps with the same `baseName`, the second is stored under `<baseName>@<workspaceLabel>`. Its `baseName` field stays as the user-facing name. `daimon list` shows the storage key in the `name` column; `workspaceLabel` distinguishes the rows.
75
+
76
+ ## [0.8.1] — 2026-05-21
77
+
78
+ Hotfix for three regressions caught running v0.8.0 against a real workspace.
79
+
80
+ ### Fixed
81
+
82
+ - **Dashboard Errors page no longer storms the daemon.** The errors-panel `effect()` was tied to the `api.apps()` signal, which emits a new array reference on every SSE tick even when membership is unchanged — causing N parallel `/api/apps/<name>/errors` fetches per emission (1,690 in-flight requests observed during the post-publish smoke test). Replaced with two narrower effects: one keyed on a membership `computed` (refetches only when the app set changes), and a push-driven effect that watches `api.events()` and only refetches when an `error-new` / `error-recur` / `status` event arrives on the existing SSE stream. The dashboard now consumes the event stream instead of polling it via HTTP.
83
+ - **Parser captures real-world Nx serve failures.** v0.7's M33 patterns required a leading `>` decoration (`^\s*>\s+NX\s+.*failed`) — the actual `nx run …:serve` output omits it. Loosened the regex to `^\s*(?:>\s+)?NX\s+.*failed`, added new patterns for `Failed tasks:` and `Task "…" is continuous but exited with code N`, and updated the nx tool-routing regex to recognize the same shapes. New fixture `test/fixtures/parsers/nx-serve-fail.{log,expected.json}` covers the workspace-realistic case where the failure signal lands without a structured `file/line/col`. Resolves the v0.8.0 status/errors disagreement where an app's status flipped to `error` (via process exit code) but the Errors tab said "No errors".
84
+ - **Nav-rail tooltip dismisses on click.** Material tooltip persisted on the just-clicked rail link because the link kept focus through the route change, leaving a stuck "g l" / "g e" floater after keyboard or mouse navigation. Added `matTooltipHideDelay="0"`, `matTooltipShowDelay="300"`, and an explicit `blur()` on click.
85
+
86
+ ### Changed
87
+
88
+ - `parser-corpus.test.mjs` gains a branch for fixtures whose `expected.errors` is empty — it now asserts the failure signal lands (status flips, at least one error entry is recorded) but does not require a parsed file/line/col.
89
+
7
90
  ## [0.8.0] — 2026-05-20
8
91
 
9
92
  Strategic theme: **Mature daimon.** v0.5–v0.7 added enormous surface; v0.8 turns inward to polish the surface and harden the internals — a big CLI polish, a reliability pass, self-observability, and a plug-in surface for doctor rules, plus a first-class Tests page that finally lands part of the v0.7.1 dashboard-test debt (H3 contrast audit deferred again to v0.8.1).
package/README.md CHANGED
@@ -16,10 +16,57 @@ After install, `daimon` is on your PATH globally.
16
16
 
17
17
  ```bash
18
18
  daimon init # interactive scaffolder; writes ./daimon.config.json or ~/.daimon/config.json
19
- daimon list # auto-spawns the daemon on first call
19
+ daimon list # auto-spawns the daemon on first call (defaults to cwd-scoped — pass --all for every workspace)
20
20
  daimon daemon status
21
21
  ```
22
22
 
23
+ ## Multi-agent / multi-workspace (v0.9)
24
+
25
+ A single daimon daemon on `127.0.0.1:4999` serves every workspace on your machine. Two agents (e.g. two Claude Code sessions in different repos) can use the same daemon without stepping on each other:
26
+
27
+ ```bash
28
+ # In repo A:
29
+ daimon list # only A's apps
30
+ daimon start editor # cwd disambiguates which "editor"
31
+
32
+ # In repo B (concurrent, different terminal):
33
+ daimon list # only B's apps
34
+ daimon start editor # B's editor — even though A also has one
35
+
36
+ # To see every workspace's apps:
37
+ daimon list --all
38
+
39
+ # Manage the workspace registry directly:
40
+ daimon workspaces list
41
+ daimon workspaces add /path/to/another-repo --label other
42
+ daimon workspaces show # which workspace covers cwd?
43
+
44
+ # Open the dashboard scoped to the current cwd:
45
+ daimon dashboard # opens http://127.0.0.1:4999/?cwd=<cwd>
46
+ ```
47
+
48
+ When two workspaces register apps with the same name, daimon stores the second under `<name>@<workspaceLabel>` so both coexist. CLI commands resolve from `process.cwd()`; a 412 `name-collision` body with candidate workspaces is returned only when no cwd disambiguates.
49
+
50
+ ## Three signal classes: errors, warnings, lint
51
+
52
+ Errors flip app status to `error`. Warnings (TS6133, NG8107, deprecation notes) are surfaced as a separate signal class — they do not flip status. **Lint findings** (eslint, biome, ruff, clippy) are a third channel: parsed from the dev-server log stream, never spawn a linter, never flip status, and live behind a dedicated severity chip on the Errors page.
53
+
54
+ ```bash
55
+ daimon errors editor # errors only (back-compat default)
56
+ daimon errors editor --level warning
57
+ daimon errors editor --level lint
58
+ daimon errors editor --level all
59
+ ```
60
+
61
+ ## Unified event timeline
62
+
63
+ `daimon timeline` and the dashboard `/timeline` route merge status, errors, warnings, lint, health, bundle, compile, and task-run rows into one chronological stream:
64
+
65
+ ```bash
66
+ daimon timeline --since 7d --kinds status,error,lint
67
+ daimon timeline --app editor --since 24h
68
+ ```
69
+
23
70
  Config lookup order:
24
71
 
25
72
  1. `./daimon.config.json` (cwd)