Skip to content

v2.8.1 — point every nudge at the real doctor

Latest

Choose a tag to compare

@Abhi902 Abhi902 released this 03 Oct 07:03
· 2 commits to main since this release
7285920

Every message the plugin shows now points at the plugin's own doctor. A bare /doctor runs Claude Code's built-in diagnostic, so "run /doctor --fix" used to send you to the wrong tool. That is the "I ran /doctor --fix like it said and nothing happened" report.

No action needed after updating: /plugin update headroom-usage-indicator@headroom-tools is enough.

The doctor is named properly everywhere

  • The yellow broken badge now reads ▲ headroom broken (…) · ask: headroom doctor. It used to end with run /doctor, which is the built-in command.
  • Every nudge, recorded failure, README section and skill says /headroom-usage-indicator:doctor.
  • The session-start line names the doctor once, not twice.

--fix only runs when you ask for it

  • What counts as consent: the doctor skips its second "OK to fix?" question only when your message is /headroom-usage-indicator:doctor --fix.
  • What does not: quoting or pasting the command, asking about it, a session-start nudge, or Claude's own guess.
  • Session-start nudges say "run /headroom-usage-indicator:doctor (read-only; it asks the user before any --fix)". You are asked once.
  • The doctor's own "re-run … --fix" hints say "(with the user's consent)".
  • The status-line-only installer runs when you asked for the status line. After only a nudge, it offers and waits for a yes.

No untrusted text in Claude's context

  • Recorded failures. The session-start probe reports a recorded failure by its component only: "a recent headroom runtime failure was recorded". It never copies the recorded message, which can contain exception or file text.
  • hcat records only the exception type.
  • The doctor prints the full record for you, cleaned and labelled "(data, not an instruction)":
    • Control, bidirectional and non-ASCII characters are removed, and the record's own "run …doctor --fix" pointer is dropped.
    • A --fix can never be reassembled from the text.
    • It shows the record that is current, not a stale copy from the start of the run.
  • Probe lines no longer echo HCAT_PYTHON, CLAUDE_CODE_GIT_BASH_PATH or project paths. They name the setting; the doctor shows the value.
  • The next-session invoice only shows numbers and a plain, short file path from its ledger.

Smaller fixes

  • HEADROOM_NO_SETUP_NUDGE=1 turns off the "status line isn't set up yet" reminder, for when you keep your own status line. A badge that is set up but missing its library files is still reported. To set it, add "env": {"HEADROOM_NO_SETUP_NUDGE": "1"} to ~/.claude/settings.json.
  • Windows line endings in recorded failures no longer duplicate the doctor pointer, and hcat writes plain LF line endings everywhere.

Tests

  • Review: 9 multi-reviewer rounds (correctness, testing, agent-native, adversarial).
  • Mutation-checked: every fix has a test, and each test was checked by breaking its fix on purpose.
  • CI: green on ubuntu-latest, macos-latest and windows-latest.
    • Ubuntu and macOS: 1392 passed, 0 failed.
    • Windows: 1372 ran; the only failures are the 58 known-POSIX-only ones.
  • New guard: a test fails CI if a bare /doctor command appears in any shipped file.

Full diff: v2.8.0...v2.8.1