Skip to content

Drop references to a design document that is not in any repo - #12

Merged
fylorn merged 1 commit into
mainfrom
dev
Sep 14, 2026
Merged

fylorn merged 1 commit into
mainfrom
dev

Conversation

@fylorn

@fylorn fylorn commented Sep 14, 2026

Copy link
Copy Markdown
Contributor

What

Same cleanup as ThinkWatchProject/ThinkWatch-Core#8. Comments here cited section numbers — §7.5, §3.5 说这个策略就是, DESIGN.md §2.2.1 — from a design document that exists in none of the three repositories. Following one of those pointers leads nowhere, so they are gone. The reasoning they sat next to is untouched.

Scope

267 lines across 28 files. All but 7 were a citation alone inside its own parentheses and came out by pattern — applied line by line (a pattern with \s* run over a whole file will eat a newline and weld two comment lines together) and only to lines that actually contained a citation, so nothing outside the scope of this change moved.

The other 7 had the citation woven into the sentence rather than set aside in parentheses, and were rewritten by hand so the clause keeps its subject.

Verification

grep -rn '§\|DESIGN\.md' over the tree returns nothing. All four gates pass locally: cargo fmt --check, cargo clippy --all-targets -- -D warnings, pnpm typecheck, 68 tests, pnpm build.

🤖 Generated with Claude Code

Same cleanup as ThinkWatch-Core: comments here cited section numbers
(`§7.5`, `§3.5 说这个策略就是`, `DESIGN.md §2.2.1`) from a design
document that exists in none of the three repositories. Following one
of those pointers leads nowhere, so they are gone; the reasoning they
sat next to is untouched.

267 lines. All but 7 were a citation alone inside its own parentheses
and came out by pattern, applied line by line and only to lines that
actually contained a citation. The other 7 had the citation woven into
the sentence and were rewritten by hand.

Verified: `grep -rn '§|DESIGN\.md'` returns nothing. fmt, clippy,
typecheck, 68 tests and the frontend build all pass.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@fylorn
fylorn merged commit fe36565 into main Sep 14, 2026
5 checks passed
fylorn added a commit that referenced this pull request Sep 20, 2026
"Restore all" on the Clients page, and the uninstall flow that reuses it,
looped over the detected clients and asked core to restore each one by its
display name. Core routes /clients/{id}/restore and looks clients up by id,
so only opencode was ever restored — it is the one client whose id and
display name are the same string. "Claude Code" and "Codex CLI" failed
before the request left the app, because a space cannot go into a URI;
"Zed" and "Aider" came back 404 "unknown client Zed".

Uninstall inherited all of it, and that is where it hurt: the step meant to
hand the user's other software back before this app goes away reported four
failures out of five and left those clients pointing at a gateway that was
about to disappear. The single-client button was never affected — it passes
c.id — so the bug only showed on the path a user takes once, at the moment
they have decided to leave.

Address core by id and keep the display name for what the user reads. The
choice now happens in restore_targets(), which returns (id, name) pairs for
the adopted clients, so a test can pin which field goes into the URL. That
test keeps opencode in the fixture on purpose: an id that happens to equal
its name is what made the wrong field look like it worked.

Also move restore_all's doc comment back onto restore_all — it had been
sitting on quit_app since #12.

Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
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