Development record
2026-07-14 (M1) — iss-95: wiring the hook does NOT by itself start the clock. `history.
2026-07-14 (M1) — iss-95: wiring the hook does NOT by itself start the clock. history. Capture requires ~/.abcd/history/<root-sha>/transcripts/ to already exist and
deliberately never creates it (the ownedDirsReal symlink-safety discipline); ahoy install bootstraps it. On a machine where install has not run — INCLUDING THIS ONE,
where ~/.abcd/ does not exist — hook session-end fails closed, logs to stderr, exits
0, and captures nothing, silently. That is exactly itd-89's failure mode (a hook that
looks wired while the corpus never accrues). Decision owed: hook self-bootstraps (changes
Capture's precondition and has the hook create dirs, which the symlink discipline avoids)
vs. ahoy install stays the sanctioned bootstrap and the not-installed case is made LOUD
(ahoy doctor already flags history.bootstrap_missing). iss-96 records the adjacent point:
automatic capture makes the scanner's secret-pattern coverage load-bearing — it catches
anchored tokens (AKIA…, ghp_, sk-ant-) and home paths but not unanchored high-entropy
values (a bare 40-char AWS secret, a prefixless token), so consider entropy detection or
the gitleaks adapter for the transcript path.
Frontmatter
| id | dcn-2607140000000008 |
|---|---|
| type | decision |
| date | 2026-07-14 |
.abcd/work/decisions/dcn-2607140000000008-iss-95-wiring-the-hook-does-not-by.md
open on GitHub ↗ · commit history ↗
mentions3
- iss-95Wiring the Stop hook does NOT by itself start the transcript clock: history.Capture requires ~/.abcd/history/<root-sha>/transcripts/ to already exist and deliberately never creates it (ownedDirsReal validates the store's dirs are real, not symlinks). That dir is bootstrapped by 'abcd ahoy install'. On a machine where install has not run — including this one, where ~/.abcd/ does not exist at all — 'hook session-end' fails closed, logs to stderr, exits 0, and captures NOTHING. Silently. That is precisely the failure mode itd-89 exists to prevent: a hook that appears wired while the corpus never accrues. Decide: (a) the hook bootstraps the store itself (changes Capture's stated precondition, and a hook creating dirs is a trust-boundary act the ownedDirsReal discipline deliberately avoids), or (b) 'ahoy install' stays the sanctioned bootstrap and the not-installed case is made LOUD rather than a stderr line nobody reads (e.g. ahoy doctor already flags history.bootstrap_missing as a required gap). Until this is settled, itd-89's acceptance is met in code but not on any machine that has not installed.
- iss-96Now that transcripts are captured automatically on every session end, the scanner's secret-pattern coverage becomes load-bearing in a way it was not when capture was a manual verb nobody ran. Verified by live test: the bundled patterns DO catch anchored tokens (AKIA... access key IDs, ghp_/gho_/sk-ant- style prefixes) and absolute home paths, but they do NOT catch unanchored high-entropy values — an AWS SECRET access key (the 40-char base64 value, no prefix), a bare password, or a generic API token with no recognisable prefix all pass through into the store verbatim. This is the standard prefix-matching limitation and is pre-existing, not a regression; the point is that the blast radius changed. Consider entropy-based detection or the opt-in gitleaks adapter for the transcript path specifically, where the input is unstructured prose rather than curated source.
- itd-89Capture the Session You Just Had, Because You Cannot Capture It Later