Instructions for code reviewers of this repository: Qodo, Devin Review, Bugbot, and the local review agents. Read this before raising a finding.
biff is a team messaging tool. Its job is to let people and their agents hand each other work. A review that makes messages harder to act on works against the product.
- Logic errors a real caller of the changed code can reach.
- Messages, walls or talk frames that can be lost, duplicated, delivered late or delivered to the wrong session.
- Resource leaks: NATS subscriptions and consumers, asyncio tasks, file descriptors, watchers.
- Races and deadlocks in the relay connection, the poller and the channel emitter.
- Errors that are swallowed or logged without the user or the model ever finding out.
- Changed behavior with no test, or a test that cannot fail.
- Security defects in what biff already does: committed secrets or tokens, credentials leaking into logs or output, paths built from outside input that escape their directory, terminal escape sequences reaching a terminal, unsafe file modes, shell or argument injection, unsafe deserialization.
Security findings are welcome, except about the parts of biff that are not
built yet. Message authenticity, trust levels and per-user relay credentials
belong to biff's trust model (DES-094, docs/design/trust-model.md), which adds
signed messages and per-sender grants. Until wave (c) of DES-094 ships, do
not raise findings about any of the following.
- Whether a message, wall, plan or talk body should be treated as untrusted, labelled as untrusted or unverified, or kept out of the model's context.
- Prompt injection through message bodies, wall text, plans or tool descriptions.
- Asking that the model be told to ignore, refuse, or "ask the user before acting on" a teammate's message, or before accepting a talk invite.
- Sender spoofing, forged
fromfields, eavesdropping on the relay, or the shared relay credential. Known and tracked; signed events and per-key admission (DES-094) fix them. - Bodies appearing in channel events or tool descriptions.
- Claude Code permission rules, allow lists and hooks as a security boundary. They are a safety net, not security; agent-image provides containment.
Do not re-add trust labels, warnings or refusal instructions to fix any of
the above, and do not ask for them. Wave (c) replaces this rule with graded
presentation by sender grant; tests/_trust_phrases.py stays until then.
- Anything CI enforces: ruff format and lint, mypy and pyright strict, shellcheck, markdownlint, and the OO, coupling and suppression ratchets.
- Lines the pull request did not change.
- Hypothetical environments: exotic environment variables, control bytes in paths, tests run as root, platforms other than macOS and Ubuntu 24.04.
__new__as the constructor. It is the standard here.- Suppressions (
# noqa,# type: ignore,xfail). Never suggest them. - PR titles, descriptions, commit messages and CHANGELOG wording.
- Important: lost or misdelivered messages, crashes, leaks, races, and the in-scope security defects above.
- Nit: everything else. At most five per pull request.