Ask, default no, before Remove Hermes deletes the user's data - #10271
Conversation
|
Reviewed against Codex found no production defect and flagged one low-severity test-rigor gap, which I verified by mutation rather than taking on trust: the assertion at Nothing here blocks the PR; the test gap is a one-line fix if you want it — assert the gum-log contains an arg exactly 🤖 Generated by Sonnet 5 in Claude Code. Reviewed by Codex XHigh. |
Chessing234
left a comment
There was a problem hiding this comment.
default-no confirm before wiping hermes data is the right fail-safe.
|
Re-reviewed at the new head Codex and I independently agree the design pivot itself is sound: no terminal or no gum still preserves everything, the default is still no, only an explicit yes deletes anything, and the prompt now names both paths explicitly so consent stays informed even without the marker. One new low-severity defect, which I reproduced directly rather than took on trust: Two test-rigor gaps, both confirmed by mutating the real script and rerunning the suite rather than by inspection alone: the Nothing here blocks the PR. 🤖 Generated by Sonnet 5 in Claude Code. Reviewed by Codex XHigh. |
Ask, default no, before Remove Hermes deletes the user's data (cherry picked from commit 959e49d) (cherry picked from commit 4e77199945a15ac194511b1af6317761fb813ba0)
Ask, default no, before Remove Hermes deletes the user's data (cherry picked from commit 959e49d) (cherry picked from commit 4e77199945a15ac194511b1af6317761fb813ba0)
Remove > AI > Hermes keeps the user's data silently today: the chats, memories and skills in
~/.hermes, the connections and their encrypted tokens in~/.config/Hermes. Keeping them stays the default, but a removal meant to be complete currently ends with two paths to delete by hand — the tokens among them. This brings over the flow #10246 introduced for OpenClaw: after the teardown, when there is a terminal to ask in and gum to ask with, offer —gum confirm --default=false, size shown — to delete that data too.Where the two differ, and why this version stays smaller than OpenClaw's:
~/.openclawcannot be split: chats and credentials share one tree with hundreds of megabytes of plugin runtimes. Hermes' tree splits, and the remover already deletes the heavy disposable runtime unasked (gated on the bootstrap marker), so the question here covers only what is left after that.~/.hermesstill carries a runtime the app never owned, a yes knowingly takes that with it; a decline — and the silent path — still touches none of it.One incidental hardening: the size probe tolerates a missing directory, where
du's non-zero exit would otherwise abort the removal throughpipefail.Verified
test/shell.d/hermes-remove-test.sh: 15 ok, six of them new — no prompt without a terminal, ask-and-decline keeps everything (with and without the bootstrap marker), an explicit yes takes~/.hermesand~/.config/Hermes(again both sides of the marker), and a runtime the app never installed is never touched by anything short of that yes. The interactive cases put the remover on a pty withscript(1)and answer through a stubbed gum, so no test ever depends on where the suite itself runs. The manual's Hermes paragraph now says the removal asks.