Skip to content

fix(branding): rtk instructions / rtk: / rtk telemetry leaks (user-reported) - #61

Merged
thehoff merged 1 commit into
developfrom
fix/branding-rtk-instructions
May 18, 2026
Merged

thehoff merged 1 commit into
developfrom
fix/branding-rtk-instructions

Conversation

@thehoff

@thehoff thehoff commented May 18, 2026

Copy link
Copy Markdown
Owner

Summary

User reported contextcrawler init --global --claude-md printing Added rtk instructions to existing /home/.../CLAUDE.md — branding leak that escaped PR #25's rebrand sweep + PR #20/#23's pinning lint.

The lint covered [rtk], [rtk:, RTK.md, @RTK.md but not other "rtk" phrases. Extending it caught 10 more "rtk: " leaks the user hadn't reported yet — all fixed in this PR.

Production fixes (19 strings, 8 files)

File Hits What
src/hooks/init.rs 8 "rtk instructions" → "contextcrawler instructions" (reported leak)
src/main.rs 3 doc comment + 2 "rtk: " error prefixes
src/core/telemetry_cmd.rs 3 "rtk telemetry disable" CLI ref + 2 "rtk: " prefixes
src/discover/registry.rs 2 "rtk: " prefixes
src/core/utils.rs 2 "rtk: " prefixes
src/hooks/integrity.rs 2 "rtk: " prefixes
src/cmds/system/read.rs 1 "rtk: " prefix
src/cmds/cloud/aws_cmd.rs 1 "rtk: " prefix

Lint extended

FORBIDDEN_TOKENS now also catches:

  • "rtk instructions" — reported leak
  • "\"rtk: " — error prefix in unstructured stderr (leading " avoids substring false positives)
  • "rtk telemetry" — CLI command reference in user-facing text

Out of scope (separate decision)

src/core/telemetry_cmd.rs still cites "RTK AI Labs" as data controller and the upstream rtk-ai/rtk TELEMETRY.md URL. That's factual attribution of who operates the upstream collector, not a branding leak. The downstream fork's telemetry posture (disable / re-attribute / keep) is a separate scope decision.

Verified

  • cargo build clean
  • cargo test --bin contextcrawler — 2156 pass / 0 fail
  • All 9 integration suites green
  • Empirical (user's exact case): init --global --claude-md --dry-run now prints would add contextcrawler instructions ...

Reported in-session via user testing of the deployed binary.

…n user-visible strings

User reported `contextcrawler init --global --claude-md` printing
"Added rtk instructions to existing ..." -- a branding leak that
escaped the rebrand sweep (PR #25) and the pinning lint
(tests/branding_lint.rs added in PRs #20/#23).

The pinning lint covered `[rtk]`, `[rtk:`, `RTK.md`, `@RTK.md`
literals but not other user-visible "rtk" phrases.

## Fixes (production source)

- `src/hooks/init.rs` -- 8x "rtk instructions" -> "contextcrawler
  instructions" (the reported leak)
- `src/main.rs` -- doc comment "Initialize rtk instructions" +
  two `eprintln!("rtk: ...")` error prefixes
- `src/core/telemetry_cmd.rs` -- "rtk telemetry disable" command
  reference in user prompt + 2x "rtk: " error prefixes
- `src/discover/registry.rs` -- 2x "rtk: " error prefixes
- `src/core/utils.rs` -- 2x "rtk: " error prefixes
- `src/cmds/system/read.rs` -- "rtk: " error prefix
- `src/cmds/cloud/aws_cmd.rs` -- "rtk: " error prefix
- `src/hooks/integrity.rs` -- 2x "rtk: " error prefixes

Total: 19 production-source replacements across 8 files.

## Branding lint extended (issue #20/#23 lineage)

`tests/branding_lint.rs::FORBIDDEN_TOKENS` now also catches:
- `"rtk instructions"` -- the reported leak
- `"\"rtk: "` -- error prefix in unstructured stderr (note the
  leading `"` so it only matches the start of a string literal,
  avoiding false positives on `"my-rtk: x"` substrings)
- `"rtk telemetry"` -- CLI command reference in user-facing text

The expanded lint immediately caught the 10 other "rtk: " leaks
that the user hadn't reported yet -- fixed in the same PR.

## Out of scope (separate scope question)

`src/core/telemetry_cmd.rs` still attributes the data controller
as "RTK AI Labs" with the upstream rtk-ai/rtk TELEMETRY.md link.
That's a factual statement about who operates the upstream
collector -- not a branding leak. Whether the downstream fork
should: (a) disable telemetry entirely, (b) re-attribute, or
(c) keep upstream attribution requires a decision separately.

## Verified

- cargo build clean
- cargo test --bin contextcrawler: 2156 pass / 0 fail
- All 9 integration suites green
- Empirical: `contextcrawler init --global --claude-md --dry-run`
  now prints "Added contextcrawler instructions ..."

Reported in-session via user testing of the deployed binary.
@thehoff
thehoff merged commit 53e5f59 into develop May 18, 2026
3 checks passed
@thehoff
thehoff deleted the fix/branding-rtk-instructions branch May 18, 2026 13:02
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.

1 participant