Commit Graph
150 Commits
Author SHA1 Message Date
kyleandClaude Opus 5.5 a15c428ea6 tests: every temporary path is removed by a guard; no leftovers in /tmp
About 10,000 test leftovers had built up in titan's /tmp. loopd's Home
and FakeServer, its fake broker's socket, bxctl's temp sockets, fake
loopd and command homes, inferproxy's socket, and a few brokerd and
toolkit tests created uniquely named directories or sockets and never
removed them, or removed them by hand at the end, which a failing test
skips. Each is now a guard removed on drop (bxctl gains
tests/support/temp.rs). Two races also left gatewayd homes behind: the
test Running only signalled its server to stop, and two Stage structs
declared the home first, so it was removed while the server could still
write into it. Running's drop now waits for the thread (with a 5-second
limit), and every home is declared last.

Checked: make gate twice, then the gate and three rounds of gatewayd and
loopd tests; no new entry in /tmp; 944 tests pass.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-26 01:29:32 -07:00
kyle e963ef72bb memoryd: note answers name notes.md and the file that was not changed 2026-09-25 20:32:29 -07:00
kyleandClaude Opus 5.5 7b95937c88 brokerd: the ledger raises a session's state by the stricter label
M5a task 21. The work is Ornith's, from the stopped run; the design
model checked it against the task file and committed it after finding
that the gate's failure came from its own reference worktree's stale
test binaries in the shared target/ (fixed with cargo clean; 944 tests).

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-25 20:20:48 -07:00
kyle 34dbbb27be memoryd: a staged write's id counts every write staged that day 2026-09-25 16:41:44 -07:00
kyle 81107bc5c6 proto, memoryd: no line of an entry may start with §, and headers are exact
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:44 -07:00
kyle 3640d32de0 memoryd, proto, brokerd, bxctl: repeated error lines written once
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:44 -07:00
kyle b98f373ead memoryd: the day and the month of a time with get, never a slice
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:44 -07:00
kyleandClaude Opus 5.5 1adce5c9df brokerd tests: a slow fake podman no longer fails the time-limit tests
The fake wrote each argument with its own printf. On a loaded machine
(titan, serving Ornith while the gate runs) the 300 ms limit fired while
`run` was still recording, and the `kill` call's lines landed inside
`run`'s: `a_tool_past_its_time_limit_is_killed_removed_and_failed`
failed about one run in five. The fake now writes each call to a file of
its own and appends it with one `cat` (bash's printf writes line by
line), and the two time-limit tests check the calls other than `run`,
which may be killed before it records itself. Test-only; 20 of 20 runs
pass, and both tests pass with a forced one-second start.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-25 16:41:44 -07:00
kyleandClaude Opus 5.5 7d5c5a8d85 gate: pass on macOS: tests use /tmp, gatewayd finds its uid without /proc
M5a task 16. The work is Ornith's, from the stopped run; the design
model checked it against the task file and committed it once the
memoryd lint that stopped the gate was fixed (44bdcbd).

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-25 16:41:44 -07:00
kyleandClaude Opus 5.5 d47fb32483 memoryd: a match guard, not an if in the arm (clippy 1.95)
Clippy 1.95's collapsible_match flags the nested `if` in the
`LogRecord::User` arm of `index_record`, and the workspace pins
rust-version 1.95, so `make gate` failed on titan. An empty user message
now falls to the `_ => {}` arm, which indexes nothing, as before.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-25 16:41:44 -07:00
kyleandClaude Opus 5.5 6f093fcd8e M5a task 15: the starter soul and device checks with memoryd, finished
The session did the task and stopped on make verify-device. The cause
was not the server: run-plan.sh and the device tests both read
BOXMAKER_MODEL, and the run's value (OpenCode's provider-prefixed id)
reached llama-server as the model name. With it unset, verify-device
passes 6 of 6. The copied files are identical to the plan's, and the
gate prints gate: ok, 936 tests.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-25 16:41:44 -07:00
kyle 0a1c206d50 bxctl: reindex, and memory log, undo, pending, accept, reject
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:44 -07:00
kyle 15ee4b8e3d loopd: the memory block from memoryd, recall and memory as core tools
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:44 -07:00
kyle e167fc871b brokerd: memory calls to memoryd with the session's state; labels only stricter
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:44 -07:00
kyle fcfd590687 brokerd: recall and memory, decided under built-in grants
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:44 -07:00
kyle 0c8d136c6b memoryd: serve, three sockets and one lock over the files and the index
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:44 -07:00
kyle 49af057c81 memoryd: recall, with source tags and the recall log
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:44 -07:00
kyle f329d23bd9 memoryd: the FTS5 index over session logs and notes, with labels
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:44 -07:00
kyle b1c9d590c8 memoryd: the edit journal, undo of the latest edit, and review
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:44 -07:00
kyle b51b320706 memoryd: notes.md, and the five memory actions with routing by trust
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:44 -07:00
kyle f5981338b4 memoryd: the memory files, and the block a new session starts with
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:44 -07:00
kyle ad5ce5c6e7 memoryd: entries, and the check on every memory write
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:44 -07:00
kyle b84b9af540 memoryd: the crate, memoryd.toml, and listening on a socket
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:44 -07:00
kyle 964bd99b12 proto: memory, the arguments of recall and memory and eight message kinds
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:35 -07:00
kyle 861ff7d06a brokerd: policy and ledger as modules, before the memory tools
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 16:41:35 -07:00
kyleandClaude Opus 5.5 d80b0b3d8a gatewayd: serve_answers waits for every reply it reads
nobody_else_and_nothing_else_answers_it read five replies after
waiting only for the first, so it failed whenever the other four were
not posted yet. It failed once in a full `make gate` run, when many
test binaries ran at once. The helper now waits for as many posts as
the test reads.

