8000 Pre-public leak sweep of comments (#30) by simon-inkie · Pull Request #63 · simon-inkie/inkie-deck · GitHub
[go: up one dir, main page]

Skip to content

Pre-public leak sweep of comments (#30) - #63

Merged
simon-inkie merged 2 commits into
mainfrom
30-leak-sweep-comments
Oct 12, 2026
Merged

simon-inkie merged 2 commits into
mainfrom
30-leak-sweep-comments

Conversation

@simon-inkie
@simon-inkie simon-inkie commented Oct 11, 2026 •
Copy link
Copy Markdown
Owner

Requested by Simon · project thread

Fixes #30

No real secret or credential was found. Test fixtures that look key-shaped are deliberately fake or split.

What was wrong

Comments and doc strings in packages/deck and packages/base still carried private context the pattern gate cannot see: named people credited as the source of a requirement, internal review process, internal tracker ids, dated incident stories, verbatim quotes of requirements, and provenance notes about a private deployment.

What changed

Read-only reviewers read every file; fixes were applied by comment-aware scripts (code untouched), hand edits for narratives, and a final line-by-line repair of every changed comment against its base. The engineering reason was kept in every case; only attribution and context went.

Area Kind of thing What I did
Most packages/deck app, lib, test and e2e files Internal tracker and spec ids in headers and comments Removed the id, kept the description
Same Named people credited with a request or report, in comments Replaced with the role or dropped
Same Review-tool and change-request citations, internal reviewer credits Reworded or dropped
Same Dated incident labels and provenance dates Dropped the date or label, kept the reason
tmux.server.ts, activity.server.ts, instance.server.ts, batch-durability.ts Incident stories, operator quotes, one-deployment assumptions Rewritten as generic design reasons
inbox, inbox-push, pane-idle, stuck-pane-sweep.sh, activity-sweep.sh Deployment provenance, quotes, incident narrative Rewritten generically
inbox-push.test.sh, pane-idle.test.sh Dated captures with named agents; a pane fixture with real product text Dropped names and dates, neutral fixture text
docs/tooling-review.md Statements about named people Reworded

Intended non-comment edits (shipped strings that carried private context), all harmless:

  1. A person's name removed from the default dictation keyterm list (voice-relay.ts, .mjs). Real runtime change, no test either way.
  2. Error text: avatars.server.ts, inbox.server.ts, queue.server.ts, safe-fs.server.ts, start-production.mjs, and root.tsx guidance no longer carry ids or internal agent names.
  3. Generated script header in cron.server.ts (~238) lost an id.
  4. Validation example in projects.server.ts (~496) and placeholder in routes/projects.tsx (~328) now use PROJ-123.
  5. The web manifest description no longer carries a first name.
  6. Test data: neutral user ids and names in instance.test.ts, projects.test.ts and a few fixtures, with asserted values updated to match. No test deleted, skipped or weakened.

Gate (scripts/leak-gate.mjs, now 33 rules): three new rules with split fragments, self-test samples and negative samples: review-tool-citation (a finding word or tool name followed by a change-request number), internal-reviewer-fold-citation, internal-tracker-prefix-in-comment. They are historyExempt only for legacy blobs, meaning blobs reachable from the pinned commit e398eb22; every later blob is scanned with every rule. A missing cut-off fails loudly, the constant is pinned by the self-test, and the self-test proves the bound in a throwaway repo. The tracker-id rule sees lines that start with a comment marker, so an id on an unmarked continuation line of a multi-line JSX comment is a known blind spot (documented in the SPEC).

SPEC: .specs/30-leak-swee 8000 p-comments/SPEC.md, including every review round and how it was addressed.

How verified

  • pnpm typecheck, check:boundaries, check:leaks, check:leaks:history, check:licence, check:lib-version, packages/deck check:dashes: pass.
  • packages/deck tests: 2227 passed, 11 skipped (committed tree).
  • node scripts/leak-gate.mjs --self-test: all 33 rules fire; negative samples hold.

What could not be verified

  • check:leaks:messages is red (23 findings) on commits already on main; none from this branch.
  • packages/base tests: 4 fail here, the same set as on main.
  • check:leaks:history is clean for main plus this PR; a clone with unmerged remote branches reports their pre-sweep blobs.
  • Large test bodies were read by pattern, so stray context in a long test body could remain.

Follow-ups (not done, owner call)

  • The live agent-home directory name appears as a code default, in env examples and tests; renaming changes runtime defaults.
  • Ticket ids remain in e2e test titles, fixture files and parser test data.
  • Two demo fixtures use a small-business theme that reads like a real business. Confirm or neutralise.
  • instance code keys cron admin on hardcoded lowercase user ids, and projects.tsx has one hardcoded second-user option.

🤖 Generated with Claude Code

https://claude.ai/code/session_01QYLVaEQcKynDndX32z2sFE

@simon-inkie simon-inkie self-assigned this Oct 11, 2026
@simon-inkie
Copy link
Copy Markdown
Owner Author

Review: merge after fixes

This is not a comment-only change, and the gate changes need another pass.

Major

  • scripts/leak-gate.mjs (around lines 62, 449, 555): historyExempt switches the new rules off for every historical blob. That also blinds the history check to anything introduced by a FUTURE commit and removed before CI runs. Scope the exemption to a fixed list of known legacy blobs (or a cut-off commit) so new history is still checked. The self-test currently proves the blindness rather than bounding it.
  • scripts/leak-gate.mjs (around lines 367, 400): two of the new patterns are too broad for a public repository. One rejects any ordinary mention of a review tool or merge request reference; the other rejects specific common first names anywhere in content, filenames or commit messages. Ordinary contributions will trip these. Narrow them to the attribution shapes they are meant to catch.
  • packages/base/bin/pane-idle (around line 22): the documented library usage was changed from sourcing the file to executing it. That instruction is now wrong; the source-versus-execute distinction is load-bearing there.

Behaviour changes found (86 non-comment hunks in 36 files; almost all harmless wording or renamed test descriptions): packages/deck/server/voice-relay.mjs (around 265) and voice-relay.ts (around 206) remove one default speech keyterm. That is a real runtime change and should be called out in the description or reverted.

Minor: comments that lost their meaning (9 of 40 sampled)

  • packages/base/bin/stuck-pane-sweep.sh ~383: calibration date deleted while the text still says "on that date".
  • packages/deck/app/lib/cron.server.ts ~594: no longer lists the validations that must stay shared between create and edit.
  • packages/deck/app/lib/inbox.server.ts ~186, 193, 390: broken prose; the comparison being described is gone.
  • packages/deck/app/routes/threads.$agent.tsx ~388, 646, 649, 680: grammatically incomplete; two no longer say which path they explain.
  • packages/deck/app/routes/projects.tsx ~147: dangling punctuation.

No new private material found, no test deleted or weakened, no catastrophic regex.

@simon-inkie
simon-inkie force-pushed the 30-leak-sweep-comments branch from 768404f to a534c9f Compare October 11, 2026 16:29
@simon-inkie
Copy link
Copy Markdown
Owner Author

Third review addressed in a534c9f (branch squashed to one commit so the sweep's own intermediate blobs do not sit outside the history cut-off).

  • historyExempt is now bounded to blobs reachable from the fixed cut-off e398eb22; blobs added later are scanned with 8000 every rule. A missing cut-off fails loudly. The self-test builds a throwaway repo and proves a legacy blob is exempt and a newer one is not.
  • review-tool-citation and person-first-name-in-prose narrowed to attribution shapes; negative samples added for a bare tool mention, a bare MR reference, a bare name and a greeting.
  • pane-idle usage line restored to . "$PANE_IDLE_LIB"; no other leading-dot comment altered.
  • Keyterm removal in voice-relay is intentional and already listed in the description.
  • The listed comments are repaired, and the whole diff was swept for dangling fragments (orphan prepositions, empty parentheses, leftover labels).

Checks: typecheck, boundaries, leaks, history, licence, dashes, lib-version and the gate self-test pass; deck tests 2227 pass; base has the same 4 failures as main.


Generated by Claude Code

@simon-inkie
simon-inkie force-pushed the 30-leak-sweep-comments branch 5 times, most recently from e94576b to df75826 Compare October 11, 2026 20:11
@simon-inkie
Copy link
Copy Markdown
Owner Author

Re-review of df75826: merge after fixes. Much closer. The damaged comments are all repaired, the pane-idle sourcing line is right, the history exemption is now bounded with a loud failure and a real self-test, and no test was deleted, skipped or weakened.

Major

  • scripts/leak-gate.mjs ~402-409, person-first-name-in-prose: still rejects ordinary public sentences. Examples that fail today: "Robin asked whether the example supports Windows." and "This change was requested by Alex in issue Narrator: activity-sweep + stuck-pane-sweep producer for the status panel #12." Those two names are this repository's own neutral placeholders, so the rule fights the docs convention. Either drop first names from the hard gate or restrict the rule to names that are not the documented placeholders. review-tool-citation (~378-385) likewise still rejects a plain statement that a review tool ran on the public pull request.

Minor

  • Comments that still read as one private deployment rather than generic documentation. This is the purpose of the PR, so worth one more pass: packages/deck/app/lib/activity.server.ts 12-24 and 29-30; packages/deck/app/lib/instance.server.ts 4-15, 46-52, 81-101 (assumes exactly two deployed users, inconsistent gendered reference, operational ownership); packages/deck/app/lib/batch-durability.ts 12-19 and 43-50 (incident narrative, stale claim about browser storage).
  • scripts/leak-gate.mjs 60-66: LEGACY_CUTOFF can be advanced by any later change and the self-test would still pass, because it accepts whichever cut-off it is given. Add one assertion that pins the constant to the expected commit, so moving it is a deliberate, visible act.
  • The description says comment-only plus the keyterm removal, but user-visible strings also changed: error text in avatars.server.ts, inbox.server.ts, queue.server.ts, safe-fs.server.ts, start-production.mjs; the generated script header in cron.server.ts ~238; a validation example in projects.server.ts ~496; error guidance in root.tsx ~120; a placeholder in routes/projects.tsx ~328; and the manifest description. All look harmless. Please list them in the description so the next reader does not have to rediscover them.
  • The keyterm removal in voice-relay.mjs / voice-relay.ts is accepted as described. It has no test either way.

Nit

  • packages/deck/scripts/start-production.mjs 126-128: "the front" is undefined. voice-relay.mjs 279-281 and voice-relay.ts 222-224: "real sample of real audio".

No new private material found.

Rewrite private context in code comments and doc strings across
packages/deck and packages/base, keeping the engineering reasons. Add
bounded, attribution-scoped gate rules with self-tests, and a legacy
cut-off so the history scan still checks every new blob.

Signed-off-by: Claude <noreply@anthropic.com>
@simon-inkie
simon-inkie force-pushed the 30-leak-sweep-comments branch from df75826 to af72135 Compare October 11, 2026 20:22
@simon-inkie
Copy link
Copy Markdown
Owner Author

Re-review of af72135: good to merge. The first-name rule is gone, so ordinary sentences no longer trip the gate, and the review-tool rule now needs a change-request reference after the word. The cut-off is pinned in the self-test, the three comments that still read as one deployment (activity, instance, batch-durability) are now generic, and the two nits are fixed. Checks green. One accepted trade-off: with the name rule removed, a real person's first name in a comment is no longer caught by the gate, so that stays a human-review item.

@simon-inkie
Copy link
Copy Markdown
Owner Author

Merge note: this PR conflicts with #62 (overlapping edits in pane-idle and four base test files). #62 is small and is being merged first. Once it is in, please rebase this branch onto main, resolve those files keeping both changes, and re-run the checks. #59, #60 and #61 merge cleanly with this one.

Resolve the inbox-push.test.sh conflict keeping both PR 62's byte-escape
fixtures and this branch's comment repairs. Note the merge in the SPEC.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Uyne7gFXbMnaS8LJMbfDYR
Signed-off-by: Claude <noreply@anthropic.com>
@simon-inkie
simon-inkie merged commit 2e6305c into main Oct 12, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Pre-public leak sweep of comments

2 participants

0