docs(adr)+fix(hooks): the session-mail channel is wired, and four places still called it a prototype (BACKLOG #1215) - #604
Merged
Conversation
…ces still called it a prototype (BACKLOG #1215)
ADR 0161's status line said the mail-drain code was "a prototype and is
deliberately NOT WIRED". It is wired. Measured three ways, each failing
differently:
source install-coordination.ps1 carries drain rows for SessionStart
and Stop -- the same rows the ADR says "stay exactly as they
are"
installed TWO installed config roots carry mail-drain.ps1, each at BOTH
events, so a config root HAS been installed from them
observed the drain fired during a real session and reported on that
session's own inbox by path
The brief named two files. A census found the same false claim in four,
one of them shipped code and one a test docstring -- neither reachable
from the two the brief named:
docs/adr/0161 the status line and the "what gates wiring" section
mail-drain.ps1:257 "this channel is deliberately not wired", inside the
hook that is wired. Its ARGUMENT survives: the idiom is
duplicated because announce-session.ps1 ends in exit 0 and
cannot be dot-sourced. Only the reason given was false.
test_session_mail.py:5 the module docstring a reader starts from
The ADR's false paragraph is CORRECTED IN PLACE rather than deleted. It was
true when written, the gating argument still stands, and a reader needs to
see what changed. What remains accurate is stated too: wiring was meant to
be a separate owner-approved step gated on #1028, and nothing records that
approval -- so the open question is not whether it is wired but whether it
was wired through the gate the ADR describes.
WHAT THIS COMMIT DOES NOT DO, deliberately.
It does not move the ADR off `Proposed`. That is a disposition, and an
owner's.
It does not edit the decision box at the tail into agreement with reality.
That box records "DECIDED 2026-08-06: NOT WIRED" for the urgent asyncRewake
tier -- and mail-watch.ps1 IS wired at Stop in both installed roots, with a
row at install-coordination.ps1:305. So SESSION-MAIL.md's sibling claim,
that the tier "is not wired and is not in the installer's wiring table", is
false on both halves. Either the decision changed and the record did not, or
the tier was wired without it. The contradiction is recorded beside the
decision and routed to the owner. A decision that flips as a side effect of
a docs fix is indistinguishable in the diff from one that was made.
It does not touch SESSION-MAIL.md. That is the operator-facing document, its
false claim is about the urgent tier rather than the drain, and correcting it
would bake in an answer to the question above.
ONE THING WORTH RECORDING FOR THE NEXT READER. A grep for "not wired" also
matches test_announce_wiring.py:266 -- which is the MESSAGE of an assert
whose condition asserts the drain IS wired. The string is only reachable
when the assertion fails, so its presence is evidence the suite checks the
opposite of what the grep implies. That test was already correct and was
left alone.
Verified: 138 passed across test_session_mail.py, test_announce_wiring.py and
test_announce_hook.py; ruff clean on the touched test.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
wshallwshall
enabled auto-merge (squash)
August 25, 2026 23:19
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
ADR 0161 said the mail-drain code was "a prototype and is deliberately NOT WIRED." It is wired --
measured three ways that fail differently: the installer carries SessionStart and Stop rows; two
installed config roots carry the hook at both events; and the drain fired in the filing session and
reported on its inbox by path. The brief named two files; a census found the same false claim in
four, including the hook's own comment and the test module docstring.
Three things this deliberately does NOT do, each stated so the next reader doesn't assume otherwise:
Proposed-- that is a disposition and the owner's to make.the urgent asyncRewake tier, and
mail-watch.ps1IS wired at Stop in both roots(
install-coordination.ps1:305). The contradiction is recorded beside the decision and routed tothe owner through the Dispatcher, not resolved here.
SESSION-MAIL.md, which carries the same false claim about that same unsettledtier.
One review note: a grep for "not wired" over this change's territory also hits
tests/test_announce_wiring.py:266-- that is the message of an assert whose condition asserts thedrain IS wired, reachable only when the assertion fails. That test was already correct and is
untouched here.
Verified: 138 passed across
test_session_mail.py,test_announce_wiring.pyandtest_announce_hook.py-- driven as subprocesses against throwaway repos, so it exercises the realhook. ruff clean on the touched test.
Built by Builder1, opened by Lander.
🤖 Generated with Claude Code