The M4b plan's copy is left as it was handed over.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-24 14:56:58 -07:00
kyleandClaude Opus 5.5 a43d9979c8 gatewayd: serve_restart takes the two caught-up turns in either order
The two posts caught up at restart are two top-level posts, so two
sessions, and their turns run on their own threads. gatewayd starts
them in order, but which one reaches loopd first is up to the
scheduler. Under load the test failed about 1 run in 60; task 18's
session hit it once. mm_json.rs already checks the order of catch-up
(reversing the sort fails there), so this test now compares the two
turns as a set. It passed 100 of 100 runs under load.

The M4a plan's copy is left as it was handed over.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-24 12:22:10 -07:00
kyle e10d93c3e8 gatewayd: approvals asked by non-approvers in direct messages go to an approver
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 12:07:06 -07:00
kyle 989548419d gatewayd: the texts that say who asked for a redirected approval
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 11:51:43 -07:00
kyle bf89512832 brokerd: the refusal without a runner names the missing [runner] section
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 11:48:49 -07:00
kyle edf9ba3515 gatewayd: approvals answered from Mattermost; typing paused; the notice
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 10:19:41 -07:00
kyle c38e450f44 gatewayd: serve, posting approvals, marking them, and the listener
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 05:07:50 -07:00
kyle a33ff240c4 gatewayd: gateway, the gateway.sock listener and one thread per connection
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 04:59:02 -07:00
kyle 07e4e16270 gatewayd: state, the posts of open approvals, and the turn of a session
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 04:50:54 -07:00
kyle c5df86d13d gatewayd: approvals, the registry and the judging of commands
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 04:48:06 -07:00
kyle d9f8fa9331 gatewayd: approvals::text, the posts that show an approval
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 04:42:37 -07:00
kyle 18791ab389 gatewayd: mm, patch_post and username
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 04:36:45 -07:00
kyle 365e50081d gatewayd: strip a leading mention of this bot; recognise approval commands 2026-09-24 04:33:03 -07:00
kyle b45ca14c14 gatewayd: config, [approvals] users and socket
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 04:28:26 -07:00
kyle e0560ab996 brokerd: courier, carrying pending approvals to gatewayd and answers back
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 04:25:07 -07:00
kyle 412f80c470 brokerd: config, [gateway] socket for Mattermost approvals 2026-09-24 04:18:04 -07:00
kyle a00711e379 brokerd: answers carry the Mattermost post; Table::contains
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 04:15:11 -07:00
kyle a5c37d8756 bxctl: deny, another name for refuse
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 04:11:01 -07:00
kyle ebb78e816d proto: gateway, the four messages between brokerd and gatewayd
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 04:07:46 -07:00
kyle db3f9ed01b proto: escape, moved from bxctl so gatewayd shows the same thing
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 04:01:03 -07:00
kyle 10c80b74f3 gatewayd: read a secret file from the file that was checked
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 01:33:36 -07:00
kyleandClaude Opus 5.5 0081f24b70 gatewayd: strict status lines and chunk lines; no as casts (M4a review, findings 1 and 3)
A status line splits on single spaces only, and every chunk line must end in CRLF. The bounded
`as` casts in http.rs, handshake.rs and proto's sha1.rs become try_from and from.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-24 01:23:51 -07:00
kyle 09b074c121 gatewayd: main, serve --config with its start checks
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 01:00:22 -07:00
kyle ed361db718 gatewayd: serve, the event loop, typing, catch-up and reconnecting
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-24 00:55:58 -07:00
kyle d1d8531495 gatewayd: deliver, turns on loop.sock and answers posted in their thread
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-23 21:34:34 -07:00