instar 1.3.1193 → 1.3.1195

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,7 +2,7 @@
2
2
  "schemaVersion": 1,
3
3
  "generatedFrom": "source-tree",
4
4
  "registrySha256": "8e6606a6722433c5ffc15b3870402283c5406083a14cdbd0e18e735731e2aae2",
5
- "packageVersion": "1.3.1193",
5
+ "packageVersion": "1.3.1195",
6
6
  "guards": [
7
7
  {
8
8
  "ref": "docs/audits/phase-b/f10-triage.md",
@@ -1,5 +1,5 @@
1
1
  {
2
- "sha256": "f0abeb280648b0f2918db12357309dcd45d2e6adfff2c41063df273544496145",
2
+ "sha256": "b4c9f07f239e4f4783980209f1e4895e84571b3925b720346a8922f6ac34ca6a",
3
3
  "registrySha256": "8e6606a6722433c5ffc15b3870402283c5406083a14cdbd0e18e735731e2aae2",
4
- "packageVersion": "1.3.1193"
4
+ "packageVersion": "1.3.1195"
5
5
  }
@@ -2,5 +2,5 @@
2
2
  "sha256": "8e6606a6722433c5ffc15b3870402283c5406083a14cdbd0e18e735731e2aae2",
3
3
  "articleCount": 90,
4
4
  "generatedFrom": "docs/STANDARDS-REGISTRY.md",
5
- "packageVersion": "1.3.1193"
5
+ "packageVersion": "1.3.1195"
6
6
  }
@@ -1 +1 @@
1
- {"version":3,"file":"OpenClawBridge.d.ts","sourceRoot":"","sources":["../../src/threadline/OpenClawBridge.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,iBAAiB,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AACjF,OAAO,KAAK,EAAE,YAAY,EAAoB,MAAM,mBAAmB,CAAC;AACxE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAK9D,MAAM,WAAW,eAAe;IAC9B,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE;QA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nC,OAAO,CAAC,gBAAgB;IAwBxB,OAAO,CAAC,oBAAoB;IA4C5B,OAAO,CAAC,mBAAmB;IAkD3B,OAAO,CAAC,kBAAkB;IAwD1B;;;OAGG;IACH,OAAO,CAAC,oBAAoB;IAK5B;;;OAGG;IACH,OAAO,CAAC,kBAAkB;IAO1B;;;;OAIG;IACH,OAAO,CAAC,aAAa;CA2BtB"}
@@ -15,12 +15,39 @@
15
15
  * No external SDK dependency — OpenClaw interfaces are defined locally and
16
16
  * all dependencies are injected via config.
17
17
  */
18
+ import { randomBytes } from 'node:crypto';
18
19
  // ── Constants ──────────────────────────────────────────────────────────
19
20
  /** Default trust level for agents arriving via OpenClaw */
20
21
  const DEFAULT_TRUST_LEVEL = 'untrusted';
21
22
  /** Default token estimate per message when actual count is unavailable */
22
23
  const DEFAULT_TOKEN_ESTIMATE = 500;
23
24
  // ── Implementation ─────────────────────────────────────────────────────
25
+ /**
26
+ * Mint a threadId for a (room, agent) pair.
27
+ *
28
+ * THE CLOCK IS NOT AN IDENTIFIER. The first version was
29
+ * `openclaw-${roomId}-${Date.now().toString(36)}` — no agent component and no
30
+ * entropy, so its ONLY distinguishing input was the millisecond. Two different
31
+ * agents resolving a thread in the SAME room within the same millisecond
32
+ * received the SAME threadId, and `ContextThreadMap`'s reverse index then
33
+ * collapsed both agents onto one thread. That is not a cosmetic collision:
34
+ * isolation between two agents' conversations in a shared room is exactly what
35
+ * the threadId is for, so the failure mode is one agent addressing another's
36
+ * thread.
37
+ *
38
+ * It surfaced as an intermittent e2e failure (Scenario 8, 2026-08-23) because
39
+ * it needs two calls inside one millisecond — a race that gets MORE likely as
40
+ * the code gets faster, which is the wrong direction for a correctness property
41
+ * to move in. Fixed with real entropy rather than by spacing the calls out: a
42
+ * uniqueness property that depends on how fast the caller runs is not a
43
+ * property.
44
+ *
45
+ * The timestamp is kept for readability and rough ordering. Uniqueness comes
46
+ * from the random suffix, never from the timestamp.
47
+ */
48
+ function newThreadId(roomId) {
49
+ return `openclaw-${roomId}-${Date.now().toString(36)}-${randomBytes(8).toString('hex')}`;
50
+ }
24
51
  export class OpenClawBridge {
25
52
  config;
26
53
  roomToThread;
@@ -319,7 +346,7 @@ export class OpenClawBridge {
319
346
  return { threadId: existingThreadId, isNewThread: false };
320
347
  }
321
348
  // Create new mapping — generate a threadId from the roomId
322
- const threadId = `openclaw-${roomId}-${Date.now().toString(36)}`;
349
+ const threadId = newThreadId(roomId);
323
350
  this.config.contextThreadMap.set(roomId, threadId, agentIdentity);
324
351
  this.metrics.threadsActive++;
325
352
  return { threadId, isNewThread: true };
@@ -330,7 +357,7 @@ export class OpenClawBridge {
330
357
  if (existingThreadId) {
331
358
  return { threadId: existingThreadId, isNewThread: false };
332
359
  }
333
- const threadId = `openclaw-${roomId}-${Date.now().toString(36)}`;
360
+ const threadId = newThreadId(roomId);
334
361
  this.roomToThread.set(key, threadId);
335
362
  this.metrics.threadsActive++;
336
363
  return { threadId, isNewThread: true };
@@ -1 +1 @@
1
- {"version":3,"file":"OpenClawBridge.js","sourceRoot":"","sources":["../../src/threadline/OpenClawBridge.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAmFH,0EAA0E;AAE1E,2DAA2D;AAC3D,MAAM,mBAAmB,GAAoB,WAAW,CAAC;AAEzD,0EAA0E;AAC1E,MAAM,sBAAsB,GAAG,GAAG,CAAC;AAEnC,0EAA0E;AAE1E,MAAM,OAAO,cAAc;IACR,MAAM,CAAuB;IAC7B,YAAY,CAAsB;IAC3C,OAAO,CAAwB;IAEvC,YAAY,MAA4B;QACtC,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,YAAY,GAAG,IAAI,GAAG,EAAE,CAAC;QAC9B,IAAI,CAAC,OAAO,GAAG;YACb,iBAAiB,EAAE,CAAC;YACpB,aAAa,EAAE,CAAC;YAChB,MAAM,EAAE,CAAC;SACV,CAAC;IACJ,CAAC;IAED,qEAAqE;IAErE;;;OAGG;IACH,UAA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C,MAAM,gBAAgB,GAAG,IAAI,CAAC,MAAM,CAAC,gBAAgB,CAAC,WAAW,CAAC,MAAM,EAAE,aAAa,CAAC,CAAC;YACzF,IAAI,gBAAgB,EAAE,CAAC;gBACrB,OAAO,EAAE,QAAQ,EAAE,gBAAgB,EAAE,WAAW,EAAE,KAAK,EAAE,CAAC;YAC5D,CAAC;YAED,2DAA2D;YAC3D,MAAM,QAAQ,GAAG,WAAW,CAAC,MAAM,CAAC,CAAC;YACrC,IAAI,CAAC,MAAM,CAAC,gBAAgB,CAAC,GAAG,CAAC,MAAM,EAAE,QAAQ,EAAE,aAAa,CAAC,CAAC;YAClE,IAAI,CAAC,OAAO,CAAC,aAAa,EAAE,CAAC;YAC7B,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,IAAI,EAAE,CAAC;QACzC,CAAC;QAED,iCAAiC;QACjC,MAAM,GAAG,GAAG,GAAG,MAAM,KAAK,aAAa,EAAE,CAAC;QAC1C,MAAM,gBAAgB,GAAG,IAAI,CAAC,YAAY,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;QACpD,IAAI,gBAAgB,EAAE,CAAC;YACrB,OAAO,EAAE,QAAQ,EAAE,gBAAgB,EAAE,WAAW,EAAE,KAAK,EAAE,CAAC;QAC5D,CAAC;QAED,MAAM,QAAQ,GAAG,WAAW,CAAC,MAAM,CAAC,CAAC;QACrC,IAAI,CAAC,YAAY,CAAC,GAAG,CAAC,GAAG,EAAE,QAAQ,CAAC,CAAC;QACrC,IAAI,CAAC,OAAO,CAAC,aAAa,EAAE,CAAC;QAC7B,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,IAAI,EAAE,CAAC;IACzC,CAAC;CACF"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "instar",
3
- "version": "1.3.1193",
3
+ "version": "1.3.1195",
4
4
  "description": "Coherence infrastructure for self-evolving AI agents — on the Claude Code or Codex subscription you already have.",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -565,22 +565,49 @@ function main() {
565
565
  const files = argv.filter((a) => !a.startsWith('--'));
566
566
  const targets = files.length ? files : listSpecFiles();
567
567
 
568
+ // ── The DENOMINATOR, reported beside the verdict (2026-08-23) ──────────
569
+ //
570
+ // WHY. On 2026-08-21 this gate was found to have been matching its section
571
+ // heading EXACTLY while spec authors had begun numbering theirs. It saw 91 of
572
+ // 149 posture-carrying specs and silently skipped 58 — printing "clean" about
573
+ // a corpus it had never read. Nobody made a mistake; the population drifted
574
+ // under the instrument, and there is no diff showing the moment it broke.
575
+ //
576
+ // The matcher was widened, which fixes THAT drift. This fixes the READING,
577
+ // which is the part that generalises: "clean" is a sentence nobody questions,
578
+ // and "clean — 0 findings across 149 spec(s), 91 carrying a posture section"
579
+ // is one somebody does. A shrinking denominator beside a reassuring word is
580
+ // the cheapest thing that would have surfaced the original bug without anyone
581
+ // auditing the matcher, and it costs a line.
582
+ //
583
+ // `unreadable` is counted rather than swallowed for the same reason: a file
584
+ // that could not be read is not a file with no findings.
568
585
  const allFindings = [];
586
+ let scanned = 0;
587
+ let withPosture = 0;
588
+ let unreadable = 0;
569
589
  for (const file of targets) {
570
590
  let text;
571
591
  try {
572
592
  text = fs.readFileSync(file, 'utf8');
573
593
  } catch {
594
+ unreadable += 1;
574
595
  continue;
575
596
  }
597
+ scanned += 1;
598
+ if (findPostureSection(text)) withPosture += 1;
576
599
  const { findings } = gradeMachineLocalMarkers(text);
577
600
  for (const f of findings) allFindings.push({ file: path.relative(ROOT, path.resolve(file)), ...f });
578
601
  }
602
+ const population = { scanned, withPosture, unreadable, findings: allFindings.length };
603
+ const denominator =
604
+ `${scanned} spec(s) scanned, ${withPosture} carrying a posture section` +
605
+ (unreadable > 0 ? `, ${unreadable} UNREADABLE` : '');
579
606
 
580
607
  if (json) {
581
- process.stdout.write(JSON.stringify({ findings: allFindings, strict }, null, 2) + '\n');
608
+ process.stdout.write(JSON.stringify({ findings: allFindings, population, strict }, null, 2) + '\n');
582
609
  } else if (allFindings.length === 0) {
583
- console.log('lint-machine-local-justification: clean — no undefended or malformed markers.');
610
+ console.log(`lint-machine-local-justification: clean — no undefended or malformed markers (${denominator}).`);
584
611
  } else {
585
612
  const header = strict
586
613
  ? 'lint-machine-local-justification: FINDINGS (strict — blocking):'
@@ -591,7 +618,7 @@ function main() {
591
618
  console.error(` ${f.message}`);
592
619
  }
593
620
  console.error(
594
- `\n ${allFindings.length} finding(s). Standard A: docs/STANDARDS-REGISTRY.md ` +
621
+ `\n ${allFindings.length} finding(s) — ${denominator}. Standard A: docs/STANDARDS-REGISTRY.md ` +
595
622
  `("An Instar Agent Is Always a Multi-Machine Entity").`,
596
623
  );
597
624
  }
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "$schema": "./builtin-manifest.schema.json",
3
3
  "schemaVersion": 1,
4
- "generatedAt": "2026-08-23T19:43:01.712Z",
5
- "instarVersion": "1.3.1193",
4
+ "generatedAt": "2026-08-24T01:00:22.148Z",
5
+ "instarVersion": "1.3.1195",
6
6
  "entryCount": 202,
7
7
  "entries": {
8
8
  "hook:session-start": {
@@ -2,7 +2,7 @@
2
2
  "schemaVersion": 1,
3
3
  "generatedFrom": "source-tree",
4
4
  "registrySha256": "8e6606a6722433c5ffc15b3870402283c5406083a14cdbd0e18e735731e2aae2",
5
- "packageVersion": "1.3.1193",
5
+ "packageVersion": "1.3.1195",
6
6
  "guards": [
7
7
  {
8
8
  "ref": "docs/audits/phase-b/f10-triage.md",
@@ -1,5 +1,5 @@
1
1
  {
2
- "sha256": "f0abeb280648b0f2918db12357309dcd45d2e6adfff2c41063df273544496145",
2
+ "sha256": "b4c9f07f239e4f4783980209f1e4895e84571b3925b720346a8922f6ac34ca6a",
3
3
  "registrySha256": "8e6606a6722433c5ffc15b3870402283c5406083a14cdbd0e18e735731e2aae2",
4
- "packageVersion": "1.3.1193"
4
+ "packageVersion": "1.3.1195"
5
5
  }
@@ -2,5 +2,5 @@
2
2
  "sha256": "8e6606a6722433c5ffc15b3870402283c5406083a14cdbd0e18e735731e2aae2",
3
3
  "articleCount": 90,
4
4
  "generatedFrom": "docs/STANDARDS-REGISTRY.md",
5
- "packageVersion": "1.3.1193"
5
+ "packageVersion": "1.3.1195"
6
6
  }
@@ -0,0 +1,34 @@
1
+ # Upgrade Guide — vNEXT
2
+
3
+ <!-- assembled-by: assemble-next-md -->
4
+ <!-- bump: patch -->
5
+
6
+ ## What Changed
7
+
8
+ `scripts/lint-machine-local-justification.js` reports its population beside its verdict — specs scanned, specs carrying a posture section, and unreadable files — on the clean path, the findings path, and as `population` in `--json`. Unreadable files are counted rather than skipped silently.
9
+
10
+ Zero behaviour change: no verdict, threshold or exit code moves.
11
+
12
+ ## What to Tell Your User
13
+
14
+ None — internal change (no user-facing surface).
15
+
16
+ ## Summary of New Capabilities
17
+
18
+ None — internal change (no user-facing surface).
19
+
20
+ ## Evidence
21
+
22
+ On 2026-08-21 this gate was found matching its section heading by exact text while authors had begun numbering theirs. It saw 91 of 149 posture-carrying specs, silently skipped 58 — including the replicated-store foundation, the mesh self-heal spec, the secure-pairing spec and the standards-registry spec — and printed `clean` about a corpus it had never read. Widening the matcher fixed that drift; this fixes the reading, which is the part that generalises to the next drift.
23
+
24
+ 40 tests, including the property the incident turned on: a one-file run and a two-file run must not print the same sentence. Also pinned: the denominator on the FINDINGS path (where a shrunken population is most dangerous — a reader sees findings and assumes the sweep was whole), and an unreadable file counted rather than swallowed.
25
+
26
+ First live output: `135 finding(s) — 1818 spec(s) scanned, 133 carrying a posture section`.
27
+
28
+ ## Known Limits
29
+
30
+ A denominator does not DETECT drift; it makes drift legible to a human reading the output. If nobody reads it, it buys nothing. An automated ratchet on the population would be the stronger control and is not built here.
31
+
32
+ The historical comment says 149 posture-carrying specs; this measures 133. **Drift is ruled out** — three independent methods (this lint, a peer's `git grep`, and a third regex pass) all return 133, including at `c465a94ef`, the widening commit itself, with the count unmoved across the two commits since. The population is not shrinking under the gate. What produced 149 remains unmeasured and no claim is made between the candidates.
33
+
34
+ No other gate in this repository was audited for the same defect, and nothing enumerates the gates that print a reassuring word with no scale.
@@ -0,0 +1,30 @@
1
+ # Upgrade Guide — vNEXT
2
+
3
+ <!-- assembled-by: assemble-next-md -->
4
+ <!-- bump: patch -->
5
+
6
+ ## What Changed
7
+
8
+ `src/threadline/OpenClawBridge.ts` mints thread ids with real entropy instead of a bare millisecond timestamp. The id was `openclaw-${roomId}-${Date.now().toString(36)}` — no agent component and no randomness — so two DIFFERENT agents resolving a thread in the SAME room within one millisecond received an identical threadId, and `ContextThreadMap`'s reverse index then collapsed both agents onto one thread. Isolation between two agents' conversations in a shared room is precisely what the threadId exists to provide.
9
+
10
+ The timestamp is kept for readability and rough ordering; uniqueness now comes from `randomBytes(8)`, never from the clock.
11
+
12
+ ## What to Tell Your User
13
+
14
+ If two of your agents talk in the same shared room, each keeps its own conversation thread — reliably now, rather than almost always. Previously the thread name was built from the room name and the clock alone, so two agents arriving in the same millisecond could be handed the same thread and their conversations would merge. Threads created before this change keep their existing names and are unaffected.
15
+
16
+ ## Summary of New Capabilities
17
+
18
+ No new capability. An existing guarantee — one thread per agent per room — now actually holds instead of holding whenever the two agents happened to be more than a millisecond apart.
19
+
20
+ ## Evidence
21
+
22
+ Caught as an intermittent failure of `tests/e2e/threadline/ThreadlineFullStack.test.ts` Scenario 8 on 2026-08-23: `expected 'openclaw-room-a-mt6h30po' not to be 'openclaw-room-a-mt6h30po'`. Both agents, one id.
23
+
24
+ The defect was already known and worked around rather than fixed. `tests/unit/threadline/OpenClawBridge.test.ts` carried a test named "different agents get different threads for same room" that passed only because of a `setTimeout(2)` inserted mid-test with the comment *"Small wait to ensure different Date.now() for threadId generation"*. The sleep bought the millisecond the id could not supply, so the assertion passed for a reason unrelated to the property it claims to check. The sleep is removed; that test now fails without the fix.
25
+
26
+ Two new frozen-clock regressions pin both sides of the boundary: two agents in one room at the same millisecond must get DIFFERENT threads, and the same agent re-entering must keep ONE thread (entropy must not leak into the reuse path and shatter continuity). Verified by reverting the fix: 2 of 89 fail, and only those 2. With the fix, 89/89.
27
+
28
+ ## Known Limits
29
+
30
+ `ContextThreadMap` keys mappings by contextId alone, with agent identity as a binding CHECK rather than part of the key. In a room shared by several agents the last writer's mapping is the one stored, so an earlier agent's lookup returns null and it mints a fresh thread. That is a separate design question about the map's key, not an id-uniqueness defect, and it is not addressed here.
@@ -0,0 +1,44 @@
1
+ # Saying how much was checked, not just that it passed — Plain-English Overview
2
+
3
+ ## The problem in one breath
4
+
5
+ A safety check in this project spent an unknown period reporting "clean" about documents it had never opened. It found the section it cared about by matching a heading word-for-word, and authors had started numbering their headings. It quietly saw 91 documents out of 149 and skipped 58 — including some of the most important ones — and said the same reassuring word it says when everything really is fine.
6
+
7
+ ## What already exists
8
+
9
+ That matching bug was fixed on the 21st. The check now finds numbered headings properly.
10
+
11
+ ## What this adds
12
+
13
+ The check now says **how much it looked at**, not only what it found.
14
+
15
+ Before: `clean`
16
+ After: `clean — 0 findings across 149 documents, 91 carrying the section we grade`
17
+
18
+ ## Why that matters more than it sounds
19
+
20
+ Fixing the matcher fixes that one drift. It doesn't fix the next one. The set of documents can shrink again for reasons nobody records, because no author does anything wrong — and the verdict stays the single most comforting word available.
21
+
22
+ "Clean" is a sentence nobody questions. "Clean, 91 of 149" is a sentence somebody does. A shrinking number next to a reassuring word is the cheapest thing that would have caught the original problem without anyone going and auditing the checker, and it costs one line.
23
+
24
+ ## The safeguards
25
+
26
+ **Nothing can newly fail.** Every verdict and exit code is identical; only the wording changes.
27
+
28
+ **A file that couldn't be opened is counted, not skipped.** A document that failed to load is not a document with no problems — silently dropping it is the same defect one level down.
29
+
30
+ **The tests pin the point, not the wording:** a run over one document and a run over two must not print the same sentence. That's the property the whole incident turned on.
31
+
32
+ ## What ships when
33
+
34
+ Immediately. Nothing to decide, no setting, no risk.
35
+
36
+ ## What you actually need to decide
37
+
38
+ Nothing — and the one loose number has since been chased down, which is worth reporting because it is the change doing its job.
39
+
40
+ On the first run the new count (133) disagreed with a number written in an old comment (149). The worrying reading was that sixteen documents had quietly lost the section nobody was checking. **That is now ruled out.** Two other people measured it different ways and both got 133 — including at the exact moment the old comment was written. Nothing has been slipping away.
41
+
42
+ What nobody has worked out is where 149 came from. A different branch, a different way of counting, or a number that was never right. Three possibilities, none of them picked, because guessing between them would be the same habit this change exists to break.
43
+
44
+ One small thing worth keeping: my own quick check first said 131, not 133. The difference was capital letters — two documents write "Posture" rather than "posture". Two measurements disagreeing is information; averaging them or taking the nicer one would have been exactly the mistake.
@@ -0,0 +1,35 @@
1
+ # Two agents in one room could end up sharing a conversation — Plain-English Overview
2
+
3
+ ## The problem in one breath
4
+
5
+ When two agents talk in the same shared room, each is supposed to get its own private conversation thread. The name of that thread was built out of the room name and the current time in milliseconds — and nothing else. Two agents entering the same room in the same millisecond got the *same* name, and their two conversations collapsed into one.
6
+
7
+ ## Why it hid for so long
8
+
9
+ It needs two things to happen inside one thousandth of a second, so it almost never fired. It failed once, at random, in an end-to-end test on 2026-08-23 — and would have gone on failing at random.
10
+
11
+ The uncomfortable part: it gets **more** likely as the code gets faster. A correctness property that erodes as you optimise is not a property.
12
+
13
+ ## The part worth reading twice
14
+
15
+ There was already a test for exactly this — "different agents get different threads for same room". It passed. It passed because someone had put a two-millisecond sleep in the middle of it, with a comment explaining that the sleep was there to make the timestamps differ.
16
+
17
+ So the defect was not undiscovered. It was **observed, described in a comment, and worked around** — and the test that would have caught it was converted into a test that could not. The sleep is gone; the test now depends on the fix.
18
+
19
+ ## What changes
20
+
21
+ The thread name gets real randomness in it. The timestamp stays, because it is useful to read, but nothing depends on it being unique any more.
22
+
23
+ ## The safeguards
24
+
25
+ **Two tests, both sides of the line.** With the clock frozen so that every timestamp is identical: two different agents in one room must get different threads, and the *same* agent coming back must get the *same* thread. The second matters — a fix that made every message unique would have bought uniqueness by destroying continuity.
26
+
27
+ **Both were checked against the un-fixed code** and both fail there, so they are tests rather than decorations.
28
+
29
+ ## What ships when
30
+
31
+ Immediately. It only affects threads created from now on; existing ones keep their names.
32
+
33
+ ## What you actually need to decide
34
+
35
+ Nothing.
@@ -0,0 +1,89 @@
1
+ # Side-Effects Review — the marker lint reports its population beside its verdict
2
+
3
+ **Version / slug:** `lint-reports-its-denominator`
4
+ **Date:** `2026-08-23`
5
+ **Author:** `echo`
6
+ **Second-pass reviewer:** `peer session (echo-fb, W24) — the structural remedy is theirs; the worked example is mine`
7
+
8
+ ## Summary of the change
9
+
10
+ `scripts/lint-machine-local-justification.js` now prints how many specs it scanned and how many carried a posture section, on both the clean and the findings path, and exposes the same counts as `population` in `--json`. Files it could not read are COUNTED, not skipped silently.
11
+
12
+ ## Why — the incident this is the reading-side fix for
13
+
14
+ On 2026-08-21 this gate was found matching its section heading by exact text while spec authors had begun numbering theirs (`## 8. Multi-machine posture`). It saw **91 of 149** posture-carrying specs and silently skipped **58** — including the replicated-store foundation, the mesh self-heal spec, the secure-pairing spec, and the standards-registry spec itself — while printing `clean` about a corpus it had never read.
15
+
16
+ From the fix's own comment: *"Nobody had to make a mistake; you just had to number your heading."*
17
+
18
+ Widening the matcher fixed **that** drift. It does not fix the next one. The population can shrink again for reasons no diff records, because no author does anything wrong — and the verdict stays the single most reassuring word available. `clean` is a sentence nobody questions. `clean — 0 findings across 149 spec(s), 91 carrying a posture section` is one somebody does.
19
+
20
+ ## Decision-point inventory
21
+
22
+ None. This changes only what the gate SAYS. Every verdict, threshold and exit code is byte-identical.
23
+
24
+ ## 1. Over-block
25
+
26
+ Impossible: no code path can newly fail. `--strict` still exits non-zero on exactly the same condition (`allFindings.length > 0`).
27
+
28
+ ## 2. Under-block
29
+
30
+ Unchanged, and worth being precise: a denominator does not detect drift. It makes drift **legible to a human who reads the output**. If nobody reads it, it buys nothing. It is deliberately not sold as a detector — an automated ratchet on the population would be the stronger control and is not built here.
31
+
32
+ ## 3. Level-of-abstraction fit
33
+
34
+ Three counters in the CLI's existing loop. No new file, no new invocation, no new dependency. It is one line of output.
35
+
36
+ ## 4. Signal vs authority compliance
37
+
38
+ Compliant and unchanged. The lint is a report-first signal; this makes the signal more honest about its own reach.
39
+
40
+ ## 4b. Judgment-point check
41
+
42
+ None. Three integers.
43
+
44
+ ## 5. Interactions
45
+
46
+ - `findPostureSection` is now called once more per file to count coverage. Pure, no I/O, negligible.
47
+ - The `--json` shape GAINS a `population` key. Additive; nothing reads it yet.
48
+ - The self-wiring contract does not pin this script, so nothing else moves.
49
+
50
+ ## 6. External surfaces
51
+
52
+ None.
53
+
54
+ ## 6b. Operator-surface quality
55
+
56
+ The operator never runs this. The audience is whoever reads a CI log — and the incident proves that reader was previously given a reassuring word with no scale attached.
57
+
58
+ ## 7. Multi-machine posture
59
+
60
+ `unified` — trivially. A pure counter in a stateless CLI.
61
+
62
+ ## 8. Rollback cost
63
+
64
+ Three counters and a string. Reverting restores a verdict with no scale attached, which is the condition the incident occurred under.
65
+
66
+ ## Conclusion
67
+
68
+ Ship. Zero behaviour change, one line of output, and it addresses the reading-side half of a defect that cost this repository 39% of its posture coverage for an unknown period.
69
+
70
+ ## Evidence pointers
71
+
72
+ - 40 tests, including: the denominator appears on the clean path AND the findings path (the failing path is where a shrunken population is most dangerous — a reader sees findings, assumes the sweep was whole, and never asks how far it reached); the JSON `population` shape; an unreadable file COUNTED rather than swallowed; and the property the incident turned on — **a one-file run and a two-file run must not print the same sentence**.
73
+ - First real output on the live corpus: `135 finding(s) — 1818 spec(s) scanned, 133 carrying a posture section`.
74
+
75
+ ## The discrepancy this surfaced on its first run — and what three instruments then established
76
+
77
+ The historical comment records **149** posture-carrying specs; this measures **133**. That gap was reported as fully unresolved when this branch was first pushed. It has since been narrowed by two further measurements, and the narrowing is recorded here rather than folded silently into the original text.
78
+
79
+ **DRIFT IS RULED OUT — the alarming reading is disconfirmed.** A peer session (echo-fb, W24) measured by an independent method (`git grep`, not this lint's regex) and got 133 at HEAD *and* 133 at `c465a94ef`, the widening commit itself, with only two commits touching `docs/specs` in between and the count unmoved. I then reproduced that with a third method: 133 at `c465a94ef`, 133 at `upstream/main`, control on an invented token 0, control on a common token 1811 of 1818.
80
+
81
+ So the count was **already 133 when the comment claiming 149 was written**. Sixteen specs did not silently lose their posture section.
82
+
83
+ **A 2-file disagreement between my third method and the other two, resolved rather than averaged.** My first pass returned 131. The difference is case: my throwaway regex was case-sensitive on the second word, while the lint's matcher carries `/i`. The two specs are `matrix-cell-operator-cancel.md` and `playwright-profile-registry.md`, whose headings capitalise "Posture". 133 is correct and matches the lint. Recorded because a two-instrument disagreement is information, and resolving it by preference would have been the error this whole change is about.
84
+
85
+ **Still unmeasured: what produced 149.** A different branch, a method nobody has guessed, or a figure that was never right. Three candidates, none distinguished, and no claim made between them. What is now measured is the part that mattered — the population is not shrinking under the gate.
86
+
87
+ ## Class-Closure Declaration (display-only mirror)
88
+
89
+ The class is "a verdict reported without its scale." Closed for this gate. NOT closed generally — no other gate in this repository was audited for it, and nothing enumerates the gates that print a reassuring word with no denominator. That sweep is the real work and is not done here.
@@ -0,0 +1,81 @@
1
+ # Side-Effects Review — thread ids stop depending on the clock for uniqueness
2
+
3
+ **Slug:** `openclaw-thread-id-collision`
4
+ **Date:** 2026-08-23
5
+ **Risk floor:** 2 (correctness fix in a cross-agent isolation path; no external surface)
6
+
7
+ ## Summary of the change
8
+
9
+ `OpenClawBridge` minted thread ids as `openclaw-${roomId}-${Date.now().toString(36)}`. Two different agents resolving a thread in the same room within one millisecond got the same id. A `randomBytes(8)` suffix is added; the timestamp remains for readability only.
10
+
11
+ ## Decision-point inventory
12
+
13
+ One: where uniqueness comes from. Previously the clock. Now entropy. No branch, threshold or policy is introduced.
14
+
15
+ ## 1. Over-block
16
+
17
+ None possible. The change cannot cause a refusal — it only widens the id space.
18
+
19
+ ## 2. Under-block
20
+
21
+ The relevant question is whether uniqueness can still fail. `randomBytes(8)` is 64 bits; a collision requires the same room, the same millisecond AND a 1-in-2^64 draw. This is no longer a timing property.
22
+
23
+ ## 3. Level-of-abstraction fit
24
+
25
+ Correct level. The id is minted in exactly two places, both in `resolveThread`, and both now call one helper — so the property has a single home rather than two copies that can drift.
26
+
27
+ ## 4. Signal vs authority compliance
28
+
29
+ Signal only. The id names a thread; it grants nothing and is not consulted for a decision.
30
+
31
+ ## 4b. Judgment-point check
32
+
33
+ None. No judgment is made from this value.
34
+
35
+ ## 5. Interactions
36
+
37
+ - **`ContextThreadMap`** keeps a reverse index `threadId → contextId`. Colliding ids were what let two agents collapse onto one thread, so this is the consumer the fix protects. Its keying (contextId alone, agent identity as a binding check) is a separate question, named under Known Limits and NOT changed here.
38
+ - **Existing threads** keep their ids; the map is not rewritten. Old ids remain valid and resolvable.
39
+ - **Length** grows by 17 characters. No downstream store bounds the id.
40
+
41
+ ## 6. External surfaces
42
+
43
+ None. No route, no message, no notification.
44
+
45
+ ## 6b. Operator-surface quality
46
+
47
+ Invisible to the operator, except that the intermittent CI failure stops.
48
+
49
+ ## 7. Multi-machine posture
50
+
51
+ `unified`. Ids are minted per-process and were never coordinated across machines; adding entropy makes a cross-machine collision strictly less likely rather than more.
52
+
53
+ ## 8. Rollback cost
54
+
55
+ One line. Reverting restores a race that gets more likely as the code gets faster, which is why it should not be reverted quietly.
56
+
57
+ ## Conclusion
58
+
59
+ Ship.
60
+
61
+ ## Phase-5 second pass
62
+
63
+ **Not required, and not run** — none of the Phase-5 triggers apply: no block/allow decision, no session lifecycle, no compaction, no coherence gate, trust level, sentinel, guard, gate or watchdog. Saying so explicitly because the section below is a review finding of my own and must not be mistaken for an independent reviewer's concurrence.
64
+
65
+ ## The finding that outlives the fix
66
+
67
+ The defect was not undiscovered. A unit test named "different agents get different threads for same room" existed and PASSED, because a `setTimeout(2)` had been inserted mid-test with the comment *"Small wait to ensure different Date.now() for threadId generation"*. Someone met the collision, understood it precisely enough to describe its cause in one line, and spent that understanding on making the test go green.
68
+
69
+ The test then actively concealed the defect: anyone auditing "is agent isolation tested?" found a green test with the right name. Only the e2e — which had no sleep and no such comment — could still fail, and it did, intermittently, which reads as flake rather than defect.
70
+
71
+ **The class:** a sleep inserted to make a test pass is a defect report written in the wrong file. This is not searched for anywhere in this repo, and I am not claiming otherwise.
72
+
73
+ ## Evidence pointers
74
+
75
+ - e2e failure, run 32674712573: `expected 'openclaw-room-a-mt6h30po' not to be 'openclaw-room-a-mt6h30po'` at `tests/e2e/threadline/ThreadlineFullStack.test.ts:1032`.
76
+ - `tests/unit/threadline/OpenClawBridge.test.ts` 89/89 with the fix.
77
+ - Negative control run: with the entropy removed, exactly 2 of 89 fail — the de-slept original and the new frozen-clock regression. The tests bite.
78
+
79
+ ## Class-Closure Declaration (display-only mirror)
80
+
81
+ The class is "an identifier whose uniqueness rests on wall-clock resolution." Closed for `OpenClawBridge`. NOT closed generally: other id-minting sites in this repo have not been enumerated, and the sibling class named in the second-pass review — a test made green with a sleep — is not swept for at all. Named, not claimed.
@@ -19,7 +19,7 @@ The lint holds no blocking authority anywhere: it ships report-first (exit 0 unl
19
19
 
20
20
  ## 1. Over-block
21
21
 
22
- The narrowing makes 19 existing `physical-credential-locality` markers report findings, and 11 of those were the sole defence of their surface, so those surfaces now also report A1-undefended. **This is the intended effect of the amendment, not an over-block**: the operator's stated reason for Amendment 3 is that the key as written let a storage habit assert a physical constraint, and a narrowing that fails none of the cases it narrowed has narrowed nothing. It cannot over-BLOCK in the literal sense because the lint blocks nothing — total findings move 73122, all report-only. The sweep to fix those 16 markers is separate work and is named as such rather than folded in here.
22
+ The narrowing makes 16 existing `physical-credential-locality` markers report findings, and 9 of those were the sole defence of their surface, so those surfaces now also report A1-undefended. **This is the intended effect of the amendment, not an over-block**: the operator's stated reason for Amendment 3 is that the key as written let a storage habit assert a physical constraint, and a narrowing that fails none of the cases it narrowed has narrowed nothing. It cannot over-BLOCK in the literal sense because the lint blocks nothing — total findings move 94135, all report-only. The sweep to fix those 16 markers is separate work and is named as such rather than folded in here.
23
23
 
24
24
  ## 2. Under-block
25
25