Repository navigation
fix(telemetry): status after off says measurement was turned off - #1041
Merged
Merged
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VWNxk63AGKkqE8HRqHLjGp
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VWNxk63AGKkqE8HRqHLjGp
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VWNxk63AGKkqE8HRqHLjGp
After `on` then `off`, status and task said the clone had never run `on`. The key `off` that `off` writes now reads as a refusal of its own, `turned-off`, worded with how to measure again. A clone that never ran `on` keeps its words; no JSON carries the reason. Closes #1035 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VWNxk63AGKkqE8HRqHLjGp
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VWNxk63AGKkqE8HRqHLjGp
A clone turned off with a damaged consent log, or with no identity, was told to run `aidd telemetry on`, which then refuses. It now reads `unreadable-consent` there, and `turned-off` only once the log is read. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VWNxk63AGKkqE8HRqHLjGp
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VWNxk63AGKkqE8HRqHLjGp
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.
🎯 What & why
After
aidd telemetry onthenoff,aidd telemetry statusclaimed the clone had never runon. Both cases shared theno-consentreason. Status now says measurement was turned off in this clone, and how to turn it back on.🛠️ How it works
offalready leaves a trace. It sets git configaidd.telemetrytooff, and only on a clone that had consented.turnedOff(reading)(telemetry-consent.ts:49) reads that key, and a key set tooffby hand counts the same.turned-off.unreadable-consent, becauseonwould refuse there. Status never says to run a command that would fail.statusandtask(telemetry-display.ts:72), and neither has--json. The report's refused envelope and itsnot_stored.no-consentcount are unchanged.consentOfis not touched. The fixture shared with the hooks pins"off": "absent", so the hooks and the CLI still agree.🧪 How to verify
Not measured: measurement was turned off in this clone. Run \aidd telemetry on` to measure it again.`aidd telemetry on --yes --anonymousaidd telemetry offaidd telemetry statuscd cli && pnpm test: 6637 passed, 1 skipped.pnpm test:mutation:telemetry: 96.3 (floor 96). Every mutant on a changed line is killed except one equivalent, explained in evidence.md.forget --yesthe key is gone, so status reads "has not runon" again. That is correct, becauseforgeterases everything.2:<token>key whose consent period is closed still readsno-consent. Theonthenoffflow never produces one.🔗 Linked issue
Closes #1035
✅ I certify
🤖 Generated with Claude Code
https://claude.ai/code/session_01VWNxk63AGKkqE8HRqHLjGp