Repository navigation
Description
laptop-agent daemon source reconciliation — prerequisite for M2 (#5769)
Found by task 16852 revalidation (lane code-d, 2026-11-14): the M2 remainder ("land the laptop-agent services-layer definition in the code flake deploy registry") cannot be done honestly yet, because the daemon source is not in the code repo, and the copies that exist have diverged into two lineages:
- Live lineage:
~/tools/laptop-agent-daemon.py(home repo, canonical) == laptop~/laptop-agent/laptop_agent.py— carries the 2026-11-10 timeout semantics (per-exec process groups, disconnect reap) and trip logging v1 + v2 (code#5702, 2026-11-14). This is what actually runs (systemd user unit, :4799). - Vendored lineage:
dezren39/darwin-nixpkgs/laptop-agent/src/laptop_agent.py(the package PR ops(dashboard): daily backups of dashboard/orchestration logs + stores — laptop, Google Drive, R2 #1459 builds) — carries features the live daemon lacks: job metadata persisted next to output with the index rebuilt on startup, and startup failing closed when the token is missing/empty/whitespace. It lacks the timeout semantics and trip logging. - Diff size at finding time: 1151 lines between the two
laptop_agent.pyfiles. Neither is a superset of the other. - The code repo itself contains no daemon source: the
dezren39-nix/tree inside a code checkout is a nested clone, not tracked code-flake source, sopkgs/deploycannot reference it (a fresh code clone would not have it).
Work: reconcile the two lineages into ONE daemon source (union of: persisted job index + fail-closed token startup from the vendored side; process-group timeout semantics + trip logging v2 from the live side), vendor that source into the code repo (e.g. pkgs/laptop-agent/src/, following the darwin-nix package shape), prove behavior parity with a real client round-trip against the live daemon's surface (exec, jobs, cancel, health), and only then does the M2 definition + cutover sequence in #5769 become executable.
Until this lands, #5769's acceptance (one definition, cutover with rollback evidence) stays open; the brokers' definitions already exist in pkgs/deploy/services.nix and are unaffected.
Activity
developing-today commentedon Nov 14, 2026
CODE-3561
dezren39 commentedon Nov 17, 2026
Triage — task 19107, lane any-i, 2026-11-16: first triage of record for #10131. State: triaged; routed to implementation follow-on task 20480.
Fresh verification (gh + laptop, 2026-11-17T06:40Z):
Triage verdict:
Labels applied: priority/high, effort/l, status/triaged.
dezren39 commentedon Nov 17, 2026
Agent note — picked up (lane any-f, task 20480)
State: claimed — implementing the reconciliation in this session, following the triage of record (task 19107, lane any-i).
Plan: (1) fetch both lineages and verify the live copies against each other (sandbox ~/tools/laptop-agent-daemon.py vs laptop ~/laptop-agent/laptop_agent.py); (2) three-way feature inventory from the diff; (3) union source on the live lineage as base (it is the operational truth) with the vendored features ported in (persisted job index, fail-closed token startup, plus anything else the inventory finds); (4) vendor into pkgs/laptop-agent/ in the code repo following the darwin-nix package shape; (5) parity round-trip against the reconciled source run on a test port (health, exec, jobs, cancel, plus restart persistence of the job index). The live daemon on :4799 is not touched by this task.
Merge pull request #11015 from developing-today/queue/20480-10131-lap…
dezren39 commentedon Nov 17, 2026
DONE — task 20480, lane any-f. Laptop-agent daemon source reconciliation landed in PR #11015 (merged; merge sha
bc1705fc4cc2a93b2eecb095ea0250cf5b1b0506).pkgs/laptop-agent/src/laptop_agent.pycarrying both lineages' feature sets — live: process-group timeout/cancel/disconnect semantics, trip logging v2,/file; vendored: persisted job index, fail-closed startup, framing 400s, job summaries, spool reaping, lifetime job slots, bytes-space auth — withpackage.nixin the darwin-nix shape./fileranges, restart persistence,trips.jsonl) passes in full. Both test files are vendored underpkgs/laptop-agent/tests/.